@para-ui/core 2.2.4 → 2.2.5-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 (353) hide show
  1. package/AutoBox/index.d.ts +12 -6
  2. package/AutoBox/index.js +203 -15
  3. package/AutoTips/index.d.ts +12 -6
  4. package/AutoTips/index.js +84 -15
  5. package/Breadcrumbs/index.d.ts +13 -7
  6. package/Breadcrumbs/index.js +227 -15
  7. package/Button/index.d.ts +92 -11
  8. package/Button/index.js +348 -14
  9. package/ButtonGroup/index.d.ts +21 -9
  10. package/ButtonGroup/index.js +128 -14
  11. package/Carousel/index.d.ts +17 -11
  12. package/Carousel/index.js +74 -15
  13. package/Cascader/index.d.ts +12 -7
  14. package/Cascader/index.js +166 -15
  15. package/Checkbox/index.d.ts +13 -7
  16. package/Checkbox/index.js +105 -14
  17. package/CheckboxGroup/index.d.ts +15 -9
  18. package/CheckboxGroup/index.js +138 -14
  19. package/Collapse/index.d.ts +49 -14
  20. package/Collapse/index.js +171 -15
  21. package/CollapseBox/index.d.ts +11 -5
  22. package/CollapseBox/index.js +164 -15
  23. package/ColorPicker/index.d.ts +4 -4
  24. package/ColorPicker/index.js +4 -1
  25. package/ComboSelect/index.d.ts +306 -6
  26. package/ComboSelect/index.js +1803 -14
  27. package/Container/index.d.ts +13 -8
  28. package/Container/index.js +239 -15
  29. package/DatePicker/index.d.ts +30 -17
  30. package/DatePicker/index.js +733 -14
  31. package/Desktop/index.d.ts +14 -6
  32. package/Desktop/index.js +853 -14
  33. package/Drawer/index.d.ts +92 -6
  34. package/Drawer/index.js +186 -14
  35. package/Dropdown/index.d.ts +29 -0
  36. package/Dropdown/index.js +67 -0
  37. package/Empty/index.d.ts +16 -10
  38. package/Empty/index.js +644 -14
  39. package/Form/index.d.ts +11 -9
  40. package/Form/index.js +384 -14
  41. package/FormItem/index.d.ts +5 -152
  42. package/FormItem/index.js +81 -14
  43. package/FunctionModal/index.d.ts +14 -3
  44. package/FunctionModal/index.js +39 -14
  45. package/GlobalContext/index.d.ts +38 -8
  46. package/GlobalContext/index.js +41 -16
  47. package/Help/index.d.ts +16 -10
  48. package/Help/index.js +39 -15
  49. package/HelperText/index.d.ts +11 -5
  50. package/HelperText/index.js +29 -15
  51. package/InputLang/index.d.ts +13 -7
  52. package/InputLang/index.js +270 -14
  53. package/InputNumber/index.d.ts +16 -10
  54. package/InputNumber/index.js +308 -14
  55. package/Label/index.d.ts +12 -6
  56. package/Label/index.js +81 -14
  57. package/Loading/index.d.ts +12 -6
  58. package/Loading/index.js +47 -15
  59. package/Menu/index.d.ts +123 -5
  60. package/Menu/index.js +1232 -14
  61. package/Message/index.d.ts +11 -5
  62. package/Message/index.js +222 -15
  63. package/Modal/index.d.ts +142 -40
  64. package/Modal/index.js +443 -14
  65. package/MultiBox/index.d.ts +13 -7
  66. package/MultiBox/index.js +231 -14
  67. package/Notification/index.d.ts +22 -16
  68. package/Notification/index.js +266 -15
  69. package/OperateBtn/index.d.ts +16 -10
  70. package/OperateBtn/index.js +260 -14
  71. package/PageHeader/index.d.ts +178 -5
  72. package/PageHeader/index.js +1171 -14
  73. package/Pagination/index.d.ts +12 -6
  74. package/Pagination/index.js +469 -14
  75. package/ParauiProvider/index.d.ts +9 -8
  76. package/ParauiProvider/index.js +53 -15
  77. package/PopConfirm/index.d.ts +23 -10
  78. package/PopConfirm/index.js +189 -14
  79. package/Popover/index.d.ts +18 -11
  80. package/Popover/index.js +66 -15
  81. package/Progress/index.d.ts +18 -12
  82. package/Progress/index.js +358 -20
  83. package/Querying/index.d.ts +15 -9
  84. package/Querying/index.js +762 -14
  85. package/Radio/index.d.ts +13 -7
  86. package/Radio/index.js +94 -14
  87. package/RadioGroup/index.d.ts +15 -9
  88. package/RadioGroup/index.js +128 -14
  89. package/Search/index.d.ts +18 -12
  90. package/Search/index.js +220 -14
  91. package/Select/index.d.ts +13 -7
  92. package/Select/index.js +1288 -14
  93. package/SelectInput/index.d.ts +11 -5
  94. package/SelectInput/index.js +51 -14
  95. package/SingleBox/index.d.ts +13 -7
  96. package/SingleBox/index.js +194 -14
  97. package/Slider/index.d.ts +104 -7
  98. package/Slider/index.js +125 -15
  99. package/Split/index.d.ts +8 -3
  100. package/Split/index.js +134 -15
  101. package/Stepper/index.d.ts +41 -25
  102. package/Stepper/index.js +99 -15
  103. package/Switch/index.d.ts +16 -10
  104. package/Switch/index.js +73 -14
  105. package/Table/index.d.ts +12 -4
  106. package/Table/index.js +2725 -14
  107. package/Tabs/index.d.ts +64 -29
  108. package/Tabs/index.js +218 -14
  109. package/Tag/index.d.ts +78 -12
  110. package/Tag/index.js +286 -14
  111. package/Test/index.d.ts +3 -2
  112. package/Test/index.js +9 -16
  113. package/TextField/index.d.ts +22 -16
  114. package/TextField/index.js +686 -14
  115. package/TimePicker/index.d.ts +20 -10
  116. package/TimePicker/index.js +77 -14
  117. package/Timeline/index.d.ts +49 -13
  118. package/Timeline/index.js +150 -15
  119. package/ToggleButton/index.d.ts +61 -10
  120. package/ToggleButton/index.js +200 -14
  121. package/Tooltip/index.d.ts +12 -10
  122. package/Tooltip/index.js +335 -15
  123. package/Transfer/index.d.ts +8 -3
  124. package/Transfer/index.js +343 -14
  125. package/Tree/index.d.ts +8 -5
  126. package/Tree/index.js +35 -14
  127. package/Upload/index.d.ts +179 -8
  128. package/Upload/index.js +1542 -14
  129. package/_verture/defineProperty-0590dc61.js +16 -0
  130. package/_verture/index-0d8e1d07.js +4 -0
  131. package/_verture/index-14a47097.js +4 -0
  132. package/_verture/index-342379c6.js +391 -0
  133. package/_verture/index-458032d7.js +10 -0
  134. package/_verture/index-46bfb2f0.js +778 -0
  135. package/_verture/index-50401de7.js +4 -0
  136. package/_verture/index-5b08df83.js +4 -0
  137. package/_verture/index-6190b129.js +4 -0
  138. package/_verture/index-7ef1e3b6.js +1553 -0
  139. package/_verture/index-a369ca3f.js +4 -0
  140. package/_verture/index-c60911dc.js +39 -0
  141. package/_verture/index-e2881a53.js +16 -0
  142. package/_verture/index-ff4c2a27.js +200 -0
  143. package/{Tree/interface.d.ts → _verture/interface-128abdd3.js} +15 -25
  144. package/_verture/interface-a77a851e.js +25 -0
  145. package/{Table/interface.d.ts → _verture/interface-a9b7c716.js} +20 -28
  146. package/_verture/intl-336570e4.js +65 -0
  147. package/_verture/modalContext-25890584.js +228 -0
  148. package/_verture/modalContext-639f2787.js +58 -0
  149. package/_verture/slicedToArray-d7722f4b.js +62 -0
  150. package/_verture/style-inject.es-300983ab.js +28 -0
  151. package/_verture/toConsumableArray-f8047a75.js +19 -0
  152. package/_verture/tslib.es6-55ed4bd2.js +38 -0
  153. package/_verture/typeof-498dd2b1.js +11 -0
  154. package/_verture/useFormatMessage-ac9d6acf.js +20 -0
  155. package/_verture/useGlobalProps-af9a2af6.js +12 -0
  156. package/index.d.ts +88 -128
  157. package/index.js +160 -19
  158. package/package.json +59 -22
  159. package/Button/SplitButton.d.ts +0 -61
  160. package/Button/lang/en_US.d.ts +0 -4
  161. package/Button/lang/index.d.ts +0 -9
  162. package/Button/lang/zh_CN.d.ts +0 -4
  163. package/Cascader/lang/en_US.d.ts +0 -4
  164. package/Cascader/lang/index.d.ts +0 -9
  165. package/Cascader/lang/zh_CN.d.ts +0 -4
  166. package/Collapse/collapsePanel.d.ts +0 -30
  167. package/Collapse/motion.d.ts +0 -5
  168. package/Collapse/util.d.ts +0 -11
  169. package/CollapseBox/util.d.ts +0 -5
  170. package/ComboSelect/WithTabsCombo/index.d.ts +0 -11
  171. package/ComboSelect/WithTabsCombo/interface.d.ts +0 -141
  172. package/ComboSelect/interface.d.ts +0 -143
  173. package/ComboSelect/lang/en_US.d.ts +0 -8
  174. package/ComboSelect/lang/index.d.ts +0 -17
  175. package/ComboSelect/lang/zh_CN.d.ts +0 -8
  176. package/ComboSelect/utils.d.ts +0 -12
  177. package/DatePicker/PickerButton.d.ts +0 -3
  178. package/DatePicker/PickerTag.d.ts +0 -3
  179. package/DatePicker/generatePicker/generateRangePicker.d.ts +0 -4
  180. package/DatePicker/generatePicker/generateSinglePicker.d.ts +0 -11
  181. package/DatePicker/generatePicker/index.d.ts +0 -77
  182. package/DatePicker/lang/en_US.d.ts +0 -3
  183. package/DatePicker/lang/index.d.ts +0 -7
  184. package/DatePicker/lang/zh_CN.d.ts +0 -3
  185. package/DatePicker/util.d.ts +0 -20
  186. package/Drawer/interface.d.ts +0 -83
  187. package/Drawer/lang/en_US.d.ts +0 -5
  188. package/Drawer/lang/index.d.ts +0 -11
  189. package/Drawer/lang/zh_CN.d.ts +0 -5
  190. package/Empty/images/index.d.ts +0 -2
  191. package/Empty/lang/en_US.d.ts +0 -6
  192. package/Empty/lang/index.d.ts +0 -13
  193. package/Empty/lang/zh_CN.d.ts +0 -6
  194. package/FormItem/compoments/defaultCompoments/index.d.ts +0 -19
  195. package/FormItem/compoments/formCheckboxGroup/index.d.ts +0 -8
  196. package/FormItem/compoments/formFile/index.d.ts +0 -38
  197. package/FormItem/compoments/formRadioGroup/index.d.ts +0 -8
  198. package/FormItem/compoments/formSelect/index.d.ts +0 -18
  199. package/FormItem/errorTips.d.ts +0 -12
  200. package/FormItem/itemType.d.ts +0 -42
  201. package/FormItem/validateFunction.d.ts +0 -15
  202. package/FunctionModal/dialog.d.ts +0 -58
  203. package/FunctionModal/modalContext.d.ts +0 -14
  204. package/GlobalContext/componentsProps.d.ts +0 -19
  205. package/GlobalContext/confirmLocale.d.ts +0 -7
  206. package/GlobalContext/intl.d.ts +0 -34
  207. package/GlobalContext/useFormatMessage.d.ts +0 -3
  208. package/Hooks/useGlobalProps.d.ts +0 -1
  209. package/Menu/footerExpansion.d.ts +0 -9
  210. package/Menu/interface.d.ts +0 -139
  211. package/Menu/logo.d.ts +0 -9
  212. package/Menu/verticalMenuList.d.ts +0 -14
  213. package/Modal/Confirm/index.d.ts +0 -66
  214. package/Modal/lang/en_US.d.ts +0 -5
  215. package/Modal/lang/index.d.ts +0 -11
  216. package/Modal/lang/zh_CN.d.ts +0 -5
  217. package/OperateBtn/lang/en_US.d.ts +0 -4
  218. package/OperateBtn/lang/index.d.ts +0 -9
  219. package/OperateBtn/lang/zh_CN.d.ts +0 -4
  220. package/PageHeader/horizontalMeun.d.ts +0 -9
  221. package/PageHeader/horizontalMeunRight.d.ts +0 -9
  222. package/PageHeader/interface.d.ts +0 -167
  223. package/Pagination/lang/en_US.d.ts +0 -8
  224. package/Pagination/lang/index.d.ts +0 -17
  225. package/Pagination/lang/zh_CN.d.ts +0 -8
  226. package/PopConfirm/lang/en_US.d.ts +0 -5
  227. package/PopConfirm/lang/index.d.ts +0 -11
  228. package/PopConfirm/lang/zh_CN.d.ts +0 -5
  229. package/Popper/index.d.ts +0 -13
  230. package/Popper/index.js +0 -16
  231. package/Progress/Line.d.ts +0 -47
  232. package/Progress/Steps.d.ts +0 -17
  233. package/Progress/utils.d.ts +0 -6
  234. package/Querying/images/index.d.ts +0 -2
  235. package/Querying/lang/en_US.d.ts +0 -4
  236. package/Querying/lang/index.d.ts +0 -9
  237. package/Querying/lang/zh_CN.d.ts +0 -4
  238. package/README.md +0 -489
  239. package/Select/lang/en_US.d.ts +0 -5
  240. package/Select/lang/index.d.ts +0 -11
  241. package/Select/lang/zh_CN.d.ts +0 -5
  242. package/Slider/interface.d.ts +0 -102
  243. package/Stepper/icons.d.ts +0 -5
  244. package/Table/lang/en_US.d.ts +0 -6
  245. package/Table/lang/index.d.ts +0 -13
  246. package/Table/lang/zh_CN.d.ts +0 -6
  247. package/Table/tableBody.d.ts +0 -9
  248. package/Table/tableBodyElement/index.d.ts +0 -15
  249. package/Table/tableBodyInterface.d.ts +0 -67
  250. package/Table/tableContainer/index.d.ts +0 -16
  251. package/Table/tableElement/index.d.ts +0 -17
  252. package/Table/tableHead.d.ts +0 -9
  253. package/Table/tableHeadElement/index.d.ts +0 -15
  254. package/Table/tableHeadInterface.d.ts +0 -30
  255. package/Table/tablePagination.d.ts +0 -9
  256. package/Table/tablePaginationInterFace.d.ts +0 -24
  257. package/Table/tdElement/index.d.ts +0 -15
  258. package/Table/thElement/index.d.ts +0 -15
  259. package/Table/trElement/index.d.ts +0 -15
  260. package/Table/util.d.ts +0 -16
  261. package/Tag/TagGroup.d.ts +0 -66
  262. package/TimePicker/locale/en_US.d.ts +0 -3
  263. package/TimePicker/locale/zh_CN.d.ts +0 -3
  264. package/TimePicker/style/index.d.ts +0 -1
  265. package/ToggleButton/ToggleButtonGroup.d.ts +0 -49
  266. package/Transfer/lang/en_US.d.ts +0 -6
  267. package/Transfer/lang/index.d.ts +0 -13
  268. package/Transfer/lang/zh_CN.d.ts +0 -6
  269. package/Tree/OperateBar/index.d.ts +0 -13
  270. package/Tree/Tree.d.ts +0 -4
  271. package/Tree/lang/en_US.d.ts +0 -8
  272. package/Tree/lang/index.d.ts +0 -17
  273. package/Tree/lang/zh_CN.d.ts +0 -8
  274. package/Tree/utils/closestPolyfill.d.ts +0 -0
  275. package/Tree/utils/tools.d.ts +0 -26
  276. package/Tree/utils/treeUtil.d.ts +0 -15
  277. package/Upload/Dragger/index.d.ts +0 -10
  278. package/Upload/ErroTip/index.d.ts +0 -13
  279. package/Upload/ImageUpload/index.d.ts +0 -14
  280. package/Upload/ImgCrop/EasyCrop.d.ts +0 -17
  281. package/Upload/ImgCrop/constants.d.ts +0 -7
  282. package/Upload/ImgCrop/index.d.ts +0 -6
  283. package/Upload/ImgCrop/interface.d.ts +0 -24
  284. package/Upload/UploadList/index.d.ts +0 -5
  285. package/Upload/interface.d.ts +0 -134
  286. package/Upload/lang/en_US.d.ts +0 -12
  287. package/Upload/lang/index.d.ts +0 -25
  288. package/Upload/lang/zh_CN.d.ts +0 -12
  289. package/cdn/AutoBox/index.js +0 -29
  290. package/cdn/AutoTips/index.js +0 -40
  291. package/cdn/Breadcrumbs/index.js +0 -53
  292. package/cdn/Button/index.js +0 -79
  293. package/cdn/ButtonGroup/index.js +0 -79
  294. package/cdn/Carousel/index.js +0 -6
  295. package/cdn/Cascader/index.js +0 -42
  296. package/cdn/Checkbox/index.js +0 -53
  297. package/cdn/CheckboxGroup/index.js +0 -53
  298. package/cdn/Collapse/index.js +0 -27
  299. package/cdn/CollapseBox/index.js +0 -1
  300. package/cdn/ColorPicker/index.js +0 -1
  301. package/cdn/ComboSelect/index.js +0 -438
  302. package/cdn/Container/index.js +0 -1
  303. package/cdn/DatePicker/index.js +0 -185
  304. package/cdn/Desktop/index.js +0 -24
  305. package/cdn/Drawer/index.js +0 -84
  306. package/cdn/Empty/index.js +0 -1
  307. package/cdn/Form/index.js +0 -477
  308. package/cdn/FormItem/index.js +0 -477
  309. package/cdn/FunctionModal/index.js +0 -144
  310. package/cdn/GlobalContext/index.js +0 -1
  311. package/cdn/Help/index.js +0 -53
  312. package/cdn/HelperText/index.js +0 -1
  313. package/cdn/InputLang/index.js +0 -144
  314. package/cdn/InputNumber/index.js +0 -118
  315. package/cdn/Label/index.js +0 -53
  316. package/cdn/Loading/index.js +0 -14
  317. package/cdn/Menu/index.js +0 -40
  318. package/cdn/Message/index.js +0 -53
  319. package/cdn/Modal/index.js +0 -144
  320. package/cdn/MultiBox/index.js +0 -131
  321. package/cdn/Notification/index.js +0 -66
  322. package/cdn/OperateBtn/index.js +0 -92
  323. package/cdn/PageHeader/index.js +0 -92
  324. package/cdn/Pagination/index.js +0 -214
  325. package/cdn/ParauiProvider/index.js +0 -9
  326. package/cdn/PopConfirm/index.js +0 -131
  327. package/cdn/Popover/index.js +0 -16
  328. package/cdn/Popper/index.js +0 -26
  329. package/cdn/Progress/index.js +0 -58
  330. package/cdn/Querying/index.js +0 -1
  331. package/cdn/Radio/index.js +0 -53
  332. package/cdn/RadioGroup/index.js +0 -53
  333. package/cdn/Search/index.js +0 -144
  334. package/cdn/Select/index.js +0 -131
  335. package/cdn/SelectInput/index.js +0 -131
  336. package/cdn/SingleBox/index.js +0 -131
  337. package/cdn/Slider/index.js +0 -16
  338. package/cdn/Split/index.js +0 -1
  339. package/cdn/Stepper/index.js +0 -154
  340. package/cdn/Switch/index.js +0 -71
  341. package/cdn/Table/index.js +0 -292
  342. package/cdn/Tabs/index.js +0 -165
  343. package/cdn/Tag/index.js +0 -27
  344. package/cdn/Test/index.js +0 -1
  345. package/cdn/TextField/index.js +0 -105
  346. package/cdn/TimePicker/index.js +0 -185
  347. package/cdn/Timeline/index.js +0 -16
  348. package/cdn/ToggleButton/index.js +0 -79
  349. package/cdn/Tooltip/index.js +0 -40
  350. package/cdn/Transfer/index.js +0 -170
  351. package/cdn/Tree/index.js +0 -170
  352. package/cdn/Upload/index.js +0 -252
  353. package/style.css +0 -72
package/Popover/index.js CHANGED
@@ -1,15 +1,66 @@
1
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react"),require("@material-ui/core")):"function"==typeof define&&define.amd?define(["react","@material-ui/core"],t):"object"==typeof exports?exports.ParaUI=t(require("react"),require("@material-ui/core")):e.ParaUI=t(e.react,e["@material-ui/core"])}(self,(function(e,t){return function(){var r={5845:function(e,t,r){(t=r(3645)(!1)).push([e.id,".paraui-popover-paper{box-shadow:0px 2px 8px 0px rgba(171,176,185,.4)}",""]),e.exports=t},3645:function(e){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var r=function(e,t){var r=e[1]||"",n=e[3];if(!n)return r;if(t&&"function"==typeof btoa){var o=(i=n,c=btoa(unescape(encodeURIComponent(JSON.stringify(i)))),u="sourceMappingURL=data:application/json;charset=utf-8;base64,".concat(c),"/*# ".concat(u," */")),a=n.sources.map((function(e){return"/*# sourceURL=".concat(n.sourceRoot||"").concat(e," */")}));return[r].concat(a).concat([o]).join("\n")}var i,c,u;return[r].join("\n")}(t,e);return t[2]?"@media ".concat(t[2]," {").concat(r,"}"):r})).join("")},t.i=function(e,r,n){"string"==typeof e&&(e=[[null,e,""]]);var o={};if(n)for(var a=0;a<this.length;a++){var i=this[a][0];null!=i&&(o[i]=!0)}for(var c=0;c<e.length;c++){var u=[].concat(e[c]);n&&o[u[0]]||(r&&(u[2]?u[2]="".concat(r," and ").concat(u[2]):u[2]=r),t.push(u))}},t}},7418:function(e){"use strict";
2
- /*
3
- object-assign
4
- (c) Sindre Sorhus
5
- @license MIT
6
- */var t=Object.getOwnPropertySymbols,r=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;function o(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 t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var n={};return"abcdefghijklmnopqrst".split("").forEach((function(e){n[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},n)).join("")}catch(e){return!1}}()?Object.assign:function(e,a){for(var i,c,u=o(e),s=1;s<arguments.length;s++){for(var f in i=Object(arguments[s]))r.call(i,f)&&(u[f]=i[f]);if(t){c=t(i);for(var l=0;l<c.length;l++)n.call(i,c[l])&&(u[c[l]]=i[c[l]])}}return u}},5251:function(e,t,r){"use strict";
7
- /** @license React v17.0.2
8
- * react-jsx-runtime.production.min.js
9
- *
10
- * Copyright (c) Facebook, Inc. and its affiliates.
11
- *
12
- * This source code is licensed under the MIT license found in the
13
- * LICENSE file in the root directory of this source tree.
14
- */
15
- r(7418);var n=r(8156),o=60103;if(60107,"function"==typeof Symbol&&Symbol.for){var a=Symbol.for;o=a("react.element"),a("react.fragment")}var i=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,c=Object.prototype.hasOwnProperty,u={key:!0,ref:!0,__self:!0,__source:!0};function s(e,t,r){var n,a={},s=null,f=null;for(n in void 0!==r&&(s=""+r),void 0!==t.key&&(s=""+t.key),void 0!==t.ref&&(f=t.ref),t)c.call(t,n)&&!u.hasOwnProperty(n)&&(a[n]=t[n]);if(e&&e.defaultProps)for(n in t=e.defaultProps)void 0===a[n]&&(a[n]=t[n]);return{$$typeof:o,type:e,key:s,ref:f,props:a,_owner:i.current}}t.jsx=s},5893:function(e,t,r){"use strict";e.exports=r(5251)},8939:function(e,t,r){var n=r(3379),o=r(5845);"string"==typeof(o=o.__esModule?o.default:o)&&(o=[[e.id,o,""]]);var a={insert:("body","body"),singleton:!1};n(o,a);e.exports=o.locals||{}},3379:function(e,t,r){"use strict";var n,o=function(){return void 0===n&&(n=Boolean(window&&document&&document.all&&!window.atob)),n},a=function(){var e={};return function(t){if(void 0===e[t]){var r=document.querySelector(t);if(window.HTMLIFrameElement&&r instanceof window.HTMLIFrameElement)try{r=r.contentDocument.head}catch(e){r=null}e[t]=r}return e[t]}}(),i=[];function c(e){for(var t=-1,r=0;r<i.length;r++)if(i[r].identifier===e){t=r;break}return t}function u(e,t){for(var r={},n=[],o=0;o<e.length;o++){var a=e[o],u=t.base?a[0]+t.base:a[0],s=r[u]||0,f="".concat(u," ").concat(s);r[u]=s+1;var l=c(f),p={css:a[1],media:a[2],sourceMap:a[3]};-1!==l?(i[l].references++,i[l].updater(p)):i.push({identifier:f,updater:b(p,t),references:1}),n.push(f)}return n}function s(e){var t=document.createElement("style"),n=e.attributes||{};if(void 0===n.nonce){var o=r.nc;o&&(n.nonce=o)}if(Object.keys(n).forEach((function(e){t.setAttribute(e,n[e])})),"function"==typeof e.insert)e.insert(t);else{var i=a(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(t)}return t}var f,l=(f=[],function(e,t){return f[e]=t,f.filter(Boolean).join("\n")});function p(e,t,r,n){var o=r?"":n.media?"@media ".concat(n.media," {").concat(n.css,"}"):n.css;if(e.styleSheet)e.styleSheet.cssText=l(t,o);else{var a=document.createTextNode(o),i=e.childNodes;i[t]&&e.removeChild(i[t]),i.length?e.insertBefore(a,i[t]):e.appendChild(a)}}function d(e,t,r){var n=r.css,o=r.media,a=r.sourceMap;if(o?e.setAttribute("media",o):e.removeAttribute("media"),a&&"undefined"!=typeof btoa&&(n+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),e.styleSheet)e.styleSheet.cssText=n;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(n))}}var v=null,y=0;function b(e,t){var r,n,o;if(t.singleton){var a=y++;r=v||(v=s(t)),n=p.bind(null,r,a,!1),o=p.bind(null,r,a,!0)}else r=s(t),n=d.bind(null,r,t),o=function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(r)};return n(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap)return;n(e=t)}else o()}}e.exports=function(e,t){(t=t||{}).singleton||"boolean"==typeof t.singleton||(t.singleton=o());var r=u(e=e||[],t);return function(e){if(e=e||[],"[object Array]"===Object.prototype.toString.call(e)){for(var n=0;n<r.length;n++){var o=c(r[n]);i[o].references--}for(var a=u(e,t),s=0;s<r.length;s++){var f=c(r[s]);0===i[f].references&&(i[f].updater(),i.splice(f,1))}r=a}}}},670:function(e){"use strict";e.exports=t},8156:function(t){"use strict";t.exports=e}},n={};function o(e){var t=n[e];if(void 0!==t)return t.exports;var a=n[e]={id:e,exports:{}};return r[e](a,a.exports,o),a.exports}o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,{a:t}),t},o.d=function(e,t){for(var r in t)o.o(t,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.nc=void 0;var a={};return function(){"use strict";o.r(a),o.d(a,{Popover:function(){return i}});var e=o(5893),t=o(670),r=(o(8939),function(){return r=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var o in t=arguments[r])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},r.apply(this,arguments)}),n=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]])}return r},i=function(o){var a,i=o.className,c=o.children,u=o.classes,s=o.style,f=n(o,["className","children","classes","style"]);return(0,e.jsx)(t.Popover,r({style:r({zIndex:1300},s),className:(a="paraui-popover",i&&(a+=" "+i),a),classes:{paper:u?"paraui-popover-paper ".concat(u):"paraui-popover-paper"}},f,{children:c}))};a.default=i}(),a}()}));
1
+ import { _ as __rest } from '../_verture/tslib.es6-55ed4bd2.js';
2
+ import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
3
+ import React__default from 'react';
4
+ import { Tooltip } from '../Tooltip/index.js';
5
+ import { s as styleInject } from '../_verture/style-inject.es-300983ab.js';
6
+ import '../_verture/slicedToArray-d7722f4b.js';
7
+ import 'rc-tooltip';
8
+ import 'rc-tooltip/lib/placements';
9
+ import 'clsx';
10
+
11
+ var css_248z = "@charset \"UTF-8\";\n/**\n* @author Hanz\n* @date 2022/6/7 上午11:06\n* @description\n*/\n/**\n* @author Hanz\n* @date 2021/10/20 下午2:08\n* @description color\n*/\n.paraui-popover {\n color: rgb(46, 55, 67);\n font-size: 14px;\n font-variant: tabular-nums;\n line-height: 1.5715;\n list-style: none;\n font-feature-settings: \"tnum\";\n position: absolute;\n top: 0;\n left: 0;\n z-index: 1500;\n font-weight: 400;\n white-space: normal;\n text-align: left;\n cursor: auto;\n user-select: text;\n}\n.paraui-popover::after {\n position: absolute;\n background: rgba(255, 255, 255, 0.01);\n content: \"\";\n}\n.paraui-popover-hidden {\n display: none;\n}\n.paraui-popover-inner {\n background-color: rgb(255, 255, 255);\n background-clip: padding-box;\n border-radius: 4px;\n box-shadow: 0px 2px 8px 0px rgba(171, 176, 185, 0.4);\n}\n.paraui-popover-title {\n min-height: 32px;\n margin: 0;\n padding: 4px 16px;\n color: rgb(46, 55, 67);\n font-weight: 400;\n border-bottom: 1px solid #f0f0f0;\n}\n.paraui-popover-inner-content {\n color: rgb(46, 55, 67);\n}\n.paraui-popover-buttons {\n margin-bottom: 4px;\n text-align: right;\n}\n.paraui-popover-buttons button {\n margin-left: 8px;\n}\n.paraui-popover-arrow {\n position: absolute;\n display: block;\n width: 16px;\n height: 16px;\n overflow: hidden;\n background: transparent;\n pointer-events: none;\n}\n.paraui-popover-arrow-content {\n position: absolute;\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n display: block;\n width: 11.3137085px;\n height: 11.3137085px;\n margin: auto;\n background-color: rgb(255, 255, 255);\n content: \"\";\n border-radius: 0 0 4px;\n pointer-events: none;\n}\n.paraui-popover-arrow-content::before {\n position: absolute;\n top: -11.3137085px;\n left: -11.3137085px;\n width: 33.9411255px;\n height: 33.9411255px;\n background: rgb(255, 255, 255) -10px -10px no-repeat;\n content: \"\";\n -webkit-clip-path: path(\"M 9.849242404917499 24.091883092036785 A 5 5 0 0 1 13.384776310850237 22.627416997969522 L 20.627416997969522 22.627416997969522 A 2 2 0 0 0 22.627416997969522 20.627416997969522 L 22.627416997969522 13.384776310850237 A 5 5 0 0 1 24.091883092036785 9.849242404917499 L 23.091883092036785 9.849242404917499 L 9.849242404917499 23.091883092036785 Z\");\n}\n.paraui-popover-placement-top .paraui-popover-arrow, .paraui-popover-placement-topLeft .paraui-popover-arrow, .paraui-popover-placement-topRight .paraui-popover-arrow {\n bottom: -0.6862915px;\n}\n.paraui-popover-placement-top .paraui-popover-arrow-content, .paraui-popover-placement-topLeft .paraui-popover-arrow-content, .paraui-popover-placement-topRight .paraui-popover-arrow-content {\n box-shadow: 3px 3px 7px rgba(0, 0, 0, 0.07);\n transform: translateY(-1px) rotate(45deg);\n}\n.paraui-popover-placement-top .paraui-popover-arrow {\n left: 50%;\n transform: translateX(-50%);\n}\n.paraui-popover-placement-topLeft .paraui-popover-arrow {\n left: 16px;\n}\n.paraui-popover-placement-topRight .paraui-popover-arrow {\n right: 16px;\n}\n.paraui-popover-placement-right .paraui-popover-arrow, .paraui-popover-placement-rightTop .paraui-popover-arrow, .paraui-popover-placement-rightBottom .paraui-popover-arrow {\n left: -0.6862915px;\n}\n.paraui-popover-placement-right .paraui-popover-arrow-content, .paraui-popover-placement-rightTop .paraui-popover-arrow-content, .paraui-popover-placement-rightBottom .paraui-popover-arrow-content {\n box-shadow: 3px 3px 7px rgba(0, 0, 0, 0.07);\n transform: translateX(1px) rotate(135deg);\n}\n.paraui-popover-placement-right .paraui-popover-arrow {\n top: 50%;\n transform: translateY(-50%);\n}\n.paraui-popover-placement-rightTop .paraui-popover-arrow {\n top: 12px;\n}\n.paraui-popover-placement-rightBottom .paraui-popover-arrow {\n bottom: 12px;\n}\n.paraui-popover-placement-bottom .paraui-popover-arrow, .paraui-popover-placement-bottomLeft .paraui-popover-arrow, .paraui-popover-placement-bottomRight .paraui-popover-arrow {\n top: -0.6862915px;\n}\n.paraui-popover-placement-bottom .paraui-popover-arrow-content, .paraui-popover-placement-bottomLeft .paraui-popover-arrow-content, .paraui-popover-placement-bottomRight .paraui-popover-arrow-content {\n box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.06);\n transform: translateY(1px) rotate(-135deg);\n}\n.paraui-popover-placement-bottom .paraui-popover-arrow {\n left: 50%;\n transform: translateX(-50%);\n}\n.paraui-popover-placement-bottomLeft .paraui-popover-arrow {\n left: 16px;\n}\n.paraui-popover-placement-bottomRight .paraui-popover-arrow {\n right: 16px;\n}\n.paraui-popover-placement-left .paraui-popover-arrow, .paraui-popover-placement-leftTop .paraui-popover-arrow, .paraui-popover-placement-leftBottom .paraui-popover-arrow {\n right: -0.6862915px;\n}\n.paraui-popover-placement-left .paraui-popover-arrow-content, .paraui-popover-placement-leftTop .paraui-popover-arrow-content, .paraui-popover-placement-leftBottom .paraui-popover-arrow-content {\n box-shadow: 3px 3px 7px rgba(0, 0, 0, 0.07);\n transform: translateX(-1px) rotate(-45deg);\n}\n.paraui-popover-placement-left .paraui-popover-arrow {\n top: 50%;\n transform: translateY(-50%);\n}\n.paraui-popover-placement-leftTop .paraui-popover-arrow {\n top: 12px;\n}\n.paraui-popover-placement-leftBottom .paraui-popover-arrow {\n bottom: 12px;\n}\n\n.paraui-popover-zoom-big-enter,\n.paraui-popover-zoom-big-appear {\n animation-duration: 0.2s;\n animation-fill-mode: both;\n animation-play-state: paused;\n}\n\n.paraui-popover-zoom-big-leave {\n animation-duration: 0.2s;\n animation-fill-mode: both;\n animation-play-state: paused;\n}\n\n.paraui-popover-zoom-big-enter.paraui-popover-zoom-big-enter-active,\n.paraui-popover-zoom-big-appear.paraui-popover-zoom-big-appear-active {\n animation-name: parauiPopoverZoomBigIn;\n animation-play-state: running;\n}\n\n.paraui-popover-zoom-big-leave.paraui-popover-zoom-big-leave-active {\n animation-name: parauiPopoverZoomBigOut;\n animation-play-state: running;\n pointer-events: none;\n}\n\n.paraui-popover-zoom-big-enter,\n.paraui-popover-zoom-big-appear {\n transform: scale(0);\n opacity: 0;\n animation-timing-function: cubic-bezier(0.08, 0.82, 0.17, 1);\n}\n\n.paraui-popover-zoom-big-enter-prepare,\n.paraui-popover-zoom-big-appear-prepare {\n transform: none;\n}\n\n.paraui-popover-zoom-big-leave {\n animation-timing-function: cubic-bezier(0.78, 0.14, 0.15, 0.86);\n}\n\n@keyframes parauiPopoverZoomBigIn {\n 0% {\n transform: scale(0.8);\n opacity: 0;\n }\n 100% {\n transform: scale(1);\n opacity: 1;\n }\n}\n@keyframes parauiPopoverZoomBigOut {\n 0% {\n transform: scale(1);\n }\n 100% {\n transform: scale(0.8);\n opacity: 0;\n }\n}";
12
+ styleInject(css_248z);
13
+
14
+ var Popover = /*#__PURE__*/React__default.forwardRef(function (props, ref) {
15
+ var title = props.title,
16
+ content = props.content,
17
+ restProps = __rest(props, ["title", "content"]);
18
+
19
+ var getPopupContainer = function getPopupContainer(triggerNode) {
20
+ var container;
21
+
22
+ if (!props.getPopupContainer) {
23
+ container = document.querySelector('.para-container-right');
24
+ if (!container) container = document.body;
25
+ } else {
26
+ container = props.getPopupContainer(triggerNode) || document.body;
27
+ }
28
+
29
+ return container;
30
+ }; //浮层
31
+
32
+
33
+ var getOverlay = function getOverlay(prefixCls) {
34
+ if (!title && !content) return null;
35
+ return jsxs(Fragment, {
36
+ children: [title && jsx("div", Object.assign({
37
+ className: "".concat(prefixCls, "-title")
38
+ }, {
39
+ children: title
40
+ })), jsx("div", Object.assign({
41
+ className: "".concat(prefixCls, "-inner-content")
42
+ }, {
43
+ children: content
44
+ }))]
45
+ });
46
+ };
47
+
48
+ var prefixCls = 'paraui-popover';
49
+ return jsx(Tooltip, Object.assign({}, restProps, {
50
+ prefixCls: prefixCls,
51
+ ref: ref,
52
+ title: getOverlay(prefixCls),
53
+ transitionName: 'paraui-popover-zoom-big',
54
+ getPopupContainer: getPopupContainer
55
+ }));
56
+ });
57
+ Popover.displayName = 'Popover';
58
+ Popover.defaultProps = {
59
+ placement: 'bottom',
60
+ trigger: 'click',
61
+ mouseEnterDelay: 0.1,
62
+ mouseLeaveDelay: 0.1,
63
+ arrow: false
64
+ };
65
+
66
+ export { Popover, Popover as default };
@@ -1,17 +1,22 @@
1
+ import React__default, { FunctionComponent } from 'react';
2
+ import styleInject from './node_modules/style-inject/dist/style-inject.es.js';
3
+
4
+ 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}";
5
+ styleInject(css_248z);
6
+
1
7
  /**
2
8
  * @author jill
3
9
  * @date 2022/3/10 18:25
4
10
  * @description 进度条
5
11
  */
6
- import React, { FunctionComponent } from "react";
7
- import "./index.scss";
12
+
8
13
  /** 进度条类型 **/
9
14
  declare enum ProgressTypes {
10
15
  "line" = 0,
11
16
  "circle" = 1,
12
17
  "dashboard" = 2
13
18
  }
14
- export declare type ProgressType = typeof ProgressTypes[number];
19
+ declare type ProgressType = typeof ProgressTypes[number];
15
20
  /** 进度条状态 **/
16
21
  declare enum ProgressStatuses {
17
22
  "normal" = 0,
@@ -20,7 +25,7 @@ declare enum ProgressStatuses {
20
25
  "success" = 3
21
26
  }
22
27
  /** 渐变进度条入参格式 两种 **/
23
- export declare type StringGradients = {
28
+ declare type StringGradients = {
24
29
  [percentage: string]: string;
25
30
  };
26
31
  declare type FromToGradients = {
@@ -28,19 +33,19 @@ declare type FromToGradients = {
28
33
  to: string;
29
34
  };
30
35
  declare type ColorStringGradients = [string, StringGradients];
31
- export declare type ProgressGradient = {
36
+ declare type ProgressGradient = {
32
37
  direction?: string;
33
38
  } & (StringGradients | FromToGradients);
34
39
  /** 进度条渐变方向 **/
35
- export declare type DirectionType = "ltr" | "rtl" | undefined;
40
+ declare type DirectionType = "ltr" | "rtl" | undefined;
36
41
  /** 成功的进度条的配置 **/
37
- export interface SuccessProps {
42
+ interface SuccessProps {
38
43
  /** 进度条值 **/
39
44
  percent: number;
40
45
  /** 进度条颜色 **/
41
46
  strokeColor?: string;
42
47
  }
43
- export interface ProgressProps {
48
+ interface ProgressProps {
44
49
  /** 自定义样式名 **/
45
50
  className?: string;
46
51
  /** 类型,可选 line circle dashboard **/
@@ -48,7 +53,7 @@ export interface ProgressProps {
48
53
  /** 百分比 **/
49
54
  percent?: number | number[];
50
55
  /** 内容的模板函数 **/
51
- format?: (percent?: number | number[], successPercent?: number) => React.ReactNode;
56
+ format?: (percent?: number | number[], successPercent?: number) => React__default.ReactNode;
52
57
  /** 状态,可选:success exception normal active(仅限 line) **/
53
58
  status?: typeof ProgressStatuses[number];
54
59
  /** 是否显示进度数值或状态图标 **/
@@ -75,7 +80,8 @@ export interface ProgressProps {
75
80
  steps?: number;
76
81
  /** 渐变颜色的方向 **/
77
82
  direction?: DirectionType;
78
- children?: React.ReactNode;
83
+ children?: React__default.ReactNode;
79
84
  }
80
- export declare const Progress: FunctionComponent<ProgressProps>;
81
- export default Progress;
85
+ declare const Progress: FunctionComponent<ProgressProps>;
86
+
87
+ export { DirectionType, Progress, ProgressGradient, ProgressProps, ProgressType, StringGradients, SuccessProps, Progress as default };
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 };