@chaoswise/ui 3.1.6 → 3.1.8

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 (357) hide show
  1. package/lib/Antd5/_util/PurePanel.js +9 -1
  2. package/lib/Antd5/_util/convertToTooltipProps.js +15 -0
  3. package/lib/Antd5/_util/extendsObject.js +14 -23
  4. package/lib/Antd5/_util/hooks/useClosable.js +25 -31
  5. package/lib/Antd5/_util/hooks/useMergeSemantic/index.js +89 -0
  6. package/lib/Antd5/_util/hooks/useMergeSemantic/interface.js +1 -0
  7. package/lib/Antd5/_util/isPrimitive.js +5 -0
  8. package/lib/Antd5/_util/mediaQueryUtil.js +16 -0
  9. package/lib/Antd5/_util/responsiveObserver.js +41 -33
  10. package/lib/Antd5/_util/toList.js +6 -3
  11. package/lib/Antd5/_util/warning.js +0 -1
  12. package/lib/Antd5/_util/wave/WaveEffect.js +29 -16
  13. package/lib/Antd5/_util/wave/index.js +2 -2
  14. package/lib/Antd5/_util/wave/useWave.js +1 -1
  15. package/lib/Antd5/affix/index.js +13 -11
  16. package/lib/Antd5/alert/Alert.js +19 -18
  17. package/lib/Antd5/anchor/Anchor.js +9 -7
  18. package/lib/Antd5/anchor/AnchorLink.js +16 -3
  19. package/lib/Antd5/app/App.js +90 -0
  20. package/lib/Antd5/app/index.js +3 -92
  21. package/lib/Antd5/app/useApp.js +6 -0
  22. package/lib/Antd5/auto-complete/AutoComplete.js +142 -0
  23. package/lib/Antd5/auto-complete/index.js +8 -106
  24. package/lib/Antd5/avatar/{avatar.js → Avatar.js} +25 -29
  25. package/lib/Antd5/avatar/{group.js → AvatarGroup.js} +14 -9
  26. package/lib/Antd5/avatar/index.js +3 -4
  27. package/lib/Antd5/breadcrumb/Breadcrumb.js +1 -0
  28. package/lib/Antd5/breadcrumb/style/index.js +1 -1
  29. package/lib/Antd5/button/{LoadingIcon.js → DefaultLoadingIcon.js} +12 -9
  30. package/lib/Antd5/button/button-group.js +11 -11
  31. package/lib/Antd5/button/button.js +60 -26
  32. package/lib/Antd5/button/buttonHelpers.js +8 -1
  33. package/lib/Antd5/button/style/compact.js +9 -10
  34. package/lib/Antd5/button/style/index.js +127 -41
  35. package/lib/Antd5/button/style/token.js +19 -8
  36. package/lib/Antd5/calendar/Header.js +4 -4
  37. package/lib/Antd5/calendar/generateCalendar.js +17 -12
  38. package/lib/Antd5/calendar/style/index.js +8 -2
  39. package/lib/Antd5/card/Card.js +9 -5
  40. package/lib/Antd5/card/style/index.js +22 -15
  41. package/lib/Antd5/carousel/index.js +21 -11
  42. package/lib/Antd5/carousel/style/index.js +39 -12
  43. package/lib/Antd5/cascader/index.js +54 -18
  44. package/lib/Antd5/cascader/style/columns.js +4 -2
  45. package/lib/Antd5/cascader/style/index.js +2 -1
  46. package/lib/Antd5/collapse/Collapse.js +32 -25
  47. package/lib/Antd5/collapse/style/index.js +14 -10
  48. package/lib/Antd5/color-picker/ColorPicker.js +13 -8
  49. package/lib/Antd5/color-picker/components/ColorAlphaInput.js +8 -13
  50. package/lib/Antd5/color-picker/components/ColorHexInput.js +1 -1
  51. package/lib/Antd5/color-picker/components/ColorHsbInput.js +8 -13
  52. package/lib/Antd5/color-picker/components/ColorInput.js +7 -7
  53. package/lib/Antd5/color-picker/components/ColorPresets.js +15 -12
  54. package/lib/Antd5/color-picker/components/ColorRgbInput.js +8 -13
  55. package/lib/Antd5/color-picker/components/ColorSteppers.js +6 -13
  56. package/lib/Antd5/color-picker/interface.js +3 -6
  57. package/lib/Antd5/color-picker/style/color-block.js +2 -1
  58. package/lib/Antd5/config-provider/MotionWrapper.js +12 -4
  59. package/lib/Antd5/config-provider/UnstableContext.js +29 -0
  60. package/lib/Antd5/config-provider/context.js +32 -2
  61. package/lib/Antd5/config-provider/cssVariables.js +7 -7
  62. package/lib/Antd5/config-provider/hooks/useSize.js +1 -1
  63. package/lib/Antd5/config-provider/index.js +12 -3
  64. package/lib/Antd5/date-picker/generatePicker/generateRangePicker.js +33 -12
  65. package/lib/Antd5/date-picker/generatePicker/generateSinglePicker.js +32 -13
  66. package/lib/Antd5/date-picker/hooks/useMergedPickerSemantic.js +47 -0
  67. package/lib/Antd5/date-picker/index.js +2 -2
  68. package/lib/Antd5/date-picker/locale/ar_EG.js +1 -8
  69. package/lib/Antd5/date-picker/locale/example.json +5 -8
  70. package/lib/Antd5/date-picker/locale/ko_KR.js +11 -1
  71. package/lib/Antd5/date-picker/locale/pl_PL.js +0 -3
  72. package/lib/Antd5/date-picker/locale/pt_PT.js +0 -3
  73. package/lib/Antd5/date-picker/locale/sl_SI.js +1 -3
  74. package/lib/Antd5/date-picker/style/index.js +9 -6
  75. package/lib/Antd5/date-picker/style/panel.js +12 -8
  76. package/lib/Antd5/date-picker/style/token.js +3 -3
  77. package/lib/Antd5/date-picker/style/variants.js +6 -2
  78. package/lib/Antd5/descriptions/Cell.js +14 -8
  79. package/lib/Antd5/descriptions/Item.js +2 -0
  80. package/lib/Antd5/descriptions/Row.js +10 -6
  81. package/lib/Antd5/descriptions/hooks/useRow.js +1 -1
  82. package/lib/Antd5/descriptions/index.js +45 -18
  83. package/lib/Antd5/descriptions/style/index.js +11 -2
  84. package/lib/Antd5/divider/index.js +32 -15
  85. package/lib/Antd5/divider/style/index.js +20 -7
  86. package/lib/Antd5/drawer/DrawerPanel.js +8 -10
  87. package/lib/Antd5/drawer/index.js +20 -17
  88. package/lib/Antd5/dropdown/dropdown-button.js +9 -3
  89. package/lib/Antd5/dropdown/dropdown.js +33 -35
  90. package/lib/Antd5/dropdown/style/index.js +1 -1
  91. package/lib/Antd5/empty/empty.js +2 -2
  92. package/lib/Antd5/empty/index.js +41 -23
  93. package/lib/Antd5/empty/simple.js +4 -4
  94. package/lib/Antd5/flex/style/index.js +2 -0
  95. package/lib/Antd5/float-button/FloatButton.js +12 -15
  96. package/lib/Antd5/float-button/FloatButtonContent.js +13 -7
  97. package/lib/Antd5/float-button/FloatButtonGroup.js +6 -6
  98. package/lib/Antd5/float-button/style/keyframes.js +4 -4
  99. package/lib/Antd5/form/ErrorList.js +1 -3
  100. package/lib/Antd5/form/Form.js +19 -19
  101. package/lib/Antd5/form/FormItem/index.js +1 -1
  102. package/lib/Antd5/form/FormItemLabel.js +12 -14
  103. package/lib/Antd5/form/context.js +3 -4
  104. package/lib/Antd5/form/hooks/useForm.js +16 -5
  105. package/lib/Antd5/form/hooks/useFormInstance.js +3 -3
  106. package/lib/Antd5/form/hooks/useFormItemStatus.js +7 -7
  107. package/lib/Antd5/form/hooks/useFormWarning.js +2 -2
  108. package/lib/Antd5/form/hooks/useFrameState.js +3 -4
  109. package/lib/Antd5/form/hooks/useItemRef.js +3 -2
  110. package/lib/Antd5/form/hooks/useVariants.js +5 -5
  111. package/lib/Antd5/form/style/index.js +22 -15
  112. package/lib/Antd5/grid/hooks/useBreakpoint.js +2 -1
  113. package/lib/Antd5/grid/hooks/useGutter.js +29 -0
  114. package/lib/Antd5/grid/row.js +8 -63
  115. package/lib/Antd5/grid/style/index.js +14 -8
  116. package/lib/Antd5/image/PreviewGroup.js +9 -2
  117. package/lib/Antd5/image/index.js +26 -17
  118. package/lib/Antd5/image/style/index.js +10 -10
  119. package/lib/Antd5/index.js +3 -1
  120. package/lib/Antd5/input/Group.js +5 -3
  121. package/lib/Antd5/input/Input.js +27 -20
  122. package/lib/Antd5/input/OTP/OTPInput.js +36 -19
  123. package/lib/Antd5/input/OTP/index.js +40 -19
  124. package/lib/Antd5/input/Password.js +7 -9
  125. package/lib/Antd5/input/Search.js +16 -9
  126. package/lib/Antd5/input/TextArea.js +90 -33
  127. package/lib/Antd5/input/style/index.js +31 -82
  128. package/lib/Antd5/input/style/otp.js +22 -6
  129. package/lib/Antd5/input/style/textarea.js +80 -0
  130. package/lib/Antd5/input/style/token.js +16 -7
  131. package/lib/Antd5/input/style/variants.js +67 -12
  132. package/lib/Antd5/input-number/index.js +1 -1
  133. package/lib/Antd5/input-number/style/index.js +10 -7
  134. package/lib/Antd5/input-number/style/token.js +6 -4
  135. package/lib/Antd5/layout/Sider.js +58 -68
  136. package/lib/Antd5/layout/layout.js +7 -5
  137. package/lib/Antd5/layout/style/sider.js +33 -42
  138. package/lib/Antd5/list/index.js +45 -45
  139. package/lib/Antd5/locale/ar_EG.js +7 -1
  140. package/lib/Antd5/locale/az_AZ.js +3 -2
  141. package/lib/Antd5/locale/bg_BG.js +8 -0
  142. package/lib/Antd5/locale/bn_BD.js +7 -1
  143. package/lib/Antd5/locale/by_BY.js +8 -2
  144. package/lib/Antd5/locale/ca_ES.js +7 -1
  145. package/lib/Antd5/locale/cs_CZ.js +19 -2
  146. package/lib/Antd5/locale/da_DK.js +8 -0
  147. package/lib/Antd5/locale/de_DE.js +4 -2
  148. package/lib/Antd5/locale/el_GR.js +3 -2
  149. package/lib/Antd5/locale/en_GB.js +8 -2
  150. package/lib/Antd5/locale/en_US.js +3 -2
  151. package/lib/Antd5/locale/es_ES.js +3 -2
  152. package/lib/Antd5/locale/et_EE.js +8 -2
  153. package/lib/Antd5/locale/eu_ES.js +3 -2
  154. package/lib/Antd5/locale/fa_IR.js +17 -7
  155. package/lib/Antd5/locale/fi_FI.js +8 -0
  156. package/lib/Antd5/locale/fr_BE.js +4 -1
  157. package/lib/Antd5/locale/fr_CA.js +9 -1
  158. package/lib/Antd5/locale/fr_FR.js +4 -1
  159. package/lib/Antd5/locale/ga_IE.js +7 -1
  160. package/lib/Antd5/locale/gl_ES.js +7 -1
  161. package/lib/Antd5/locale/he_IL.js +10 -1
  162. package/lib/Antd5/locale/hi_IN.js +7 -1
  163. package/lib/Antd5/locale/hr_HR.js +7 -1
  164. package/lib/Antd5/locale/hu_HU.js +8 -0
  165. package/lib/Antd5/locale/hy_AM.js +8 -3
  166. package/lib/Antd5/locale/id_ID.js +3 -2
  167. package/lib/Antd5/locale/is_IS.js +8 -0
  168. package/lib/Antd5/locale/it_IT.js +3 -2
  169. package/lib/Antd5/locale/ja_JP.js +3 -2
  170. package/lib/Antd5/locale/ka_GE.js +7 -1
  171. package/lib/Antd5/locale/kk_KZ.js +7 -1
  172. package/lib/Antd5/locale/km_KH.js +3 -0
  173. package/lib/Antd5/locale/kmr_IQ.js +8 -0
  174. package/lib/Antd5/locale/kn_IN.js +8 -2
  175. package/lib/Antd5/locale/ko_KR.js +3 -2
  176. package/lib/Antd5/locale/ku_IQ.js +8 -0
  177. package/lib/Antd5/locale/lt_LT.js +3 -2
  178. package/lib/Antd5/locale/lv_LV.js +8 -0
  179. package/lib/Antd5/locale/mk_MK.js +7 -1
  180. package/lib/Antd5/locale/ml_IN.js +7 -1
  181. package/lib/Antd5/locale/mn_MN.js +8 -2
  182. package/lib/Antd5/locale/ms_MY.js +3 -2
  183. package/lib/Antd5/locale/my_MM.js +3 -2
  184. package/lib/Antd5/locale/nb_NO.js +7 -1
  185. package/lib/Antd5/locale/ne_NP.js +3 -2
  186. package/lib/Antd5/locale/nl_BE.js +2 -1
  187. package/lib/Antd5/locale/nl_NL.js +2 -1
  188. package/lib/Antd5/locale/pl_PL.js +3 -2
  189. package/lib/Antd5/locale/pt_BR.js +3 -2
  190. package/lib/Antd5/locale/pt_PT.js +3 -2
  191. package/lib/Antd5/locale/ro_RO.js +7 -1
  192. package/lib/Antd5/locale/ru_RU.js +4 -3
  193. package/lib/Antd5/locale/si_LK.js +8 -2
  194. package/lib/Antd5/locale/sk_SK.js +8 -2
  195. package/lib/Antd5/locale/sl_SI.js +8 -0
  196. package/lib/Antd5/locale/sr_RS.js +7 -1
  197. package/lib/Antd5/locale/sv_SE.js +3 -2
  198. package/lib/Antd5/locale/ta_IN.js +8 -2
  199. package/lib/Antd5/locale/th_TH.js +3 -2
  200. package/lib/Antd5/locale/tk_TK.js +7 -1
  201. package/lib/Antd5/locale/tr_TR.js +8 -2
  202. package/lib/Antd5/locale/uk_UA.js +3 -2
  203. package/lib/Antd5/locale/ur_PK.js +7 -1
  204. package/lib/Antd5/locale/uz_UZ.js +5 -4
  205. package/lib/Antd5/locale/vi_VN.js +3 -2
  206. package/lib/Antd5/locale/zh_CN.js +3 -2
  207. package/lib/Antd5/locale/zh_HK.js +11 -3
  208. package/lib/Antd5/locale/zh_TW.js +11 -3
  209. package/lib/Antd5/mentions/index.js +1 -1
  210. package/lib/Antd5/mentions/style/index.js +12 -7
  211. package/lib/Antd5/menu/MenuItem.js +3 -1
  212. package/lib/Antd5/menu/OverrideContext.js +2 -2
  213. package/lib/Antd5/menu/menu.js +1 -7
  214. package/lib/Antd5/menu/style/index.js +9 -6
  215. package/lib/Antd5/menu/style/theme.js +4 -3
  216. package/lib/Antd5/menu/style/vertical.js +1 -1
  217. package/lib/Antd5/message/style/index.js +4 -3
  218. package/lib/Antd5/modal/ConfirmDialog.js +2 -19
  219. package/lib/Antd5/modal/Modal.js +67 -35
  220. package/lib/Antd5/modal/confirm.js +5 -3
  221. package/lib/Antd5/modal/style/confirm.js +3 -1
  222. package/lib/Antd5/modal/style/index.js +21 -1
  223. package/lib/Antd5/modal/useModal/HookModal.js +2 -1
  224. package/lib/Antd5/notification/PurePanel.js +13 -6
  225. package/lib/Antd5/notification/index.js +3 -4
  226. package/lib/Antd5/notification/style/index.js +4 -3
  227. package/lib/Antd5/notification/style/stack.js +2 -1
  228. package/lib/Antd5/notification/useNotification.js +9 -4
  229. package/lib/Antd5/notification/util.js +9 -0
  230. package/lib/Antd5/pagination/Pagination.js +87 -20
  231. package/lib/Antd5/pagination/style/index.js +2 -10
  232. package/lib/Antd5/pagination/useShowSizeChanger.js +13 -0
  233. package/lib/Antd5/popconfirm/index.js +21 -6
  234. package/lib/Antd5/popover/index.js +21 -8
  235. package/lib/Antd5/progress/Steps.js +6 -2
  236. package/lib/Antd5/progress/progress.js +2 -2
  237. package/lib/Antd5/progress/utils.js +3 -3
  238. package/lib/Antd5/qr-code/style/index.js +2 -2
  239. package/lib/Antd5/segmented/index.js +16 -8
  240. package/lib/Antd5/segmented/style/index.js +14 -6
  241. package/lib/Antd5/select/index.js +45 -16
  242. package/lib/Antd5/select/style/dropdown.js +10 -9
  243. package/lib/Antd5/select/style/index.js +14 -10
  244. package/lib/Antd5/select/style/single.js +6 -3
  245. package/lib/Antd5/select/style/variants.js +55 -1
  246. package/lib/Antd5/skeleton/Paragraph.js +5 -8
  247. package/lib/Antd5/skeleton/Skeleton.js +8 -7
  248. package/lib/Antd5/slider/SliderTooltip.js +3 -2
  249. package/lib/Antd5/slider/index.js +43 -17
  250. package/lib/Antd5/slider/style/index.js +3 -3
  251. package/lib/Antd5/slider/useRafLock.js +1 -1
  252. package/lib/Antd5/space/Compact.js +8 -6
  253. package/lib/Antd5/space/index.js +16 -12
  254. package/lib/Antd5/spin/index.js +11 -9
  255. package/lib/Antd5/spin/style/index.js +1 -3
  256. package/lib/Antd5/spin/usePercent.js +1 -1
  257. package/lib/Antd5/splitter/SplitBar.js +56 -7
  258. package/lib/Antd5/splitter/Splitter.js +27 -17
  259. package/lib/Antd5/splitter/hooks/useResizable.js +3 -3
  260. package/lib/Antd5/splitter/hooks/useResize.js +17 -6
  261. package/lib/Antd5/splitter/style/index.js +32 -6
  262. package/lib/Antd5/statistic/Countdown.js +8 -61
  263. package/lib/Antd5/statistic/Statistic.js +17 -9
  264. package/lib/Antd5/statistic/Timer.js +91 -0
  265. package/lib/Antd5/statistic/index.js +2 -0
  266. package/lib/Antd5/statistic/utils.js +2 -2
  267. package/lib/Antd5/steps/index.js +8 -7
  268. package/lib/Antd5/steps/style/index.js +1 -1
  269. package/lib/Antd5/style/index.js +9 -4
  270. package/lib/Antd5/switch/style/index.js +2 -2
  271. package/lib/Antd5/table/InternalTable.js +6 -5
  272. package/lib/Antd5/table/hooks/useFilter/FilterDropdown.js +15 -11
  273. package/lib/Antd5/table/hooks/useFilter/FilterSearch.js +1 -1
  274. package/lib/Antd5/table/hooks/useFilter/index.js +3 -2
  275. package/lib/Antd5/table/hooks/useSelection.js +11 -3
  276. package/lib/Antd5/table/hooks/useSorter.js +4 -3
  277. package/lib/Antd5/table/style/filter.js +2 -2
  278. package/lib/Antd5/table/style/index.js +9 -9
  279. package/lib/Antd5/table/style/sorter.js +2 -1
  280. package/lib/Antd5/table/style/sticky.js +1 -1
  281. package/lib/Antd5/tabs/hooks/useLegacyItems.js +11 -4
  282. package/lib/Antd5/tabs/index.js +9 -2
  283. package/lib/Antd5/tabs/style/index.js +44 -23
  284. package/lib/Antd5/tag/style/index.js +3 -3
  285. package/lib/Antd5/theme/context.js +1 -3
  286. package/lib/Antd5/theme/getDesignToken.js +2 -2
  287. package/lib/Antd5/theme/themes/dark/colorAlgorithm.js +3 -3
  288. package/lib/Antd5/theme/themes/dark/index.js +13 -3
  289. package/lib/Antd5/theme/themes/default/colorAlgorithm.js +3 -3
  290. package/lib/Antd5/theme/themes/default/index.js +5 -1
  291. package/lib/Antd5/theme/themes/default/theme.js +4 -0
  292. package/lib/Antd5/theme/themes/shared/genColorMapToken.js +3 -3
  293. package/lib/Antd5/theme/themes/shared/genFontSizes.js +3 -1
  294. package/lib/Antd5/theme/util/alias.js +2 -2
  295. package/lib/Antd5/theme/util/genStyleUtils.js +9 -11
  296. package/lib/Antd5/theme/util/getAlphaColor.js +12 -12
  297. package/lib/Antd5/theme/util/useResetIconStyle.js +2 -10
  298. package/lib/Antd5/time-picker/index.js +1 -1
  299. package/lib/Antd5/timeline/TimelineItemList.js +1 -1
  300. package/lib/Antd5/tooltip/index.js +46 -31
  301. package/lib/Antd5/tooltip/style/index.js +13 -4
  302. package/lib/Antd5/tour/index.js +4 -2
  303. package/lib/Antd5/tour/panelRender.js +42 -27
  304. package/lib/Antd5/tour/style/index.js +3 -3
  305. package/lib/Antd5/transfer/ListItem.js +1 -1
  306. package/lib/Antd5/transfer/hooks/useData.js +8 -4
  307. package/lib/Antd5/transfer/hooks/useSelection.js +5 -4
  308. package/lib/Antd5/transfer/index.js +6 -2
  309. package/lib/Antd5/transfer/list.js +32 -13
  310. package/lib/Antd5/transfer/search.js +1 -1
  311. package/lib/Antd5/transfer/style/index.js +3 -1
  312. package/lib/Antd5/tree/DirectoryTree.js +2 -2
  313. package/lib/Antd5/tree/style/index.js +9 -3
  314. package/lib/Antd5/tree-select/index.js +61 -18
  315. package/lib/Antd5/tree-select/style/index.js +1 -1
  316. package/lib/Antd5/typography/Base/Ellipsis.js +3 -3
  317. package/lib/Antd5/typography/Base/index.js +20 -13
  318. package/lib/Antd5/typography/Editable.js +1 -1
  319. package/lib/Antd5/typography/Typography.js +8 -7
  320. package/lib/Antd5/typography/hooks/useCopyClick.js +24 -25
  321. package/lib/Antd5/typography/hooks/usePrevious.js +1 -1
  322. package/lib/Antd5/typography/style/index.js +5 -5
  323. package/lib/Antd5/typography/style/mixins.js +1 -1
  324. package/lib/Antd5/upload/Upload.js +22 -24
  325. package/lib/Antd5/version/index.js +0 -1
  326. package/lib/Antd5/version/token-meta.json +1 -0
  327. package/lib/Antd5/version/token.json +1 -0
  328. package/lib/Antd5/version/version.js +1 -1
  329. package/lib/Antd5/watermark/context.js +1 -1
  330. package/lib/Antd5/watermark/index.js +20 -13
  331. package/lib/Antd5/watermark/useClips.js +18 -16
  332. package/lib/Antd5/watermark/useRafDebounce.js +1 -1
  333. package/lib/Antd5/watermark/useSingletonCache.js +19 -0
  334. package/lib/Antd5/watermark/useWatermark.js +9 -18
  335. package/lib/CWCascader/rc-cascader/OptionList/Column.js +17 -18
  336. package/lib/CWMessage/MessageContent/TabList/index.js +10 -10
  337. package/lib/CWMessage/MessageContent/index.js +26 -28
  338. package/lib/CWMessage/index.js +42 -46
  339. package/lib/CWRangePicker/index.js +15 -15
  340. package/lib/CWRangePicker/utils/generate/dayjs.js +112 -23
  341. package/lib/CWRangePicker/utils/generate/moment.js +109 -21
  342. package/lib/CWSelect/index.js +423 -150
  343. package/lib/CWTable/CWTable.js +11 -11
  344. package/lib/Joyride/index.js +3 -3
  345. package/lib/ModuleFederation/react-dynamic-remote-component/RemoteComponent.js +38 -39
  346. package/lib/ModuleFederation/react-dynamic-remote-component/load-module.js +22 -23
  347. package/lib/QuickTransfer/index.js +13 -13
  348. package/lib/SearchBar/index.js +7 -7
  349. package/lib/SingleSpa/index.js +22 -24
  350. package/lib/TimeRangeSlider/TimeRangeSliderCmp/hooks/useMouse.js +3 -3
  351. package/lib/TimeRangeSlider/index.js +6 -6
  352. package/lib/TimeRangeSlider/utils/generate/dayjs.js +109 -20
  353. package/lib/TimeRangeSlider/utils/generate/moment.js +109 -20
  354. package/lib/TimeZoneSelect/index.js +21 -22
  355. package/package.json +35 -34
  356. package/lib/Antd5/_util/isNumeric.js +0 -4
  357. package/lib/Antd5/pagination/Select.js +0 -24
@@ -1,6 +1,6 @@
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
1
  var _excluded = ["currentSlide", "slideCount"],
3
- _excluded2 = ["dots", "arrows", "prevArrow", "nextArrow", "draggable", "waitForAnimate", "dotPosition", "vertical", "rootClassName", "className", "style", "id"];
2
+ _excluded2 = ["dots", "arrows", "prevArrow", "nextArrow", "draggable", "waitForAnimate", "dotPosition", "vertical", "rootClassName", "className", "style", "id", "autoplay", "autoplaySpeed"];
3
+ 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); }
4
4
  function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }
5
5
  function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
6
6
  function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
@@ -18,8 +18,8 @@ import { jsx as _jsx } from "react/jsx-runtime";
18
18
  import * as React from 'react';
19
19
  import SlickCarousel from '@ant-design/react-slick';
20
20
  import classNames from 'classnames';
21
- import { ConfigContext } from '../config-provider';
22
- import useStyle from './style';
21
+ import { useComponentConfig } from '../config-provider/context';
22
+ import useStyle, { DotDuration } from './style';
23
23
  var dotsClass = 'slick-dots';
24
24
  var ArrowButton = function ArrowButton(_ref) {
25
25
  var currentSlide = _ref.currentSlide,
@@ -54,12 +54,17 @@ var Carousel = /*#__PURE__*/React.forwardRef(function (props, ref) {
54
54
  customClassName = props.className,
55
55
  style = props.style,
56
56
  id = props.id,
57
+ _props$autoplay = props.autoplay,
58
+ autoplay = _props$autoplay === void 0 ? false : _props$autoplay,
59
+ _props$autoplaySpeed = props.autoplaySpeed,
60
+ autoplaySpeed = _props$autoplaySpeed === void 0 ? 3000 : _props$autoplaySpeed,
57
61
  otherProps = _objectWithoutProperties(props, _excluded2);
58
- var _React$useContext = React.useContext(ConfigContext),
59
- getPrefixCls = _React$useContext.getPrefixCls,
60
- direction = _React$useContext.direction,
61
- carousel = _React$useContext.carousel;
62
- var slickRef = React.useRef();
62
+ var _useComponentConfig = useComponentConfig('carousel'),
63
+ getPrefixCls = _useComponentConfig.getPrefixCls,
64
+ direction = _useComponentConfig.direction,
65
+ contextClassName = _useComponentConfig.className,
66
+ contextStyle = _useComponentConfig.style;
67
+ var slickRef = React.useRef(null);
63
68
  var goTo = function goTo(slide) {
64
69
  var dontAnimate = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
65
70
  slickRef.current.slickGoTo(slide, dontAnimate);
@@ -82,8 +87,9 @@ var Carousel = /*#__PURE__*/React.forwardRef(function (props, ref) {
82
87
  }, [props.children]);
83
88
  var newProps = _objectSpread({
84
89
  vertical: vertical,
85
- className: classNames(customClassName, carousel === null || carousel === void 0 ? void 0 : carousel.className),
86
- style: _objectSpread(_objectSpread({}, carousel === null || carousel === void 0 ? void 0 : carousel.style), style)
90
+ className: classNames(customClassName, contextClassName),
91
+ style: _objectSpread(_objectSpread({}, contextStyle), style),
92
+ autoplay: !!autoplay
87
93
  }, otherProps);
88
94
  if (newProps.effect === 'fade') {
89
95
  newProps.fade = true;
@@ -97,9 +103,12 @@ var Carousel = /*#__PURE__*/React.forwardRef(function (props, ref) {
97
103
  hashId = _useStyle2[1],
98
104
  cssVarCls = _useStyle2[2];
99
105
  var className = classNames(prefixCls, _defineProperty(_defineProperty({}, "".concat(prefixCls, "-rtl"), direction === 'rtl'), "".concat(prefixCls, "-vertical"), newProps.vertical), hashId, cssVarCls, rootClassName);
106
+ var mergedShowDuration = autoplay && (_typeof(autoplay) === 'object' ? autoplay.dotDuration : false);
107
+ var dotDurationStyle = mergedShowDuration ? _defineProperty({}, DotDuration, "".concat(autoplaySpeed, "ms")) : {};
100
108
  return wrapCSSVar(_jsx("div", {
101
109
  className: className,
102
110
  id: id,
111
+ style: dotDurationStyle,
103
112
  children: _jsx(SlickCarousel, _objectSpread(_objectSpread({
104
113
  ref: slickRef
105
114
  }, newProps), {}, {
@@ -110,6 +119,7 @@ var Carousel = /*#__PURE__*/React.forwardRef(function (props, ref) {
110
119
  nextArrow: nextArrow,
111
120
  draggable: draggable,
112
121
  verticalSwiping: vertical,
122
+ autoplaySpeed: autoplaySpeed,
113
123
  waitForAnimate: waitForAnimate
114
124
  }))
115
125
  }));
@@ -7,6 +7,7 @@ function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e
7
7
  import { unit } from '@ant-design/cssinjs';
8
8
  import { resetComponent } from '../../style';
9
9
  import { genStyleHooks } from '../../theme/internal';
10
+ export var DotDuration = '--dot-duration';
10
11
  var genCarouselStyle = function genCarouselStyle(token) {
11
12
  var componentCls = token.componentCls,
12
13
  antCls = token.antCls;
@@ -87,7 +88,7 @@ var genArrowsStyle = function genArrowsStyle(token) {
87
88
  arrowSize = token.arrowSize,
88
89
  arrowOffset = token.arrowOffset;
89
90
  var arrowLength = token.calc(arrowSize).div(Math.SQRT2).equal();
90
- return [_defineProperty({}, componentCls, {
91
+ return _defineProperty({}, componentCls, {
91
92
  // Arrows
92
93
  '.slick-prev, .slick-next': {
93
94
  position: 'absolute',
@@ -121,8 +122,8 @@ var genArrowsStyle = function genArrowsStyle(token) {
121
122
  width: arrowLength,
122
123
  height: arrowLength,
123
124
  border: "0 solid currentcolor",
124
- borderInlineWidth: '2px 0',
125
- borderBlockWidth: '2px 0',
125
+ borderInlineStartWidth: 2,
126
+ borderBlockStartWidth: 2,
126
127
  borderRadius: 1,
127
128
  content: '""'
128
129
  }
@@ -139,7 +140,7 @@ var genArrowsStyle = function genArrowsStyle(token) {
139
140
  transform: 'rotate(135deg)'
140
141
  }
141
142
  }
142
- })];
143
+ });
143
144
  };
144
145
  var genDotsStyle = function genDotsStyle(token) {
145
146
  var componentCls = token.componentCls,
@@ -149,7 +150,7 @@ var genDotsStyle = function genDotsStyle(token) {
149
150
  dotGap = token.dotGap,
150
151
  colorBgContainer = token.colorBgContainer,
151
152
  motionDurationSlow = token.motionDurationSlow;
152
- return [_defineProperty({}, componentCls, {
153
+ return _defineProperty({}, componentCls, {
153
154
  '.slick-dots': {
154
155
  position: 'absolute',
155
156
  insetInlineEnd: 0,
@@ -181,6 +182,24 @@ var genDotsStyle = function genDotsStyle(token) {
181
182
  textIndent: -999,
182
183
  verticalAlign: 'top',
183
184
  transition: "all ".concat(motionDurationSlow),
185
+ borderRadius: dotHeight,
186
+ overflow: 'hidden',
187
+ '&::after': {
188
+ display: 'block',
189
+ position: 'absolute',
190
+ top: 0,
191
+ insetInlineStart: 0,
192
+ width: '100%',
193
+ height: dotHeight,
194
+ content: '""',
195
+ background: colorBgContainer,
196
+ borderRadius: dotHeight,
197
+ opacity: 1,
198
+ outline: 'none',
199
+ cursor: 'pointer',
200
+ overflow: 'hidden',
201
+ transform: 'translate3d(-100%, 0, 0)'
202
+ },
184
203
  button: {
185
204
  position: 'relative',
186
205
  display: 'block',
@@ -196,7 +215,8 @@ var genDotsStyle = function genDotsStyle(token) {
196
215
  cursor: 'pointer',
197
216
  opacity: 0.2,
198
217
  transition: "all ".concat(motionDurationSlow),
199
- '&: hover, &:focus': {
218
+ overflow: 'hidden',
219
+ '&:hover': {
200
220
  opacity: 0.75
201
221
  },
202
222
  '&::after': {
@@ -207,17 +227,18 @@ var genDotsStyle = function genDotsStyle(token) {
207
227
  },
208
228
  '&.slick-active': {
209
229
  width: token.dotActiveWidth,
210
- '& button': {
211
- background: colorBgContainer,
230
+ position: 'relative',
231
+ '&:hover': {
212
232
  opacity: 1
213
233
  },
214
- '&: hover, &:focus': {
215
- opacity: 1
234
+ '&::after': {
235
+ transform: 'translate3d(0, 0, 0)',
236
+ transition: "transform var(".concat(DotDuration, ") ease-out")
216
237
  }
217
238
  }
218
239
  }
219
240
  }
220
- })];
241
+ });
221
242
  };
222
243
  var genCarouselVerticalStyle = function genCarouselVerticalStyle(token) {
223
244
  var componentCls = token.componentCls,
@@ -268,8 +289,14 @@ var genCarouselVerticalStyle = function genCarouselVerticalStyle(token) {
268
289
  margin: "".concat(unit(marginXXS), " 0"),
269
290
  verticalAlign: 'baseline',
270
291
  button: reverseSizeOfDot,
292
+ '&::after': _objectSpread(_objectSpread({}, reverseSizeOfDot), {}, {
293
+ height: 0
294
+ }),
271
295
  '&.slick-active': _objectSpread(_objectSpread({}, reverseSizeOfDot), {}, {
272
- button: reverseSizeOfDot
296
+ button: reverseSizeOfDot,
297
+ '&::after': _objectSpread(_objectSpread({}, reverseSizeOfDot), {}, {
298
+ transition: "height var(".concat(DotDuration, ") ease-out")
299
+ })
273
300
  })
274
301
  })
275
302
  }
@@ -1,4 +1,4 @@
1
- var _excluded = ["prefixCls", "size", "disabled", "className", "rootClassName", "multiple", "bordered", "transitionName", "choiceTransitionName", "popupClassName", "dropdownClassName", "expandIcon", "placement", "showSearch", "allowClear", "notFoundContent", "direction", "getPopupContainer", "status", "showArrow", "builtinPlacements", "style", "variant"];
1
+ var _excluded = ["prefixCls", "size", "disabled", "className", "rootClassName", "multiple", "bordered", "transitionName", "choiceTransitionName", "popupClassName", "dropdownClassName", "expandIcon", "placement", "showSearch", "allowClear", "notFoundContent", "direction", "getPopupContainer", "status", "showArrow", "builtinPlacements", "style", "variant", "dropdownRender", "onDropdownVisibleChange", "dropdownMenuColumnStyle", "popupRender", "dropdownStyle", "popupMenuColumnStyle", "onOpenChange", "styles", "classNames"];
2
2
  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; }
3
3
  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; }
4
4
  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; }
@@ -19,7 +19,7 @@ function _arrayWithoutHoles(r) { if (Array.isArray(r)) return _arrayLikeToArray(
19
19
  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; }
20
20
  import { jsx as _jsx } from "react/jsx-runtime";
21
21
  import * as React from 'react';
22
- import classNames from 'classnames';
22
+ import cls from 'classnames';
23
23
  import RcCascader from 'rc-cascader';
24
24
  import omit from 'rc-util/lib/omit';
25
25
  import { useZIndex } from '../_util/hooks/useZIndex';
@@ -28,6 +28,7 @@ import genPurePanel from '../_util/PurePanel';
28
28
  import { getMergedStatus, getStatusClassNames } from '../_util/statusUtils';
29
29
  import { devUseWarning } from '../_util/warning';
30
30
  import { ConfigContext } from '../config-provider';
31
+ import { useComponentConfig } from '../config-provider/context';
31
32
  import DefaultRenderEmpty from '../config-provider/defaultRenderEmpty';
32
33
  import DisabledContext from '../config-provider/DisabledContext';
33
34
  import useCSSVarCls from '../config-provider/hooks/useCSSVarCls';
@@ -86,7 +87,7 @@ var defaultSearchRender = function defaultSearchRender(inputValue, path, prefixC
86
87
  return optionList;
87
88
  };
88
89
  var Cascader = /*#__PURE__*/React.forwardRef(function (props, ref) {
89
- var _restProps$dropdownSt;
90
+ var _classNames$popup, _contextClassNames$po, _styles$popup, _contextStyles$popup;
90
91
  var customizePrefixCls = props.prefixCls,
91
92
  customizeSize = props.size,
92
93
  customDisabled = props.disabled,
@@ -113,13 +114,26 @@ var Cascader = /*#__PURE__*/React.forwardRef(function (props, ref) {
113
114
  builtinPlacements = props.builtinPlacements,
114
115
  style = props.style,
115
116
  customVariant = props.variant,
117
+ dropdownRender = props.dropdownRender,
118
+ onDropdownVisibleChange = props.onDropdownVisibleChange,
119
+ dropdownMenuColumnStyle = props.dropdownMenuColumnStyle,
120
+ popupRender = props.popupRender,
121
+ dropdownStyle = props.dropdownStyle,
122
+ popupMenuColumnStyle = props.popupMenuColumnStyle,
123
+ onOpenChange = props.onOpenChange,
124
+ styles = props.styles,
125
+ classNames = props.classNames,
116
126
  rest = _objectWithoutProperties(props, _excluded);
117
127
  var restProps = omit(rest, ['suffixIcon']);
128
+ var _useComponentConfig = useComponentConfig('cascader'),
129
+ getPrefixCls = _useComponentConfig.getPrefixCls,
130
+ getContextPopupContainer = _useComponentConfig.getPopupContainer,
131
+ contextClassName = _useComponentConfig.className,
132
+ contextStyle = _useComponentConfig.style,
133
+ contextClassNames = _useComponentConfig.classNames,
134
+ contextStyles = _useComponentConfig.styles;
118
135
  var _React$useContext = React.useContext(ConfigContext),
119
- getContextPopupContainer = _React$useContext.getPopupContainer,
120
- getPrefixCls = _React$useContext.getPrefixCls,
121
- popupOverflow = _React$useContext.popupOverflow,
122
- cascader = _React$useContext.cascader;
136
+ popupOverflow = _React$useContext.popupOverflow;
123
137
  // =================== Form =====================
124
138
  var _React$useContext2 = React.useContext(FormItemInputContext),
125
139
  contextStatus = _React$useContext2.status,
@@ -130,9 +144,22 @@ var Cascader = /*#__PURE__*/React.forwardRef(function (props, ref) {
130
144
  // =================== Warning =====================
131
145
  if (process.env.NODE_ENV !== 'production') {
132
146
  var warning = devUseWarning('Cascader');
133
- warning.deprecated(!dropdownClassName, 'dropdownClassName', 'popupClassName');
147
+ // v5 deprecated dropdown api
148
+ var deprecatedProps = {
149
+ dropdownClassName: 'classNames.popup.root',
150
+ dropdownStyle: 'styles.popup.root',
151
+ dropdownRender: 'popupRender',
152
+ dropdownMenuColumnStyle: 'popupMenuColumnStyle',
153
+ onDropdownVisibleChange: 'onOpenChange',
154
+ bordered: 'variant'
155
+ };
156
+ Object.entries(deprecatedProps).forEach(function (_ref) {
157
+ var _ref2 = _slicedToArray(_ref, 2),
158
+ oldProp = _ref2[0],
159
+ newProp = _ref2[1];
160
+ warning.deprecated(!(oldProp in props), oldProp, newProp);
161
+ });
134
162
  warning(!('showArrow' in props), 'deprecated', '`showArrow` is deprecated which will be removed in next major version. It will be a default behavior, you can hide it by setting `suffixIcon` to null.');
135
- warning.deprecated(!('bordered' in props), 'bordered', 'variant');
136
163
  }
137
164
  // ==================== Prefix =====================
138
165
  var _useBase = useBase(customizePrefixCls, direction),
@@ -165,7 +192,11 @@ var Cascader = /*#__PURE__*/React.forwardRef(function (props, ref) {
165
192
  componentName: "Cascader"
166
193
  });
167
194
  // =================== Dropdown ====================
168
- var mergedDropdownClassName = classNames(popupClassName || dropdownClassName, "".concat(cascaderPrefixCls, "-dropdown"), _defineProperty({}, "".concat(cascaderPrefixCls, "-dropdown-rtl"), mergedDirection === 'rtl'), rootClassName, rootCls, cascaderRootCls, hashId, cssVarCls);
195
+ var mergedPopupClassName = cls((classNames === null || classNames === void 0 || (_classNames$popup = classNames.popup) === null || _classNames$popup === void 0 ? void 0 : _classNames$popup.root) || ((_contextClassNames$po = contextClassNames.popup) === null || _contextClassNames$po === void 0 ? void 0 : _contextClassNames$po.root) || popupClassName || dropdownClassName, "".concat(cascaderPrefixCls, "-dropdown"), _defineProperty({}, "".concat(cascaderPrefixCls, "-dropdown-rtl"), mergedDirection === 'rtl'), rootClassName, rootCls, contextClassNames.root, classNames === null || classNames === void 0 ? void 0 : classNames.root, cascaderRootCls, hashId, cssVarCls);
196
+ var mergedPopupRender = popupRender || dropdownRender;
197
+ var mergedPopupMenuColumnStyle = popupMenuColumnStyle || dropdownMenuColumnStyle;
198
+ var mergedOnOpenChange = onOpenChange || onDropdownVisibleChange;
199
+ var mergedPopupStyle = (styles === null || styles === void 0 || (_styles$popup = styles.popup) === null || _styles$popup === void 0 ? void 0 : _styles$popup.root) || ((_contextStyles$popup = contextStyles.popup) === null || _contextStyles$popup === void 0 ? void 0 : _contextStyles$popup.root) || dropdownStyle;
169
200
  // ==================== Search =====================
170
201
  var mergedShowSearch = React.useMemo(function () {
171
202
  if (!showSearch) {
@@ -181,8 +212,8 @@ var Cascader = /*#__PURE__*/React.forwardRef(function (props, ref) {
181
212
  }, [showSearch]);
182
213
  // ===================== Size ======================
183
214
  var mergedSize = useSize(function (ctx) {
184
- var _ref;
185
- return (_ref = customizeSize !== null && customizeSize !== void 0 ? customizeSize : compactSize) !== null && _ref !== void 0 ? _ref : ctx;
215
+ var _ref3;
216
+ return (_ref3 = customizeSize !== null && customizeSize !== void 0 ? customizeSize : compactSize) !== null && _ref3 !== void 0 ? _ref3 : ctx;
186
217
  });
187
218
  // ===================== Disabled =====================
188
219
  var disabled = React.useContext(DisabledContext);
@@ -218,15 +249,15 @@ var Cascader = /*#__PURE__*/React.forwardRef(function (props, ref) {
218
249
  clearIcon: clearIcon
219
250
  } : allowClear;
220
251
  // ============================ zIndex ============================
221
- var _useZIndex = useZIndex('SelectLike', (_restProps$dropdownSt = restProps.dropdownStyle) === null || _restProps$dropdownSt === void 0 ? void 0 : _restProps$dropdownSt.zIndex),
252
+ var _useZIndex = useZIndex('SelectLike', mergedPopupStyle === null || mergedPopupStyle === void 0 ? void 0 : mergedPopupStyle.zIndex),
222
253
  _useZIndex2 = _slicedToArray(_useZIndex, 1),
223
254
  zIndex = _useZIndex2[0];
224
255
  // ==================== Render =====================
225
256
  var renderNode = _jsx(RcCascader, _objectSpread(_objectSpread({
226
257
  prefixCls: prefixCls,
227
- className: classNames(!customizePrefixCls && cascaderPrefixCls, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(prefixCls, "-lg"), mergedSize === 'large'), "".concat(prefixCls, "-sm"), mergedSize === 'small'), "".concat(prefixCls, "-rtl"), isRtl), "".concat(prefixCls, "-").concat(variant), enableVariantCls), "".concat(prefixCls, "-in-form-item"), isFormItemInput), getStatusClassNames(prefixCls, mergedStatus, hasFeedback), compactItemClassnames, cascader === null || cascader === void 0 ? void 0 : cascader.className, className, rootClassName, rootCls, cascaderRootCls, hashId, cssVarCls),
258
+ className: cls(!customizePrefixCls && cascaderPrefixCls, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(prefixCls, "-lg"), mergedSize === 'large'), "".concat(prefixCls, "-sm"), mergedSize === 'small'), "".concat(prefixCls, "-rtl"), isRtl), "".concat(prefixCls, "-").concat(variant), enableVariantCls), "".concat(prefixCls, "-in-form-item"), isFormItemInput), getStatusClassNames(prefixCls, mergedStatus, hasFeedback), compactItemClassnames, contextClassName, className, rootClassName, classNames === null || classNames === void 0 ? void 0 : classNames.root, contextClassNames.root, rootCls, cascaderRootCls, hashId, cssVarCls),
228
259
  disabled: mergedDisabled,
229
- style: _objectSpread(_objectSpread({}, cascader === null || cascader === void 0 ? void 0 : cascader.style), style)
260
+ style: _objectSpread(_objectSpread(_objectSpread(_objectSpread({}, contextStyles.root), styles === null || styles === void 0 ? void 0 : styles.root), contextStyle), style)
230
261
  }, restProps), {}, {
231
262
  builtinPlacements: mergedBuiltinPlacements(builtinPlacements, popupOverflow),
232
263
  direction: mergedDirection,
@@ -239,11 +270,14 @@ var Cascader = /*#__PURE__*/React.forwardRef(function (props, ref) {
239
270
  removeIcon: removeIcon,
240
271
  loadingIcon: loadingIcon,
241
272
  checkable: checkable,
242
- dropdownClassName: mergedDropdownClassName,
273
+ dropdownClassName: mergedPopupClassName,
243
274
  dropdownPrefixCls: customizePrefixCls || cascaderPrefixCls,
244
- dropdownStyle: _objectSpread(_objectSpread({}, restProps.dropdownStyle), {}, {
275
+ dropdownStyle: _objectSpread(_objectSpread({}, mergedPopupStyle), {}, {
245
276
  zIndex: zIndex
246
277
  }),
278
+ dropdownRender: mergedPopupRender,
279
+ dropdownMenuColumnStyle: mergedPopupMenuColumnStyle,
280
+ onOpenChange: mergedOnOpenChange,
247
281
  choiceTransitionName: getTransitionName(rootPrefixCls, '', choiceTransitionName),
248
282
  transitionName: getTransitionName(rootPrefixCls, 'slide-up', transitionName),
249
283
  getPopupContainer: getPopupContainer || getContextPopupContainer,
@@ -256,7 +290,9 @@ if (process.env.NODE_ENV !== 'production') {
256
290
  }
257
291
  // We don't care debug panel
258
292
  /* istanbul ignore next */
259
- var PurePanel = genPurePanel(Cascader);
293
+ var PurePanel = genPurePanel(Cascader, 'dropdownAlign', function (props) {
294
+ return omit(props, ['visible']);
295
+ });
260
296
  Cascader.SHOW_PARENT = SHOW_PARENT;
261
297
  Cascader.SHOW_CHILD = SHOW_CHILD;
262
298
  Cascader.Panel = CascaderPanel;
@@ -18,7 +18,8 @@ var getColumnsStyle = function getColumnsStyle(token) {
18
18
  // ================== Checkbox ==================
19
19
  '&-checkbox': {
20
20
  top: 0,
21
- marginInlineEnd: token.paddingXS
21
+ marginInlineEnd: token.paddingXS,
22
+ pointerEvents: 'unset'
22
23
  },
23
24
  // ==================== Menu ====================
24
25
  // >>> Menus
@@ -71,6 +72,7 @@ var getColumnsStyle = function getColumnsStyle(token) {
71
72
  })
72
73
  }, "&-active:not(".concat(cascaderMenuItemCls, "-disabled)"), {
73
74
  '&, &:hover': {
75
+ color: token.optionSelectedColor,
74
76
  fontWeight: token.optionSelectedFontWeight,
75
77
  backgroundColor: token.optionSelectedBg
76
78
  }
@@ -78,7 +80,7 @@ var getColumnsStyle = function getColumnsStyle(token) {
78
80
  flex: 'auto'
79
81
  }), iconCls, {
80
82
  marginInlineStart: token.paddingXXS,
81
- color: token.colorTextDescription,
83
+ color: token.colorIcon,
82
84
  fontSize: token.fontSizeIcon
83
85
  }), '&-keyword', {
84
86
  color: token.colorHighlight
@@ -40,7 +40,8 @@ export var prepareComponentToken = function prepareComponentToken(token) {
40
40
  optionSelectedBg: token.controlItemBgActive,
41
41
  optionSelectedFontWeight: token.fontWeightStrong,
42
42
  optionPadding: "".concat(itemPaddingVertical, "px ").concat(token.paddingSM, "px"),
43
- menuPadding: token.paddingXXS
43
+ menuPadding: token.paddingXXS,
44
+ optionSelectedColor: token.colorText
44
45
  };
45
46
  };
46
47
  export default genStyleHooks('Cascader', function (token) {
@@ -20,15 +20,17 @@ import omit from 'rc-util/lib/omit';
20
20
  import initCollapseMotion from '../_util/motion';
21
21
  import { cloneElement } from '../_util/reactNode';
22
22
  import { devUseWarning } from '../_util/warning';
23
- import { ConfigContext } from '../config-provider';
23
+ import { useComponentConfig } from '../config-provider/context';
24
24
  import useSize from '../config-provider/hooks/useSize';
25
25
  import CollapsePanel from './CollapsePanel';
26
26
  import useStyle from './style';
27
27
  var Collapse = /*#__PURE__*/React.forwardRef(function (props, ref) {
28
- var _React$useContext = React.useContext(ConfigContext),
29
- getPrefixCls = _React$useContext.getPrefixCls,
30
- direction = _React$useContext.direction,
31
- collapse = _React$useContext.collapse;
28
+ var _useComponentConfig = useComponentConfig('collapse'),
29
+ getPrefixCls = _useComponentConfig.getPrefixCls,
30
+ direction = _useComponentConfig.direction,
31
+ contextExpandIcon = _useComponentConfig.expandIcon,
32
+ contextClassName = _useComponentConfig.className,
33
+ contextStyle = _useComponentConfig.style;
32
34
  var customizePrefixCls = props.prefixCls,
33
35
  className = props.className,
34
36
  rootClassName = props.rootClassName,
@@ -40,6 +42,8 @@ var Collapse = /*#__PURE__*/React.forwardRef(function (props, ref) {
40
42
  _props$expandIconPosi = props.expandIconPosition,
41
43
  expandIconPosition = _props$expandIconPosi === void 0 ? 'start' : _props$expandIconPosi,
42
44
  children = props.children,
45
+ destroyInactivePanel = props.destroyInactivePanel,
46
+ destroyOnHidden = props.destroyOnHidden,
43
47
  expandIcon = props.expandIcon;
44
48
  var mergedSize = useSize(function (ctx) {
45
49
  var _ref;
@@ -56,6 +60,7 @@ var Collapse = /*#__PURE__*/React.forwardRef(function (props, ref) {
56
60
  var warning = devUseWarning('Collapse');
57
61
  // Warning if use legacy type `expandIconPosition`
58
62
  warning(expandIconPosition !== 'left' && expandIconPosition !== 'right', 'deprecated', '`expandIconPosition` with `left` or `right` is deprecated. Please use `start` or `end` instead.');
63
+ warning.deprecated(!('destroyInactivePanel' in props), 'destroyInactivePanel', 'destroyOnHidden');
59
64
  }
60
65
  // Align with logic position
61
66
  var mergedExpandIconPosition = React.useMemo(function () {
@@ -64,11 +69,11 @@ var Collapse = /*#__PURE__*/React.forwardRef(function (props, ref) {
64
69
  }
65
70
  return expandIconPosition === 'right' ? 'end' : expandIconPosition;
66
71
  }, [expandIconPosition]);
67
- var mergedExpandIcon = expandIcon !== null && expandIcon !== void 0 ? expandIcon : collapse === null || collapse === void 0 ? void 0 : collapse.expandIcon;
72
+ var mergedExpandIcon = expandIcon !== null && expandIcon !== void 0 ? expandIcon : contextExpandIcon;
68
73
  var renderExpandIcon = React.useCallback(function () {
69
74
  var panelProps = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
70
75
  var icon = typeof mergedExpandIcon === 'function' ? mergedExpandIcon(panelProps) : _jsx(RightOutlined, {
71
- rotate: panelProps.isActive ? 90 : undefined,
76
+ rotate: panelProps.isActive ? direction === 'rtl' ? -90 : 90 : undefined,
72
77
  "aria-label": panelProps.isActive ? 'expanded' : 'collapsed'
73
78
  });
74
79
  return cloneElement(icon, function () {
@@ -78,28 +83,28 @@ var Collapse = /*#__PURE__*/React.forwardRef(function (props, ref) {
78
83
  };
79
84
  });
80
85
  }, [mergedExpandIcon, prefixCls]);
81
- var collapseClassName = classNames("".concat(prefixCls, "-icon-position-").concat(mergedExpandIconPosition), _defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(prefixCls, "-borderless"), !bordered), "".concat(prefixCls, "-rtl"), direction === 'rtl'), "".concat(prefixCls, "-ghost"), !!ghost), "".concat(prefixCls, "-").concat(mergedSize), mergedSize !== 'middle'), collapse === null || collapse === void 0 ? void 0 : collapse.className, className, rootClassName, hashId, cssVarCls);
86
+ var collapseClassName = classNames("".concat(prefixCls, "-icon-position-").concat(mergedExpandIconPosition), _defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "".concat(prefixCls, "-borderless"), !bordered), "".concat(prefixCls, "-rtl"), direction === 'rtl'), "".concat(prefixCls, "-ghost"), !!ghost), "".concat(prefixCls, "-").concat(mergedSize), mergedSize !== 'middle'), contextClassName, className, rootClassName, hashId, cssVarCls);
82
87
  var openMotion = _objectSpread(_objectSpread({}, initCollapseMotion(rootPrefixCls)), {}, {
83
88
  motionAppear: false,
84
89
  leavedClassName: "".concat(prefixCls, "-content-hidden")
85
90
  });
86
91
  var items = React.useMemo(function () {
87
- return children ? toArray(children).map(function (child, index) {
88
- var _child$props;
89
- if ((_child$props = child.props) !== null && _child$props !== void 0 && _child$props.disabled) {
90
- var _child$key;
91
- var key = (_child$key = child.key) !== null && _child$key !== void 0 ? _child$key : String(index);
92
- var _child$props2 = child.props,
93
- disabled = _child$props2.disabled,
94
- collapsible = _child$props2.collapsible;
95
- var childProps = _objectSpread(_objectSpread({}, omit(child.props, ['disabled'])), {}, {
96
- key: key,
97
- collapsible: collapsible !== null && collapsible !== void 0 ? collapsible : disabled ? 'disabled' : undefined
98
- });
99
- return cloneElement(child, childProps);
100
- }
101
- return child;
102
- }) : null;
92
+ if (children) {
93
+ return toArray(children).map(function (child, index) {
94
+ var childProps = child.props;
95
+ if (childProps !== null && childProps !== void 0 && childProps.disabled) {
96
+ var _child$key, _childProps$collapsib;
97
+ var key = (_child$key = child.key) !== null && _child$key !== void 0 ? _child$key : String(index);
98
+ var mergedChildProps = _objectSpread(_objectSpread({}, omit(child.props, ['disabled'])), {}, {
99
+ key: key,
100
+ collapsible: (_childProps$collapsib = childProps.collapsible) !== null && _childProps$collapsib !== void 0 ? _childProps$collapsib : 'disabled'
101
+ });
102
+ return cloneElement(child, mergedChildProps);
103
+ }
104
+ return child;
105
+ });
106
+ }
107
+ return null;
103
108
  }, [children]);
104
109
  return wrapCSSVar(
105
110
  // @ts-ignore
@@ -110,7 +115,9 @@ var Collapse = /*#__PURE__*/React.forwardRef(function (props, ref) {
110
115
  expandIcon: renderExpandIcon,
111
116
  prefixCls: prefixCls,
112
117
  className: collapseClassName,
113
- style: _objectSpread(_objectSpread({}, collapse === null || collapse === void 0 ? void 0 : collapse.style), style),
118
+ style: _objectSpread(_objectSpread({}, contextStyle), style),
119
+ // TODO: In the future, destroyInactivePanel in rc-collapse needs to be upgrade to destroyOnHidden
120
+ destroyInactivePanel: destroyOnHidden !== null && destroyOnHidden !== void 0 ? destroyOnHidden : destroyInactivePanel,
114
121
  children: items
115
122
  })));
116
123
  });
@@ -5,7 +5,7 @@ function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object
5
5
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
6
6
  function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
7
7
  import { unit } from '@ant-design/cssinjs';
8
- import { resetComponent, resetIcon } from '../../style';
8
+ import { genFocusStyle, resetComponent, resetIcon } from '../../style';
9
9
  import { genCollapseMotion } from '../../style/motion';
10
10
  import { genStyleHooks, mergeToken } from '../../theme/internal';
11
11
  export var genBaseStyle = function genBaseStyle(token) {
@@ -45,10 +45,13 @@ export var genBaseStyle = function genBaseStyle(token) {
45
45
  }
46
46
  }, "& > ".concat(componentCls, "-item"), _defineProperty(_defineProperty(_defineProperty({
47
47
  borderBottom: borderBase,
48
+ '&:first-child': _defineProperty({}, "\n &,\n & > ".concat(componentCls, "-header"), {
49
+ borderRadius: "".concat(unit(collapsePanelBorderRadius), " ").concat(unit(collapsePanelBorderRadius), " 0 0")
50
+ }),
48
51
  '&:last-child': _defineProperty({}, "\n &,\n & > ".concat(componentCls, "-header"), {
49
52
  borderRadius: "0 0 ".concat(unit(collapsePanelBorderRadius), " ").concat(unit(collapsePanelBorderRadius))
50
53
  })
51
- }, "> ".concat(componentCls, "-header"), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
54
+ }, "> ".concat(componentCls, "-header"), _objectSpread(_objectSpread({
52
55
  position: 'relative',
53
56
  // Compatible with old version of antd, should remove in next version
54
57
  display: 'flex',
@@ -59,10 +62,8 @@ export var genBaseStyle = function genBaseStyle(token) {
59
62
  lineHeight: lineHeight,
60
63
  cursor: 'pointer',
61
64
  transition: "all ".concat(motionDurationSlow, ", visibility 0s")
62
- }, "> ".concat(componentCls, "-header-text"), {
65
+ }, genFocusStyle(token)), {}, _defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "> ".concat(componentCls, "-header-text"), {
63
66
  flex: 'auto'
64
- }), '&:focus', {
65
- outline: 'none'
66
67
  }), "".concat(componentCls, "-expand-icon"), {
67
68
  height: fontHeight,
68
69
  display: 'flex',
@@ -78,7 +79,7 @@ export var genBaseStyle = function genBaseStyle(token) {
78
79
  }
79
80
  })), "".concat(componentCls, "-header-text"), {
80
81
  marginInlineEnd: 'auto'
81
- })), "".concat(componentCls, "-collapsible-header"), _defineProperty({
82
+ }))), "".concat(componentCls, "-collapsible-header"), _defineProperty({
82
83
  cursor: 'default'
83
84
  }, "".concat(componentCls, "-header-text"), {
84
85
  flex: 'none',
@@ -138,7 +139,8 @@ var genArrowStyle = function genArrowStyle(token) {
138
139
  var genBorderlessStyle = function genBorderlessStyle(token) {
139
140
  var componentCls = token.componentCls,
140
141
  headerBg = token.headerBg,
141
- paddingXXS = token.paddingXXS,
142
+ borderlessContentPadding = token.borderlessContentPadding,
143
+ borderlessContentBg = token.borderlessContentBg,
142
144
  colorBorder = token.colorBorder;
143
145
  return _defineProperty({}, "".concat(componentCls, "-borderless"), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
144
146
  backgroundColor: headerBg,
@@ -150,10 +152,10 @@ var genBorderlessStyle = function genBorderlessStyle(token) {
150
152
  }), "> ".concat(componentCls, "-item:last-child"), {
151
153
  borderBottom: 0
152
154
  }), "> ".concat(componentCls, "-item > ").concat(componentCls, "-content"), {
153
- backgroundColor: 'transparent',
155
+ backgroundColor: borderlessContentBg,
154
156
  borderTop: 0
155
157
  }), "> ".concat(componentCls, "-item > ").concat(componentCls, "-content > ").concat(componentCls, "-content-box"), {
156
- paddingTop: paddingXXS
158
+ padding: borderlessContentPadding
157
159
  }));
158
160
  };
159
161
  var genGhostStyle = function genGhostStyle(token) {
@@ -177,7 +179,9 @@ export var prepareComponentToken = function prepareComponentToken(token) {
177
179
  headerBg: token.colorFillAlter,
178
180
  contentPadding: "".concat(token.padding, "px 16px"),
179
181
  // Fixed Value
180
- contentBg: token.colorBgContainer
182
+ contentBg: token.colorBgContainer,
183
+ borderlessContentPadding: "".concat(token.paddingXXS, "px 16px ").concat(token.padding, "px"),
184
+ borderlessContentBg: 'transparent'
181
185
  };
182
186
  };
183
187
  export default genStyleHooks('Collapse', function (token) {