@chaoswise/ui 3.0.23 → 3.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (407) hide show
  1. package/lib/Antd5/_util/ActionButton.js +4 -2
  2. package/lib/Antd5/_util/ContextIsolator.js +27 -0
  3. package/lib/Antd5/_util/easings.js +2 -2
  4. package/lib/Antd5/_util/getScroll.js +9 -8
  5. package/lib/Antd5/_util/hooks/useClosable.js +3 -2
  6. package/lib/Antd5/_util/hooks/useUniqueMemo.js +123 -0
  7. package/lib/Antd5/_util/hooks/useZIndex.js +31 -15
  8. package/lib/Antd5/_util/motion.js +3 -2
  9. package/lib/Antd5/_util/placements.js +2 -2
  10. package/lib/Antd5/_util/scrollTo.js +1 -1
  11. package/lib/Antd5/_util/statusUtils.js +1 -1
  12. package/lib/Antd5/_util/toList.js +5 -0
  13. package/lib/Antd5/_util/warning.js +0 -1
  14. package/lib/Antd5/_util/wave/WaveEffect.js +2 -2
  15. package/lib/Antd5/_util/wave/interface.js +2 -1
  16. package/lib/Antd5/_util/wave/useWave.js +1 -1
  17. package/lib/Antd5/_util/wave/util.js +1 -9
  18. package/lib/Antd5/alert/Alert.js +1 -2
  19. package/lib/Antd5/alert/ErrorBoundary.js +1 -1
  20. package/lib/Antd5/alert/design/behavior-pattern.js +3 -3
  21. package/lib/Antd5/alert/style/index.js +6 -4
  22. package/lib/Antd5/anchor/Anchor.js +8 -7
  23. package/lib/Antd5/anchor/AnchorLink.js +4 -4
  24. package/lib/Antd5/app/index.js +2 -1
  25. package/lib/Antd5/app/style/index.js +4 -2
  26. package/lib/Antd5/auto-complete/index.js +1 -1
  27. package/lib/Antd5/avatar/group.js +35 -17
  28. package/lib/Antd5/avatar/style/index.js +18 -13
  29. package/lib/Antd5/back-top/index.js +3 -2
  30. package/lib/Antd5/badge/ScrollNumber.js +1 -1
  31. package/lib/Antd5/badge/SingleNumber.js +17 -16
  32. package/lib/Antd5/badge/style/index.js +6 -7
  33. package/lib/Antd5/badge/style/ribbon.js +3 -3
  34. package/lib/Antd5/breadcrumb/design/behavior-pattern.js +4 -4
  35. package/lib/Antd5/breadcrumb/style/index.js +1 -1
  36. package/lib/Antd5/button/LoadingIcon.js +5 -10
  37. package/lib/Antd5/button/button-group.js +0 -1
  38. package/lib/Antd5/button/button.js +70 -41
  39. package/lib/Antd5/button/buttonHelpers.js +7 -5
  40. package/lib/Antd5/button/style/{compactCmp.js → compact.js} +20 -27
  41. package/lib/Antd5/button/style/group.js +9 -7
  42. package/lib/Antd5/button/style/index.js +150 -110
  43. package/lib/Antd5/button/style/token.js +8 -1
  44. package/lib/Antd5/calendar/generateCalendar.js +25 -28
  45. package/lib/Antd5/calendar/style/index.js +4 -4
  46. package/lib/Antd5/card/Card.js +3 -3
  47. package/lib/Antd5/card/style/index.js +6 -9
  48. package/lib/Antd5/carousel/index.js +3 -3
  49. package/lib/Antd5/carousel/style/index.js +1 -1
  50. package/lib/Antd5/cascader/Panel.js +7 -2
  51. package/lib/Antd5/cascader/hooks/useBase.js +3 -2
  52. package/lib/Antd5/cascader/hooks/useColumnIcons.js +6 -3
  53. package/lib/Antd5/cascader/index.js +1 -1
  54. package/lib/Antd5/cascader/style/columns.js +6 -4
  55. package/lib/Antd5/checkbox/Checkbox.js +44 -10
  56. package/lib/Antd5/checkbox/Group.js +7 -2
  57. package/lib/Antd5/checkbox/assets/duigou1.js +29 -0
  58. package/lib/Antd5/checkbox/assets/duigou2.js +29 -0
  59. package/lib/Antd5/checkbox/style/index.js +112 -6
  60. package/lib/Antd5/collapse/Collapse.js +2 -1
  61. package/lib/Antd5/collapse/style/index.js +20 -13
  62. package/lib/Antd5/color-picker/ColorPicker.js +120 -78
  63. package/lib/Antd5/color-picker/ColorPickerPanel.js +44 -26
  64. package/lib/Antd5/color-picker/color.js +82 -10
  65. package/lib/Antd5/color-picker/components/ColorAlphaInput.js +2 -2
  66. package/lib/Antd5/color-picker/components/ColorClear.js +2 -2
  67. package/lib/Antd5/color-picker/components/ColorHexInput.js +5 -4
  68. package/lib/Antd5/color-picker/components/ColorInput.js +4 -3
  69. package/lib/Antd5/color-picker/components/ColorPresets.js +1 -1
  70. package/lib/Antd5/color-picker/components/ColorSlider.js +139 -0
  71. package/lib/Antd5/color-picker/components/ColorTrigger.js +52 -26
  72. package/lib/Antd5/color-picker/components/PanelPicker/GradientColorBar.js +130 -0
  73. package/lib/Antd5/color-picker/components/PanelPicker/index.js +194 -0
  74. package/lib/Antd5/color-picker/context.js +1 -5
  75. package/lib/Antd5/color-picker/hooks/useModeColor.js +87 -0
  76. package/lib/Antd5/color-picker/style/color-block.js +3 -2
  77. package/lib/Antd5/color-picker/style/index.js +33 -15
  78. package/lib/Antd5/color-picker/style/input.js +1 -1
  79. package/lib/Antd5/color-picker/style/picker.js +6 -33
  80. package/lib/Antd5/color-picker/style/slider.js +87 -0
  81. package/lib/Antd5/color-picker/util.js +53 -7
  82. package/lib/Antd5/config-provider/context.js +3 -1
  83. package/lib/Antd5/config-provider/cssVariables.js +0 -1
  84. package/lib/Antd5/config-provider/defaultRenderEmpty.js +8 -1
  85. package/lib/Antd5/config-provider/index.js +13 -5
  86. package/lib/Antd5/config-provider/style/index.js +0 -1
  87. package/lib/Antd5/date-picker/PickerButton.js +3 -2
  88. package/lib/Antd5/date-picker/design/behavior-pattern.js +15 -15
  89. package/lib/Antd5/date-picker/generatePicker/constant.js +15 -0
  90. package/lib/Antd5/date-picker/generatePicker/generateRangePicker.js +16 -11
  91. package/lib/Antd5/date-picker/generatePicker/generateSinglePicker.js +19 -15
  92. package/lib/Antd5/date-picker/generatePicker/index.js +2 -2
  93. package/lib/Antd5/date-picker/generatePicker/interface.js +1 -1
  94. package/lib/Antd5/date-picker/index.js +2 -17
  95. package/lib/Antd5/date-picker/locale/ar_EG.js +9 -1
  96. package/lib/Antd5/date-picker/locale/az_AZ.js +9 -1
  97. package/lib/Antd5/date-picker/locale/el_GR.js +9 -1
  98. package/lib/Antd5/date-picker/locale/ja_JP.js +11 -1
  99. package/lib/Antd5/date-picker/locale/kn_IN.js +9 -1
  100. package/lib/Antd5/date-picker/locale/pl_PL.js +9 -1
  101. package/lib/Antd5/date-picker/locale/uk_UA.js +10 -1
  102. package/lib/Antd5/date-picker/style/index.js +13 -10
  103. package/lib/Antd5/date-picker/style/panel.js +36 -32
  104. package/lib/Antd5/date-picker/style/token.js +1 -1
  105. package/lib/Antd5/date-picker/util.js +0 -48
  106. package/lib/Antd5/descriptions/hooks/useItems.js +5 -0
  107. package/lib/Antd5/descriptions/hooks/useRow.js +42 -34
  108. package/lib/Antd5/descriptions/style/index.js +20 -8
  109. package/lib/Antd5/divider/index.js +4 -3
  110. package/lib/Antd5/divider/style/index.js +19 -4
  111. package/lib/Antd5/drawer/DrawerPanel.js +11 -20
  112. package/lib/Antd5/drawer/index.js +39 -42
  113. package/lib/Antd5/drawer/style/index.js +10 -11
  114. package/lib/Antd5/dropdown/dropdown.js +5 -7
  115. package/lib/Antd5/dropdown/style/index.js +27 -11
  116. package/lib/Antd5/empty/empty.js +9 -3
  117. package/lib/Antd5/empty/simple.js +9 -3
  118. package/lib/Antd5/empty/style/index.js +1 -1
  119. package/lib/Antd5/float-button/BackTop.js +3 -2
  120. package/lib/Antd5/float-button/FloatButton.js +16 -5
  121. package/lib/Antd5/float-button/FloatButtonGroup.js +76 -52
  122. package/lib/Antd5/float-button/style/index.js +117 -76
  123. package/lib/Antd5/float-button/style/keyframes.js +118 -0
  124. package/lib/Antd5/form/ErrorList.js +14 -2
  125. package/lib/Antd5/form/Form.js +11 -3
  126. package/lib/Antd5/form/FormItem/ItemHolder.js +8 -4
  127. package/lib/Antd5/form/FormItem/index.js +6 -4
  128. package/lib/Antd5/form/FormItemInput.js +68 -28
  129. package/lib/Antd5/form/FormItemLabel.js +3 -3
  130. package/lib/Antd5/form/hooks/useForm.js +8 -1
  131. package/lib/Antd5/form/hooks/useVariants.js +10 -4
  132. package/lib/Antd5/form/style/explain.js +9 -8
  133. package/lib/Antd5/form/style/index.js +30 -18
  134. package/lib/Antd5/grid/row.js +2 -2
  135. package/lib/Antd5/image/index.js +3 -1
  136. package/lib/Antd5/image/style/index.js +17 -20
  137. package/lib/Antd5/index.js +2 -1
  138. package/lib/Antd5/input/Input.js +18 -38
  139. package/lib/Antd5/input/OTP/OTPInput.js +10 -5
  140. package/lib/Antd5/input/OTP/index.js +12 -4
  141. package/lib/Antd5/input/Password.js +6 -2
  142. package/lib/Antd5/input/Search.js +2 -4
  143. package/lib/Antd5/input/TextArea.js +1 -1
  144. package/lib/Antd5/input/style/index.js +72 -63
  145. package/lib/Antd5/input/style/otp.js +1 -1
  146. package/lib/Antd5/input/style/variants.js +38 -23
  147. package/lib/Antd5/input/utils.js +0 -1
  148. package/lib/Antd5/input-number/index.js +19 -22
  149. package/lib/Antd5/input-number/style/index.js +26 -16
  150. package/lib/Antd5/layout/Sider.js +15 -8
  151. package/lib/Antd5/layout/style/index.js +6 -96
  152. package/lib/Antd5/layout/style/sider.js +115 -0
  153. package/lib/Antd5/list/Item.js +18 -5
  154. package/lib/Antd5/list/index.js +15 -10
  155. package/lib/Antd5/list/style/index.js +40 -41
  156. package/lib/Antd5/locale/ar_EG.js +14 -1
  157. package/lib/Antd5/locale/az_AZ.js +78 -28
  158. package/lib/Antd5/locale/bn_BD.js +0 -1
  159. package/lib/Antd5/locale/by_BY.js +0 -1
  160. package/lib/Antd5/locale/ca_ES.js +0 -1
  161. package/lib/Antd5/locale/cs_CZ.js +0 -1
  162. package/lib/Antd5/locale/de_DE.js +0 -1
  163. package/lib/Antd5/locale/el_GR.js +104 -3
  164. package/lib/Antd5/locale/en_GB.js +0 -1
  165. package/lib/Antd5/locale/en_US.js +4 -2
  166. package/lib/Antd5/locale/es_ES.js +10 -6
  167. package/lib/Antd5/locale/et_EE.js +0 -1
  168. package/lib/Antd5/locale/eu_ES.js +4 -2
  169. package/lib/Antd5/locale/fa_IR.js +0 -1
  170. package/lib/Antd5/locale/fr_BE.js +5 -1
  171. package/lib/Antd5/locale/fr_CA.js +0 -1
  172. package/lib/Antd5/locale/fr_FR.js +5 -6
  173. package/lib/Antd5/locale/ga_IE.js +0 -1
  174. package/lib/Antd5/locale/gl_ES.js +0 -1
  175. package/lib/Antd5/locale/he_IL.js +0 -1
  176. package/lib/Antd5/locale/hi_IN.js +0 -1
  177. package/lib/Antd5/locale/hr_HR.js +0 -1
  178. package/lib/Antd5/locale/id_ID.js +4 -2
  179. package/lib/Antd5/locale/index.js +1 -1
  180. package/lib/Antd5/locale/it_IT.js +0 -1
  181. package/lib/Antd5/locale/ja_JP.js +4 -2
  182. package/lib/Antd5/locale/ka_GE.js +0 -1
  183. package/lib/Antd5/locale/kk_KZ.js +0 -1
  184. package/lib/Antd5/locale/km_KH.js +0 -1
  185. package/lib/Antd5/locale/kn_IN.js +82 -4
  186. package/lib/Antd5/locale/ko_KR.js +4 -2
  187. package/lib/Antd5/locale/lt_LT.js +4 -2
  188. package/lib/Antd5/locale/ml_IN.js +0 -1
  189. package/lib/Antd5/locale/mn_MN.js +86 -2
  190. package/lib/Antd5/locale/ms_MY.js +101 -18
  191. package/lib/Antd5/locale/my_MM.js +0 -1
  192. package/lib/Antd5/locale/nb_NO.js +0 -1
  193. package/lib/Antd5/locale/ne_NP.js +104 -2
  194. package/lib/Antd5/locale/nl_BE.js +5 -1
  195. package/lib/Antd5/locale/nl_NL.js +5 -1
  196. package/lib/Antd5/locale/pl_PL.js +0 -1
  197. package/lib/Antd5/locale/pt_BR.js +0 -1
  198. package/lib/Antd5/locale/pt_PT.js +55 -38
  199. package/lib/Antd5/locale/ro_RO.js +0 -1
  200. package/lib/Antd5/locale/ru_RU.js +9 -2
  201. package/lib/Antd5/locale/si_LK.js +0 -1
  202. package/lib/Antd5/locale/sk_SK.js +0 -1
  203. package/lib/Antd5/locale/sr_RS.js +0 -1
  204. package/lib/Antd5/locale/sv_SE.js +0 -1
  205. package/lib/Antd5/locale/th_TH.js +11 -3
  206. package/lib/Antd5/locale/tk_TK.js +0 -1
  207. package/lib/Antd5/locale/tr_TR.js +2 -1
  208. package/lib/Antd5/locale/uk_UA.js +1 -1
  209. package/lib/Antd5/locale/ur_PK.js +0 -1
  210. package/lib/Antd5/locale/uz_UZ.js +6 -7
  211. package/lib/Antd5/locale/zh_CN.js +4 -2
  212. package/lib/Antd5/locale/zh_HK.js +0 -1
  213. package/lib/Antd5/locale/zh_TW.js +0 -1
  214. package/lib/Antd5/mentions/index.js +4 -4
  215. package/lib/Antd5/menu/MenuItem.js +6 -5
  216. package/lib/Antd5/menu/OverrideContext.js +4 -3
  217. package/lib/Antd5/menu/SubMenu.js +2 -2
  218. package/lib/Antd5/menu/menu.js +2 -2
  219. package/lib/Antd5/menu/style/index.js +58 -40
  220. package/lib/Antd5/menu/style/theme.js +24 -20
  221. package/lib/Antd5/menu/style/vertical.js +10 -7
  222. package/lib/Antd5/modal/Modal.js +50 -38
  223. package/lib/Antd5/modal/PurePanel.js +0 -1
  224. package/lib/Antd5/modal/confirm.js +4 -5
  225. package/lib/Antd5/modal/style/confirm.js +1 -2
  226. package/lib/Antd5/modal/style/index.js +13 -3
  227. package/lib/Antd5/modal/useModal/HookModal.js +4 -3
  228. package/lib/Antd5/modal/useModal/index.js +0 -1
  229. package/lib/Antd5/notification/index.js +6 -3
  230. package/lib/Antd5/notification/style/index.js +35 -3
  231. package/lib/Antd5/notification/useNotification.js +6 -1
  232. package/lib/Antd5/pagination/Pagination.js +10 -5
  233. package/lib/Antd5/pagination/design/behavior-pattern.js +3 -3
  234. package/lib/Antd5/pagination/style/bordered.js +1 -1
  235. package/lib/Antd5/pagination/style/index.js +27 -18
  236. package/lib/Antd5/popconfirm/PurePanel.js +7 -7
  237. package/lib/Antd5/popover/PurePanel.js +16 -6
  238. package/lib/Antd5/popover/index.js +7 -19
  239. package/lib/Antd5/popover/style/index.js +3 -1
  240. package/lib/Antd5/progress/Line.js +27 -19
  241. package/lib/Antd5/progress/design/behavior-pattern.js +3 -3
  242. package/lib/Antd5/progress/progress.js +37 -11
  243. package/lib/Antd5/progress/style/index.js +46 -11
  244. package/lib/Antd5/progress/utils.js +20 -18
  245. package/lib/Antd5/qr-code/QrcodeStatus.js +42 -0
  246. package/lib/Antd5/qr-code/index.js +31 -31
  247. package/lib/Antd5/radio/radio.js +4 -10
  248. package/lib/Antd5/radio/style/index.js +65 -80
  249. package/lib/Antd5/rate/index.js +8 -2
  250. package/lib/Antd5/result/noFound.js +3 -1
  251. package/lib/Antd5/result/serverError.js +3 -1
  252. package/lib/Antd5/result/unauthorized.js +5 -3
  253. package/lib/Antd5/segmented/index.js +5 -3
  254. package/lib/Antd5/segmented/style/index.js +11 -3
  255. package/lib/Antd5/select/index.js +4 -2
  256. package/lib/Antd5/select/style/dropdown.js +1 -1
  257. package/lib/Antd5/select/style/index.js +21 -8
  258. package/lib/Antd5/select/style/multiple.js +18 -9
  259. package/lib/Antd5/select/style/single.js +8 -10
  260. package/lib/Antd5/select/style/token.js +9 -2
  261. package/lib/Antd5/select/style/variants.js +20 -11
  262. package/lib/Antd5/skeleton/Image.js +6 -4
  263. package/lib/Antd5/skeleton/Node.js +1 -3
  264. package/lib/Antd5/skeleton/Paragraph.js +1 -1
  265. package/lib/Antd5/skeleton/Title.js +9 -6
  266. package/lib/Antd5/skeleton/style/index.js +13 -13
  267. package/lib/Antd5/slider/Context.js +4 -0
  268. package/lib/Antd5/slider/SliderTooltip.js +9 -5
  269. package/lib/Antd5/slider/index.js +32 -31
  270. package/lib/Antd5/slider/style/index.js +60 -44
  271. package/lib/Antd5/space/Compact.js +1 -1
  272. package/lib/Antd5/space/index.js +3 -3
  273. package/lib/Antd5/spin/Indicator/Looper.js +29 -0
  274. package/lib/Antd5/spin/Indicator/Progress.js +78 -0
  275. package/lib/Antd5/spin/Indicator/index.js +21 -0
  276. package/lib/Antd5/spin/index.js +27 -45
  277. package/lib/Antd5/spin/style/index.js +54 -17
  278. package/lib/Antd5/spin/usePercent.js +40 -0
  279. package/lib/Antd5/splitter/Panel.js +36 -0
  280. package/lib/Antd5/splitter/SplitBar.js +124 -0
  281. package/lib/Antd5/splitter/Splitter.js +194 -0
  282. package/lib/Antd5/{_util/transButton.js → splitter/hooks/useItems.js} +28 -54
  283. package/lib/Antd5/splitter/hooks/useResizable.js +43 -0
  284. package/lib/Antd5/splitter/hooks/useResize.js +138 -0
  285. package/lib/Antd5/splitter/hooks/useSizes.js +109 -0
  286. package/lib/Antd5/splitter/index.js +5 -0
  287. package/lib/Antd5/splitter/interface.js +1 -0
  288. package/lib/Antd5/splitter/style/index.js +219 -0
  289. package/lib/Antd5/statistic/style/index.js +1 -1
  290. package/lib/Antd5/steps/style/custom-icon.js +1 -1
  291. package/lib/Antd5/steps/style/index.js +11 -8
  292. package/lib/Antd5/steps/style/inline.js +5 -4
  293. package/lib/Antd5/steps/style/progress-dot.js +2 -2
  294. package/lib/Antd5/steps/style/small.js +3 -3
  295. package/lib/Antd5/steps/style/vertical.js +2 -2
  296. package/lib/Antd5/style/index.js +37 -13
  297. package/lib/Antd5/style/motion/slide.js +6 -5
  298. package/lib/Antd5/style/placementArrow.js +15 -6
  299. package/lib/Antd5/switch/style/index.js +1 -1
  300. package/lib/Antd5/table/Column.js +2 -3
  301. package/lib/Antd5/table/ColumnGroup.js +2 -3
  302. package/lib/Antd5/table/ExpandIcon.js +6 -6
  303. package/lib/Antd5/table/InternalTable.js +6 -6
  304. package/lib/Antd5/table/RcTable/VirtualTable.js +3 -2
  305. package/lib/Antd5/table/RcTable/index.js +3 -2
  306. package/lib/Antd5/table/hooks/useFilter/FilterDropdown.js +82 -61
  307. package/lib/Antd5/table/hooks/useFilter/FilterSearch.js +7 -7
  308. package/lib/Antd5/table/hooks/useFilter/index.js +28 -26
  309. package/lib/Antd5/table/hooks/useLazyKVMap.js +5 -5
  310. package/lib/Antd5/table/hooks/useSelection.js +21 -11
  311. package/lib/Antd5/table/hooks/useSorter.js +66 -42
  312. package/lib/Antd5/table/hooks/useTitleColumns.js +9 -7
  313. package/lib/Antd5/table/interface.js +1 -1
  314. package/lib/Antd5/table/style/bordered.js +5 -3
  315. package/lib/Antd5/table/style/expand.js +44 -38
  316. package/lib/Antd5/table/style/filter.js +1 -1
  317. package/lib/Antd5/table/style/index.js +26 -21
  318. package/lib/Antd5/table/style/selection.js +3 -1
  319. package/lib/Antd5/table/style/sorter.js +3 -1
  320. package/lib/Antd5/table/style/virtual.js +2 -2
  321. package/lib/Antd5/table/util.js +9 -8
  322. package/lib/Antd5/tabs/style/index.js +2 -2
  323. package/lib/Antd5/tag/style/index.js +2 -2
  324. package/lib/Antd5/theme/index.js +12 -5
  325. package/lib/Antd5/theme/interface/cssinjs-utils.js +1 -0
  326. package/lib/Antd5/theme/internal.js +10 -5
  327. package/lib/Antd5/theme/themes/dark/colors.js +3 -0
  328. package/lib/Antd5/theme/themes/dark/index.js +1 -0
  329. package/lib/Antd5/theme/themes/default/colors.js +3 -0
  330. package/lib/Antd5/theme/themes/default/index.js +6 -2
  331. package/lib/Antd5/theme/themes/seed.js +5 -2
  332. package/lib/Antd5/theme/themes/shared/genColorMapToken.js +2 -0
  333. package/lib/Antd5/theme/themes/shared/genFontSizes.js +1 -1
  334. package/lib/Antd5/theme/useToken.js +2 -1
  335. package/lib/Antd5/theme/util/alias.js +1 -1
  336. package/lib/Antd5/theme/util/genStyleUtils.js +61 -0
  337. package/lib/Antd5/time-picker/index.js +15 -2
  338. package/lib/Antd5/time-picker/locale/az_AZ.js +2 -1
  339. package/lib/Antd5/time-picker/locale/it_IT.js +2 -1
  340. package/lib/Antd5/time-picker/locale/uk_UA.js +2 -1
  341. package/lib/Antd5/timeline/TimelineItemList.js +0 -1
  342. package/lib/Antd5/timeline/style/index.js +1 -1
  343. package/lib/Antd5/tooltip/index.js +3 -2
  344. package/lib/Antd5/tooltip/style/index.js +3 -1
  345. package/lib/Antd5/tooltip/util.js +0 -1
  346. package/lib/Antd5/tour/panelRender.js +7 -13
  347. package/lib/Antd5/tour/style/index.js +6 -13
  348. package/lib/Antd5/transfer/ListItem.js +3 -3
  349. package/lib/Antd5/transfer/hooks/useData.js +1 -1
  350. package/lib/Antd5/transfer/hooks/useSelection.js +26 -21
  351. package/lib/Antd5/transfer/style/index.js +12 -22
  352. package/lib/Antd5/tree/Tree.js +2 -0
  353. package/lib/Antd5/tree/style/directory.js +39 -0
  354. package/lib/Antd5/tree/style/index.js +115 -166
  355. package/lib/Antd5/tree/utils/dropIndicator.js +3 -2
  356. package/lib/Antd5/tree/utils/iconUtil.js +5 -1
  357. package/lib/Antd5/tree-select/index.js +47 -43
  358. package/lib/Antd5/typography/Base/CopyBtn.js +17 -17
  359. package/lib/Antd5/typography/Base/Ellipsis.js +48 -40
  360. package/lib/Antd5/typography/Base/index.js +20 -60
  361. package/lib/Antd5/typography/Base/util.js +31 -1
  362. package/lib/Antd5/typography/Editable.js +11 -10
  363. package/lib/Antd5/typography/Title.js +1 -6
  364. package/lib/Antd5/typography/Typography.js +2 -6
  365. package/lib/Antd5/typography/hooks/useCopyClick.js +3 -2
  366. package/lib/Antd5/typography/hooks/usePrevious.js +1 -1
  367. package/lib/Antd5/typography/hooks/useTooltipProps.js +30 -0
  368. package/lib/Antd5/typography/style/mixins.js +3 -9
  369. package/lib/Antd5/version/version.js +1 -1
  370. package/lib/Antd5/watermark/context.js +1 -1
  371. package/lib/Antd5/watermark/index.js +35 -18
  372. package/lib/Antd5/watermark/useClips.js +2 -1
  373. package/lib/Antd5/watermark/useRafDebounce.js +1 -1
  374. package/lib/Antd5/watermark/utils.js +1 -1
  375. package/lib/AppHolder/index.js +2 -1
  376. package/lib/CWSelect/index.js +39 -1
  377. package/lib/CWSelect/index.style.js +39 -0
  378. package/lib/CWTree/index.js +3 -9
  379. package/lib/CWTree/index.style.js +2 -0
  380. package/lib/ConfigProvider/ConfigProvider.js +11 -10
  381. package/lib/ConfigProvider/customTheme.js +6 -0
  382. package/lib/ConfigProvider/theme/common.js +140 -0
  383. package/lib/ConfigProvider/theme/dark.js +2 -0
  384. package/lib/ConfigProvider/theme/default.js +122 -0
  385. package/lib/ConfigProvider/theme/utils.js +49 -0
  386. package/lib/Header/UserSetting/TenantTree.js +0 -1
  387. package/lib/Pagination/index.style.js +1 -1
  388. package/lib/QuickTransfer/index.js +45 -59
  389. package/lib/SiderMenu/index.style.js +4 -2
  390. package/lib/Slider/index.style.js +2 -1
  391. package/lib/Splitter/index.js +2 -0
  392. package/package.json +37 -35
  393. package/lib/Antd5/color-picker/components/PanelPicker.js +0 -53
  394. package/lib/Antd5/color-picker/hooks/useColorState.js +0 -53
  395. package/lib/Antd5/layout/style/light.js +0 -24
  396. package/lib/Antd5/style/operationUnit.js +0 -18
  397. package/lib/Antd5/theme/util/calc/CSSCalculator.js +0 -119
  398. package/lib/Antd5/theme/util/calc/NumCalculator.js +0 -81
  399. package/lib/Antd5/theme/util/calc/calculator.js +0 -10
  400. package/lib/Antd5/theme/util/calc/index.js +0 -9
  401. package/lib/Antd5/theme/util/genComponentStyleHook.js +0 -243
  402. package/lib/Antd5/theme/util/maxmin.js +0 -27
  403. package/lib/Antd5/theme/util/statistic.js +0 -74
  404. package/lib/Antd5/typography/hooks/useUpdatedEffect.js +0 -13
  405. package/lib/Antd5/version/token-meta.json +0 -1
  406. package/lib/Antd5/version/token.json +0 -1
  407. package/lib/ConfigProvider/customTheme.json +0 -163
@@ -15,12 +15,14 @@ var genBaseOutlinedStyle = function genBaseOutlinedStyle(token, options) {
15
15
  return _defineProperty(_defineProperty({}, "&:not(".concat(componentCls, "-customize-input) ").concat(componentCls, "-selector"), {
16
16
  border: "".concat(unit(token.lineWidth), " ").concat(token.lineType, " ").concat(options.borderColor),
17
17
  background: token.selectorBg
18
- }), "&:not(".concat(componentCls, "-disabled):not(").concat(componentCls, "-customize-input):not(").concat(antCls, "-pagination-size-changer)"), _defineProperty(_defineProperty({}, "&:hover ".concat(componentCls, "-selector"), {
18
+ }), "&:not(".concat(componentCls, "-disabled):not(").concat(componentCls, "-customize-input):not(").concat(antCls, "-pagination-size-changer)"), _defineProperty(_defineProperty(_defineProperty({}, "&:hover ".concat(componentCls, "-selector"), {
19
19
  borderColor: options.hoverBorderHover
20
20
  }), "".concat(componentCls, "-focused& ").concat(componentCls, "-selector"), {
21
21
  borderColor: options.activeBorderColor,
22
- boxShadow: "0 0 0 ".concat(unit(controlOutlineWidth), " ").concat(options.activeShadowColor),
22
+ boxShadow: "0 0 0 ".concat(unit(controlOutlineWidth), " ").concat(options.activeOutlineColor),
23
23
  outline: 0
24
+ }), "".concat(componentCls, "-prefix"), {
25
+ color: options.color
24
26
  }));
25
27
  };
26
28
  var genOutlinedStatusStyle = function genOutlinedStatusStyle(token, options) {
@@ -30,21 +32,24 @@ var genOutlinedStyle = function genOutlinedStyle(token) {
30
32
  return {
31
33
  '&-outlined': _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, genBaseOutlinedStyle(token, {
32
34
  borderColor: token.colorBorder,
33
- hoverBorderHover: token.colorPrimaryHover,
34
- activeBorderColor: token.colorPrimary,
35
- activeShadowColor: token.controlOutline
35
+ hoverBorderHover: token.hoverBorderColor,
36
+ activeBorderColor: token.activeBorderColor,
37
+ activeOutlineColor: token.activeOutlineColor,
38
+ color: token.colorText
36
39
  })), genOutlinedStatusStyle(token, {
37
40
  status: 'error',
38
41
  borderColor: token.colorError,
39
42
  hoverBorderHover: token.colorErrorHover,
40
43
  activeBorderColor: token.colorError,
41
- activeShadowColor: token.colorErrorOutline
44
+ activeOutlineColor: token.colorErrorOutline,
45
+ color: token.colorError
42
46
  })), genOutlinedStatusStyle(token, {
43
47
  status: 'warning',
44
48
  borderColor: token.colorWarning,
45
49
  hoverBorderHover: token.colorWarningHover,
46
50
  activeBorderColor: token.colorWarning,
47
- activeShadowColor: token.colorWarningOutline
51
+ activeOutlineColor: token.colorWarningOutline,
52
+ color: token.colorWarning
48
53
  })), {}, _defineProperty(_defineProperty({}, "&".concat(token.componentCls, "-disabled"), _defineProperty({}, "&:not(".concat(token.componentCls, "-customize-input) ").concat(token.componentCls, "-selector"), {
49
54
  background: token.colorBgContainerDisabled,
50
55
  color: token.colorTextDisabled
@@ -80,7 +85,7 @@ var genFilledStyle = function genFilledStyle(token) {
80
85
  '&-filled': _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, genBaseFilledStyle(token, {
81
86
  bg: token.colorFillTertiary,
82
87
  hoverBg: token.colorFillSecondary,
83
- activeBorderColor: token.colorPrimary,
88
+ activeBorderColor: token.activeBorderColor,
84
89
  color: token.colorText
85
90
  })), genFilledStatusStyle(token, {
86
91
  status: 'error',
@@ -109,15 +114,19 @@ var genFilledStyle = function genFilledStyle(token) {
109
114
  // =====================================================
110
115
  var genBorderlessStyle = function genBorderlessStyle(token) {
111
116
  return {
112
- '&-borderless': _defineProperty(_defineProperty(_defineProperty({}, "".concat(token.componentCls, "-selector"), {
117
+ '&-borderless': _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(token.componentCls, "-selector"), {
113
118
  background: 'transparent',
114
- borderColor: 'transparent'
119
+ border: "".concat(unit(token.lineWidth), " ").concat(token.lineType, " transparent")
115
120
  }), "&".concat(token.componentCls, "-disabled"), _defineProperty({}, "&:not(".concat(token.componentCls, "-customize-input) ").concat(token.componentCls, "-selector"), {
116
121
  color: token.colorTextDisabled
117
122
  })), "&".concat(token.componentCls, "-multiple ").concat(token.componentCls, "-selection-item"), {
118
123
  background: token.multipleItemBg,
119
124
  border: "".concat(unit(token.lineWidth), " ").concat(token.lineType, " ").concat(token.multipleItemBorderColor)
120
- })
125
+ }), "&".concat(token.componentCls, "-status-error"), _defineProperty({}, "".concat(token.componentCls, "-prefix, ").concat(token.componentCls, "-selection-item"), {
126
+ color: token.colorError
127
+ })), "&".concat(token.componentCls, "-status-warning"), _defineProperty({}, "".concat(token.componentCls, "-prefix, ").concat(token.componentCls, "-selection-item"), {
128
+ color: token.colorWarning
129
+ }))
121
130
  };
122
131
  };
123
132
  var genVariantsStyle = function genVariantsStyle(token) {
@@ -8,7 +8,7 @@ function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r)
8
8
  function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
9
9
  function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t["return"] && (u = t["return"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
10
10
  function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
11
- import { jsx as _jsx } from "react/jsx-runtime";
11
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
12
12
  import * as React from 'react';
13
13
  import classNames from 'classnames';
14
14
  import { ConfigContext } from '../config-provider';
@@ -34,14 +34,16 @@ var SkeletonImage = function SkeletonImage(props) {
34
34
  children: _jsx("div", {
35
35
  className: classNames("".concat(prefixCls, "-image"), className),
36
36
  style: style,
37
- children: _jsx("svg", {
37
+ children: _jsxs("svg", {
38
38
  viewBox: "0 0 1098 1024",
39
39
  xmlns: "http://www.w3.org/2000/svg",
40
40
  className: "".concat(prefixCls, "-image-svg"),
41
- children: _jsx("path", {
41
+ children: [_jsx("title", {
42
+ children: "Image placeholder"
43
+ }), _jsx("path", {
42
44
  d: path,
43
45
  className: "".concat(prefixCls, "-image-path")
44
- })
46
+ })]
45
47
  })
46
48
  })
47
49
  }));
@@ -10,7 +10,6 @@ function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" !=
10
10
  function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
11
11
  import { jsx as _jsx } from "react/jsx-runtime";
12
12
  import * as React from 'react';
13
- import DotChartOutlined from '@ant-design/icons/DotChartOutlined';
14
13
  import classNames from 'classnames';
15
14
  import { ConfigContext } from '../config-provider';
16
15
  import useStyle from './style';
@@ -30,13 +29,12 @@ var SkeletonNode = function SkeletonNode(props) {
30
29
  hashId = _useStyle2[1],
31
30
  cssVarCls = _useStyle2[2];
32
31
  var cls = classNames(prefixCls, "".concat(prefixCls, "-element"), _defineProperty({}, "".concat(prefixCls, "-active"), active), hashId, className, rootClassName, cssVarCls);
33
- var content = children !== null && children !== void 0 ? children : _jsx(DotChartOutlined, {});
34
32
  return wrapCSSVar(_jsx("div", {
35
33
  className: cls,
36
34
  children: _jsx("div", {
37
35
  className: classNames("".concat(prefixCls, "-image"), className),
38
36
  style: style,
39
- children: content
37
+ children: children
40
38
  })
41
39
  }));
42
40
  };
@@ -25,7 +25,7 @@ var Paragraph = function Paragraph(props) {
25
25
  className = props.className,
26
26
  style = props.style,
27
27
  rows = props.rows;
28
- var rowList = _toConsumableArray(Array(rows)).map(function (_, index) {
28
+ var rowList = _toConsumableArray(new Array(rows)).map(function (_, index) {
29
29
  return (
30
30
  // eslint-disable-next-line react/no-array-index-key
31
31
  _jsx("li", {
@@ -13,11 +13,14 @@ var Title = function Title(_ref) {
13
13
  className = _ref.className,
14
14
  width = _ref.width,
15
15
  style = _ref.style;
16
- return _jsx("h3", {
17
- className: classNames(prefixCls, className),
18
- style: _objectSpread({
19
- width: width
20
- }, style)
21
- });
16
+ return (
17
+ // biome-ignore lint/a11y/useHeadingContent: HOC here
18
+ _jsx("h3", {
19
+ className: classNames(prefixCls, className),
20
+ style: _objectSpread({
21
+ width: width
22
+ }, style)
23
+ })
24
+ );
22
25
  };
23
26
  export default Title;
@@ -47,7 +47,7 @@ var genSkeletonElementAvatar = function genSkeletonElementAvatar(token) {
47
47
  controlHeight = token.controlHeight,
48
48
  controlHeightLG = token.controlHeightLG,
49
49
  controlHeightSM = token.controlHeightSM;
50
- return _defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(skeletonAvatarCls), _objectSpread({
50
+ return _defineProperty(_defineProperty(_defineProperty(_defineProperty({}, skeletonAvatarCls, _objectSpread({
51
51
  display: 'inline-block',
52
52
  verticalAlign: 'top',
53
53
  background: gradientFromColor
@@ -63,7 +63,7 @@ var genSkeletonElementInput = function genSkeletonElementInput(token) {
63
63
  controlHeightSM = token.controlHeightSM,
64
64
  gradientFromColor = token.gradientFromColor,
65
65
  calc = token.calc;
66
- return _defineProperty(_defineProperty(_defineProperty({}, "".concat(skeletonInputCls), _objectSpread({
66
+ return _defineProperty(_defineProperty(_defineProperty({}, skeletonInputCls, _objectSpread({
67
67
  display: 'inline-block',
68
68
  verticalAlign: 'top',
69
69
  background: gradientFromColor,
@@ -81,11 +81,11 @@ var genSkeletonElementImage = function genSkeletonElementImage(token) {
81
81
  gradientFromColor = token.gradientFromColor,
82
82
  borderRadiusSM = token.borderRadiusSM,
83
83
  calc = token.calc;
84
- return _defineProperty(_defineProperty({}, "".concat(skeletonImageCls), _objectSpread(_objectSpread({
85
- display: 'flex',
84
+ return _defineProperty(_defineProperty({}, skeletonImageCls, _objectSpread(_objectSpread({
85
+ display: 'inline-flex',
86
86
  alignItems: 'center',
87
87
  justifyContent: 'center',
88
- verticalAlign: 'top',
88
+ verticalAlign: 'middle',
89
89
  background: gradientFromColor,
90
90
  borderRadius: borderRadiusSM
91
91
  }, genSkeletonElementImageSize(calc(imageSizeBase).mul(2).equal())), {}, _defineProperty(_defineProperty(_defineProperty({}, "".concat(skeletonImageCls, "-path"), {
@@ -123,7 +123,7 @@ var genSkeletonElementButton = function genSkeletonElementButton(token) {
123
123
  controlHeightSM = token.controlHeightSM,
124
124
  gradientFromColor = token.gradientFromColor,
125
125
  calc = token.calc;
126
- return _objectSpread(_objectSpread(_objectSpread(_defineProperty({}, "".concat(skeletonButtonCls), _objectSpread({
126
+ return _objectSpread(_objectSpread(_objectSpread(_defineProperty({}, skeletonButtonCls, _objectSpread({
127
127
  display: 'inline-block',
128
128
  verticalAlign: 'top',
129
129
  background: gradientFromColor,
@@ -153,14 +153,14 @@ var genBaseStyle = function genBaseStyle(token) {
153
153
  paragraphLiHeight = token.paragraphLiHeight,
154
154
  controlHeightXS = token.controlHeightXS,
155
155
  paragraphMarginTop = token.paragraphMarginTop;
156
- return _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(componentCls), _defineProperty(_defineProperty(_defineProperty({
156
+ return _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, componentCls, _defineProperty(_defineProperty(_defineProperty({
157
157
  display: 'table',
158
158
  width: '100%'
159
159
  }, "".concat(componentCls, "-header"), _defineProperty(_defineProperty(_defineProperty(_defineProperty({
160
160
  display: 'table-cell',
161
161
  paddingInlineEnd: padding,
162
162
  verticalAlign: 'top'
163
- }, "".concat(skeletonAvatarCls), _objectSpread({
163
+ }, skeletonAvatarCls, _objectSpread({
164
164
  display: 'inline-block',
165
165
  verticalAlign: 'top',
166
166
  background: gradientFromColor
@@ -170,14 +170,14 @@ var genBaseStyle = function genBaseStyle(token) {
170
170
  display: 'table-cell',
171
171
  width: '100%',
172
172
  verticalAlign: 'top'
173
- }, "".concat(skeletonTitleCls), _defineProperty({
173
+ }, skeletonTitleCls, _defineProperty({
174
174
  width: '100%',
175
175
  height: titleHeight,
176
176
  background: gradientFromColor,
177
177
  borderRadius: blockRadius
178
178
  }, "+ ".concat(skeletonParagraphCls), {
179
179
  marginBlockStart: controlHeightSM
180
- })), "".concat(skeletonParagraphCls), {
180
+ })), skeletonParagraphCls, {
181
181
  padding: 0,
182
182
  '> li': {
183
183
  width: '100%',
@@ -193,7 +193,7 @@ var genBaseStyle = function genBaseStyle(token) {
193
193
  width: '61%'
194
194
  })), "&-round ".concat(componentCls, "-content"), _defineProperty({}, "".concat(skeletonTitleCls, ", ").concat(skeletonParagraphCls, " > li"), {
195
195
  borderRadius: borderRadius
196
- }))), "".concat(componentCls, "-with-avatar ").concat(componentCls, "-content"), _defineProperty({}, "".concat(skeletonTitleCls), _defineProperty({
196
+ }))), "".concat(componentCls, "-with-avatar ").concat(componentCls, "-content"), _defineProperty({}, skeletonTitleCls, _defineProperty({
197
197
  marginBlockStart: marginSM
198
198
  }, "+ ".concat(skeletonParagraphCls), {
199
199
  marginBlockStart: paragraphMarginTop
@@ -202,9 +202,9 @@ var genBaseStyle = function genBaseStyle(token) {
202
202
  width: 'auto'
203
203
  }, genSkeletonElementButton(token)), genSkeletonElementAvatar(token)), genSkeletonElementInput(token)), genSkeletonElementImage(token))), "".concat(componentCls).concat(componentCls, "-block"), _defineProperty(_defineProperty({
204
204
  width: '100%'
205
- }, "".concat(skeletonButtonCls), {
205
+ }, skeletonButtonCls, {
206
206
  width: '100%'
207
- }), "".concat(skeletonInputCls), {
207
+ }), skeletonInputCls, {
208
208
  width: '100%'
209
209
  })), "".concat(componentCls).concat(componentCls, "-active"), _defineProperty({}, "\n ".concat(skeletonTitleCls, ",\n ").concat(skeletonParagraphCls, " > li,\n ").concat(skeletonAvatarCls, ",\n ").concat(skeletonButtonCls, ",\n ").concat(skeletonInputCls, ",\n ").concat(skeletonImageCls, "\n "), _objectSpread({}, genSkeletonColor(token))));
210
210
  };
@@ -0,0 +1,4 @@
1
+ import { createContext } from 'react';
2
+ /** @private Internal context. Do not use in your production. */
3
+ var SliderInternalContext = /*#__PURE__*/createContext({});
4
+ export default SliderInternalContext;
@@ -11,8 +11,10 @@ import raf from 'rc-util/lib/raf';
11
11
  import { composeRef } from 'rc-util/lib/ref';
12
12
  import Tooltip from '../tooltip';
13
13
  var SliderTooltip = /*#__PURE__*/React.forwardRef(function (props, ref) {
14
- var open = props.open;
14
+ var open = props.open,
15
+ draggingDelete = props.draggingDelete;
15
16
  var innerRef = useRef(null);
17
+ var mergedOpen = open && !draggingDelete;
16
18
  var rafRef = useRef(null);
17
19
  function cancelKeepAlign() {
18
20
  raf.cancel(rafRef.current);
@@ -26,16 +28,18 @@ var SliderTooltip = /*#__PURE__*/React.forwardRef(function (props, ref) {
26
28
  });
27
29
  }
28
30
  React.useEffect(function () {
29
- if (open) {
31
+ if (mergedOpen) {
30
32
  keepAlign();
31
33
  } else {
32
34
  cancelKeepAlign();
33
35
  }
34
36
  return cancelKeepAlign;
35
- }, [open, props.title]);
36
- return _jsx(Tooltip, _objectSpread({
37
+ }, [mergedOpen, props.title]);
38
+ return _jsx(Tooltip, _objectSpread(_objectSpread({
37
39
  ref: composeRef(innerRef, ref)
38
- }, props));
40
+ }, props), {}, {
41
+ open: mergedOpen
42
+ }));
39
43
  });
40
44
  if (process.env.NODE_ENV !== 'production') {
41
45
  SliderTooltip.displayName = 'SliderTooltip';
@@ -1,5 +1,5 @@
1
- var _excluded = ["prefixCls", "range", "className", "rootClassName", "style", "disabled", "tooltipPrefixCls", "tipFormatter", "tooltipVisible", "getTooltipPopupContainer", "tooltipPlacement", "tooltip", "onChangeComplete"];
2
1
  function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
2
+ var _excluded = ["prefixCls", "range", "className", "rootClassName", "style", "disabled", "tooltipPrefixCls", "tipFormatter", "tooltipVisible", "getTooltipPopupContainer", "tooltipPlacement", "tooltip", "onChangeComplete"];
3
3
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
4
4
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
5
5
  function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
@@ -24,6 +24,7 @@ import { ConfigContext } from '../config-provider';
24
24
  import DisabledContext from '../config-provider/DisabledContext';
25
25
  import SliderTooltip from './SliderTooltip';
26
26
  import useStyle from './style';
27
+ import SliderInternalContext from './Context';
27
28
  import useRafLock from './useRafLock';
28
29
  function getTipFormatter(tipFormatter, legacyTipFormatter) {
29
30
  if (tipFormatter || tipFormatter === null) {
@@ -54,12 +55,18 @@ var Slider = /*#__PURE__*/React.forwardRef(function (props, ref) {
54
55
  restProps = _objectWithoutProperties(props, _excluded);
55
56
  var vertical = props.vertical;
56
57
  var _React$useContext = React.useContext(ConfigContext),
57
- direction = _React$useContext.direction,
58
+ contextDirection = _React$useContext.direction,
58
59
  slider = _React$useContext.slider,
59
60
  getPrefixCls = _React$useContext.getPrefixCls,
60
61
  getPopupContainer = _React$useContext.getPopupContainer;
61
62
  var contextDisabled = React.useContext(DisabledContext);
62
63
  var mergedDisabled = disabled !== null && disabled !== void 0 ? disabled : contextDisabled;
64
+ // ============================= Context ==============================
65
+ var _React$useContext2 = React.useContext(SliderInternalContext),
66
+ contextHandleRender = _React$useContext2.handleRender,
67
+ internalContextDirection = _React$useContext2.direction;
68
+ var mergedDirection = internalContextDirection || contextDirection;
69
+ var isRTL = mergedDirection === 'rtl';
63
70
  // =============================== Open ===============================
64
71
  var _useRafLock = useRafLock(),
65
72
  _useRafLock2 = _slicedToArray(_useRafLock, 2),
@@ -95,7 +102,7 @@ var Slider = /*#__PURE__*/React.forwardRef(function (props, ref) {
95
102
  if (!vert) {
96
103
  return 'top';
97
104
  }
98
- return direction === 'rtl' ? 'left' : 'right';
105
+ return isRTL ? 'left' : 'right';
99
106
  };
100
107
  // ============================== Style ===============================
101
108
  var prefixCls = getPrefixCls('slider', customizePrefixCls);
@@ -104,22 +111,11 @@ var Slider = /*#__PURE__*/React.forwardRef(function (props, ref) {
104
111
  wrapCSSVar = _useStyle2[0],
105
112
  hashId = _useStyle2[1],
106
113
  cssVarCls = _useStyle2[2];
107
- var cls = classNames(className, slider === null || slider === void 0 ? void 0 : slider.className, rootClassName, _defineProperty(_defineProperty({}, "".concat(prefixCls, "-rtl"), direction === 'rtl'), "".concat(prefixCls, "-lock"), dragging), hashId, cssVarCls);
114
+ var cls = classNames(className, slider === null || slider === void 0 ? void 0 : slider.className, rootClassName, _defineProperty(_defineProperty({}, "".concat(prefixCls, "-rtl"), isRTL), "".concat(prefixCls, "-lock"), dragging), hashId, cssVarCls);
108
115
  // make reverse default on rtl direction
109
- if (direction === 'rtl' && !restProps.vertical) {
116
+ if (isRTL && !restProps.vertical) {
110
117
  restProps.reverse = !restProps.reverse;
111
118
  }
112
- // ============================= Multiple =============================
113
- // Range config
114
- var _React$useMemo = React.useMemo(function () {
115
- if (!range) {
116
- return [false];
117
- }
118
- return _typeof(range) === 'object' ? [true, range.draggableTrack] : [true, false];
119
- }, [range]),
120
- _React$useMemo2 = _slicedToArray(_React$useMemo, 2),
121
- mergedRange = _React$useMemo2[0],
122
- draggableTrack = _React$useMemo2[1];
123
119
  // ============================= Warning ==============================
124
120
  // Warning for deprecated usage
125
121
  if (process.env.NODE_ENV !== 'production') {
@@ -145,38 +141,43 @@ var Slider = /*#__PURE__*/React.forwardRef(function (props, ref) {
145
141
  document.removeEventListener('mouseup', onMouseUp);
146
142
  };
147
143
  }, []);
148
- var useActiveTooltipHandle = mergedRange && !lockOpen;
149
- var handleRender = function handleRender(node, info) {
144
+ var useActiveTooltipHandle = range && !lockOpen;
145
+ var handleRender = contextHandleRender || function (node, info) {
150
146
  var index = info.index;
151
147
  var nodeProps = node.props;
148
+ function proxyEvent(eventName, event, triggerRestPropsEvent) {
149
+ var _nodeProps$eventName;
150
+ if (triggerRestPropsEvent) {
151
+ var _restProps$eventName;
152
+ (_restProps$eventName = restProps[eventName]) === null || _restProps$eventName === void 0 || _restProps$eventName.call(restProps, event);
153
+ }
154
+ (_nodeProps$eventName = nodeProps[eventName]) === null || _nodeProps$eventName === void 0 || _nodeProps$eventName.call(nodeProps, event);
155
+ }
152
156
  var passedProps = _objectSpread(_objectSpread({}, nodeProps), {}, {
153
157
  onMouseEnter: function onMouseEnter(e) {
154
- var _nodeProps$onMouseEnt;
155
158
  setHoverOpen(true);
156
- (_nodeProps$onMouseEnt = nodeProps.onMouseEnter) === null || _nodeProps$onMouseEnt === void 0 || _nodeProps$onMouseEnt.call(nodeProps, e);
159
+ proxyEvent('onMouseEnter', e);
157
160
  },
158
161
  onMouseLeave: function onMouseLeave(e) {
159
- var _nodeProps$onMouseLea;
160
162
  setHoverOpen(false);
161
- (_nodeProps$onMouseLea = nodeProps.onMouseLeave) === null || _nodeProps$onMouseLea === void 0 || _nodeProps$onMouseLea.call(nodeProps, e);
163
+ proxyEvent('onMouseLeave', e);
162
164
  },
163
165
  onMouseDown: function onMouseDown(e) {
164
- var _nodeProps$onMouseDow;
165
166
  setFocusOpen(true);
166
167
  setDragging(true);
167
- (_nodeProps$onMouseDow = nodeProps.onMouseDown) === null || _nodeProps$onMouseDow === void 0 || _nodeProps$onMouseDow.call(nodeProps, e);
168
+ proxyEvent('onMouseDown', e);
168
169
  },
169
170
  onFocus: function onFocus(e) {
170
- var _restProps$onFocus, _nodeProps$onFocus;
171
+ var _restProps$onFocus;
171
172
  setFocusOpen(true);
172
173
  (_restProps$onFocus = restProps.onFocus) === null || _restProps$onFocus === void 0 || _restProps$onFocus.call(restProps, e);
173
- (_nodeProps$onFocus = nodeProps.onFocus) === null || _nodeProps$onFocus === void 0 || _nodeProps$onFocus.call(nodeProps, e);
174
+ proxyEvent('onFocus', e, true);
174
175
  },
175
176
  onBlur: function onBlur(e) {
176
- var _restProps$onBlur, _nodeProps$onBlur;
177
+ var _restProps$onBlur;
177
178
  setFocusOpen(false);
178
179
  (_restProps$onBlur = restProps.onBlur) === null || _restProps$onBlur === void 0 || _restProps$onBlur.call(restProps, e);
179
- (_nodeProps$onBlur = nodeProps.onBlur) === null || _nodeProps$onBlur === void 0 || _nodeProps$onBlur.call(nodeProps, e);
180
+ proxyEvent('onBlur', e, true);
180
181
  }
181
182
  });
182
183
  var cloneNode = /*#__PURE__*/React.cloneElement(node, passedProps);
@@ -209,7 +210,8 @@ var Slider = /*#__PURE__*/React.forwardRef(function (props, ref) {
209
210
  placement: getTooltipPlacement(tooltipPlacement !== null && tooltipPlacement !== void 0 ? tooltipPlacement : legacyTooltipPlacement, vertical),
210
211
  key: "tooltip",
211
212
  overlayClassName: "".concat(prefixCls, "-tooltip"),
212
- getPopupContainer: getTooltipPopupContainer || legacyGetTooltipPopupContainer || getPopupContainer
213
+ getPopupContainer: getTooltipPopupContainer || legacyGetTooltipPopupContainer || getPopupContainer,
214
+ draggingDelete: info.draggingDelete
213
215
  }), cloneNode);
214
216
  } : undefined;
215
217
  // ============================== Render ==============================
@@ -218,8 +220,7 @@ var Slider = /*#__PURE__*/React.forwardRef(function (props, ref) {
218
220
  // @ts-ignore
219
221
  _jsx(RcSlider, _objectSpread(_objectSpread({}, restProps), {}, {
220
222
  step: restProps.step,
221
- range: mergedRange,
222
- draggableTrack: draggableTrack,
223
+ range: range,
223
224
  className: cls,
224
225
  style: mergedStyle,
225
226
  disabled: mergedDisabled,
@@ -19,24 +19,32 @@ var genBaseStyle = function genBaseStyle(token) {
19
19
  marginPart = token.marginPart,
20
20
  colorFillContentHover = token.colorFillContentHover,
21
21
  handleColorDisabled = token.handleColorDisabled,
22
- calc = token.calc;
22
+ calc = token.calc,
23
+ handleSize = token.handleSize,
24
+ handleSizeHover = token.handleSizeHover,
25
+ handleActiveColor = token.handleActiveColor,
26
+ handleActiveOutlineColor = token.handleActiveOutlineColor,
27
+ handleLineWidth = token.handleLineWidth,
28
+ handleLineWidthHover = token.handleLineWidthHover,
29
+ motionDurationMid = token.motionDurationMid;
23
30
  return _defineProperty({}, componentCls, _objectSpread(_objectSpread({}, resetComponent(token)), {}, (_objectSpread2 = {
24
31
  position: 'relative',
25
32
  height: controlSize,
26
33
  margin: "".concat(unit(marginPart), " ").concat(unit(marginFull)),
27
34
  padding: 0,
28
35
  cursor: 'pointer',
29
- touchAction: 'none'
30
- }, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_objectSpread2, "&-vertical", {
31
- margin: "".concat(unit(marginFull), " ").concat(unit(marginPart))
32
- }), "".concat(componentCls, "-rail"), {
36
+ touchAction: 'none',
37
+ '&-vertical': {
38
+ margin: "".concat(unit(marginFull), " ").concat(unit(marginPart))
39
+ }
40
+ }, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_objectSpread2, "".concat(componentCls, "-rail"), {
33
41
  position: 'absolute',
34
42
  backgroundColor: token.railBg,
35
43
  borderRadius: token.borderRadiusXS,
36
- transition: "background-color ".concat(token.motionDurationMid)
44
+ transition: "background-color ".concat(motionDurationMid)
37
45
  }), "".concat(componentCls, "-track,").concat(componentCls, "-tracks"), {
38
46
  position: 'absolute',
39
- transition: "background-color ".concat(token.motionDurationMid)
47
+ transition: "background-color ".concat(motionDurationMid)
40
48
  }), "".concat(componentCls, "-track"), {
41
49
  backgroundColor: token.trackBg,
42
50
  borderRadius: token.borderRadiusXS
@@ -51,22 +59,27 @@ var genBaseStyle = function genBaseStyle(token) {
51
59
  }), "".concat(componentCls, "-dot"), {
52
60
  borderColor: colorFillContentHover
53
61
  }), "".concat(componentCls, "-handle::after"), {
54
- boxShadow: "0 0 0 ".concat(unit(token.handleLineWidth), " ").concat(token.colorPrimaryBorderHover)
62
+ boxShadow: "0 0 0 ".concat(unit(handleLineWidth), " ").concat(token.colorPrimaryBorderHover)
55
63
  }), "".concat(componentCls, "-dot-active"), {
56
64
  borderColor: token.dotActiveBorderColor
57
65
  })), "".concat(componentCls, "-handle"), {
58
66
  position: 'absolute',
59
- width: token.handleSize,
60
- height: token.handleSize,
67
+ width: handleSize,
68
+ height: handleSize,
61
69
  outline: 'none',
70
+ userSelect: 'none',
71
+ // Dragging status
72
+ '&-dragging-delete': {
73
+ opacity: 0
74
+ },
62
75
  // 扩大选区
63
76
  '&::before': {
64
77
  content: '""',
65
78
  position: 'absolute',
66
- insetInlineStart: calc(token.handleLineWidth).mul(-1).equal(),
67
- insetBlockStart: calc(token.handleLineWidth).mul(-1).equal(),
68
- width: calc(token.handleSize).add(calc(token.handleLineWidth).mul(2)).equal(),
69
- height: calc(token.handleSize).add(calc(token.handleLineWidth).mul(2)).equal(),
79
+ insetInlineStart: calc(handleLineWidth).mul(-1).equal(),
80
+ insetBlockStart: calc(handleLineWidth).mul(-1).equal(),
81
+ width: calc(handleSize).add(calc(handleLineWidth).mul(2)).equal(),
82
+ height: calc(handleSize).add(calc(handleLineWidth).mul(2)).equal(),
70
83
  backgroundColor: 'transparent'
71
84
  },
72
85
  '&::after': {
@@ -74,36 +87,36 @@ var genBaseStyle = function genBaseStyle(token) {
74
87
  position: 'absolute',
75
88
  insetBlockStart: 0,
76
89
  insetInlineStart: 0,
77
- width: token.handleSize,
78
- height: token.handleSize,
90
+ width: handleSize,
91
+ height: handleSize,
79
92
  backgroundColor: token.colorBgElevated,
80
- boxShadow: "0 0 0 ".concat(unit(token.handleLineWidth), " ").concat(token.handleColor),
93
+ boxShadow: "0 0 0 ".concat(unit(handleLineWidth), " ").concat(token.handleColor),
94
+ outline: "0px solid transparent",
81
95
  borderRadius: '50%',
82
96
  cursor: 'pointer',
83
- transition: "\n inset-inline-start ".concat(token.motionDurationMid, ",\n inset-block-start ").concat(token.motionDurationMid, ",\n width ").concat(token.motionDurationMid, ",\n height ").concat(token.motionDurationMid, ",\n box-shadow ").concat(token.motionDurationMid, "\n ")
97
+ transition: "\n inset-inline-start ".concat(motionDurationMid, ",\n inset-block-start ").concat(motionDurationMid, ",\n width ").concat(motionDurationMid, ",\n height ").concat(motionDurationMid, ",\n box-shadow ").concat(motionDurationMid, ",\n outline ").concat(motionDurationMid, "\n ")
84
98
  },
85
99
  '&:hover, &:active, &:focus': {
86
100
  '&::before': {
87
- // -(
88
- // (token.handleSizeHover - token.handleSize) / 2 +
89
- // token.handleLineWidthHover
90
- // ),
91
- insetInlineStart: calc(token.handleSizeHover).sub(token.handleSize).div(2).add(token.handleLineWidthHover).mul(-1).equal(),
92
- insetBlockStart: calc(token.handleSizeHover).sub(token.handleSize).div(2).add(token.handleLineWidthHover).mul(-1).equal(),
93
- width: calc(token.handleSizeHover).add(calc(token.handleLineWidthHover).mul(2)).equal(),
94
- height: calc(token.handleSizeHover).add(calc(token.handleLineWidthHover).mul(2)).equal()
101
+ insetInlineStart: calc(handleSizeHover).sub(handleSize).div(2).add(handleLineWidthHover).mul(-1).equal(),
102
+ insetBlockStart: calc(handleSizeHover).sub(handleSize).div(2).add(handleLineWidthHover).mul(-1).equal(),
103
+ width: calc(handleSizeHover).add(calc(handleLineWidthHover).mul(2)).equal(),
104
+ height: calc(handleSizeHover).add(calc(handleLineWidthHover).mul(2)).equal()
95
105
  },
96
106
  '&::after': {
97
- boxShadow: "0 0 0 ".concat(unit(token.handleLineWidthHover), " ").concat(token.handleActiveColor),
98
- width: token.handleSizeHover,
99
- height: token.handleSizeHover,
100
- insetInlineStart: token.calc(token.handleSize).sub(token.handleSizeHover).div(2).equal(),
101
- insetBlockStart: token.calc(token.handleSize).sub(token.handleSizeHover).div(2).equal()
107
+ boxShadow: "0 0 0 ".concat(unit(handleLineWidthHover), " ").concat(handleActiveColor),
108
+ outline: "6px solid ".concat(handleActiveOutlineColor),
109
+ width: handleSizeHover,
110
+ height: handleSizeHover,
111
+ insetInlineStart: token.calc(handleSize).sub(handleSizeHover).div(2).equal(),
112
+ insetBlockStart: token.calc(handleSize).sub(handleSizeHover).div(2).equal()
102
113
  }
103
114
  }
104
- }), "&-lock ".concat(componentCls, "-handle"), _defineProperty({}, "&::before, &::after", {
105
- transition: 'none'
106
- })), "".concat(componentCls, "-mark"), {
115
+ }), "&-lock ".concat(componentCls, "-handle"), {
116
+ '&::before, &::after': {
117
+ transition: 'none'
118
+ }
119
+ }), "".concat(componentCls, "-mark"), {
107
120
  position: 'absolute',
108
121
  fontSize: token.fontSize
109
122
  }), "".concat(componentCls, "-mark-text"), {
@@ -117,16 +130,16 @@ var genBaseStyle = function genBaseStyle(token) {
117
130
  '&-active': {
118
131
  color: token.colorText
119
132
  }
120
- }), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_objectSpread2, "".concat(componentCls, "-step"), {
133
+ }), "".concat(componentCls, "-step"), {
121
134
  position: 'absolute',
122
135
  background: 'transparent',
123
136
  pointerEvents: 'none'
124
- }), "".concat(componentCls, "-dot"), {
137
+ }), _defineProperty(_defineProperty(_defineProperty(_objectSpread2, "".concat(componentCls, "-dot"), {
125
138
  position: 'absolute',
126
139
  width: dotSize,
127
140
  height: dotSize,
128
141
  backgroundColor: token.colorBgElevated,
129
- border: "".concat(unit(token.handleLineWidth), " solid ").concat(token.dotBorderColor),
142
+ border: "".concat(unit(handleLineWidth), " solid ").concat(token.dotBorderColor),
130
143
  borderRadius: '50%',
131
144
  cursor: 'pointer',
132
145
  transition: "border-color ".concat(token.motionDurationSlow),
@@ -148,9 +161,9 @@ var genBaseStyle = function genBaseStyle(token) {
148
161
  }), "".concat(componentCls, "-handle::after"), {
149
162
  backgroundColor: token.colorBgElevated,
150
163
  cursor: 'not-allowed',
151
- width: token.handleSize,
152
- height: token.handleSize,
153
- boxShadow: "0 0 0 ".concat(unit(token.handleLineWidth), " ").concat(handleColorDisabled),
164
+ width: handleSize,
165
+ height: handleSize,
166
+ boxShadow: "0 0 0 ".concat(unit(handleLineWidth), " ").concat(handleColorDisabled),
154
167
  insetInlineStart: 0,
155
168
  insetBlockStart: 0
156
169
  }), "\n ".concat(componentCls, "-mark-text,\n ").concat(componentCls, "-dot\n "), {
@@ -215,7 +228,9 @@ export var prepareComponentToken = function prepareComponentToken(token) {
215
228
  var controlSize = token.controlHeightLG / 4;
216
229
  var controlSizeHover = token.controlHeightSM / 2;
217
230
  var handleLineWidth = token.lineWidth + increaseHandleWidth;
218
- var handleLineWidthHover = token.lineWidth + increaseHandleWidth * 3;
231
+ var handleLineWidthHover = token.lineWidth + increaseHandleWidth * 1.5;
232
+ var handleActiveColor = token.colorPrimary;
233
+ var handleActiveOutlineColor = new TinyColor(handleActiveColor).setAlpha(0.2).toRgbString();
219
234
  return {
220
235
  controlSize: controlSize,
221
236
  railSize: 4,
@@ -226,10 +241,11 @@ export var prepareComponentToken = function prepareComponentToken(token) {
226
241
  handleLineWidthHover: handleLineWidthHover,
227
242
  railBg: token.colorFillTertiary,
228
243
  railHoverBg: token.colorFillSecondary,
229
- trackBg: token.colorPrimary,
230
- trackHoverBg: token.colorPrimary,
244
+ trackBg: token.colorPrimaryBorder,
245
+ trackHoverBg: token.colorPrimaryBorderHover,
231
246
  handleColor: token.colorPrimaryBorder,
232
- handleActiveColor: token.colorPrimary,
247
+ handleActiveColor: handleActiveColor,
248
+ handleActiveOutlineColor: handleActiveOutlineColor,
233
249
  handleColorDisabled: new TinyColor(token.colorTextDisabled).onBackground(token.colorBgContainer).toHexShortString(),
234
250
  dotBorderColor: token.colorBorderSecondary,
235
251
  dotActiveBorderColor: token.colorPrimaryBorder,