@para-ui/core 2.2.6 → 2.2.7-beta

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 (348) hide show
  1. package/AutoBox/index.d.ts +34 -34
  2. package/AutoBox/index.js +203 -15
  3. package/AutoTips/index.d.ts +27 -27
  4. package/AutoTips/index.js +84 -15
  5. package/Breadcrumbs/index.d.ts +39 -39
  6. package/Breadcrumbs/index.js +227 -15
  7. package/Button/SplitButton.d.ts +62 -61
  8. package/Button/index.d.ts +71 -56
  9. package/Button/index.js +348 -14
  10. package/Button/lang/en_US.d.ts +4 -4
  11. package/Button/lang/index.d.ts +9 -9
  12. package/Button/lang/zh_CN.d.ts +4 -4
  13. package/ButtonGroup/index.d.ts +33 -33
  14. package/ButtonGroup/index.js +128 -14
  15. package/Carousel/index.d.ts +30 -30
  16. package/Carousel/index.js +74 -15
  17. package/Cascader/index.d.ts +52 -52
  18. package/Cascader/index.js +166 -15
  19. package/Cascader/lang/en_US.d.ts +4 -4
  20. package/Cascader/lang/index.d.ts +9 -9
  21. package/Cascader/lang/zh_CN.d.ts +4 -4
  22. package/Checkbox/index.d.ts +40 -40
  23. package/Checkbox/index.js +105 -14
  24. package/CheckboxGroup/index.d.ts +46 -46
  25. package/CheckboxGroup/index.js +138 -14
  26. package/Collapse/collapsePanel.d.ts +30 -30
  27. package/Collapse/index.d.ts +57 -57
  28. package/Collapse/index.js +171 -15
  29. package/Collapse/motion.d.ts +5 -5
  30. package/Collapse/util.d.ts +11 -11
  31. package/CollapseBox/index.d.ts +27 -27
  32. package/CollapseBox/index.js +164 -15
  33. package/CollapseBox/util.d.ts +5 -5
  34. package/ColorPicker/index.d.ts +4 -4
  35. package/ColorPicker/index.js +4 -1
  36. package/ComboSelect/WithTabsCombo/index.d.ts +11 -11
  37. package/ComboSelect/WithTabsCombo/interface.d.ts +141 -141
  38. package/ComboSelect/index.d.ts +11 -11
  39. package/ComboSelect/index.js +1803 -14
  40. package/ComboSelect/interface.d.ts +140 -143
  41. package/ComboSelect/lang/en_US.d.ts +8 -8
  42. package/ComboSelect/lang/index.d.ts +17 -17
  43. package/ComboSelect/lang/zh_CN.d.ts +8 -8
  44. package/ComboSelect/utils.d.ts +12 -12
  45. package/Container/index.d.ts +77 -77
  46. package/Container/index.js +239 -15
  47. package/DatePicker/PickerButton.d.ts +3 -3
  48. package/DatePicker/PickerTag.d.ts +3 -3
  49. package/DatePicker/generatePicker/generateRangePicker.d.ts +4 -4
  50. package/DatePicker/generatePicker/generateSinglePicker.d.ts +11 -11
  51. package/DatePicker/generatePicker/index.d.ts +77 -77
  52. package/DatePicker/index.d.ts +18 -18
  53. package/DatePicker/index.js +733 -14
  54. package/DatePicker/lang/en_US.d.ts +3 -3
  55. package/DatePicker/lang/index.d.ts +7 -7
  56. package/DatePicker/lang/zh_CN.d.ts +3 -3
  57. package/DatePicker/util.d.ts +20 -20
  58. package/Desktop/index.d.ts +57 -55
  59. package/Desktop/index.js +853 -14
  60. package/Drawer/index.d.ts +11 -11
  61. package/Drawer/index.js +186 -14
  62. package/Drawer/interface.d.ts +83 -83
  63. package/Drawer/lang/en_US.d.ts +5 -5
  64. package/Drawer/lang/index.d.ts +11 -11
  65. package/Drawer/lang/zh_CN.d.ts +5 -5
  66. package/Dropdown/index.d.ts +25 -0
  67. package/Dropdown/index.js +67 -0
  68. package/Empty/images/index.d.ts +3 -2
  69. package/Empty/index.d.ts +30 -30
  70. package/Empty/index.js +644 -14
  71. package/Empty/lang/en_US.d.ts +6 -6
  72. package/Empty/lang/index.d.ts +13 -13
  73. package/Empty/lang/zh_CN.d.ts +6 -6
  74. package/Form/index.d.ts +181 -181
  75. package/Form/index.js +384 -14
  76. package/FormItem/compoments/defaultCompoments/index.d.ts +19 -19
  77. package/FormItem/compoments/formCheckboxGroup/index.d.ts +8 -8
  78. package/FormItem/compoments/formFile/index.d.ts +38 -38
  79. package/FormItem/compoments/formRadioGroup/index.d.ts +8 -8
  80. package/FormItem/compoments/formSelect/index.d.ts +18 -18
  81. package/FormItem/errorTips.d.ts +12 -12
  82. package/FormItem/index.d.ts +152 -152
  83. package/FormItem/index.js +81 -14
  84. package/FormItem/itemType.d.ts +42 -42
  85. package/FormItem/validateFunction.d.ts +15 -15
  86. package/FunctionModal/dialog.d.ts +58 -58
  87. package/FunctionModal/index.d.ts +8 -8
  88. package/FunctionModal/index.js +39 -14
  89. package/FunctionModal/modalContext.d.ts +15 -14
  90. package/GlobalContext/componentsProps.d.ts +19 -19
  91. package/GlobalContext/confirmLocale.d.ts +7 -7
  92. package/GlobalContext/index.d.ts +28 -28
  93. package/GlobalContext/index.js +41 -16
  94. package/GlobalContext/intl.d.ts +34 -34
  95. package/GlobalContext/useFormatMessage.d.ts +3 -3
  96. package/Help/index.d.ts +18 -20
  97. package/Help/index.js +39 -15
  98. package/HelperText/index.d.ts +19 -19
  99. package/HelperText/index.js +29 -15
  100. package/Hooks/useGlobalProps.d.ts +1 -1
  101. package/InputLang/index.d.ts +49 -49
  102. package/InputLang/index.js +270 -14
  103. package/InputNumber/index.d.ts +74 -74
  104. package/InputNumber/index.js +308 -14
  105. package/Label/index.d.ts +35 -35
  106. package/Label/index.js +81 -14
  107. package/Loading/index.d.ts +17 -17
  108. package/Loading/index.js +47 -15
  109. package/Menu/footerExpansion.d.ts +9 -9
  110. package/Menu/index.d.ts +10 -10
  111. package/Menu/index.js +1232 -14
  112. package/Menu/interface.d.ts +139 -139
  113. package/Menu/logo.d.ts +9 -9
  114. package/Menu/verticalMenuList.d.ts +14 -14
  115. package/Message/index.d.ts +73 -73
  116. package/Message/index.js +222 -15
  117. package/Modal/Confirm/index.d.ts +65 -66
  118. package/Modal/index.d.ts +90 -61
  119. package/Modal/index.js +443 -14
  120. package/Modal/lang/en_US.d.ts +5 -5
  121. package/Modal/lang/index.d.ts +11 -11
  122. package/Modal/lang/zh_CN.d.ts +5 -5
  123. package/MultiBox/index.d.ts +54 -54
  124. package/MultiBox/index.js +231 -14
  125. package/Notification/index.d.ts +52 -52
  126. package/Notification/index.js +266 -15
  127. package/OperateBtn/index.d.ts +59 -59
  128. package/OperateBtn/index.js +260 -14
  129. package/OperateBtn/lang/en_US.d.ts +4 -4
  130. package/OperateBtn/lang/index.d.ts +9 -9
  131. package/OperateBtn/lang/zh_CN.d.ts +4 -4
  132. package/PageHeader/horizontalMeun.d.ts +9 -9
  133. package/PageHeader/horizontalMeunRight.d.ts +9 -9
  134. package/PageHeader/index.d.ts +10 -10
  135. package/PageHeader/index.js +1171 -14
  136. package/PageHeader/interface.d.ts +167 -167
  137. package/Pagination/index.d.ts +33 -33
  138. package/Pagination/index.js +469 -14
  139. package/Pagination/lang/en_US.d.ts +8 -8
  140. package/Pagination/lang/index.d.ts +17 -17
  141. package/Pagination/lang/zh_CN.d.ts +8 -8
  142. package/ParauiProvider/index.d.ts +8 -12
  143. package/ParauiProvider/index.js +53 -15
  144. package/PopConfirm/index.d.ts +58 -56
  145. package/PopConfirm/index.js +189 -14
  146. package/PopConfirm/lang/en_US.d.ts +5 -5
  147. package/PopConfirm/lang/index.d.ts +11 -11
  148. package/PopConfirm/lang/zh_CN.d.ts +5 -5
  149. package/Popover/index.d.ts +14 -14
  150. package/Popover/index.js +66 -15
  151. package/Progress/Line.d.ts +47 -47
  152. package/Progress/Steps.d.ts +17 -17
  153. package/Progress/index.d.ts +81 -81
  154. package/Progress/index.js +358 -20
  155. package/Progress/utils.d.ts +6 -6
  156. package/Querying/images/index.d.ts +3 -2
  157. package/Querying/index.d.ts +26 -26
  158. package/Querying/index.js +762 -14
  159. package/Querying/lang/en_US.d.ts +4 -4
  160. package/Querying/lang/index.d.ts +9 -9
  161. package/Querying/lang/zh_CN.d.ts +4 -4
  162. package/Radio/index.d.ts +38 -38
  163. package/Radio/index.js +94 -14
  164. package/RadioGroup/index.d.ts +47 -47
  165. package/RadioGroup/index.js +128 -14
  166. package/Search/index.d.ts +56 -56
  167. package/Search/index.js +220 -14
  168. package/Select/index.d.ts +86 -86
  169. package/Select/index.js +1288 -14
  170. package/Select/lang/en_US.d.ts +5 -5
  171. package/Select/lang/index.d.ts +11 -11
  172. package/Select/lang/zh_CN.d.ts +5 -5
  173. package/SelectInput/index.d.ts +11 -11
  174. package/SelectInput/index.js +51 -14
  175. package/SingleBox/index.d.ts +42 -42
  176. package/SingleBox/index.js +194 -14
  177. package/Slider/index.d.ts +14 -14
  178. package/Slider/index.js +125 -15
  179. package/Slider/interface.d.ts +102 -102
  180. package/Split/index.d.ts +7 -7
  181. package/Split/index.js +134 -15
  182. package/Stepper/icons.d.ts +5 -5
  183. package/Stepper/index.d.ts +49 -39
  184. package/Stepper/index.js +99 -15
  185. package/Switch/index.d.ts +78 -78
  186. package/Switch/index.js +73 -14
  187. package/Table/index.d.ts +10 -10
  188. package/Table/index.js +2725 -14
  189. package/Table/interface.d.ts +202 -202
  190. package/Table/lang/en_US.d.ts +6 -6
  191. package/Table/lang/index.d.ts +13 -13
  192. package/Table/lang/zh_CN.d.ts +6 -6
  193. package/Table/tableBody.d.ts +9 -9
  194. package/Table/tableBodyElement/index.d.ts +15 -15
  195. package/Table/tableBodyInterface.d.ts +67 -67
  196. package/Table/tableContainer/index.d.ts +16 -16
  197. package/Table/tableElement/index.d.ts +17 -17
  198. package/Table/tableHead.d.ts +9 -9
  199. package/Table/tableHeadElement/index.d.ts +15 -15
  200. package/Table/tableHeadInterface.d.ts +26 -30
  201. package/Table/tablePagination.d.ts +9 -9
  202. package/Table/tablePaginationInterFace.d.ts +24 -24
  203. package/Table/tdElement/index.d.ts +15 -15
  204. package/Table/thElement/index.d.ts +15 -15
  205. package/Table/trElement/index.d.ts +15 -15
  206. package/Table/util.d.ts +16 -16
  207. package/Tabs/index.d.ts +69 -48
  208. package/Tabs/index.js +218 -14
  209. package/Tabs/lang/en_US.d.ts +4 -0
  210. package/Tabs/lang/index.d.ts +9 -0
  211. package/Tabs/lang/zh_CN.d.ts +4 -0
  212. package/Tag/TagGroup.d.ts +66 -66
  213. package/Tag/index.d.ts +34 -34
  214. package/Tag/index.js +286 -14
  215. package/Test/index.d.ts +3 -2
  216. package/Test/index.js +9 -16
  217. package/TextField/index.d.ts +93 -93
  218. package/TextField/index.js +686 -14
  219. package/TimePicker/index.d.ts +22 -22
  220. package/TimePicker/index.js +77 -14
  221. package/TimePicker/locale/en_US.d.ts +3 -3
  222. package/TimePicker/locale/zh_CN.d.ts +3 -3
  223. package/TimePicker/style/index.d.ts +1 -1
  224. package/Timeline/TimelineItem.d.ts +23 -0
  225. package/Timeline/index.d.ts +31 -22
  226. package/Timeline/index.js +150 -15
  227. package/ToggleButton/ToggleButtonGroup.d.ts +49 -49
  228. package/ToggleButton/index.d.ts +49 -49
  229. package/ToggleButton/index.js +200 -14
  230. package/Tooltip/index.d.ts +11 -14
  231. package/Tooltip/index.js +335 -15
  232. package/Tooltip/interface.d.ts +21 -0
  233. package/Tooltip/utils.d.ts +22 -0
  234. package/Transfer/index.d.ts +18 -17
  235. package/Transfer/index.js +343 -14
  236. package/Transfer/lang/en_US.d.ts +6 -6
  237. package/Transfer/lang/index.d.ts +13 -13
  238. package/Transfer/lang/zh_CN.d.ts +6 -6
  239. package/Tree/OperateBar/index.d.ts +13 -13
  240. package/Tree/Tree.d.ts +4 -4
  241. package/Tree/index.d.ts +5 -5
  242. package/Tree/index.js +35 -14
  243. package/Tree/interface.d.ts +209 -207
  244. package/Tree/lang/en_US.d.ts +8 -8
  245. package/Tree/lang/index.d.ts +17 -17
  246. package/Tree/lang/zh_CN.d.ts +8 -8
  247. package/Tree/utils/tools.d.ts +26 -26
  248. package/Tree/utils/treeUtil.d.ts +15 -15
  249. package/Upload/Dragger/index.d.ts +10 -10
  250. package/Upload/ErroTip/index.d.ts +13 -13
  251. package/Upload/ImageUpload/index.d.ts +14 -14
  252. package/Upload/ImgCrop/EasyCrop.d.ts +17 -17
  253. package/Upload/ImgCrop/constants.d.ts +7 -7
  254. package/Upload/ImgCrop/index.d.ts +6 -6
  255. package/Upload/ImgCrop/interface.d.ts +24 -24
  256. package/Upload/UploadList/index.d.ts +5 -5
  257. package/Upload/index.d.ts +15 -15
  258. package/Upload/index.js +1542 -14
  259. package/Upload/interface.d.ts +134 -134
  260. package/Upload/lang/en_US.d.ts +12 -12
  261. package/Upload/lang/index.d.ts +25 -25
  262. package/Upload/lang/zh_CN.d.ts +12 -12
  263. package/_verture/defineProperty-0590dc61.js +16 -0
  264. package/_verture/index-2c0ecd8d.js +778 -0
  265. package/_verture/index-342379c6.js +391 -0
  266. package/_verture/index-a369ca3f.js +4 -0
  267. package/_verture/index-e2881a53.js +16 -0
  268. package/_verture/index-ee85b1cd.js +1555 -0
  269. package/_verture/intl-336570e4.js +65 -0
  270. package/_verture/modalContext-e7cc8067.js +228 -0
  271. package/_verture/slicedToArray-d7722f4b.js +62 -0
  272. package/_verture/style-inject.es-300983ab.js +28 -0
  273. package/_verture/toConsumableArray-f8047a75.js +19 -0
  274. package/_verture/tslib.es6-55ed4bd2.js +38 -0
  275. package/_verture/typeof-498dd2b1.js +11 -0
  276. package/_verture/useFormatMessage-ac9d6acf.js +20 -0
  277. package/_verture/useGlobalProps-af9a2af6.js +12 -0
  278. package/index.d.ts +128 -128
  279. package/index.js +160 -19
  280. package/package.json +54 -21
  281. package/Popper/index.d.ts +0 -13
  282. package/Popper/index.js +0 -16
  283. package/README.md +0 -501
  284. package/cdn/AutoBox/index.js +0 -29
  285. package/cdn/AutoTips/index.js +0 -40
  286. package/cdn/Breadcrumbs/index.js +0 -53
  287. package/cdn/Button/index.js +0 -79
  288. package/cdn/ButtonGroup/index.js +0 -79
  289. package/cdn/Carousel/index.js +0 -6
  290. package/cdn/Cascader/index.js +0 -42
  291. package/cdn/Checkbox/index.js +0 -53
  292. package/cdn/CheckboxGroup/index.js +0 -53
  293. package/cdn/Collapse/index.js +0 -27
  294. package/cdn/CollapseBox/index.js +0 -1
  295. package/cdn/ColorPicker/index.js +0 -1
  296. package/cdn/ComboSelect/index.js +0 -438
  297. package/cdn/Container/index.js +0 -1
  298. package/cdn/DatePicker/index.js +0 -185
  299. package/cdn/Desktop/index.js +0 -24
  300. package/cdn/Drawer/index.js +0 -84
  301. package/cdn/Empty/index.js +0 -1
  302. package/cdn/Form/index.js +0 -477
  303. package/cdn/FormItem/index.js +0 -477
  304. package/cdn/FunctionModal/index.js +0 -144
  305. package/cdn/GlobalContext/index.js +0 -1
  306. package/cdn/Help/index.js +0 -53
  307. package/cdn/HelperText/index.js +0 -1
  308. package/cdn/InputLang/index.js +0 -144
  309. package/cdn/InputNumber/index.js +0 -118
  310. package/cdn/Label/index.js +0 -53
  311. package/cdn/Loading/index.js +0 -14
  312. package/cdn/Menu/index.js +0 -40
  313. package/cdn/Message/index.js +0 -53
  314. package/cdn/Modal/index.js +0 -144
  315. package/cdn/MultiBox/index.js +0 -131
  316. package/cdn/Notification/index.js +0 -66
  317. package/cdn/OperateBtn/index.js +0 -92
  318. package/cdn/PageHeader/index.js +0 -92
  319. package/cdn/Pagination/index.js +0 -214
  320. package/cdn/ParauiProvider/index.js +0 -9
  321. package/cdn/PopConfirm/index.js +0 -131
  322. package/cdn/Popover/index.js +0 -16
  323. package/cdn/Popper/index.js +0 -26
  324. package/cdn/Progress/index.js +0 -58
  325. package/cdn/Querying/index.js +0 -1
  326. package/cdn/Radio/index.js +0 -53
  327. package/cdn/RadioGroup/index.js +0 -53
  328. package/cdn/Search/index.js +0 -144
  329. package/cdn/Select/index.js +0 -131
  330. package/cdn/SelectInput/index.js +0 -131
  331. package/cdn/SingleBox/index.js +0 -131
  332. package/cdn/Slider/index.js +0 -16
  333. package/cdn/Split/index.js +0 -1
  334. package/cdn/Stepper/index.js +0 -154
  335. package/cdn/Switch/index.js +0 -71
  336. package/cdn/Table/index.js +0 -292
  337. package/cdn/Tabs/index.js +0 -165
  338. package/cdn/Tag/index.js +0 -27
  339. package/cdn/Test/index.js +0 -1
  340. package/cdn/TextField/index.js +0 -105
  341. package/cdn/TimePicker/index.js +0 -185
  342. package/cdn/Timeline/index.js +0 -16
  343. package/cdn/ToggleButton/index.js +0 -79
  344. package/cdn/Tooltip/index.js +0 -40
  345. package/cdn/Transfer/index.js +0 -170
  346. package/cdn/Tree/index.js +0 -170
  347. package/cdn/Upload/index.js +0 -252
  348. package/style.css +0 -72
package/Progress/index.js CHANGED
@@ -1,20 +1,358 @@
1
- !function(e,r){"object"==typeof exports&&"object"==typeof module?module.exports=r(require("react"),require("@para-ui/icons/CheckCircleF"),require("@para-ui/icons/CloseCircleF"),require("@para-ui/icons/Check"),require("@para-ui/icons/Close")):"function"==typeof define&&define.amd?define(["react","@para-ui/icons/CheckCircleF","@para-ui/icons/CloseCircleF","@para-ui/icons/Check","@para-ui/icons/Close"],r):"object"==typeof exports?exports.ParaUI=r(require("react"),require("@para-ui/icons/CheckCircleF"),require("@para-ui/icons/CloseCircleF"),require("@para-ui/icons/Check"),require("@para-ui/icons/Close")):e.ParaUI=r(e.react,e["@para-ui/icons/CheckCircleF"],e["@para-ui/icons/CloseCircleF"],e["@para-ui/icons/Check"],e["@para-ui/icons/Close"])}(self,(function(e,r,t,o,n){return function(){var s={4184:function(e,r){var t;
2
- /*!
3
- Copyright (c) 2018 Jed Watson.
4
- Licensed under the MIT License (MIT), see
5
- http://jedwatson.github.io/classnames
6
- */!function(){"use strict";var o={}.hasOwnProperty;function n(){for(var e=[],r=0;r<arguments.length;r++){var t=arguments[r];if(t){var s=typeof t;if("string"===s||"number"===s)e.push(t);else if(Array.isArray(t)){if(t.length){var i=n.apply(null,t);i&&e.push(i)}}else if("object"===s)if(t.toString===Object.prototype.toString)for(var a in t)o.call(t,a)&&t[a]&&e.push(a);else e.push(t.toString())}}return e.join(" ")}e.exports?(n.default=n,e.exports=n):void 0===(t=function(){return n}.apply(r,[]))||(e.exports=t)}()},1442:function(e,r,t){(r=t(3645)(!1)).push([e.id,'.paraui-progress-line .progress-outer{display:flex;margin-right:8px;margin-bottom:8px}.paraui-progress-line .progress-outer .progress-inner{width:100%}.paraui-progress-line .progress-outer .progress-inner .rc-progress-line{height:10px;width:100%}.paraui-progress-line .progress-outer .progress-inner .steps-outer{display:flex;flex-direction:row;align-items:center}.paraui-progress-line .progress-outer .progress-inner .steps-outer .steps-item{flex-shrink:0;min-width:2px;margin-right:2px;background:#f3f3f3;transition:all .3s}.paraui-progress-line .progress-outer .progress-inner .steps-outer .steps-item-active{background-color:#2db7f5}.paraui-progress-line .progress-outer .progress-inner .trail-bar{position:relative;display:inline-block;width:100%;overflow:hidden;vertical-align:middle;background-color:rgba(0,0,0,.0392156863);border-radius:100px}.paraui-progress-line .progress-outer .progress-inner .trail-bar .active-bar{position:relative;background-color:var(--ant-primary-color);border-radius:100px;transition:all .4s cubic-bezier(0.08, 0.82, 0.17, 1) 0s}.paraui-progress-line .progress-outer .progress-text{font-size:12px;font-weight:700;text-align:left;color:#3d66f8;display:inline-block;margin-left:20px;white-space:nowrap;text-align:left;vertical-align:middle;word-break:normal;display:flex;align-items:center}.paraui-progress-line .progress-outer .progress-text svg{width:14px;height:14px;position:relative;top:2px}.paraui-progress-line .progress-outer .progress-text svg.success{color:#41d658 !important}.paraui-progress-line .progress-outer .progress-text svg.error{color:#f46b53 !important}.paraui-progress-circle,.paraui-progress-dashboard{display:inline-block;position:relative;margin:0 5px}.paraui-progress-circle .progress-outer .progress-text,.paraui-progress-dashboard .progress-outer .progress-text{position:absolute;top:50%;left:50%;width:100%;margin:0;padding:0;color:rgba(0,0,0,.8509803922);font-size:1em;line-height:1;white-space:normal;text-align:center;transform:translate(-50%, -50%)}.paraui-progress-circle .progress-outer .progress-text svg,.paraui-progress-dashboard .progress-outer .progress-text svg{width:2em;height:2em}.paraui-progress-circle .progress-outer .progress-text svg.success,.paraui-progress-dashboard .progress-outer .progress-text svg.success{color:#52c41a !important}.paraui-progress-circle .progress-outer .progress-text svg.error,.paraui-progress-dashboard .progress-outer .progress-text svg.error{color:#ff4d4f !important}.paraui-progress-success-status .progress-text{color:#52c41a !important}.paraui-progress-exception-status .progress-text{color:#ff4d4f !important}.paraui-progress-active-status .active-bar:before{position:absolute;inset:0;background:#fff;border-radius:10px;opacity:0;-webkit-animation:progress-active 2.4s cubic-bezier(0.23, 1, 0.32, 1) infinite;animation:progress-active 2.4s cubic-bezier(0.23, 1, 0.32, 1) infinite;content:""}@keyframes progress-active{0%{transform:translateX(-100%) scaleX(0);opacity:.1}20%{transform:translateX(-100%) scaleX(0);opacity:.5}100%{transform:translateX(0) scaleX(1);opacity:0}}',""]),e.exports=r},3645:function(e){"use strict";e.exports=function(e){var r=[];return r.toString=function(){return this.map((function(r){var t=function(e,r){var t=e[1]||"",o=e[3];if(!o)return t;if(r&&"function"==typeof btoa){var n=(i=o,a=btoa(unescape(encodeURIComponent(JSON.stringify(i)))),c="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(a),"/*# ".concat(c," */")),s=o.sources.map((function(e){return"/*# sourceURL=".concat(o.sourceRoot||"").concat(e," */")}));return[t].concat(s).concat([n]).join("\n")}var i,a,c;return[t].join("\n")}(r,e);return r[2]?"@media ".concat(r[2]," {").concat(t,"}"):t})).join("")},r.i=function(e,t,o){"string"==typeof e&&(e=[[null,e,""]]);var n={};if(o)for(var s=0;s<this.length;s++){var i=this[s][0];null!=i&&(n[i]=!0)}for(var a=0;a<e.length;a++){var c=[].concat(e[a]);o&&n[c[0]]||(t&&(c[2]?c[2]="".concat(t," and ").concat(c[2]):c[2]=t),r.push(c))}},r}},7418:function(e){"use strict";
7
- /*
8
- object-assign
9
- (c) Sindre Sorhus
10
- @license MIT
11
- */var r=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable;function n(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var r={},t=0;t<10;t++)r["_"+String.fromCharCode(t)]=t;if("0123456789"!==Object.getOwnPropertyNames(r).map((function(e){return r[e]})).join(""))return!1;var o={};return"abcdefghijklmnopqrst".split("").forEach((function(e){o[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},o)).join("")}catch(e){return!1}}()?Object.assign:function(e,s){for(var i,a,c=n(e),l=1;l<arguments.length;l++){for(var u in i=Object(arguments[l]))t.call(i,u)&&(c[u]=i[u]);if(r){a=r(i);for(var p=0;p<a.length;p++)o.call(i,a[p])&&(c[a[p]]=i[a[p]])}}return c}},5251:function(e,r,t){"use strict";
12
- /** @license React v17.0.2
13
- * react-jsx-runtime.production.min.js
14
- *
15
- * Copyright (c) Facebook, Inc. and its affiliates.
16
- *
17
- * This source code is licensed under the MIT license found in the
18
- * LICENSE file in the root directory of this source tree.
19
- */
20
- t(7418);var o=t(8156),n=60103;if(60107,"function"==typeof Symbol&&Symbol.for){var s=Symbol.for;n=s("react.element"),s("react.fragment")}var i=o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a=Object.prototype.hasOwnProperty,c={key:!0,ref:!0,__self:!0,__source:!0};function l(e,r,t){var o,s={},l=null,u=null;for(o in void 0!==t&&(l=""+t),void 0!==r.key&&(l=""+r.key),void 0!==r.ref&&(u=r.ref),r)a.call(r,o)&&!c.hasOwnProperty(o)&&(s[o]=r[o]);if(e&&e.defaultProps)for(o in r=e.defaultProps)void 0===s[o]&&(s[o]=r[o]);return{$$typeof:n,type:e,key:l,ref:u,props:s,_owner:i.current}}r.jsx=l,r.jsxs=l},5893:function(e,r,t){"use strict";e.exports=t(5251)},2738:function(e,r,t){var o=t(3379),n=t(1442);"string"==typeof(n=n.__esModule?n.default:n)&&(n=[[e.id,n,""]]);var s={insert:("body","body"),singleton:!1};o(n,s);e.exports=n.locals||{}},3379:function(e,r,t){"use strict";var o,n=function(){return void 0===o&&(o=Boolean(window&&document&&document.all&&!window.atob)),o},s=function(){var e={};return function(r){if(void 0===e[r]){var t=document.querySelector(r);if(window.HTMLIFrameElement&&t instanceof window.HTMLIFrameElement)try{t=t.contentDocument.head}catch(e){t=null}e[r]=t}return e[r]}}(),i=[];function a(e){for(var r=-1,t=0;t<i.length;t++)if(i[t].identifier===e){r=t;break}return r}function c(e,r){for(var t={},o=[],n=0;n<e.length;n++){var s=e[n],c=r.base?s[0]+r.base:s[0],l=t[c]||0,u="".concat(c," ").concat(l);t[c]=l+1;var p=a(u),f={css:s[1],media:s[2],sourceMap:s[3]};-1!==p?(i[p].references++,i[p].updater(f)):i.push({identifier:u,updater:h(f,r),references:1}),o.push(u)}return o}function l(e){var r=document.createElement("style"),o=e.attributes||{};if(void 0===o.nonce){var n=t.nc;n&&(o.nonce=n)}if(Object.keys(o).forEach((function(e){r.setAttribute(e,o[e])})),"function"==typeof e.insert)e.insert(r);else{var i=s(e.insert||"head");if(!i)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");i.appendChild(r)}return r}var u,p=(u=[],function(e,r){return u[e]=r,u.filter(Boolean).join("\n")});function f(e,r,t,o){var n=t?"":o.media?"@media ".concat(o.media," {").concat(o.css,"}"):o.css;if(e.styleSheet)e.styleSheet.cssText=p(r,n);else{var s=document.createTextNode(n),i=e.childNodes;i[r]&&e.removeChild(i[r]),i.length?e.insertBefore(s,i[r]):e.appendChild(s)}}function d(e,r,t){var o=t.css,n=t.media,s=t.sourceMap;if(n?e.setAttribute("media",n):e.removeAttribute("media"),s&&"undefined"!=typeof btoa&&(o+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(s))))," */")),e.styleSheet)e.styleSheet.cssText=o;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(o))}}var g=null,y=0;function h(e,r){var t,o,n;if(r.singleton){var s=y++;t=g||(g=l(r)),o=f.bind(null,t,s,!1),n=f.bind(null,t,s,!0)}else t=l(r),o=d.bind(null,t,r),n=function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)};return o(e),function(r){if(r){if(r.css===e.css&&r.media===e.media&&r.sourceMap===e.sourceMap)return;o(e=r)}else n()}}e.exports=function(e,r){(r=r||{}).singleton||"boolean"==typeof r.singleton||(r.singleton=n());var t=c(e=e||[],r);return function(e){if(e=e||[],"[object Array]"===Object.prototype.toString.call(e)){for(var o=0;o<t.length;o++){var n=a(t[o]);i[n].references--}for(var s=c(e,r),l=0;l<t.length;l++){var u=a(t[l]);0===i[u].references&&(i[u].updater(),i.splice(u,1))}t=s}}}},2004:function(e){"use strict";e.exports=o},1014:function(e){"use strict";e.exports=r},5927:function(e){"use strict";e.exports=n},6649:function(e){"use strict";e.exports=t},8156:function(r){"use strict";r.exports=e}},i={};function a(e){var r=i[e];if(void 0!==r)return r.exports;var t=i[e]={id:e,exports:{}};return s[e](t,t.exports,a),t.exports}a.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return a.d(r,{a:r}),r},a.d=function(e,r){for(var t in r)a.o(r,t)&&!a.o(e,t)&&Object.defineProperty(e,t,{enumerable:!0,get:r[t]})},a.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},a.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},a.nc=void 0;var c={};return function(){"use strict";a.r(c),a.d(c,{Progress:function(){return $},default:function(){return H}});var e=a(5893);function r(){return r=Object.assign?Object.assign.bind():function(e){for(var r=1;r<arguments.length;r++){var t=arguments[r];for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])}return e},r.apply(this,arguments)}function t(e,r){if(null==e)return{};var t,o,n=function(e,r){if(null==e)return{};var t,o,n={},s=Object.keys(e);for(o=0;o<s.length;o++)t=s[o],r.indexOf(t)>=0||(n[t]=e[t]);return n}(e,r);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(o=0;o<s.length;o++)t=s[o],r.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(n[t]=e[t])}return n}var o=a(8156),n=a(4184),s=a.n(n),i={className:"",percent:0,prefixCls:"rc-progress",strokeColor:"#2db7f5",strokeLinecap:"round",strokeWidth:1,style:{},trailColor:"#D9D9D9",trailWidth:1,gapPosition:"bottom"},l=function(){var e=(0,o.useRef)([]),r=(0,o.useRef)(null);return(0,o.useEffect)((function(){var t=Date.now(),o=!1;e.current.forEach((function(e){if(e){o=!0;var n=e.style;n.transitionDuration=".3s, .3s, .3s, .06s",r.current&&t-r.current<100&&(n.transitionDuration="0s, 0s")}})),o&&(r.current=Date.now())})),e.current},u=["className","percent","prefixCls","strokeColor","strokeLinecap","strokeWidth","style","trailColor","trailWidth","transition"],p=function(e){var n=e.className,i=e.percent,a=e.prefixCls,c=e.strokeColor,p=e.strokeLinecap,f=e.strokeWidth,d=e.style,g=e.trailColor,y=e.trailWidth,h=e.transition,v=t(e,u);delete v.gapPosition;var m=Array.isArray(i)?i:[i],b=Array.isArray(c)?c:[c],x=l(),k=f/2,j=100-f/2,O="M ".concat("round"===p?k:0,",").concat(k,"\n L ").concat("round"===p?j:100,",").concat(k),w="0 0 100 ".concat(f),C=0;return o.createElement("svg",r({className:s()("".concat(a,"-line"),n),viewBox:w,preserveAspectRatio:"none",style:d},v),o.createElement("path",{className:"".concat(a,"-line-trail"),d:O,strokeLinecap:p,stroke:g,strokeWidth:y||f,fillOpacity:"0"}),m.map((function(e,r){var t=1;switch(p){case"round":t=1-f/100;break;case"square":t=1-f/2/100;break;default:t=1}var n={strokeDasharray:"".concat(e*t,"px, 100px"),strokeDashoffset:"-".concat(C,"px"),transition:h||"stroke-dashoffset 0.3s ease 0s, stroke-dasharray .3s ease 0s, stroke 0.3s linear"},s=b[r]||b[b.length-1];return C+=e,o.createElement("path",{key:r,className:"".concat(a,"-line-path"),d:O,strokeLinecap:p,stroke:s,strokeWidth:f,fillOpacity:"0",ref:function(e){x[r]=e},style:n})})))};p.defaultProps=i,p.displayName="Line";function f(e){return f="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},f(e)}function d(e,r){(null==r||r>e.length)&&(r=e.length);for(var t=0,o=new Array(r);t<r;t++)o[t]=e[t];return o}function g(e,r){return function(e){if(Array.isArray(e))return e}(e)||function(e,r){var t=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=t){var o,n,s=[],i=!0,a=!1;try{for(t=t.call(e);!(i=(o=t.next()).done)&&(s.push(o.value),!r||s.length!==r);i=!0);}catch(e){a=!0,n=e}finally{try{i||null==t.return||t.return()}finally{if(a)throw n}}return s}}(e,r)||function(e,r){if(e){if("string"==typeof e)return d(e,r);var t=Object.prototype.toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(e):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?d(e,r):void 0}}(e,r)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var y=0,h=!("undefined"==typeof window||!window.document||!window.document.createElement);var v=function(e){var r=g(o.useState(),2),t=r[0],n=r[1];return o.useEffect((function(){var e;n("rc_progress_".concat((h?(e=y,y+=1):e="TEST_OR_SSR",e)))}),[]),e||t},m=["id","prefixCls","steps","strokeWidth","trailWidth","gapDegree","gapPosition","trailColor","strokeLinecap","style","className","strokeColor","percent"];function b(e){return+e.replace("%","")}function x(e){var r=null!=e?e:[];return Array.isArray(r)?r:[r]}var k=100,j=function(e,r,t,o,n,s,i,a,c,l){var u=arguments.length>10&&void 0!==arguments[10]?arguments[10]:0,p=t/100*360*((360-s)/360),f=0===s?0:{bottom:0,top:180,left:90,right:-90}[i],d=(100-o)/100*r;return"round"===c&&100!==o&&(d+=l/2)>=r&&(d=r-.01),{stroke:"string"==typeof a?a:void 0,strokeDasharray:"".concat(r,"px ").concat(e),strokeDashoffset:d+u,transform:"rotate(".concat(n+p+f,"deg)"),transformOrigin:"50% 50%",transition:"stroke-dashoffset .3s ease 0s, stroke-dasharray .3s ease 0s, stroke .3s, stroke-width .06s ease .3s, opacity .3s ease 0s",fillOpacity:0}},O=function(e){var n,i,a,c=e.id,u=e.prefixCls,p=e.steps,d=e.strokeWidth,g=e.trailWidth,y=e.gapDegree,h=void 0===y?0:y,O=e.gapPosition,w=e.trailColor,C=e.strokeLinecap,S=e.style,N=e.className,P=e.strokeColor,E=e.percent,_=t(e,m),D=v(c),W="".concat(D,"-gradient"),A=50-d/2,I=2*Math.PI*A,L=h>0?90+h/2:-90,F=I*((360-h)/360),M="object"===f(p)?p:{count:p,space:2},R=M.count,T=M.space,q=j(I,F,0,100,L,h,O,w,C,d),U=x(E),B=x(P),X=B.find((function(e){return e&&"object"===f(e)})),z=l();return o.createElement("svg",r({className:s()("".concat(u,"-circle"),N),viewBox:"0 0 ".concat(k," ").concat(k),style:S,id:c},_),X&&o.createElement("defs",null,o.createElement("linearGradient",{id:W,x1:"100%",y1:"0%",x2:"0%",y2:"0%"},Object.keys(X).sort((function(e,r){return b(e)-b(r)})).map((function(e,r){return o.createElement("stop",{key:r,offset:e,stopColor:X[e]})})))),!R&&o.createElement("circle",{className:"".concat(u,"-circle-trail"),r:A,cx:50,cy:50,stroke:w,strokeLinecap:C,strokeWidth:g||d,style:q}),R?(n=Math.round(R*(U[0]/100)),i=100/R,a=0,new Array(R).fill(null).map((function(e,r){var t=r<=n-1?B[0]:w,s=t&&"object"===f(t)?"url(#".concat(W,")"):void 0,c=j(I,F,a,i,L,h,O,t,"butt",d,T);return a+=100*(F-c.strokeDashoffset+T)/F,o.createElement("circle",{key:r,className:"".concat(u,"-circle-path"),r:A,cx:50,cy:50,stroke:s,strokeWidth:d,opacity:1,style:c,ref:function(e){z[r]=e}})}))):function(){var e=0;return U.map((function(r,t){var n=B[t]||B[B.length-1],s=n&&"object"===f(n)?"url(#".concat(W,")"):void 0,i=j(I,F,e,r,L,h,O,n,C,d);return e+=r,o.createElement("circle",{key:t,className:"".concat(u,"-circle-path"),r:A,cx:50,cy:50,stroke:s,strokeLinecap:C,strokeWidth:d,opacity:0===r?0:1,style:i,ref:function(e){z[t]=e}})})).reverse()}())};O.defaultProps=i,O.displayName="Circle";var w=O,C=a(1014),S=a.n(C),N=a(6649),P=a.n(N),E=a(2004),_=a.n(E),D=a(5927),W=a.n(D),A=function(){return A=Object.assign||function(e){for(var r,t=1,o=arguments.length;t<o;t++)for(var n in r=arguments[t])Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n]);return e},A.apply(this,arguments)},I=function(r){for(var t=r.steps,o=r.percent,n=void 0===o?0:o,s=r.strokeWidth,i=void 0===s?8:s,a=r.strokeColor,c=r.trailColor,l=r.children,u="number"==typeof n?Math.round(t*(n/100)):1,p=[],f=0;f<t;f+=1)p.push((0,e.jsx)("div",{className:f<=u-1?"steps-item steps-item-active":"steps-item",style:{backgroundColor:f<=u-1?a:c,width:14,height:i}},f));return(0,e.jsxs)("div",A({className:"steps-outer"},{children:[p,l]}))};function L(e){return!e||e<0?0:e>100?100:e}var F,M,R=function(){return R=Object.assign||function(e){for(var r,t=1,o=arguments.length;t<o;t++)for(var n in r=arguments[t])Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n]);return e},R.apply(this,arguments)},T=function(e,r){var t={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&r.indexOf(o)<0&&(t[o]=e[o]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(o=Object.getOwnPropertySymbols(e);n<o.length;n++)r.indexOf(o[n])<0&&Object.prototype.propertyIsEnumerable.call(e,o[n])&&(t[o[n]]=e[o[n]])}return t},q=function(e,r){var t,o,n=e.from,s=void 0===n?"#3D66F8":n,i=e.to,a=void 0===i?"#4F93F0":i,c=e.direction,l=void 0===c?"rtl"===r?"to left":"to right":c,u=T(e,["from","to","direction"]);if(0!==Object.keys(u).length){var p=(t=u,o=[],Object.keys(t).forEach((function(e){var r=parseFloat(e.replace(/%/g,""));isNaN(r)||o.push({key:r,value:t[e]})})),(o=o.sort((function(e,r){return e.key-r.key}))).map((function(e){var r=e.key,t=e.value;return"".concat(t," ").concat(r,"%")})).join(", "));return{backgroundImage:"linear-gradient(".concat(l,", ").concat(p,")")}}return{backgroundImage:"linear-gradient(".concat(l,", ").concat(s,", ").concat(a,")")}},U=function(r){var t=r.direction,o=r.percent,n=r.strokeWidth,s=r.strokeColor,i=r.strokeLinecap,a=r.trailColor,c=s&&"string"!=typeof s?q(s,t):{background:s},l=a?{backgroundColor:a}:void 0,u=R({width:"".concat(L(o),"%"),height:n||10,borderRadius:"square"===i?0:""},c);return(0,e.jsx)("div",R({className:"trail-bar",style:l},{children:(0,e.jsx)("div",{className:"active-bar",style:u})}))},B=(a(2738),function(){return B=Object.assign||function(e){for(var r,t=1,o=arguments.length;t<o;t++)for(var n in r=arguments[t])Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n]);return e},B.apply(this,arguments)}),X=function(e,r){var t={};for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&r.indexOf(o)<0&&(t[o]=e[o]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(o=Object.getOwnPropertySymbols(e);n<o.length;n++)r.indexOf(o[n])<0&&Object.prototype.propertyIsEnumerable.call(e,o[n])&&(t[o[n]]=e[o[n]])}return t};!function(e){e[e.line=0]="line",e[e.circle=1]="circle",e[e.dashboard=2]="dashboard"}(F||(F={})),function(e){e[e.normal=0]="normal",e[e.exception=1]="exception",e[e.active=2]="active",e[e.success=3]="success"}(M||(M={}));var z={success:"#41D658",exception:"#F46B53",normal:"#3D66F8",active:"#3D66F8"},$=function(r){var t,o=r.type,n=void 0===o?"line":o,s=r.className,i=(r.children,r.status),a=r.width,c=void 0===a?132:a,l=r.showInfo,u=void 0===l||l,p=r.format,f=r.success,d=r.percent,g=void 0===d?0:d,y=r.steps,h=r.direction,v=r.strokeColor,m=r.gapDegree,b=void 0===m?75:m,x=X(r,["type","className","children","status","width","showInfo","format","success","percent","steps","direction","strokeColor","gapDegree"]),k=function(){return v||(f&&f.percent<g?[f.strokeColor||z.success,z.normal]:O?z.success:z[i||"normal"])},j=function(){return f&&f.percent<g&&"number"==typeof g?[f.percent,g-f.percent]:g},O=g&&100===g&&!i||"success"===i,C="circle"===n||"dashboard"===n?{width:c,height:c}:{},N=function(){return p?p(g):O?"circle"===n?(0,e.jsx)(_(),{className:"success"}):(0,e.jsx)(S(),{className:"success"}):"exception"===i?"circle"===n?(0,e.jsx)(W(),{className:"error"}):(0,e.jsx)(P(),{className:"error"}):L(g)+"%"},E=y?(0,e.jsx)(I,B({steps:y,strokeColor:k(),percent:j()},x,{children:u&&(0,e.jsx)("div",B({className:"progress-text"},{children:N()}))})):(0,e.jsx)(U,B({strokeColor:k(),percent:j(),direction:h},x,{children:" "})),D=(0,e.jsx)(w,B({strokeWidth:6,trailWidth:6,strokeColor:k(),percent:j()},x)),A=(0,e.jsx)(w,B({strokeWidth:6,trailWidth:6,gapPosition:"bottom",gapDegree:b,strokeColor:k(),percent:j()},x));return(0,e.jsx)("div",B({className:(t="paraui-progress paraui-progress-".concat(n||"default"),O&&(t+=" paraui-progress-success-status"),"exception"===i&&(t+=" paraui-progress-exception-status"),"active"===i&&(t+=" paraui-progress-active-status"),s&&(t+=" "+s),t)},{children:(0,e.jsxs)("div",B({className:"progress-outer"},{children:[(0,e.jsx)("div",B({className:"progress-inner",style:C},{children:"dashboard"===n?A:"circle"===n?D:E})),u&&!y&&(0,e.jsx)("div",B({className:"progress-text"},{children:N()}))]}))}))},H=$}(),c}()}));
1
+ import { _ as __rest } from '../_verture/tslib.es6-55ed4bd2.js';
2
+ import { jsx, jsxs } from 'react/jsx-runtime';
3
+ import { Circle } from 'rc-progress';
4
+ import SuccessOutlined from '@para-ui/icons/CheckCircleF';
5
+ import ErrorOutlined from '@para-ui/icons/CloseCircleF';
6
+ import Check from '@para-ui/icons/Check';
7
+ import CloseIcon from '@para-ui/icons/Close';
8
+ import { s as styleInject } from '../_verture/style-inject.es-300983ab.js';
9
+
10
+ var Steps = function Steps(props) {
11
+ var steps = props.steps,
12
+ _props$percent = props.percent,
13
+ percent = _props$percent === void 0 ? 0 : _props$percent,
14
+ _props$strokeWidth = props.strokeWidth,
15
+ strokeWidth = _props$strokeWidth === void 0 ? 8 : _props$strokeWidth,
16
+ strokeColor = props.strokeColor,
17
+ trailColor = props.trailColor,
18
+ children = props.children;
19
+ /** 计算出应该高亮多少步 **/
20
+
21
+ var current = typeof percent === "number" ? Math.round(steps * (percent / 100)) : 1;
22
+ var styledSteps = [];
23
+
24
+ for (var i = 0; i < steps; i += 1) {
25
+ styledSteps.push(jsx("div", {
26
+ className: i <= current - 1 ? "steps-item steps-item-active" : "steps-item",
27
+ style: {
28
+ backgroundColor: i <= current - 1 ? strokeColor : trailColor,
29
+ width: 14,
30
+ height: strokeWidth
31
+ }
32
+ }, i));
33
+ }
34
+
35
+ return jsxs("div", Object.assign({
36
+ className: "steps-outer"
37
+ }, {
38
+ children: [styledSteps, children]
39
+ }));
40
+ };
41
+
42
+ /**
43
+ * 判断进度条传的百分比参数是否规范
44
+ * @param {number | undefined} progress 方法入参说明
45
+ * @return {numner} 百分比值
46
+ */
47
+ function validProgress(progress) {
48
+ if (!progress || progress < 0) {
49
+ return 0;
50
+ }
51
+
52
+ if (progress > 100) {
53
+ return 100;
54
+ }
55
+
56
+ return progress;
57
+ }
58
+
59
+ /**
60
+ * 转换 百分比 到 样式格式
61
+ * {
62
+ * "0%": "#afc163",
63
+ * "75%": "#009900",
64
+ * "50%": "green", // ====> '#afc163 0%, #66FF00 25%, #00CC00 50%, #009900 75%, #ffffff 100%'
65
+ * "25%": "#66FF00",
66
+ * "100%": "#ffffff"
67
+ * }
68
+ * @param gradients 渐变的参数
69
+ * @return {string} 样式值
70
+ */
71
+
72
+ var sortGradient = function sortGradient(gradients) {
73
+ var tempArr = [];
74
+ Object.keys(gradients).forEach(function (key) {
75
+ // 拿到百分比的数字
76
+ var formattedKey = parseFloat(key.replace(/%/g, "")); // 进行序列化
77
+
78
+ if (!isNaN(formattedKey)) {
79
+ tempArr.push({
80
+ key: formattedKey,
81
+ value: gradients[key]
82
+ });
83
+ }
84
+ }); // 排序 从小到大
85
+
86
+ tempArr = tempArr.sort(function (a, b) {
87
+ return a.key - b.key;
88
+ });
89
+ return tempArr.map(function (_ref) {
90
+ var key = _ref.key,
91
+ value = _ref.value;
92
+ return "".concat(value, " ").concat(key, "%");
93
+ }).join(", ");
94
+ };
95
+ /**
96
+ * 转换传进来 渐变的参数 为css样式
97
+ * {
98
+ * "0%": "#afc163",
99
+ * "25%": "#66FF00",
100
+ * "50%": "#00CC00", // ====> linear-gradient(to right, #afc163 0%, #66FF00 25%,
101
+ * "75%": "#009900", // #00CC00 50%, #009900 75%, #ffffff 100%)
102
+ * "100%": "#ffffff"
103
+ * }
104
+ *
105
+ * {
106
+ * "from": "#afc163",
107
+ * "to": "#66FF00",// ====> linear-gradient(to right, #afc163, #66FF00)
108
+ * }
109
+ *
110
+ * @param {string} strokeColor 颜色值
111
+ * @return 返回 backgroundImage 的样式值
112
+ */
113
+
114
+ var handleGradient = function handleGradient(strokeColor, directionConfig) {
115
+ var _strokeColor$from = strokeColor.from,
116
+ from = _strokeColor$from === void 0 ? "#3D66F8" : _strokeColor$from,
117
+ _strokeColor$to = strokeColor.to,
118
+ to = _strokeColor$to === void 0 ? "#4F93F0" : _strokeColor$to,
119
+ _strokeColor$directio = strokeColor.direction,
120
+ direction = _strokeColor$directio === void 0 ? directionConfig === "rtl" ? "to left" : "to right" : _strokeColor$directio,
121
+ rest = __rest(strokeColor, ["from", "to", "direction"]); // 剩余参数有值说明除了from to direction 还传了 另外的参数
122
+
123
+
124
+ if (Object.keys(rest).length !== 0) {
125
+ var sortedGradients = sortGradient(rest);
126
+ return {
127
+ backgroundImage: "linear-gradient(".concat(direction, ", ").concat(sortedGradients, ")")
128
+ };
129
+ }
130
+
131
+ return {
132
+ backgroundImage: "linear-gradient(".concat(direction, ", ").concat(from, ", ").concat(to, ")")
133
+ };
134
+ };
135
+
136
+ var Line = function Line(props) {
137
+ var directionConfig = props.direction,
138
+ percent = props.percent,
139
+ strokeWidth = props.strokeWidth,
140
+ strokeColor = props.strokeColor,
141
+ strokeLinecap = props.strokeLinecap,
142
+ trailColor = props.trailColor;
143
+ /** 进度条高亮部分的颜色样式 **/
144
+
145
+ var backgroundProps = strokeColor && typeof strokeColor !== "string" ? handleGradient(strokeColor, directionConfig) : {
146
+ background: strokeColor
147
+ };
148
+ /** 进度条轨道部分的颜色样式 **/
149
+
150
+ var trailStyle = trailColor ? {
151
+ backgroundColor: trailColor
152
+ } : undefined;
153
+ /** 进度条百分比的样式 **/
154
+
155
+ var percentStyle = Object.assign({
156
+ width: "".concat(validProgress(percent), "%"),
157
+ height: strokeWidth || 10,
158
+ borderRadius: strokeLinecap === "square" ? 0 : ""
159
+ }, backgroundProps);
160
+ return jsx("div", Object.assign({
161
+ className: "trail-bar",
162
+ style: trailStyle
163
+ }, {
164
+ children: jsx("div", {
165
+ className: "active-bar",
166
+ style: percentStyle
167
+ })
168
+ }));
169
+ };
170
+
171
+ var css_248z = "@charset \"UTF-8\";\n/**\n* @author Hanz\n* @date 2021/10/20 下午2:08\n* @description color\n*/\n.paraui-progress-line .progress-outer {\n display: flex;\n margin-right: 8px;\n margin-bottom: 8px;\n}\n.paraui-progress-line .progress-outer .progress-inner {\n width: 100%;\n}\n.paraui-progress-line .progress-outer .progress-inner .rc-progress-line {\n height: 10px;\n width: 100%;\n}\n.paraui-progress-line .progress-outer .progress-inner .steps-outer {\n display: flex;\n flex-direction: row;\n align-items: center;\n}\n.paraui-progress-line .progress-outer .progress-inner .steps-outer .steps-item {\n flex-shrink: 0;\n min-width: 2px;\n margin-right: 2px;\n background: #f3f3f3;\n transition: all 0.3s;\n}\n.paraui-progress-line .progress-outer .progress-inner .steps-outer .steps-item-active {\n background-color: #2DB7F5;\n}\n.paraui-progress-line .progress-outer .progress-inner .trail-bar {\n position: relative;\n display: inline-block;\n width: 100%;\n overflow: hidden;\n vertical-align: middle;\n background-color: rgba(0, 0, 0, 0.0392156863);\n border-radius: 100px;\n}\n.paraui-progress-line .progress-outer .progress-inner .trail-bar .active-bar {\n position: relative;\n background-color: var(--ant-primary-color);\n border-radius: 100px;\n transition: all 0.4s cubic-bezier(0.08, 0.82, 0.17, 1) 0s;\n}\n.paraui-progress-line .progress-outer .progress-text {\n font-size: 12px;\n font-weight: 700;\n text-align: left;\n color: #3d66f8;\n display: inline-block;\n margin-left: 20px;\n white-space: nowrap;\n text-align: left;\n vertical-align: middle;\n word-break: normal;\n display: flex;\n align-items: center;\n}\n.paraui-progress-line .progress-outer .progress-text svg {\n width: 14px;\n height: 14px;\n position: relative;\n top: 2px;\n}\n.paraui-progress-line .progress-outer .progress-text svg.success {\n color: #41D658 !important;\n}\n.paraui-progress-line .progress-outer .progress-text svg.error {\n color: #F46B53 !important;\n}\n.paraui-progress-circle, .paraui-progress-dashboard {\n display: inline-block;\n position: relative;\n margin: 0 5px;\n}\n.paraui-progress-circle .progress-outer .progress-text, .paraui-progress-dashboard .progress-outer .progress-text {\n position: absolute;\n top: 50%;\n left: 50%;\n width: 100%;\n margin: 0;\n padding: 0;\n color: rgba(0, 0, 0, 0.8509803922);\n font-size: 1em;\n line-height: 1;\n white-space: normal;\n text-align: center;\n transform: translate(-50%, -50%);\n}\n.paraui-progress-circle .progress-outer .progress-text svg, .paraui-progress-dashboard .progress-outer .progress-text svg {\n width: 2em;\n height: 2em;\n}\n.paraui-progress-circle .progress-outer .progress-text svg.success, .paraui-progress-dashboard .progress-outer .progress-text svg.success {\n color: #52C41A !important;\n}\n.paraui-progress-circle .progress-outer .progress-text svg.error, .paraui-progress-dashboard .progress-outer .progress-text svg.error {\n color: #FF4D4F !important;\n}\n.paraui-progress-success-status .progress-text {\n color: #52c41a !important;\n}\n.paraui-progress-exception-status .progress-text {\n color: #ff4d4f !important;\n}\n.paraui-progress-active-status .active-bar:before {\n position: absolute;\n inset: 0;\n background: #fff;\n border-radius: 10px;\n opacity: 0;\n -webkit-animation: progress-active 2.4s cubic-bezier(0.23, 1, 0.32, 1) infinite;\n animation: progress-active 2.4s cubic-bezier(0.23, 1, 0.32, 1) infinite;\n content: \"\";\n}\n\n@keyframes progress-active {\n 0% {\n transform: translateX(-100%) scaleX(0);\n opacity: 0.1;\n }\n 20% {\n transform: translateX(-100%) scaleX(0);\n opacity: 0.5;\n }\n 100% {\n transform: translateX(0) scaleX(1);\n opacity: 0;\n }\n}";
172
+ styleInject(css_248z);
173
+
174
+ /** 进度条类型 **/
175
+
176
+ var ProgressTypes;
177
+
178
+ (function (ProgressTypes) {
179
+ ProgressTypes[ProgressTypes["line"] = 0] = "line";
180
+ ProgressTypes[ProgressTypes["circle"] = 1] = "circle";
181
+ ProgressTypes[ProgressTypes["dashboard"] = 2] = "dashboard";
182
+ })(ProgressTypes || (ProgressTypes = {}));
183
+ /** 进度条状态 **/
184
+
185
+
186
+ var ProgressStatuses;
187
+
188
+ (function (ProgressStatuses) {
189
+ ProgressStatuses[ProgressStatuses["normal"] = 0] = "normal";
190
+ ProgressStatuses[ProgressStatuses["exception"] = 1] = "exception";
191
+ ProgressStatuses[ProgressStatuses["active"] = 2] = "active";
192
+ ProgressStatuses[ProgressStatuses["success"] = 3] = "success";
193
+ })(ProgressStatuses || (ProgressStatuses = {}));
194
+ /** 每个类型对应的进度条默认颜色 **/
195
+
196
+
197
+ var strokeColorMap = {
198
+ success: "#41D658",
199
+ exception: "#F46B53",
200
+ normal: "#3D66F8",
201
+ active: "#3D66F8"
202
+ };
203
+ var Progress = function Progress(props) {
204
+ var _props$type = props.type,
205
+ type = _props$type === void 0 ? "line" : _props$type,
206
+ className = props.className;
207
+ props.children;
208
+ var status = props.status,
209
+ _props$width = props.width,
210
+ width = _props$width === void 0 ? 132 : _props$width,
211
+ _props$showInfo = props.showInfo,
212
+ showInfo = _props$showInfo === void 0 ? true : _props$showInfo,
213
+ format = props.format,
214
+ success = props.success,
215
+ _props$percent = props.percent,
216
+ percent = _props$percent === void 0 ? 0 : _props$percent,
217
+ steps = props.steps,
218
+ direction = props.direction,
219
+ strokeColor = props.strokeColor,
220
+ _props$gapDegree = props.gapDegree,
221
+ gapDegree = _props$gapDegree === void 0 ? 75 : _props$gapDegree,
222
+ otherProps = __rest(props, ["type", "className", "children", "status", "width", "showInfo", "format", "success", "percent", "steps", "direction", "strokeColor", "gapDegree"]);
223
+ /**
224
+ * 处理class
225
+ * @return {string}
226
+ */
227
+
228
+
229
+ var classString = function classString() {
230
+ var str = "paraui-progress paraui-progress-".concat(type || "default"); // 添加成功状态的class
231
+
232
+ if (isSuccessStatus) str += " paraui-progress-success-status"; // 添加错误状态下的class
233
+
234
+ if (status === "exception") str += " paraui-progress-exception-status"; // 添加active状态下的class
235
+
236
+ if (status === "active") str += " paraui-progress-active-status";
237
+ if (className) str += " " + className;
238
+ return str;
239
+ };
240
+ /**
241
+ * 处理进度条颜色
242
+ * @return {string}
243
+ */
244
+
245
+
246
+ var strokeColorVal = function strokeColorVal() {
247
+ // 如果传了成功进度条的配置
248
+ if (strokeColor) return strokeColor;
249
+
250
+ if (success && success.percent < percent) {
251
+ return [success.strokeColor || strokeColorMap["success"], strokeColorMap["normal"]];
252
+ }
253
+
254
+ return isSuccessStatus ? strokeColorMap["success"] : strokeColorMap[status || "normal"];
255
+ };
256
+ /**
257
+ * 处理进度条的值
258
+ * @return {string}
259
+ */
260
+
261
+
262
+ var renderPercent = function renderPercent() {
263
+ if (success && success.percent < percent && typeof percent === "number") {
264
+ return [success.percent, percent - success.percent];
265
+ }
266
+
267
+ return percent;
268
+ };
269
+ /** 标记是不是成功状态 **/
270
+
271
+
272
+ var isSuccessStatus = percent && percent === 100 && !status || status === "success";
273
+ /** style值 **/
274
+
275
+ var renderStyle = type === "circle" || type === "dashboard" ? {
276
+ width: width,
277
+ height: width
278
+ } : {};
279
+ /**
280
+ * 处理描述信息
281
+ * @return {string | ReactNode}
282
+ */
283
+
284
+ var renderLabel = function renderLabel() {
285
+ if (format) return format(percent);
286
+ if (isSuccessStatus) return type === "circle" ? jsx(Check, {
287
+ className: "success"
288
+ }) : jsx(SuccessOutlined, {
289
+ className: "success"
290
+ });
291
+ if (status === "exception") return type === "circle" ? jsx(CloseIcon, {
292
+ className: "error"
293
+ }) : jsx(ErrorOutlined, {
294
+ className: "error"
295
+ });
296
+ return validProgress(percent) + "%";
297
+ };
298
+ /** 默认进度条 **/
299
+
300
+
301
+ var renderLineProgress = steps ? jsx(Steps, Object.assign({
302
+ steps: steps,
303
+ strokeColor: strokeColorVal(),
304
+ percent: renderPercent()
305
+ }, otherProps, {
306
+ children: showInfo && jsx("div", Object.assign({
307
+ className: "progress-text"
308
+ }, {
309
+ children: renderLabel()
310
+ }))
311
+ })) : jsx(Line, Object.assign({
312
+ strokeColor: strokeColorVal(),
313
+ percent: renderPercent(),
314
+ direction: direction
315
+ }, otherProps, {
316
+ children: " "
317
+ }));
318
+ /** 圆形进度条 **/
319
+
320
+ var renderCircleProgress = jsx(Circle, Object.assign({
321
+ strokeWidth: 6,
322
+ trailWidth: 6,
323
+ strokeColor: strokeColorVal(),
324
+ percent: renderPercent()
325
+ }, otherProps));
326
+ /** 仪表盘 **/
327
+
328
+
329
+ var renderDashboardProgress = jsx(Circle, Object.assign({
330
+ strokeWidth: 6,
331
+ trailWidth: 6,
332
+ gapPosition: "bottom",
333
+ gapDegree: gapDegree,
334
+ strokeColor: strokeColorVal(),
335
+ percent: renderPercent()
336
+ }, otherProps));
337
+
338
+ return jsx("div", Object.assign({
339
+ className: classString()
340
+ }, {
341
+ children: jsxs("div", Object.assign({
342
+ className: "progress-outer"
343
+ }, {
344
+ children: [jsx("div", Object.assign({
345
+ className: "progress-inner",
346
+ style: renderStyle
347
+ }, {
348
+ children: type === "dashboard" ? renderDashboardProgress : type === "circle" ? renderCircleProgress : renderLineProgress
349
+ })), showInfo && !steps && jsx("div", Object.assign({
350
+ className: "progress-text"
351
+ }, {
352
+ children: renderLabel()
353
+ }))]
354
+ }))
355
+ }));
356
+ };
357
+
358
+ export { Progress, Progress as default };
@@ -1,6 +1,6 @@
1
- /**
2
- * 判断进度条传的百分比参数是否规范
3
- * @param {number | undefined} progress 方法入参说明
4
- * @return {numner} 百分比值
5
- */
6
- export declare function validProgress(progress: number | number[] | undefined): number | number[];
1
+ /**
2
+ * 判断进度条传的百分比参数是否规范
3
+ * @param {number | undefined} progress 方法入参说明
4
+ * @return {numner} 百分比值
5
+ */
6
+ export declare function validProgress(progress: number | number[] | undefined): number | number[];
@@ -1,2 +1,3 @@
1
- export declare const LargeSearch: () => JSX.Element;
2
- export declare const SmallSearch: () => JSX.Element;
1
+ /// <reference types="react" />
2
+ export declare const LargeSearch: () => JSX.Element;
3
+ export declare const SmallSearch: () => JSX.Element;
@@ -1,26 +1,26 @@
1
- /**
2
- * @author Hanz
3
- * @date 2022/4/2 上午10:45
4
- * @description
5
- */
6
- import React, { FC } from "react";
7
- import './index.scss';
8
- export interface QueryingProps {
9
- /** cls */
10
- className?: string;
11
- /** style */
12
- style?: React.CSSProperties;
13
- /** 尺寸 */
14
- size?: 'large' | 'small';
15
- /** 图片样式 */
16
- imageStyle?: React.CSSProperties;
17
- /** 图片 */
18
- image?: React.ReactNode;
19
- /** 描述 */
20
- description?: React.ReactNode;
21
- /** 自定义节点 */
22
- customQuerying?: React.ReactNode;
23
- [name: string]: any;
24
- }
25
- declare const Querying: FC<QueryingProps>;
26
- export default Querying;
1
+ /**
2
+ * @author Hanz
3
+ * @date 2022/4/2 上午10:45
4
+ * @description
5
+ */
6
+ import React, { FC } from "react";
7
+ import './index.scss';
8
+ export interface QueryingProps {
9
+ /** cls */
10
+ className?: string;
11
+ /** style */
12
+ style?: React.CSSProperties;
13
+ /** 尺寸 */
14
+ size?: 'large' | 'small';
15
+ /** 图片样式 */
16
+ imageStyle?: React.CSSProperties;
17
+ /** 图片 */
18
+ image?: React.ReactNode;
19
+ /** 描述 */
20
+ description?: React.ReactNode;
21
+ /** 自定义节点 */
22
+ customQuerying?: React.ReactNode;
23
+ [name: string]: any;
24
+ }
25
+ declare const Querying: FC<QueryingProps>;
26
+ export default Querying;