@para-ui/core 4.0.0-rc → 4.0.0-rc.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (250) hide show
  1. package/AutoBox/index.d.ts +1 -1
  2. package/AutoBox/index.js +12 -12
  3. package/AutoTips/autoTipsMultiline/index.d.ts +1 -1
  4. package/AutoTips/index.d.ts +2 -2
  5. package/AutoTips/index.js +12 -12
  6. package/Badge/index.d.ts +23 -0
  7. package/Badge/index.js +54 -0
  8. package/Breadcrumbs/index.js +8 -8
  9. package/Button/SplitButton.d.ts +1 -1
  10. package/Button/index.d.ts +1 -1
  11. package/Button/index.js +3 -3
  12. package/Carousel/index.d.ts +6 -6
  13. package/Carousel/index.js +5 -5
  14. package/Cascader/Cascader.d.ts +10 -10
  15. package/Cascader/OptionList/Column.d.ts +3 -3
  16. package/Cascader/OptionList/index.d.ts +2 -2
  17. package/Cascader/index.d.ts +1 -1
  18. package/Cascader/index.js +4 -2
  19. package/Cascader/lang/en_US.d.ts +5 -0
  20. package/Cascader/lang/index.d.ts +11 -0
  21. package/Cascader/lang/zh_CN.d.ts +5 -0
  22. package/Cascader/utils/treeUtil.d.ts +1 -1
  23. package/Checkbox/index.d.ts +1 -1
  24. package/Checkbox/index.js +4 -4
  25. package/CheckboxGroup/index.d.ts +2 -2
  26. package/CheckboxGroup/index.js +3 -3
  27. package/Collapse/index.js +4 -4
  28. package/CollapseBox/index.js +12 -20
  29. package/CollapseLayout/index.js +20 -20
  30. package/ColorPicker/index.js +2 -2
  31. package/ComboSelect/index.js +43 -52
  32. package/ComboSelect/interface.d.ts +3 -3
  33. package/Container/index.d.ts +3 -3
  34. package/Container/index.js +56 -56
  35. package/CopyText/index.d.ts +2 -2
  36. package/DatePicker/generatePicker/index.d.ts +22 -22
  37. package/DatePicker/index.js +8 -7
  38. package/DatePicker/util.d.ts +1 -1
  39. package/Desktop/index.d.ts +1 -1
  40. package/Desktop/index.js +18 -13
  41. package/DragVerify/index.d.ts +1 -1
  42. package/DragVerify/index.js +13 -13
  43. package/Drawer/index.js +29 -33
  44. package/Drawer/interface.d.ts +2 -2
  45. package/Dropdown/index.d.ts +1 -1
  46. package/DynamicMultiBox/formItem.d.ts +1 -1
  47. package/DynamicMultiBox/index.d.ts +1 -1
  48. package/DynamicMultiBox/index.js +38 -35
  49. package/DynamicMultiBox/interface.d.ts +8 -8
  50. package/DynamicMultiBox/rowForm.d.ts +3 -1
  51. package/Empty/index.d.ts +1 -1
  52. package/Empty/index.js +2 -2
  53. package/Form/index.d.ts +12 -13
  54. package/Form/index.js +10 -8
  55. package/FormItem/compoments/defaultCompoments/index.d.ts +4 -4
  56. package/FormItem/compoments/formCheckboxGroup/index.d.ts +1 -1
  57. package/FormItem/compoments/formFile/index.d.ts +2 -2
  58. package/FormItem/compoments/formRadioGroup/index.d.ts +1 -1
  59. package/FormItem/compoments/formSelect/index.d.ts +7 -7
  60. package/FormItem/errorTips.d.ts +3 -3
  61. package/FormItem/index.d.ts +5 -5
  62. package/FormItem/index.js +3 -2
  63. package/FormItem/lang/en_US.d.ts +10 -0
  64. package/FormItem/lang/index.d.ts +21 -0
  65. package/FormItem/lang/zh_CN.d.ts +10 -0
  66. package/FormItem/validateFunction.d.ts +1 -1
  67. package/FunctionModal/dialog.d.ts +26 -26
  68. package/FunctionModal/index.d.ts +6 -6
  69. package/FunctionModal/index.js +6 -6
  70. package/FunctionModal/modalContext.d.ts +3 -3
  71. package/GlobalContext/componentsProps.d.ts +7 -7
  72. package/GlobalContext/index.d.ts +2 -2
  73. package/GlobalContext/useFormatMessage.d.ts +1 -1
  74. package/Help/index.js +1 -1
  75. package/HelperText/index.js +1 -1
  76. package/InputLang/index.d.ts +2 -2
  77. package/InputLang/index.js +8 -8
  78. package/InputNumber/index.d.ts +2 -2
  79. package/InputNumber/index.js +3 -3
  80. package/Label/index.js +2 -2
  81. package/Loading/index.js +1 -1
  82. package/Menu/index.js +14 -14
  83. package/Menu/interface.d.ts +1 -1
  84. package/Message/index.js +12 -12
  85. package/Modal/Confirm/index.d.ts +3 -3
  86. package/Modal/index.d.ts +1 -1
  87. package/Modal/index.js +5 -5
  88. package/MultiBox/index.d.ts +2 -2
  89. package/MultiBox/index.js +3 -3
  90. package/Notification/index.js +1 -1
  91. package/OperateBtn/index.d.ts +2 -2
  92. package/OperateBtn/index.js +40 -36
  93. package/PageHeader/index.js +30 -30
  94. package/PageHeader/interface.d.ts +1 -1
  95. package/Pagination/index.d.ts +1 -1
  96. package/Pagination/index.js +17 -17
  97. package/PasswordRules/index.js +7 -7
  98. package/PopConfirm/index.js +3 -3
  99. package/Progress/Line.d.ts +10 -10
  100. package/Progress/Steps.d.ts +2 -2
  101. package/Progress/index.d.ts +12 -12
  102. package/Progress/index.js +40 -40
  103. package/Progress/utils.d.ts +4 -4
  104. package/Querying/index.d.ts +1 -1
  105. package/Querying/index.js +2 -2
  106. package/README.md +3 -0
  107. package/Radio/index.d.ts +1 -1
  108. package/Radio/index.js +4 -4
  109. package/RadioGroup/index.d.ts +2 -2
  110. package/RadioGroup/index.js +3 -3
  111. package/Search/index.js +1 -1
  112. package/Select/index.d.ts +3 -3
  113. package/Select/index.js +42 -42
  114. package/SelectInput/index.js +2 -2
  115. package/Selector/index.js +15 -15
  116. package/Selector/interface.d.ts +6 -6
  117. package/SelectorPicker/index.d.ts +4 -4
  118. package/SelectorPicker/index.js +9 -9
  119. package/SingleBox/index.d.ts +2 -2
  120. package/SingleBox/index.js +3 -3
  121. package/Slider/interface.d.ts +1 -1
  122. package/Status/index.d.ts +4 -4
  123. package/Status/index.js +4 -4
  124. package/Stepper/index.d.ts +5 -5
  125. package/Stepper/index.js +23 -23
  126. package/Switch/index.d.ts +7 -7
  127. package/Switch/index.js +23 -5
  128. package/Switch/lang/en_US.d.ts +4 -0
  129. package/Switch/lang/index.d.ts +9 -0
  130. package/Switch/lang/zh_CN.d.ts +4 -0
  131. package/Table/index.js +34 -34
  132. package/Table/interface.d.ts +4 -4
  133. package/Table/tableBodyElement/index.d.ts +1 -1
  134. package/Table/tableBodyInterface.d.ts +2 -2
  135. package/Table/tableContainer/index.d.ts +1 -1
  136. package/Table/tableElement/index.d.ts +1 -1
  137. package/Table/tableHeadElement/index.d.ts +1 -1
  138. package/Table/tableHeadInterface.d.ts +1 -1
  139. package/Table/tablePaginationInterface.d.ts +6 -6
  140. package/Table/tdElement/index.d.ts +1 -1
  141. package/Table/thElement/index.d.ts +2 -2
  142. package/Table/trElement/index.d.ts +1 -1
  143. package/Table/util.d.ts +1 -1
  144. package/Tabs/index.d.ts +1 -1
  145. package/Tabs/index.js +25 -17
  146. package/Tag/TagGroup.d.ts +5 -5
  147. package/Tag/index.d.ts +7 -7
  148. package/Tag/index.js +25 -25
  149. package/TextEditor/index.d.ts +2 -2
  150. package/TextEditor/index.js +45 -27
  151. package/TextEditor/lang/en_US.d.ts +4 -0
  152. package/TextEditor/lang/index.d.ts +9 -0
  153. package/TextEditor/lang/zh_CN.d.ts +4 -0
  154. package/TextField/index.d.ts +1 -1
  155. package/TextField/index.js +13 -13
  156. package/TimePicker/index.d.ts +1 -1
  157. package/TimePicker/index.js +1 -1
  158. package/Timeline/TimelineItem.d.ts +1 -1
  159. package/Timeline/index.d.ts +5 -5
  160. package/Timeline/index.js +14 -14
  161. package/Title/index.d.ts +4 -4
  162. package/Title/index.js +3 -3
  163. package/ToggleButton/ToggleButtonGroup.d.ts +1 -1
  164. package/ToggleButton/index.d.ts +5 -1
  165. package/ToggleButton/index.js +17 -10
  166. package/Transfer/box.d.ts +6 -6
  167. package/Transfer/index.js +21 -21
  168. package/Tree/OperateBar/index.d.ts +4 -4
  169. package/Tree/Tree.d.ts +2 -2
  170. package/Tree/index.js +2 -2
  171. package/Tree/interface.d.ts +4 -4
  172. package/Tree/utils/tools.d.ts +1 -1
  173. package/Upload/Dragger/index.d.ts +2 -2
  174. package/Upload/ErroTip/index.d.ts +1 -1
  175. package/Upload/index.d.ts +2 -2
  176. package/Upload/index.js +7 -7
  177. package/Upload/interface.d.ts +1 -1
  178. package/_verture/{index-8469865e.js → index-0f315bca.js} +2 -2
  179. package/_verture/{index-e1b800aa.js → index-92e406f4.js} +48 -24
  180. package/_verture/{index-47297a40.js → index-bc461491.js} +45 -45
  181. package/_verture/{index-1c8d3e94.js → index-d251967e.js} +101 -47
  182. package/_verture/{modalContext-670eab09.js → modalContext-9299acc9.js} +25 -25
  183. package/index.d.ts +2 -0
  184. package/index.js +8 -7
  185. package/locale/en-US.d.ts +19 -0
  186. package/locale/index.d.ts +38 -0
  187. package/locale/index.js +39 -1
  188. package/locale/zh-CN.d.ts +19 -0
  189. package/package.json +3 -1
  190. package/umd/AutoBox.js +1 -1
  191. package/umd/AutoTips.js +1 -1
  192. package/umd/Badge.js +1 -0
  193. package/umd/Breadcrumbs.js +1 -1
  194. package/umd/Button.js +2 -2
  195. package/umd/ButtonGroup.js +2 -2
  196. package/umd/Cascader.js +5 -5
  197. package/umd/Checkbox.js +1 -1
  198. package/umd/CheckboxGroup.js +1 -1
  199. package/umd/Collapse.js +1 -1
  200. package/umd/CollapseBox.js +1 -1
  201. package/umd/CollapseLayout.js +4 -4
  202. package/umd/ComboSelect.js +4 -4
  203. package/umd/CopyText.js +1 -1
  204. package/umd/DatePicker.js +2 -2
  205. package/umd/Desktop.js +2 -2
  206. package/umd/DragVerify.js +4 -4
  207. package/umd/Drawer.js +2 -2
  208. package/umd/DynamicMultiBox.js +4 -4
  209. package/umd/Form.js +4 -4
  210. package/umd/FormItem.js +4 -4
  211. package/umd/FunctionModal.js +2 -2
  212. package/umd/Help.js +1 -1
  213. package/umd/HelperText.js +1 -1
  214. package/umd/InputLang.js +1 -1
  215. package/umd/InputNumber.js +1 -1
  216. package/umd/Label.js +1 -1
  217. package/umd/Loading.js +1 -1
  218. package/umd/Menu.js +2 -2
  219. package/umd/Message.js +1 -1
  220. package/umd/Modal.js +2 -2
  221. package/umd/MultiBox.js +7 -7
  222. package/umd/Notification.js +1 -1
  223. package/umd/OperateBtn.js +2 -2
  224. package/umd/PageHeader.js +2 -2
  225. package/umd/Pagination.js +4 -4
  226. package/umd/PasswordRules.js +4 -4
  227. package/umd/PopConfirm.js +2 -2
  228. package/umd/Progress.js +1 -1
  229. package/umd/Radio.js +1 -1
  230. package/umd/RadioGroup.js +1 -1
  231. package/umd/Search.js +7 -7
  232. package/umd/Select.js +1 -1
  233. package/umd/SelectInput.js +1 -1
  234. package/umd/Selector.js +1 -1
  235. package/umd/SelectorPicker.js +1 -1
  236. package/umd/SingleBox.js +1 -1
  237. package/umd/Stepper.js +1 -1
  238. package/umd/Switch.js +4 -4
  239. package/umd/Table.js +2 -2
  240. package/umd/Tabs.js +4 -4
  241. package/umd/Tag.js +1 -1
  242. package/umd/TextEditor.js +2 -2
  243. package/umd/TextField.js +7 -7
  244. package/umd/TimePicker.js +2 -2
  245. package/umd/Title.js +1 -1
  246. package/umd/ToggleButton.js +4 -4
  247. package/umd/Transfer.js +2 -2
  248. package/umd/Tree.js +1 -1
  249. package/umd/Upload.js +2 -2
  250. package/umd/locale.js +1 -1
package/Progress/index.js CHANGED
@@ -18,11 +18,11 @@ var Steps = function Steps(props) {
18
18
  trailColor = props.trailColor,
19
19
  children = props.children;
20
20
  /** 计算出应该高亮多少步 **/
21
- var current = typeof percent === "number" ? Math.round(steps * (percent / 100)) : 1;
21
+ var current = typeof percent === 'number' ? Math.round(steps * (percent / 100)) : 1;
22
22
  var styledSteps = [];
23
23
  for (var i = 0; i < steps; i += 1) {
24
24
  styledSteps.push(jsx("div", {
25
- className: i <= current - 1 ? "steps-item steps-item-active" : "steps-item",
25
+ className: i <= current - 1 ? 'steps-item steps-item-active' : 'steps-item',
26
26
  style: {
27
27
  backgroundColor: i <= current - 1 ? strokeColor : trailColor,
28
28
  width: 14,
@@ -38,10 +38,10 @@ var Steps = function Steps(props) {
38
38
  };
39
39
 
40
40
  /**
41
- * 判断进度条传的百分比参数是否规范
42
- * @param {number | undefined} progress 方法入参说明
43
- * @return {numner} 百分比值
44
- */
41
+ * 判断进度条传的百分比参数是否规范
42
+ * @param {number | undefined} progress 方法入参说明
43
+ * @return {numner} 百分比值
44
+ */
45
45
  function validProgress(progress) {
46
46
  if (!progress || progress < 0) {
47
47
  return 0;
@@ -53,7 +53,7 @@ function validProgress(progress) {
53
53
  }
54
54
 
55
55
  /**
56
- * 转换 百分比 到 样式格式
56
+ * 转换 百分比 到 样式格式
57
57
  * {
58
58
  * "0%": "#afc163",
59
59
  * "75%": "#009900",
@@ -61,14 +61,14 @@ function validProgress(progress) {
61
61
  * "25%": "#66FF00",
62
62
  * "100%": "#ffffff"
63
63
  * }
64
- * @param gradients 渐变的参数
65
- * @return {string} 样式值
66
- */
64
+ * @param gradients 渐变的参数
65
+ * @return {string} 样式值
66
+ */
67
67
  var sortGradient = function sortGradient(gradients) {
68
68
  var tempArr = [];
69
69
  Object.keys(gradients).forEach(function (key) {
70
70
  // 拿到百分比的数字
71
- var formattedKey = parseFloat(key.replace(/%/g, ""));
71
+ var formattedKey = parseFloat(key.replace(/%/g, ''));
72
72
  // 进行序列化
73
73
  if (!isNaN(formattedKey)) {
74
74
  tempArr.push({
@@ -85,10 +85,10 @@ var sortGradient = function sortGradient(gradients) {
85
85
  var key = _ref.key,
86
86
  value = _ref.value;
87
87
  return "".concat(value, " ").concat(key, "%");
88
- }).join(", ");
88
+ }).join(', ');
89
89
  };
90
90
  /**
91
- * 转换传进来 渐变的参数 为css样式
91
+ * 转换传进来 渐变的参数 为css样式
92
92
  * {
93
93
  * "0%": "#afc163",
94
94
  * "25%": "#66FF00",
@@ -102,16 +102,16 @@ var sortGradient = function sortGradient(gradients) {
102
102
  * "to": "#66FF00",// ====> linear-gradient(to right, #afc163, #66FF00)
103
103
  * }
104
104
  *
105
- * @param {string} strokeColor 颜色值
106
- * @return 返回 backgroundImage 的样式值
107
- */
105
+ * @param {string} strokeColor 颜色值
106
+ * @return 返回 backgroundImage 的样式值
107
+ */
108
108
  var handleGradient = function handleGradient(strokeColor, directionConfig) {
109
109
  var _strokeColor$from = strokeColor.from,
110
- from = _strokeColor$from === void 0 ? "#3D66F8" : _strokeColor$from,
110
+ from = _strokeColor$from === void 0 ? '#3D66F8' : _strokeColor$from,
111
111
  _strokeColor$to = strokeColor.to,
112
- to = _strokeColor$to === void 0 ? "#4F93F0" : _strokeColor$to,
112
+ to = _strokeColor$to === void 0 ? '#4F93F0' : _strokeColor$to,
113
113
  _strokeColor$directio = strokeColor.direction,
114
- direction = _strokeColor$directio === void 0 ? directionConfig === "rtl" ? "to left" : "to right" : _strokeColor$directio,
114
+ direction = _strokeColor$directio === void 0 ? directionConfig === 'rtl' ? 'to left' : 'to right' : _strokeColor$directio,
115
115
  rest = __rest(strokeColor, ["from", "to", "direction"]);
116
116
  // 剩余参数有值说明除了from to direction 还传了 另外的参数
117
117
  if (Object.keys(rest).length !== 0) {
@@ -132,7 +132,7 @@ var Line = function Line(props) {
132
132
  strokeLinecap = props.strokeLinecap,
133
133
  trailColor = props.trailColor;
134
134
  /** 进度条高亮部分的颜色样式 **/
135
- var backgroundProps = strokeColor && typeof strokeColor !== "string" ? handleGradient(strokeColor, directionConfig) : {
135
+ var backgroundProps = strokeColor && typeof strokeColor !== 'string' ? handleGradient(strokeColor, directionConfig) : {
136
136
  background: strokeColor
137
137
  };
138
138
  /** 进度条轨道部分的颜色样式 **/
@@ -143,7 +143,7 @@ var Line = function Line(props) {
143
143
  var percentStyle = Object.assign({
144
144
  width: "".concat(validProgress(percent), "%"),
145
145
  height: strokeWidth || 8,
146
- borderRadius: strokeLinecap === "square" ? 0 : ""
146
+ borderRadius: strokeLinecap === 'square' ? 0 : ''
147
147
  }, backgroundProps);
148
148
  return jsx("div", Object.assign({
149
149
  className: "trail-bar",
@@ -176,14 +176,14 @@ var ProgressStatuses;
176
176
  })(ProgressStatuses || (ProgressStatuses = {}));
177
177
  /** 每个类型对应的进度条默认颜色 **/
178
178
  var strokeColorMap = {
179
- success: "rgba(19, 191, 76, 1)",
180
- exception: "rgba(244, 66, 66, 1)",
181
- normal: "rgba(46, 101, 230, 1)",
182
- active: "rgba(46, 101, 230, 1)"
179
+ success: 'rgba(19, 191, 76, 1)',
180
+ exception: 'rgba(244, 66, 66, 1)',
181
+ normal: 'rgba(46, 101, 230, 1)',
182
+ active: 'rgba(46, 101, 230, 1)'
183
183
  };
184
184
  var Progress = function Progress(props) {
185
185
  var _props$type = props.type,
186
- type = _props$type === void 0 ? "line" : _props$type,
186
+ type = _props$type === void 0 ? 'line' : _props$type,
187
187
  className = props.className,
188
188
  style = props.style;
189
189
  props.children;
@@ -207,14 +207,14 @@ var Progress = function Progress(props) {
207
207
  * @return {string}
208
208
  */
209
209
  var classString = function classString() {
210
- var str = "".concat($prefixCls, "-progress ").concat($prefixCls, "-progress-").concat(type || "default");
210
+ var str = "".concat($prefixCls, "-progress ").concat($prefixCls, "-progress-").concat(type || 'default');
211
211
  // 添加成功状态的class
212
212
  if (isSuccessStatus) str += " ".concat($prefixCls, "-progress-success-status");
213
213
  // 添加错误状态下的class
214
- if (status === "exception") str += " ".concat($prefixCls, "-progress-exception-status");
214
+ if (status === 'exception') str += " ".concat($prefixCls, "-progress-exception-status");
215
215
  // 添加active状态下的class
216
- if (status === "active") str += " ".concat($prefixCls, "-progress-active-status");
217
- if (className) str += " " + className;
216
+ if (status === 'active') str += " ".concat($prefixCls, "-progress-active-status");
217
+ if (className) str += " ".concat(className);
218
218
  return str;
219
219
  };
220
220
  /**
@@ -225,24 +225,24 @@ var Progress = function Progress(props) {
225
225
  // 如果传了成功进度条的配置
226
226
  if (strokeColor) return strokeColor;
227
227
  if (success && success.percent < percent) {
228
- return [success.strokeColor || strokeColorMap["success"], strokeColorMap["normal"]];
228
+ return [success.strokeColor || strokeColorMap['success'], strokeColorMap['normal']];
229
229
  }
230
- return isSuccessStatus ? strokeColorMap["success"] : strokeColorMap[status || "normal"];
230
+ return isSuccessStatus ? strokeColorMap['success'] : strokeColorMap[status || 'normal'];
231
231
  };
232
232
  /**
233
233
  * 处理进度条的值
234
234
  * @return {string}
235
235
  */
236
236
  var renderPercent = function renderPercent() {
237
- if (success && success.percent < percent && typeof percent === "number") {
237
+ if (success && success.percent < percent && typeof percent === 'number') {
238
238
  return [success.percent, percent - success.percent];
239
239
  }
240
240
  return percent;
241
241
  };
242
242
  /** 标记是不是成功状态 **/
243
- var isSuccessStatus = percent && percent === 100 && !status || status === "success";
243
+ var isSuccessStatus = percent && percent === 100 && !status || status === 'success';
244
244
  /** style值 **/
245
- var renderStyle = type === "circle" || type === "dashboard" ? {
245
+ var renderStyle = type === 'circle' || type === 'dashboard' ? {
246
246
  width: width,
247
247
  height: width
248
248
  } : {};
@@ -252,17 +252,17 @@ var Progress = function Progress(props) {
252
252
  */
253
253
  var renderLabel = function renderLabel() {
254
254
  if (format) return format(percent);
255
- if (isSuccessStatus) return type === "circle" ? jsx(Check, {
255
+ if (isSuccessStatus) return type === 'circle' ? jsx(Check, {
256
256
  className: "success"
257
257
  }) : jsx(CompleteIcon, {
258
258
  className: "success"
259
259
  });
260
- if (status === "exception") return type === "circle" ? jsx(CloseIcon, {
260
+ if (status === 'exception') return type === 'circle' ? jsx(CloseIcon, {
261
261
  className: "error"
262
262
  }) : jsx(CloseCircleF, {
263
263
  className: "error"
264
264
  });
265
- return validProgress(percent) + "%";
265
+ return "".concat(validProgress(percent), "%");
266
266
  };
267
267
  /** 默认进度条 **/
268
268
  var renderLineProgress = steps ? jsx(Steps, Object.assign({
@@ -280,7 +280,7 @@ var Progress = function Progress(props) {
280
280
  percent: renderPercent(),
281
281
  direction: direction
282
282
  }, otherProps, {
283
- children: " "
283
+ children: ' '
284
284
  }));
285
285
  /** 圆形进度条 **/
286
286
  var renderCircleProgress = jsx(Circle, Object.assign({
@@ -311,7 +311,7 @@ var Progress = function Progress(props) {
311
311
  className: "progress-inner",
312
312
  style: renderStyle
313
313
  }, {
314
- children: type === "dashboard" ? renderDashboardProgress : type === "circle" ? renderCircleProgress : renderLineProgress
314
+ children: type === 'dashboard' ? renderDashboardProgress : type === 'circle' ? renderCircleProgress : renderLineProgress
315
315
  })), showInfo && !steps && jsx("div", Object.assign({
316
316
  className: "progress-text"
317
317
  }, {
@@ -1,6 +1,6 @@
1
1
  /**
2
- * 判断进度条传的百分比参数是否规范
3
- * @param {number | undefined} progress 方法入参说明
4
- * @return {numner} 百分比值
5
- */
2
+ * 判断进度条传的百分比参数是否规范
3
+ * @param {number | undefined} progress 方法入参说明
4
+ * @return {numner} 百分比值
5
+ */
6
6
  export declare function validProgress(progress: number | number[] | undefined): number | number[];
@@ -3,7 +3,7 @@
3
3
  * @date 2022/4/2 上午10:45
4
4
  * @description
5
5
  */
6
- import React, { FC } from "react";
6
+ import React, { FC } from 'react';
7
7
  import './index.scss';
8
8
  export interface QueryingProps {
9
9
  /** cls */
package/Querying/index.js CHANGED
@@ -709,8 +709,8 @@ var css_248z = "@charset \"UTF-8\";\n/**\n* @author Hanz\n* @date 2022/4/2 上
709
709
  styleInject(css_248z);
710
710
 
711
711
  var imageMap = {
712
- 'large': jsx(LargeSearch, {}),
713
- 'small': jsx(SmallSearch, {})
712
+ large: jsx(LargeSearch, {}),
713
+ small: jsx(SmallSearch, {})
714
714
  };
715
715
  //Querying 查询中
716
716
  var Querying = function Querying(props) {
package/README.md CHANGED
@@ -26,6 +26,9 @@
26
26
  【通知提示框-Notification】支持移除closeIcon
27
27
 
28
28
  【linhd】
29
+ 【动态多值框-DynamicMultiBox】没有拖拽,valueList不生成chosen,selected字段
30
+ 【动态多值框-DynamicMultiBox】增加labelProps参数,用来修改标题
31
+ 【动态多值框-DynamicMultiBox】增加rowKey,用来自定义每行的唯一id
29
32
  【输入框-TextField】修复输入框存在焦点,点击输入框,触发onBlur事件
30
33
  【下拉框-Select】去除searchModel为inside,自动得到焦点,防止页面上下抖动
31
34
  【下拉框-Select】修复下拉框闪烁渲染
package/Radio/index.d.ts CHANGED
@@ -5,7 +5,7 @@
5
5
  */
6
6
  import React, { FunctionComponent, ReactNode } from 'react';
7
7
  import { LabelTooltipProps } from '../Label';
8
- import { TooltipProps } from "../Tooltip";
8
+ import { TooltipProps } from '../Tooltip';
9
9
  import './index.scss';
10
10
  export interface RadioProps {
11
11
  /** 样式class */
package/Radio/index.js CHANGED
@@ -52,8 +52,8 @@ var Radio = function Radio(props) {
52
52
  };
53
53
  // 处理className
54
54
  var handClass = function handClass() {
55
- var str = $prefixCls + '-radio';
56
- if (className) str += ' ' + className;
55
+ var str = "".concat($prefixCls, "-radio");
56
+ if (className) str += " ".concat(className);
57
57
  if (size) str += " ".concat($prefixCls, "-radio-").concat(size);
58
58
  if (disabled) str += " ".concat($prefixCls, "-radio-disabled");
59
59
  if (checkedCom) str += " ".concat($prefixCls, "-radio-checked");
@@ -62,7 +62,7 @@ var Radio = function Radio(props) {
62
62
  var handLabelClass = function handLabelClass() {
63
63
  var str = 'radio-label';
64
64
  if (labelTooltip && labelTooltip.className) {
65
- str += ' ' + labelTooltip.className;
65
+ str += " ".concat(labelTooltip.className);
66
66
  }
67
67
  return str;
68
68
  };
@@ -70,7 +70,7 @@ var Radio = function Radio(props) {
70
70
  var handHelpClassName = function handHelpClassName() {
71
71
  var str = ' radio-help';
72
72
  if (labelTooltip && labelTooltip.helpClassName) {
73
- str += ' ' + labelTooltip.helpClassName;
73
+ str += " ".concat(labelTooltip.helpClassName);
74
74
  }
75
75
  return str;
76
76
  };
@@ -5,8 +5,8 @@
5
5
  */
6
6
  import React, { FunctionComponent, ReactNode } from 'react';
7
7
  import { RadioProps } from '../Radio';
8
- import { LabelTooltipProps } from "../Label";
9
- import { HelperTextDetailProps } from "../HelperText";
8
+ import { LabelTooltipProps } from '../Label';
9
+ import { HelperTextDetailProps } from '../HelperText';
10
10
  import './index.scss';
11
11
  export interface RadioListProps extends RadioProps {
12
12
  [name: string]: any;
@@ -73,7 +73,7 @@ var RadioGroup = function RadioGroup(props) {
73
73
  var handLabelClass = function handLabelClass() {
74
74
  var str = 'radio-group-label';
75
75
  if (labelTooltip && labelTooltip.className) {
76
- str += ' ' + labelTooltip.className;
76
+ str += " ".concat(labelTooltip.className);
77
77
  }
78
78
  return str;
79
79
  };
@@ -102,8 +102,8 @@ var RadioGroup = function RadioGroup(props) {
102
102
  };
103
103
  // 处理class
104
104
  var handClass = function handClass() {
105
- var str = $prefixCls + '-radio-group';
106
- if (className) str += ' ' + className;
105
+ var str = "".concat($prefixCls, "-radio-group");
106
+ if (className) str += " ".concat(className);
107
107
  if (size) str += " ".concat($prefixCls, "-radio-group-size");
108
108
  if (error) str += " ".concat($prefixCls, "-radio-group-error");
109
109
  if (disabled) str += " ".concat($prefixCls, "-radio-group-disabled");
package/Search/index.js CHANGED
@@ -107,7 +107,7 @@ var Search = function Search(props) {
107
107
  */
108
108
  var handClass = function handClass() {
109
109
  var str = "".concat($prefixCls, "-search");
110
- if (className) str += ' ' + className;
110
+ if (className) str += " ".concat(className);
111
111
  if (size) str += " ".concat($prefixCls, "-search-").concat(size);
112
112
  if (radius) str += " ".concat($prefixCls, "-search-radius");
113
113
  return str;
package/Select/index.d.ts CHANGED
@@ -4,10 +4,10 @@
4
4
  * @description 下拉框
5
5
  */
6
6
  import React, { FunctionComponent, ReactNode } from 'react';
7
- import { EmptyProps } from "../Empty";
8
- import { LabelTooltipProps } from "../Label";
7
+ import { EmptyProps } from '../Empty';
8
+ import { LabelTooltipProps } from '../Label';
9
9
  import { TooltipProps } from '../Tooltip';
10
- import { HelperTextDetailProps } from "../HelperText";
10
+ import { HelperTextDetailProps } from '../HelperText';
11
11
  import './index.scss';
12
12
  export interface SelectProps extends HelperTextDetailProps {
13
13
  /** 样式class */
package/Select/index.js CHANGED
@@ -61,21 +61,21 @@ styleInject(css_248z);
61
61
  * @param text 文本
62
62
  */
63
63
  var textSize = function textSize(fontSize, fontFamily, text) {
64
- var span = document.createElement("span");
64
+ var span = document.createElement('span');
65
65
  span.id = 'referenceSpan';
66
66
  var result = {};
67
67
  result.width = span.offsetWidth;
68
68
  result.height = span.offsetHeight;
69
- span.style.visibility = "hidden";
69
+ span.style.visibility = 'hidden';
70
70
  span.style.fontSize = fontSize;
71
71
  span.style.fontFamily = fontFamily;
72
- span.style.display = "inline-block";
73
- var isExists = document.getElementById("referenceSpan");
72
+ span.style.display = 'inline-block';
73
+ var isExists = document.getElementById('referenceSpan');
74
74
  if (isExists) {
75
75
  document.body.removeChild(isExists);
76
76
  }
77
77
  document.body.appendChild(span);
78
- if (typeof span.textContent != "undefined") {
78
+ if (typeof span.textContent !== 'undefined') {
79
79
  span.textContent = text;
80
80
  } else {
81
81
  span.innerText = text;
@@ -146,10 +146,10 @@ var Select = function Select(props) {
146
146
  _useGlobalProps$selec = _useGlobalProps.selectCheckIcon,
147
147
  selectCheckIcon = _useGlobalProps$selec === void 0 ? true : _useGlobalProps$selec;
148
148
  var posDom = useRef(null);
149
- var _useState = useState($prefixCls + '-select-' + UUID()),
149
+ var _useState = useState("".concat($prefixCls, "-select-").concat(UUID())),
150
150
  _useState2 = _slicedToArray(_useState, 1),
151
151
  classOne = _useState2[0]; // 唯一class
152
- var _useState3 = useState('select-popover-' + UUID()),
152
+ var _useState3 = useState("select-popover-".concat(UUID())),
153
153
  _useState4 = _slicedToArray(_useState3, 1),
154
154
  classOneSelect = _useState4[0]; // 唯一class
155
155
  var _useState5 = useState(false),
@@ -272,13 +272,13 @@ var Select = function Select(props) {
272
272
  useEffect(function () {
273
273
  // 多行不换行计算
274
274
  if (!overLineCom && multiple) {
275
- window.addEventListener("resize", changeSize);
275
+ window.addEventListener('resize', changeSize);
276
276
  } else {
277
277
  //setMorePos(constData.valueCom.length)
278
- window.removeEventListener("resize", changeSize);
278
+ window.removeEventListener('resize', changeSize);
279
279
  }
280
280
  return function () {
281
- window.removeEventListener("resize", changeSize);
281
+ window.removeEventListener('resize', changeSize);
282
282
  };
283
283
  }, [overLineCom, multiple]);
284
284
  // 计算是否显示label,placehold
@@ -297,7 +297,7 @@ var Select = function Select(props) {
297
297
  if (!open) return;
298
298
  setLoading(true);
299
299
  if (props.fetchSuggestions) {
300
- props.fetchSuggestions && props.fetchSuggestions(searchValue, function (data) {
300
+ props.fetchSuggestions(searchValue, function (data) {
301
301
  var listHand = handList(data);
302
302
  handSelectList(listHand, true);
303
303
  setLoading(false);
@@ -313,18 +313,18 @@ var Select = function Select(props) {
313
313
  clearTimeout(constData.openTimer);
314
314
  constData.openTimer = setTimeout(function () {
315
315
  inputFocus();
316
- window.addEventListener("click", clickCom);
317
- window.addEventListener("keydown", keydownCom);
316
+ window.addEventListener('click', clickCom);
317
+ window.addEventListener('keydown', keydownCom);
318
318
  });
319
319
  } else {
320
320
  setSearchValue('');
321
- window.removeEventListener("click", clickCom);
322
- window.removeEventListener("keydown", keydownCom);
321
+ window.removeEventListener('click', clickCom);
322
+ window.removeEventListener('keydown', keydownCom);
323
323
  }
324
324
  return function () {
325
325
  clearTimeout(constData.openTimer);
326
- window.removeEventListener("click", clickCom);
327
- window.removeEventListener("keydown", keydownCom);
326
+ window.removeEventListener('click', clickCom);
327
+ window.removeEventListener('keydown', keydownCom);
328
328
  };
329
329
  }, [open]);
330
330
  // 是否计算搜索框长度
@@ -339,7 +339,7 @@ var Select = function Select(props) {
339
339
  var handMultiline = function handMultiline(index) {
340
340
  if (index === null || index === 0) return;
341
341
  if (index === undefined) index = constData.valueCom.length;
342
- var boxDom = document.querySelector('.' + classOne + ' > .select-content > .check-select-content');
342
+ var boxDom = document.querySelector(".".concat(classOne, " > .select-content > .check-select-content"));
343
343
  if (!boxDom) return;
344
344
  if (boxDom.scrollHeight > boxDom.clientHeight) {
345
345
  var num = Number(index) - 1;
@@ -422,7 +422,7 @@ var Select = function Select(props) {
422
422
  // 输入框的到焦点
423
423
  var inputFocus = function inputFocus() {
424
424
  var inputDom = textDom && textDom.current;
425
- if (constData.searchModel === "inside") return;
425
+ if (constData.searchModel === 'inside') return;
426
426
  inputDom && inputDom.focus({
427
427
  preventScroll: true
428
428
  });
@@ -447,7 +447,7 @@ var Select = function Select(props) {
447
447
  * @param e 当前点击元素
448
448
  */
449
449
  var clickCom = function clickCom(e) {
450
- var bol = closest(e.target, '.' + classOneSelect); // 是否存在下拉当中
450
+ var bol = closest(e.target, ".".concat(classOneSelect)); // 是否存在下拉当中
451
451
  if (!bol) setOpen(false);
452
452
  };
453
453
  /**
@@ -541,8 +541,8 @@ var Select = function Select(props) {
541
541
  // 处理下拉框class
542
542
  var handClass = function handClass() {
543
543
  var str = "".concat($prefixCls, "-select");
544
- if (multiple && !overLineCom) str += ' ' + classOne; // 多选 超出不换行
545
- if (className) str += ' ' + className;
544
+ if (multiple && !overLineCom) str += " ".concat(classOne); // 多选 超出不换行
545
+ if (className) str += " ".concat(className);
546
546
  if (size) str += " ".concat($prefixCls, "-select-").concat(size);
547
547
  if (error) str += " ".concat($prefixCls, "-select-error");
548
548
  if (disabled === true) str += " ".concat($prefixCls, "-select-disabled");
@@ -563,14 +563,14 @@ var Select = function Select(props) {
563
563
  } else {
564
564
  str += " ".concat($prefixCls, "-select-popover-radio");
565
565
  }
566
- if (selectPopoverClassName) str += ' ' + selectPopoverClassName;
566
+ if (selectPopoverClassName) str += " ".concat(selectPopoverClassName);
567
567
  return str;
568
568
  };
569
569
  // 处理下拉框更多class
570
570
  var handleClassMorePopover = function handleClassMorePopover() {
571
571
  var str = "".concat($prefixCls, "-select-more-popover ").concat($prefixCls, "-scrollbar-small");
572
572
  if (size) str += " ".concat($prefixCls, "-select-more-popover-").concat(size);
573
- if (morePopoverClassName) str += ' ' + morePopoverClassName;
573
+ if (morePopoverClassName) str += " ".concat(morePopoverClassName);
574
574
  return str;
575
575
  };
576
576
  /**
@@ -588,7 +588,7 @@ var Select = function Select(props) {
588
588
  var onKeyDownSearch = function onKeyDownSearch(e) {
589
589
  if (e.keyCode === 13) {
590
590
  onEnterInput && onEnterInput(searchValue);
591
- var selectDom = document.querySelector('.' + classOneSelect + ' .select-popover-list');
591
+ var selectDom = document.querySelector(".".concat(classOneSelect, " .select-popover-list"));
592
592
  if (selectDom) {
593
593
  var hoverDom = selectDom.querySelector('.select-popover-list-item-hover');
594
594
  var keydownDom = selectDom.querySelector('.select-popover-list-item-keydown');
@@ -622,7 +622,7 @@ var Select = function Select(props) {
622
622
  var results = textSize(fontSize, fontFamily, text);
623
623
  var width = results.width;
624
624
  if (width < 10) width = 10;
625
- inputDom.style.width = width + 'px';
625
+ inputDom.style.width = "".concat(width, "px");
626
626
  };
627
627
  /**
628
628
  * 处理键盘事件 上/下
@@ -677,11 +677,11 @@ var Select = function Select(props) {
677
677
  if (brotherDom.className.indexOf('select-popover-list-group') !== -1) {
678
678
  var currentDom = brotherDom.querySelector(classGroupStr);
679
679
  if (currentDom) {
680
- currentDom.classList.add("select-popover-list-item-keydown");
680
+ currentDom.classList.add('select-popover-list-item-keydown');
681
681
  domClientTop(currentDom, selectDom);
682
682
  }
683
683
  } else {
684
- brotherDom.classList.add("select-popover-list-item-keydown");
684
+ brotherDom.classList.add('select-popover-list-item-keydown');
685
685
  domClientTop(brotherDom, selectDom);
686
686
  }
687
687
  }
@@ -712,7 +712,7 @@ var Select = function Select(props) {
712
712
  * @param e 键盘信息
713
713
  */
714
714
  var keydownCom = function keydownCom(e) {
715
- var selectDom = document.querySelector('.' + classOneSelect + ' .select-popover-list');
715
+ var selectDom = document.querySelector(".".concat(classOneSelect, " .select-popover-list"));
716
716
  if (!selectDom) return;
717
717
  var selectItemDom = selectDom.querySelector('.select-popover-list-item-select');
718
718
  var hoverDom = selectDom.querySelector('.select-popover-list-item-hover');
@@ -733,7 +733,7 @@ var Select = function Select(props) {
733
733
  }
734
734
  if (keydownDom) {
735
735
  currentKeydownDom = keydownDom;
736
- keydownDom.classList.remove("select-popover-list-item-keydown");
736
+ keydownDom.classList.remove('select-popover-list-item-keydown');
737
737
  }
738
738
  // 下
739
739
  if (e.keyCode === 40) {
@@ -760,11 +760,11 @@ var Select = function Select(props) {
760
760
  if (constData.scroll) return;
761
761
  var target = closest(e.target, '.select-popover-list-item');
762
762
  if (!target) return;
763
- target.classList.add("select-popover-list-item-hover");
763
+ target.classList.add('select-popover-list-item-hover');
764
764
  // 鼠标移入清除所有keydown
765
- var selectDom = document.querySelector('.' + classOneSelect);
765
+ var selectDom = document.querySelector(".".concat(classOneSelect));
766
766
  var keydownDom = selectDom.querySelector('.select-popover-list-item-keydown');
767
- if (keydownDom) keydownDom.classList.remove("select-popover-list-item-keydown");
767
+ if (keydownDom) keydownDom.classList.remove('select-popover-list-item-keydown');
768
768
  };
769
769
  /**
770
770
  * 鼠标移出
@@ -773,7 +773,7 @@ var Select = function Select(props) {
773
773
  var mouseLeave = function mouseLeave(e) {
774
774
  var target = closest(e.target, '.select-popover-list-item');
775
775
  if (!target) return;
776
- target.classList.remove("select-popover-list-item-hover");
776
+ target.classList.remove('select-popover-list-item-hover');
777
777
  };
778
778
  // 外标题memo
779
779
  var OutLabelMemo = useMemo(function () {
@@ -781,7 +781,7 @@ var Select = function Select(props) {
781
781
  var handLabelClass = function handLabelClass() {
782
782
  var str = 'select-label';
783
783
  if (labelTooltip && labelTooltip.className) {
784
- str += ' ' + labelTooltip.className;
784
+ str += " ".concat(labelTooltip.className);
785
785
  }
786
786
  return str;
787
787
  };
@@ -843,7 +843,7 @@ var Select = function Select(props) {
843
843
  var renderContentVal = renderContent && renderContent(listJson[valueCom[0]], false);
844
844
  if (overLineCom) return renderContentVal || val;
845
845
  return jsx(AutoTips, Object.assign({
846
- placement: "top-start"
846
+ placement: 'top-start'
847
847
  }, {
848
848
  children: renderContentVal || val
849
849
  }));
@@ -883,7 +883,7 @@ var Select = function Select(props) {
883
883
  }, {
884
884
  children: [jsx("span", {
885
885
  children: jsx(AutoTips, Object.assign({
886
- placement: "top-start"
886
+ placement: 'top-start'
887
887
  }, {
888
888
  children: handContent(index)
889
889
  }))
@@ -973,7 +973,7 @@ var Select = function Select(props) {
973
973
  }, {
974
974
  children: [jsx("span", {
975
975
  children: jsx(AutoTips, Object.assign({
976
- placement: "top-start"
976
+ placement: 'top-start'
977
977
  }, {
978
978
  children: handContent(index)
979
979
  }))
@@ -1022,7 +1022,7 @@ var Select = function Select(props) {
1022
1022
  className: "select-popover-list-item-label"
1023
1023
  }, {
1024
1024
  children: jsx(AutoTips, Object.assign({
1025
- placement: "top-start"
1025
+ placement: 'top-start'
1026
1026
  }, {
1027
1027
  children: renderContentVal || val
1028
1028
  }))
@@ -1091,7 +1091,7 @@ var Select = function Select(props) {
1091
1091
  className: "select-nodata"
1092
1092
  }, {
1093
1093
  children: jsx(Empty, Object.assign({}, emptyProps, {
1094
- size: (emptyProps === null || emptyProps === void 0 ? void 0 : emptyProps.size) || "small"
1094
+ size: (emptyProps === null || emptyProps === void 0 ? void 0 : emptyProps.size) || 'small'
1095
1095
  }))
1096
1096
  })), loading && jsx(Loading, {})]
1097
1097
  }));
@@ -1100,13 +1100,13 @@ var Select = function Select(props) {
1100
1100
  var SelectPopoverMemo = useMemo(function () {
1101
1101
  if (!showSelect) return '';
1102
1102
  var handSelectPopoverMemoClass = function handSelectPopoverMemoClass() {
1103
- var classStr = 'select-popover-content ' + classOneSelect;
1103
+ var classStr = "select-popover-content ".concat(classOneSelect);
1104
1104
  if (search && searchModel === 'inside') classStr += ' select-popover-content-search';
1105
1105
  return classStr;
1106
1106
  };
1107
1107
  return jsxs("div", Object.assign({
1108
1108
  style: {
1109
- width: (posDom && posDom.current ? posDom.current.offsetWidth : 0) + 'px'
1109
+ width: "".concat(posDom && posDom.current ? posDom.current.offsetWidth : 0, "px")
1110
1110
  },
1111
1111
  className: handSelectPopoverMemoClass()
1112
1112
  }, {
@@ -39,8 +39,8 @@ import '../HelperText/index.js';
39
39
 
40
40
  var SelectInput = function SelectInput(props) {
41
41
  var handClass = function handClass() {
42
- var str = $prefixCls + '-select-input';
43
- if (props.className) str += ' ' + props.className;
42
+ var str = "".concat($prefixCls, "-select-input");
43
+ if (props.className) str += " ".concat(props.className);
44
44
  return str;
45
45
  };
46
46
  return jsx(Select, Object.assign({}, props, {