@ant-design/pro-components 3.0.2-0 → 3.1.1-0

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 (829) hide show
  1. package/README.es-PR.md +1 -3
  2. package/README.md +8 -10
  3. package/README.zh-CN.md +11 -11
  4. package/dist/pro-components.min.js +1 -1
  5. package/es/card/ProCard.js +7 -7
  6. package/es/card/components/Actions/index.js +25 -25
  7. package/es/card/components/Actions/style.d.ts +1 -1
  8. package/es/card/components/Actions/style.js +79 -71
  9. package/es/card/components/Card/index.js +160 -141
  10. package/es/card/components/Card/style.d.ts +1 -1
  11. package/es/card/components/Card/style.js +249 -192
  12. package/es/card/components/CheckCard/Group.js +94 -115
  13. package/es/card/components/CheckCard/index.d.ts +6 -0
  14. package/es/card/components/CheckCard/index.js +85 -78
  15. package/es/card/components/CheckCard/style.d.ts +1 -1
  16. package/es/card/components/CheckCard/style.js +184 -168
  17. package/es/card/components/Divider/index.js +19 -15
  18. package/es/card/components/Divider/style.d.ts +1 -1
  19. package/es/card/components/Divider/style.js +32 -29
  20. package/es/card/components/Loading/index.js +19 -16
  21. package/es/card/components/Loading/style.d.ts +1 -1
  22. package/es/card/components/Loading/style.js +34 -31
  23. package/es/card/components/Operation/index.js +16 -13
  24. package/es/card/components/Operation/style.d.ts +1 -1
  25. package/es/card/components/Operation/style.js +19 -18
  26. package/es/card/components/Statistic/index.js +46 -41
  27. package/es/card/components/Statistic/style.d.ts +1 -1
  28. package/es/card/components/Statistic/style.js +89 -70
  29. package/es/card/components/StatisticCard/index.js +45 -38
  30. package/es/card/components/StatisticCard/style.d.ts +1 -1
  31. package/es/card/components/StatisticCard/style.js +37 -35
  32. package/es/card/typing.d.ts +5 -0
  33. package/es/descriptions/index.js +214 -225
  34. package/es/descriptions/useFetchData.js +53 -91
  35. package/es/field/AllProField.js +265 -216
  36. package/es/field/FieldHOC/index.js +9 -14
  37. package/es/field/PureProField.js +82 -80
  38. package/es/field/ValueTypeToComponent.js +517 -618
  39. package/es/field/components/Cascader/index.d.ts +2 -3
  40. package/es/field/components/Cascader/index.js +65 -84
  41. package/es/field/components/Checkbox/index.d.ts +2 -3
  42. package/es/field/components/Checkbox/index.js +75 -72
  43. package/es/field/components/Code/index.js +40 -39
  44. package/es/field/components/ColorPicker/index.d.ts +1 -1
  45. package/es/field/components/ColorPicker/index.js +38 -32
  46. package/es/field/components/DatePicker/index.d.ts +2 -2
  47. package/es/field/components/DatePicker/index.js +49 -53
  48. package/es/field/components/Digit/index.js +41 -42
  49. package/es/field/components/DigitRange/index.js +71 -77
  50. package/es/field/components/FromNow/index.js +27 -25
  51. package/es/field/components/Image/index.js +28 -24
  52. package/es/field/components/IndexColumn/index.js +22 -16
  53. package/es/field/components/Money/index.js +107 -116
  54. package/es/field/components/Options/index.js +34 -33
  55. package/es/field/components/Password/index.js +35 -38
  56. package/es/field/components/Percent/index.js +40 -44
  57. package/es/field/components/Percent/util.d.ts +1 -1
  58. package/es/field/components/Percent/util.js +3 -5
  59. package/es/field/components/Progress/index.js +29 -27
  60. package/es/field/components/Radio/index.d.ts +1 -2
  61. package/es/field/components/Radio/index.js +61 -62
  62. package/es/field/components/RangePicker/index.d.ts +2 -2
  63. package/es/field/components/RangePicker/index.js +52 -63
  64. package/es/field/components/Rate/index.js +24 -21
  65. package/es/field/components/Second/index.js +36 -33
  66. package/es/field/components/Segmented/index.d.ts +1 -2
  67. package/es/field/components/Segmented/index.js +37 -46
  68. package/es/field/components/Select/LightSelect/index.d.ts +1 -1
  69. package/es/field/components/Select/LightSelect/index.js +102 -110
  70. package/es/field/components/Select/SearchSelect/index.d.ts +6 -1
  71. package/es/field/components/Select/SearchSelect/index.js +189 -129
  72. package/es/field/components/Select/index.d.ts +2 -5
  73. package/es/field/components/Select/index.js +197 -221
  74. package/es/field/components/Slider/index.js +25 -22
  75. package/es/field/components/Status/index.js +67 -78
  76. package/es/field/components/Switch/index.d.ts +1 -1
  77. package/es/field/components/Switch/index.js +32 -30
  78. package/es/field/components/Text/index.js +34 -37
  79. package/es/field/components/TextArea/index.js +26 -21
  80. package/es/field/components/TextArea/readonly.js +24 -21
  81. package/es/field/components/TimePicker/index.js +96 -105
  82. package/es/field/components/TreeSelect/index.d.ts +2 -3
  83. package/es/field/components/TreeSelect/index.js +107 -125
  84. package/es/form/BaseForm/BaseForm.d.ts +3 -0
  85. package/es/form/BaseForm/BaseForm.js +418 -498
  86. package/es/form/BaseForm/EditOrReadOnlyContext.js +1 -1
  87. package/es/form/BaseForm/LightWrapper/index.js +56 -65
  88. package/es/form/BaseForm/LightWrapper/style.d.ts +1 -1
  89. package/es/form/BaseForm/LightWrapper/style.js +17 -13
  90. package/es/form/BaseForm/Submitter/index.js +44 -43
  91. package/es/form/FieldContext.js +1 -1
  92. package/es/form/components/Captcha/index.d.ts +8 -2
  93. package/es/form/components/Captcha/index.js +76 -128
  94. package/es/form/components/Cascader/index.js +26 -28
  95. package/es/form/components/Checkbox/index.js +60 -61
  96. package/es/form/components/ColorPicker/index.js +24 -26
  97. package/es/form/components/DatePicker/BaseDatePicker.js +33 -31
  98. package/es/form/components/DatePicker/DatePicker.js +14 -13
  99. package/es/form/components/DatePicker/DateTimePicker.js +11 -12
  100. package/es/form/components/DatePicker/MonthPicker.js +14 -13
  101. package/es/form/components/DatePicker/QuarterPicker.js +14 -13
  102. package/es/form/components/DatePicker/TimePicker.js +26 -27
  103. package/es/form/components/DatePicker/WeekPicker.js +14 -13
  104. package/es/form/components/DatePicker/YearPicker.js +14 -13
  105. package/es/form/components/DatePicker/index.js +1 -1
  106. package/es/form/components/DateRangePicker/BaseDateRanger.js +35 -35
  107. package/es/form/components/DateRangePicker/DateMonthRangePicker.js +15 -16
  108. package/es/form/components/DateRangePicker/DateQuarterRangePicker.js +15 -16
  109. package/es/form/components/DateRangePicker/DateTimeRangePicker.js +15 -16
  110. package/es/form/components/DateRangePicker/DateWeekRangePicker.js +15 -16
  111. package/es/form/components/DateRangePicker/DateYearRangePicker.js +15 -16
  112. package/es/form/components/DateRangePicker/TimeRangePicker.js +26 -29
  113. package/es/form/components/DateRangePicker/index.js +15 -16
  114. package/es/form/components/Dependency/index.js +31 -34
  115. package/es/form/components/Digit/DigitRange.js +23 -24
  116. package/es/form/components/Digit/index.js +27 -29
  117. package/es/form/components/Field/index.js +55 -63
  118. package/es/form/components/FieldSet/index.js +68 -76
  119. package/es/form/components/FormItem/FormItemRender/index.js +58 -48
  120. package/es/form/components/FormItem/Group/index.js +95 -95
  121. package/es/form/components/FormItem/Group/style.d.ts +1 -1
  122. package/es/form/components/FormItem/Group/style.js +46 -40
  123. package/es/form/components/FormItem/index.js +135 -141
  124. package/es/form/components/FormItem/warpField.js +165 -149
  125. package/es/form/components/List/ListContainer.js +98 -189
  126. package/es/form/components/List/ListItem.js +151 -198
  127. package/es/form/components/List/index.d.ts +1 -1
  128. package/es/form/components/List/index.js +97 -107
  129. package/es/form/components/List/style.d.ts +1 -1
  130. package/es/form/components/List/style.js +71 -47
  131. package/es/form/components/Money/index.js +28 -30
  132. package/es/form/components/Radio/index.js +45 -49
  133. package/es/form/components/Rate/index.js +17 -20
  134. package/es/form/components/SchemaForm/index.js +58 -72
  135. package/es/form/components/SchemaForm/layoutType/Embed.js +5 -6
  136. package/es/form/components/SchemaForm/layoutType/StepsForm.js +22 -26
  137. package/es/form/components/SchemaForm/valueType/dependency.js +11 -11
  138. package/es/form/components/SchemaForm/valueType/divider.js +4 -5
  139. package/es/form/components/SchemaForm/valueType/field.js +45 -44
  140. package/es/form/components/SchemaForm/valueType/formList.js +8 -7
  141. package/es/form/components/SchemaForm/valueType/formSet.js +8 -7
  142. package/es/form/components/SchemaForm/valueType/group.js +7 -8
  143. package/es/form/components/SchemaForm/valueType/ignore.js +2 -2
  144. package/es/form/components/SchemaForm/valueType/index.js +5 -5
  145. package/es/form/components/Segmented/index.js +20 -23
  146. package/es/form/components/Select/index.js +69 -73
  147. package/es/form/components/Slider/index.js +33 -35
  148. package/es/form/components/Switch/index.js +24 -26
  149. package/es/form/components/Text/index.js +79 -88
  150. package/es/form/components/TextArea/index.js +17 -20
  151. package/es/form/components/TreeSelect/index.js +20 -23
  152. package/es/form/components/UploadButton/index.js +56 -103
  153. package/es/form/components/UploadDragger/index.js +37 -44
  154. package/es/form/helpers/grid.js +65 -67
  155. package/es/form/index.d.ts +1 -0
  156. package/es/form/layouts/DrawerForm/index.d.ts +1 -1
  157. package/es/form/layouts/DrawerForm/index.js +152 -242
  158. package/es/form/layouts/DrawerForm/style.d.ts +1 -1
  159. package/es/form/layouts/DrawerForm/style.js +26 -25
  160. package/es/form/layouts/LightFilter/index.d.ts +12 -1
  161. package/es/form/layouts/LightFilter/index.js +158 -140
  162. package/es/form/layouts/LightFilter/style.d.ts +1 -1
  163. package/es/form/layouts/LightFilter/style.js +52 -48
  164. package/es/form/layouts/LoginForm/index.d.ts +1 -1
  165. package/es/form/layouts/LoginForm/index.js +44 -47
  166. package/es/form/layouts/LoginForm/style.d.ts +1 -1
  167. package/es/form/layouts/LoginForm/style.js +71 -67
  168. package/es/form/layouts/LoginFormPage/index.d.ts +1 -1
  169. package/es/form/layouts/LoginFormPage/index.js +45 -48
  170. package/es/form/layouts/LoginFormPage/style.d.ts +1 -1
  171. package/es/form/layouts/LoginFormPage/style.js +136 -126
  172. package/es/form/layouts/ModalForm/index.js +120 -203
  173. package/es/form/layouts/ProForm/index.d.ts +2 -2
  174. package/es/form/layouts/ProForm/index.js +5 -5
  175. package/es/form/layouts/QueryFilter/Actions.js +23 -22
  176. package/es/form/layouts/QueryFilter/index.d.ts +2 -1
  177. package/es/form/layouts/QueryFilter/index.js +178 -203
  178. package/es/form/layouts/QueryFilter/style.d.ts +1 -1
  179. package/es/form/layouts/QueryFilter/style.js +45 -37
  180. package/es/form/layouts/StepsForm/StepForm.d.ts +2 -3
  181. package/es/form/layouts/StepsForm/StepForm.js +50 -71
  182. package/es/form/layouts/StepsForm/index.js +187 -216
  183. package/es/form/layouts/StepsForm/style.d.ts +1 -1
  184. package/es/form/layouts/StepsForm/style.js +30 -28
  185. package/es/form/layouts/index.js +1 -1
  186. package/es/layout/ProLayout.js +281 -292
  187. package/es/layout/WrapContent.js +16 -12
  188. package/es/layout/assert/Logo.js +95 -97
  189. package/es/layout/components/AppsLogoComponents/AppsLogo.js +10 -12
  190. package/es/layout/components/AppsLogoComponents/DefaultContent.js +17 -16
  191. package/es/layout/components/AppsLogoComponents/SimpleContent.js +19 -18
  192. package/es/layout/components/AppsLogoComponents/index.js +34 -37
  193. package/es/layout/components/AppsLogoComponents/style/default.js +2 -2
  194. package/es/layout/components/AppsLogoComponents/style/index.d.ts +1 -1
  195. package/es/layout/components/AppsLogoComponents/style/index.js +52 -50
  196. package/es/layout/components/AppsLogoComponents/style/simple.js +1 -1
  197. package/es/layout/components/CollapsedIcon/index.js +18 -15
  198. package/es/layout/components/CollapsedIcon/style.d.ts +1 -1
  199. package/es/layout/components/CollapsedIcon/style.js +40 -40
  200. package/es/layout/components/Footer.js +22 -21
  201. package/es/layout/components/FooterToolbar/index.js +58 -52
  202. package/es/layout/components/FooterToolbar/style/index.d.ts +1 -1
  203. package/es/layout/components/FooterToolbar/style/index.js +38 -37
  204. package/es/layout/components/FooterToolbar/style/stylish.d.ts +1 -1
  205. package/es/layout/components/FooterToolbar/style/stylish.js +11 -9
  206. package/es/layout/components/GlobalFooter/index.d.ts +1 -1
  207. package/es/layout/components/GlobalFooter/index.js +25 -25
  208. package/es/layout/components/GlobalFooter/style.d.ts +1 -1
  209. package/es/layout/components/GlobalFooter/style.js +31 -30
  210. package/es/layout/components/GlobalHeader/ActionsContent.js +62 -78
  211. package/es/layout/components/GlobalHeader/index.js +59 -47
  212. package/es/layout/components/GlobalHeader/rightContentStyle.d.ts +1 -1
  213. package/es/layout/components/GlobalHeader/rightContentStyle.js +49 -49
  214. package/es/layout/components/GlobalHeader/style.d.ts +1 -1
  215. package/es/layout/components/GlobalHeader/style.js +58 -54
  216. package/es/layout/components/GridContent/index.js +24 -19
  217. package/es/layout/components/GridContent/style.d.ts +1 -1
  218. package/es/layout/components/GridContent/style.js +14 -13
  219. package/es/layout/components/Header/index.js +63 -57
  220. package/es/layout/components/Header/style/header.d.ts +1 -1
  221. package/es/layout/components/Header/style/header.js +49 -47
  222. package/es/layout/components/Header/style/stylish.d.ts +1 -1
  223. package/es/layout/components/Header/style/stylish.js +15 -11
  224. package/es/layout/components/Help/AsyncContentPanel.js +13 -18
  225. package/es/layout/components/Help/HelpProvide.js +1 -1
  226. package/es/layout/components/Help/ProHelpContentPanel.js +64 -83
  227. package/es/layout/components/Help/ProHelpDrawer.d.ts +1 -1
  228. package/es/layout/components/Help/ProHelpDrawer.js +25 -29
  229. package/es/layout/components/Help/ProHelpModal.d.ts +1 -1
  230. package/es/layout/components/Help/ProHelpModal.js +24 -27
  231. package/es/layout/components/Help/ProHelpPanel.js +86 -94
  232. package/es/layout/components/Help/ProHelpPopover.js +19 -17
  233. package/es/layout/components/Help/RenderContentPanel.js +34 -24
  234. package/es/layout/components/Help/Search.js +52 -78
  235. package/es/layout/components/Help/index.js +9 -11
  236. package/es/layout/components/Help/style.d.ts +1 -1
  237. package/es/layout/components/Help/style.js +82 -75
  238. package/es/layout/components/PageContainer/index.js +168 -149
  239. package/es/layout/components/PageContainer/style/index.d.ts +1 -1
  240. package/es/layout/components/PageContainer/style/index.js +95 -78
  241. package/es/layout/components/PageContainer/style/stylish.d.ts +1 -1
  242. package/es/layout/components/PageContainer/style/stylish.js +11 -9
  243. package/es/layout/components/PageHeader/index.js +96 -97
  244. package/es/layout/components/PageHeader/style/index.d.ts +1 -1
  245. package/es/layout/components/PageHeader/style/index.js +142 -122
  246. package/es/layout/components/PageLoading/index.js +17 -20
  247. package/es/layout/components/SettingDrawer/BlockCheckbox.js +29 -32
  248. package/es/layout/components/SettingDrawer/LayoutChange.js +22 -22
  249. package/es/layout/components/SettingDrawer/RegionalChange.js +14 -15
  250. package/es/layout/components/SettingDrawer/ThemeColor.js +32 -35
  251. package/es/layout/components/SettingDrawer/index.js +139 -170
  252. package/es/layout/components/SettingDrawer/style/index.d.ts +1 -1
  253. package/es/layout/components/SettingDrawer/style/index.js +141 -137
  254. package/es/layout/components/SiderMenu/BaseMenu.d.ts +1 -1
  255. package/es/layout/components/SiderMenu/BaseMenu.js +236 -222
  256. package/es/layout/components/SiderMenu/SiderMenu.js +127 -117
  257. package/es/layout/components/SiderMenu/index.js +51 -43
  258. package/es/layout/components/SiderMenu/style/index.d.ts +1 -1
  259. package/es/layout/components/SiderMenu/style/index.js +179 -161
  260. package/es/layout/components/SiderMenu/style/menu.d.ts +1 -1
  261. package/es/layout/components/SiderMenu/style/menu.js +148 -110
  262. package/es/layout/components/SiderMenu/style/stylish.d.ts +1 -1
  263. package/es/layout/components/SiderMenu/style/stylish.js +15 -11
  264. package/es/layout/components/TopNavHeader/index.js +71 -60
  265. package/es/layout/components/TopNavHeader/style.d.ts +1 -1
  266. package/es/layout/components/TopNavHeader/style.js +64 -63
  267. package/es/layout/context/RouteContext.js +1 -1
  268. package/es/layout/defaultSettings.d.ts +6 -0
  269. package/es/layout/defaultSettings.js +1 -1
  270. package/es/layout/getPageTitle.js +23 -24
  271. package/es/layout/locales/en-US.js +3 -2
  272. package/es/layout/locales/index.js +5 -5
  273. package/es/layout/locales/it-IT.js +3 -2
  274. package/es/layout/locales/ko-KR.js +3 -2
  275. package/es/layout/locales/zh-CN.js +3 -2
  276. package/es/layout/locales/zh-TW.js +3 -2
  277. package/es/layout/style/index.d.ts +1 -1
  278. package/es/layout/style/index.js +48 -42
  279. package/es/layout/utils/getBreadcrumbProps.js +60 -60
  280. package/es/layout/utils/getMenuData.js +7 -11
  281. package/es/layout/utils/pathTools.js +2 -6
  282. package/es/layout/utils/useCurrentMenuLayoutProps.js +4 -9
  283. package/es/layout/utils/utils.js +15 -17
  284. package/es/list/Item.js +157 -137
  285. package/es/list/ListView.js +106 -115
  286. package/es/list/constants.js +2 -2
  287. package/es/list/index.js +72 -70
  288. package/es/list/style/index.d.ts +1 -1
  289. package/es/list/style/index.js +281 -213
  290. package/es/provider/index.d.ts +1 -0
  291. package/es/provider/index.js +126 -114
  292. package/es/provider/intl.js +53 -55
  293. package/es/provider/typing/layoutToken.js +26 -23
  294. package/es/provider/useStyle/index.d.ts +2 -1
  295. package/es/provider/useStyle/index.js +60 -60
  296. package/es/provider/utils/merge.js +10 -12
  297. package/es/skeleton/components/Descriptions/index.js +211 -229
  298. package/es/skeleton/components/List/index.js +208 -223
  299. package/es/skeleton/components/Result/index.js +45 -47
  300. package/es/skeleton/index.js +13 -10
  301. package/es/table/Store/Provide.d.ts +4 -4
  302. package/es/table/Store/Provide.js +102 -117
  303. package/es/table/Table.d.ts +5 -2
  304. package/es/table/Table.js +593 -603
  305. package/es/table/TableSearch.d.ts +24 -0
  306. package/es/table/TableSearch.js +54 -0
  307. package/es/table/TableToolbar.d.ts +22 -0
  308. package/es/table/TableToolbar.js +47 -0
  309. package/es/table/components/Alert/index.d.ts +1 -1
  310. package/es/table/components/Alert/index.js +41 -40
  311. package/es/table/components/Alert/style.d.ts +1 -1
  312. package/es/table/components/Alert/style.js +28 -27
  313. package/es/table/components/ColumnSetting/index.d.ts +1 -1
  314. package/es/table/components/ColumnSetting/index.js +230 -223
  315. package/es/table/components/ColumnSetting/style.d.ts +1 -1
  316. package/es/table/components/ColumnSetting/style.js +86 -71
  317. package/es/table/components/DragSortTable/index.d.ts +1 -1
  318. package/es/table/components/DragSortTable/index.js +65 -79
  319. package/es/table/components/DragSortTable/style.d.ts +1 -1
  320. package/es/table/components/DragSortTable/style.js +20 -19
  321. package/es/table/components/Dropdown/index.js +42 -47
  322. package/es/table/components/EditableTable/CellEditorTable.js +24 -32
  323. package/es/table/components/EditableTable/RowEditorTable.js +23 -28
  324. package/es/table/components/EditableTable/index.js +601 -302
  325. package/es/table/components/Form/FormRender.js +99 -103
  326. package/es/table/components/Form/index.d.ts +4 -19
  327. package/es/table/components/Form/index.js +112 -159
  328. package/es/table/components/ListToolBar/HeaderMenu.js +44 -52
  329. package/es/table/components/ListToolBar/index.js +122 -147
  330. package/es/table/components/ListToolBar/style.d.ts +1 -1
  331. package/es/table/components/ListToolBar/style.js +127 -117
  332. package/es/table/components/ToolBar/DensityIcon.js +10 -9
  333. package/es/table/components/ToolBar/FullscreenIcon.js +5 -9
  334. package/es/table/components/ToolBar/index.d.ts +2 -8
  335. package/es/table/components/ToolBar/index.js +155 -195
  336. package/es/table/style/index.d.ts +1 -1
  337. package/es/table/style/index.js +144 -112
  338. package/es/table/typing.d.ts +13 -6
  339. package/es/table/useFetchData.js +204 -348
  340. package/es/table/utils/cellRenderToFromItem.js +105 -119
  341. package/es/table/utils/columnRender.js +63 -54
  342. package/es/table/utils/columnSort.js +22 -22
  343. package/es/table/utils/genProColumnToColumn.d.ts +13 -9
  344. package/es/table/utils/genProColumnToColumn.js +121 -98
  345. package/es/table/utils/index.d.ts +12 -0
  346. package/es/table/utils/index.js +114 -178
  347. package/es/table/utils/useDragSort.d.ts +1 -1
  348. package/es/table/utils/useDragSort.js +99 -92
  349. package/es/table/utils/usePageInfo.d.ts +6 -0
  350. package/es/table/utils/usePageInfo.js +55 -0
  351. package/es/utils/components/DropdownFooter/index.js +23 -21
  352. package/es/utils/components/DropdownFooter/style.d.ts +1 -1
  353. package/es/utils/components/DropdownFooter/style.js +16 -15
  354. package/es/utils/components/ErrorBoundary/index.js +27 -50
  355. package/es/utils/components/FieldLabel/index.js +70 -70
  356. package/es/utils/components/FieldLabel/style.d.ts +1 -1
  357. package/es/utils/components/FieldLabel/style.js +104 -81
  358. package/es/utils/components/FilterDropdown/index.d.ts +11 -0
  359. package/es/utils/components/FilterDropdown/index.js +43 -32
  360. package/es/utils/components/FilterDropdown/style.d.ts +1 -1
  361. package/es/utils/components/FilterDropdown/style.js +19 -16
  362. package/es/utils/components/InlineErrorFormItem/index.js +78 -78
  363. package/es/utils/components/InlineErrorFormItem/style.d.ts +1 -1
  364. package/es/utils/components/InlineErrorFormItem/style.js +56 -49
  365. package/es/utils/components/LabelIconTip/index.js +30 -31
  366. package/es/utils/components/LabelIconTip/style.d.ts +1 -1
  367. package/es/utils/components/LabelIconTip/style.js +36 -35
  368. package/es/utils/components/ProFormContext/index.js +1 -1
  369. package/es/utils/conversionMomentValue/index.js +19 -22
  370. package/es/utils/dateArrayFormatter/index.js +9 -14
  371. package/es/utils/genCopyable/index.js +74 -32
  372. package/es/utils/getFieldPropsOrFormItemProps/index.js +1 -1
  373. package/es/utils/hooks/useDebounceFn/index.js +18 -51
  374. package/es/utils/hooks/useDebounceValue/index.js +7 -16
  375. package/es/utils/hooks/useDeepCompareEffect/index.js +6 -18
  376. package/es/utils/hooks/useDocumentTitle/index.js +2 -2
  377. package/es/utils/hooks/useFetchData/index.js +36 -65
  378. package/es/utils/hooks/useForceRender/index.js +2 -9
  379. package/es/utils/hooks/useLatest/index.js +2 -2
  380. package/es/utils/hooks/usePrevious/index.js +3 -3
  381. package/es/utils/hooks/useReactiveRef/index.js +2 -2
  382. package/es/utils/hooks/useRefCallback/index.js +3 -3
  383. package/es/utils/hooks/useRefFunction/index.js +4 -9
  384. package/es/utils/index.d.ts +1 -2
  385. package/es/utils/index.js +1 -2
  386. package/es/utils/isBrowser/index.js +2 -2
  387. package/es/utils/isDeepEqualReact/index.js +9 -44
  388. package/es/utils/isDropdownValueType/index.js +2 -2
  389. package/es/utils/isNil/index.js +1 -3
  390. package/es/utils/isUrl/index.js +2 -2
  391. package/es/utils/merge/index.js +10 -12
  392. package/es/utils/nanoid/index.js +5 -6
  393. package/es/utils/omitBoolean/index.js +1 -1
  394. package/es/utils/omitUndefined/index.js +3 -3
  395. package/es/utils/omitUndefinedAndEmptyArr/index.js +4 -5
  396. package/es/utils/parseValueToMoment/index.js +3 -7
  397. package/es/utils/pickProFormItemProps/index.js +3 -3
  398. package/es/utils/pickProProps/index.js +6 -7
  399. package/es/utils/proFieldParsingText/index.js +86 -99
  400. package/es/utils/runFunction/index.js +2 -5
  401. package/es/utils/stringify/index.js +1 -1
  402. package/es/utils/transformKeySubmitValue/index.js +99 -116
  403. package/es/utils/typing.d.ts +1 -1
  404. package/es/utils/useEditableArray/index.d.ts +9 -7
  405. package/es/utils/useEditableArray/index.js +788 -700
  406. package/es/utils/useEditableMap/index.d.ts +1 -1
  407. package/es/utils/useEditableMap/index.js +148 -137
  408. package/es/utils/useMediaQuery/index.js +16 -18
  409. package/es/utils/useMediaQuery/query.js +15 -19
  410. package/es/version.js +1 -1
  411. package/lib/card/ProCard.js +7 -7
  412. package/lib/card/components/Actions/index.js +25 -25
  413. package/lib/card/components/Actions/style.d.ts +1 -1
  414. package/lib/card/components/Actions/style.js +79 -72
  415. package/lib/card/components/Card/index.js +157 -138
  416. package/lib/card/components/Card/style.d.ts +1 -1
  417. package/lib/card/components/Card/style.js +249 -193
  418. package/lib/card/components/CheckCard/Group.js +97 -115
  419. package/lib/card/components/CheckCard/index.d.ts +6 -0
  420. package/lib/card/components/CheckCard/index.js +85 -77
  421. package/lib/card/components/CheckCard/style.d.ts +1 -1
  422. package/lib/card/components/CheckCard/style.js +184 -169
  423. package/lib/card/components/Divider/index.js +20 -16
  424. package/lib/card/components/Divider/style.d.ts +1 -1
  425. package/lib/card/components/Divider/style.js +32 -30
  426. package/lib/card/components/Loading/index.js +19 -16
  427. package/lib/card/components/Loading/style.d.ts +1 -1
  428. package/lib/card/components/Loading/style.js +34 -32
  429. package/lib/card/components/Operation/index.js +16 -14
  430. package/lib/card/components/Operation/style.d.ts +1 -1
  431. package/lib/card/components/Operation/style.js +19 -19
  432. package/lib/card/components/Statistic/index.js +46 -42
  433. package/lib/card/components/Statistic/style.d.ts +1 -1
  434. package/lib/card/components/Statistic/style.js +89 -71
  435. package/lib/card/components/StatisticCard/index.js +45 -38
  436. package/lib/card/components/StatisticCard/style.d.ts +1 -1
  437. package/lib/card/components/StatisticCard/style.js +37 -36
  438. package/lib/card/index.js +4 -4
  439. package/lib/card/typing.d.ts +5 -0
  440. package/lib/descriptions/index.js +219 -225
  441. package/lib/descriptions/useFetchData.js +51 -90
  442. package/lib/field/AllProField.js +267 -217
  443. package/lib/field/FieldHOC/index.js +9 -15
  444. package/lib/field/PureProField.js +84 -82
  445. package/lib/field/ValueTypeToComponent.js +517 -618
  446. package/lib/field/components/Cascader/index.d.ts +2 -3
  447. package/lib/field/components/Cascader/index.js +65 -85
  448. package/lib/field/components/Checkbox/index.d.ts +1 -2
  449. package/lib/field/components/Checkbox/index.js +75 -73
  450. package/lib/field/components/Code/index.js +40 -39
  451. package/lib/field/components/ColorPicker/index.js +38 -33
  452. package/lib/field/components/DatePicker/index.d.ts +1 -1
  453. package/lib/field/components/DatePicker/index.js +49 -53
  454. package/lib/field/components/Digit/index.js +41 -43
  455. package/lib/field/components/DigitRange/index.js +69 -76
  456. package/lib/field/components/FromNow/index.js +27 -25
  457. package/lib/field/components/Image/index.js +28 -24
  458. package/lib/field/components/IndexColumn/index.js +22 -17
  459. package/lib/field/components/Money/index.js +106 -116
  460. package/lib/field/components/Options/index.js +34 -34
  461. package/lib/field/components/Password/index.js +35 -38
  462. package/lib/field/components/Percent/index.js +40 -45
  463. package/lib/field/components/Percent/util.js +3 -6
  464. package/lib/field/components/Progress/index.js +29 -28
  465. package/lib/field/components/Radio/index.d.ts +1 -2
  466. package/lib/field/components/Radio/index.js +61 -63
  467. package/lib/field/components/RangePicker/index.d.ts +1 -1
  468. package/lib/field/components/RangePicker/index.js +52 -63
  469. package/lib/field/components/Rate/index.js +24 -21
  470. package/lib/field/components/Second/index.js +36 -33
  471. package/lib/field/components/Segmented/index.d.ts +1 -2
  472. package/lib/field/components/Segmented/index.js +37 -48
  473. package/lib/field/components/Select/LightSelect/index.d.ts +1 -1
  474. package/lib/field/components/Select/LightSelect/index.js +103 -111
  475. package/lib/field/components/Select/SearchSelect/index.d.ts +6 -1
  476. package/lib/field/components/Select/SearchSelect/index.js +193 -130
  477. package/lib/field/components/Select/index.d.ts +1 -4
  478. package/lib/field/components/Select/index.js +198 -220
  479. package/lib/field/components/Slider/index.js +25 -22
  480. package/lib/field/components/Status/index.js +69 -79
  481. package/lib/field/components/Switch/index.d.ts +1 -1
  482. package/lib/field/components/Switch/index.js +32 -31
  483. package/lib/field/components/Text/index.js +34 -38
  484. package/lib/field/components/TextArea/index.js +26 -21
  485. package/lib/field/components/TextArea/readonly.js +24 -22
  486. package/lib/field/components/TimePicker/index.js +96 -105
  487. package/lib/field/components/TreeSelect/index.d.ts +2 -3
  488. package/lib/field/components/TreeSelect/index.js +105 -124
  489. package/lib/field/index.js +34 -34
  490. package/lib/form/BaseForm/BaseForm.d.ts +3 -0
  491. package/lib/form/BaseForm/BaseForm.js +415 -495
  492. package/lib/form/BaseForm/EditOrReadOnlyContext.js +1 -1
  493. package/lib/form/BaseForm/LightWrapper/index.js +57 -66
  494. package/lib/form/BaseForm/LightWrapper/style.d.ts +1 -1
  495. package/lib/form/BaseForm/LightWrapper/style.js +17 -14
  496. package/lib/form/BaseForm/Submitter/index.js +44 -44
  497. package/lib/form/BaseForm/index.js +3 -3
  498. package/lib/form/FieldContext.js +1 -1
  499. package/lib/form/components/Captcha/index.d.ts +8 -2
  500. package/lib/form/components/Captcha/index.js +76 -129
  501. package/lib/form/components/Cascader/index.js +26 -29
  502. package/lib/form/components/Checkbox/index.js +60 -61
  503. package/lib/form/components/ColorPicker/index.js +24 -26
  504. package/lib/form/components/DatePicker/BaseDatePicker.js +32 -30
  505. package/lib/form/components/DatePicker/DatePicker.js +14 -13
  506. package/lib/form/components/DatePicker/DateTimePicker.js +11 -12
  507. package/lib/form/components/DatePicker/MonthPicker.js +14 -13
  508. package/lib/form/components/DatePicker/QuarterPicker.js +14 -13
  509. package/lib/form/components/DatePicker/TimePicker.js +26 -27
  510. package/lib/form/components/DatePicker/WeekPicker.js +14 -13
  511. package/lib/form/components/DatePicker/YearPicker.js +14 -13
  512. package/lib/form/components/DatePicker/index.js +1 -1
  513. package/lib/form/components/DateRangePicker/BaseDateRanger.js +34 -34
  514. package/lib/form/components/DateRangePicker/DateMonthRangePicker.js +15 -16
  515. package/lib/form/components/DateRangePicker/DateQuarterRangePicker.js +15 -16
  516. package/lib/form/components/DateRangePicker/DateTimeRangePicker.js +15 -16
  517. package/lib/form/components/DateRangePicker/DateWeekRangePicker.js +15 -16
  518. package/lib/form/components/DateRangePicker/DateYearRangePicker.js +15 -16
  519. package/lib/form/components/DateRangePicker/TimeRangePicker.js +26 -29
  520. package/lib/form/components/DateRangePicker/index.js +15 -16
  521. package/lib/form/components/Dependency/index.js +31 -35
  522. package/lib/form/components/Digit/DigitRange.js +23 -24
  523. package/lib/form/components/Digit/index.js +27 -29
  524. package/lib/form/components/Field/index.js +55 -63
  525. package/lib/form/components/FieldSet/index.js +68 -76
  526. package/lib/form/components/FormItem/FormItemRender/index.js +58 -48
  527. package/lib/form/components/FormItem/Group/index.js +95 -95
  528. package/lib/form/components/FormItem/Group/style.d.ts +1 -1
  529. package/lib/form/components/FormItem/Group/style.js +46 -41
  530. package/lib/form/components/FormItem/index.js +135 -141
  531. package/lib/form/components/FormItem/warpField.js +165 -149
  532. package/lib/form/components/List/ListContainer.js +100 -191
  533. package/lib/form/components/List/ListItem.js +153 -200
  534. package/lib/form/components/List/index.d.ts +1 -1
  535. package/lib/form/components/List/index.js +97 -107
  536. package/lib/form/components/List/style.d.ts +1 -1
  537. package/lib/form/components/List/style.js +71 -48
  538. package/lib/form/components/Money/index.js +28 -30
  539. package/lib/form/components/Radio/index.js +45 -49
  540. package/lib/form/components/Rate/index.js +17 -21
  541. package/lib/form/components/SchemaForm/index.js +54 -68
  542. package/lib/form/components/SchemaForm/layoutType/Embed.js +5 -6
  543. package/lib/form/components/SchemaForm/layoutType/StepsForm.js +22 -26
  544. package/lib/form/components/SchemaForm/layoutType/index.js +2 -2
  545. package/lib/form/components/SchemaForm/valueType/dependency.js +13 -12
  546. package/lib/form/components/SchemaForm/valueType/divider.js +6 -7
  547. package/lib/form/components/SchemaForm/valueType/field.js +47 -45
  548. package/lib/form/components/SchemaForm/valueType/formList.js +10 -9
  549. package/lib/form/components/SchemaForm/valueType/formSet.js +10 -8
  550. package/lib/form/components/SchemaForm/valueType/group.js +9 -10
  551. package/lib/form/components/SchemaForm/valueType/ignore.js +4 -3
  552. package/lib/form/components/SchemaForm/valueType/index.js +7 -6
  553. package/lib/form/components/Segmented/index.js +20 -24
  554. package/lib/form/components/Select/index.js +69 -73
  555. package/lib/form/components/Slider/index.js +33 -35
  556. package/lib/form/components/Switch/index.js +24 -26
  557. package/lib/form/components/Text/index.js +77 -86
  558. package/lib/form/components/TextArea/index.js +17 -21
  559. package/lib/form/components/TreeSelect/index.js +20 -23
  560. package/lib/form/components/UploadButton/index.js +56 -103
  561. package/lib/form/components/UploadDragger/index.js +37 -44
  562. package/lib/form/components/index.js +42 -42
  563. package/lib/form/helpers/grid.js +68 -69
  564. package/lib/form/helpers/index.js +1 -1
  565. package/lib/form/index.d.ts +1 -0
  566. package/lib/form/index.js +8 -8
  567. package/lib/form/layouts/DrawerForm/index.d.ts +1 -1
  568. package/lib/form/layouts/DrawerForm/index.js +151 -242
  569. package/lib/form/layouts/DrawerForm/style.d.ts +1 -1
  570. package/lib/form/layouts/DrawerForm/style.js +26 -26
  571. package/lib/form/layouts/LightFilter/index.d.ts +12 -1
  572. package/lib/form/layouts/LightFilter/index.js +158 -141
  573. package/lib/form/layouts/LightFilter/style.d.ts +1 -1
  574. package/lib/form/layouts/LightFilter/style.js +52 -49
  575. package/lib/form/layouts/LoginForm/index.d.ts +1 -1
  576. package/lib/form/layouts/LoginForm/index.js +44 -48
  577. package/lib/form/layouts/LoginForm/style.d.ts +1 -1
  578. package/lib/form/layouts/LoginForm/style.js +71 -68
  579. package/lib/form/layouts/LoginFormPage/index.d.ts +1 -1
  580. package/lib/form/layouts/LoginFormPage/index.js +45 -49
  581. package/lib/form/layouts/LoginFormPage/style.d.ts +1 -1
  582. package/lib/form/layouts/LoginFormPage/style.js +136 -127
  583. package/lib/form/layouts/ModalForm/index.js +119 -203
  584. package/lib/form/layouts/ProForm/index.d.ts +1 -1
  585. package/lib/form/layouts/ProForm/index.js +5 -5
  586. package/lib/form/layouts/QueryFilter/Actions.js +23 -22
  587. package/lib/form/layouts/QueryFilter/index.d.ts +2 -1
  588. package/lib/form/layouts/QueryFilter/index.js +177 -202
  589. package/lib/form/layouts/QueryFilter/style.d.ts +1 -1
  590. package/lib/form/layouts/QueryFilter/style.js +45 -38
  591. package/lib/form/layouts/StepsForm/StepForm.d.ts +2 -3
  592. package/lib/form/layouts/StepsForm/StepForm.js +50 -72
  593. package/lib/form/layouts/StepsForm/index.js +186 -215
  594. package/lib/form/layouts/StepsForm/style.d.ts +1 -1
  595. package/lib/form/layouts/StepsForm/style.js +30 -29
  596. package/lib/form/layouts/index.js +9 -9
  597. package/lib/index.js +11 -11
  598. package/lib/layout/ProLayout.js +281 -292
  599. package/lib/layout/WrapContent.js +18 -14
  600. package/lib/layout/assert/Logo.js +96 -97
  601. package/lib/layout/components/AppsLogoComponents/AppsLogo.js +11 -12
  602. package/lib/layout/components/AppsLogoComponents/DefaultContent.js +19 -17
  603. package/lib/layout/components/AppsLogoComponents/SimpleContent.js +22 -19
  604. package/lib/layout/components/AppsLogoComponents/index.js +37 -39
  605. package/lib/layout/components/AppsLogoComponents/style/default.js +4 -3
  606. package/lib/layout/components/AppsLogoComponents/style/index.d.ts +1 -1
  607. package/lib/layout/components/AppsLogoComponents/style/index.js +52 -51
  608. package/lib/layout/components/AppsLogoComponents/style/simple.js +3 -2
  609. package/lib/layout/components/CollapsedIcon/index.js +20 -17
  610. package/lib/layout/components/CollapsedIcon/style.d.ts +1 -1
  611. package/lib/layout/components/CollapsedIcon/style.js +40 -41
  612. package/lib/layout/components/Footer.js +23 -22
  613. package/lib/layout/components/FooterToolbar/index.js +59 -53
  614. package/lib/layout/components/FooterToolbar/style/index.d.ts +1 -1
  615. package/lib/layout/components/FooterToolbar/style/index.js +38 -38
  616. package/lib/layout/components/FooterToolbar/style/stylish.d.ts +1 -1
  617. package/lib/layout/components/FooterToolbar/style/stylish.js +11 -10
  618. package/lib/layout/components/GlobalFooter/index.d.ts +1 -1
  619. package/lib/layout/components/GlobalFooter/index.js +27 -27
  620. package/lib/layout/components/GlobalFooter/style.d.ts +1 -1
  621. package/lib/layout/components/GlobalFooter/style.js +31 -31
  622. package/lib/layout/components/GlobalHeader/ActionsContent.js +65 -81
  623. package/lib/layout/components/GlobalHeader/index.js +61 -49
  624. package/lib/layout/components/GlobalHeader/rightContentStyle.d.ts +1 -1
  625. package/lib/layout/components/GlobalHeader/rightContentStyle.js +49 -50
  626. package/lib/layout/components/GlobalHeader/style.d.ts +1 -1
  627. package/lib/layout/components/GlobalHeader/style.js +58 -55
  628. package/lib/layout/components/GridContent/index.js +26 -21
  629. package/lib/layout/components/GridContent/style.d.ts +1 -1
  630. package/lib/layout/components/GridContent/style.js +14 -14
  631. package/lib/layout/components/Header/index.js +65 -59
  632. package/lib/layout/components/Header/style/header.d.ts +1 -1
  633. package/lib/layout/components/Header/style/header.js +49 -48
  634. package/lib/layout/components/Header/style/stylish.d.ts +1 -1
  635. package/lib/layout/components/Header/style/stylish.js +15 -12
  636. package/lib/layout/components/Help/AsyncContentPanel.js +15 -20
  637. package/lib/layout/components/Help/HelpProvide.js +1 -1
  638. package/lib/layout/components/Help/ProHelpContentPanel.js +66 -85
  639. package/lib/layout/components/Help/ProHelpDrawer.d.ts +1 -1
  640. package/lib/layout/components/Help/ProHelpDrawer.js +27 -30
  641. package/lib/layout/components/Help/ProHelpModal.d.ts +1 -1
  642. package/lib/layout/components/Help/ProHelpModal.js +26 -28
  643. package/lib/layout/components/Help/ProHelpPanel.js +86 -94
  644. package/lib/layout/components/Help/ProHelpPopover.js +21 -19
  645. package/lib/layout/components/Help/RenderContentPanel.js +36 -26
  646. package/lib/layout/components/Help/Search.js +55 -80
  647. package/lib/layout/components/Help/index.js +19 -20
  648. package/lib/layout/components/Help/style.d.ts +1 -1
  649. package/lib/layout/components/Help/style.js +82 -76
  650. package/lib/layout/components/PageContainer/index.js +172 -151
  651. package/lib/layout/components/PageContainer/style/index.d.ts +1 -1
  652. package/lib/layout/components/PageContainer/style/index.js +95 -79
  653. package/lib/layout/components/PageContainer/style/stylish.d.ts +1 -1
  654. package/lib/layout/components/PageContainer/style/stylish.js +11 -10
  655. package/lib/layout/components/PageHeader/index.js +99 -99
  656. package/lib/layout/components/PageHeader/style/index.d.ts +1 -1
  657. package/lib/layout/components/PageHeader/style/index.js +142 -123
  658. package/lib/layout/components/PageLoading/index.js +18 -20
  659. package/lib/layout/components/SettingDrawer/BlockCheckbox.js +31 -34
  660. package/lib/layout/components/SettingDrawer/LayoutChange.js +25 -23
  661. package/lib/layout/components/SettingDrawer/RegionalChange.js +16 -16
  662. package/lib/layout/components/SettingDrawer/ThemeColor.js +34 -36
  663. package/lib/layout/components/SettingDrawer/index.js +140 -170
  664. package/lib/layout/components/SettingDrawer/style/index.d.ts +1 -1
  665. package/lib/layout/components/SettingDrawer/style/index.js +141 -138
  666. package/lib/layout/components/SiderMenu/BaseMenu.d.ts +1 -1
  667. package/lib/layout/components/SiderMenu/BaseMenu.js +236 -222
  668. package/lib/layout/components/SiderMenu/SiderMenu.js +130 -119
  669. package/lib/layout/components/SiderMenu/index.js +53 -45
  670. package/lib/layout/components/SiderMenu/style/index.d.ts +1 -1
  671. package/lib/layout/components/SiderMenu/style/index.js +179 -162
  672. package/lib/layout/components/SiderMenu/style/menu.d.ts +1 -1
  673. package/lib/layout/components/SiderMenu/style/menu.js +148 -111
  674. package/lib/layout/components/SiderMenu/style/stylish.d.ts +1 -1
  675. package/lib/layout/components/SiderMenu/style/stylish.js +15 -12
  676. package/lib/layout/components/TopNavHeader/index.js +73 -62
  677. package/lib/layout/components/TopNavHeader/style.d.ts +1 -1
  678. package/lib/layout/components/TopNavHeader/style.js +64 -64
  679. package/lib/layout/context/RouteContext.js +1 -1
  680. package/lib/layout/defaultSettings.d.ts +6 -0
  681. package/lib/layout/defaultSettings.js +1 -1
  682. package/lib/layout/getPageTitle.js +27 -26
  683. package/lib/layout/index.js +16 -16
  684. package/lib/layout/locales/en-US.js +3 -2
  685. package/lib/layout/locales/index.js +8 -6
  686. package/lib/layout/locales/it-IT.js +3 -2
  687. package/lib/layout/locales/ko-KR.js +3 -2
  688. package/lib/layout/locales/zh-CN.js +3 -2
  689. package/lib/layout/locales/zh-TW.js +3 -2
  690. package/lib/layout/style/index.d.ts +1 -1
  691. package/lib/layout/style/index.js +48 -43
  692. package/lib/layout/utils/getBreadcrumbProps.js +65 -62
  693. package/lib/layout/utils/getMenuData.js +9 -13
  694. package/lib/layout/utils/pathTools.js +2 -6
  695. package/lib/layout/utils/useCurrentMenuLayoutProps.js +6 -11
  696. package/lib/layout/utils/utils.js +16 -18
  697. package/lib/list/Item.js +155 -136
  698. package/lib/list/ListView.js +110 -119
  699. package/lib/list/constants.js +2 -2
  700. package/lib/list/index.js +72 -70
  701. package/lib/list/style/index.d.ts +1 -1
  702. package/lib/list/style/index.js +281 -214
  703. package/lib/provider/index.d.ts +1 -0
  704. package/lib/provider/index.js +132 -117
  705. package/lib/provider/intl.js +56 -56
  706. package/lib/provider/typing/layoutToken.js +28 -25
  707. package/lib/provider/useStyle/index.d.ts +2 -1
  708. package/lib/provider/useStyle/index.js +64 -61
  709. package/lib/provider/utils/merge.js +12 -14
  710. package/lib/skeleton/components/Descriptions/index.js +213 -229
  711. package/lib/skeleton/components/List/index.js +211 -221
  712. package/lib/skeleton/components/Result/index.js +45 -47
  713. package/lib/skeleton/index.js +23 -19
  714. package/lib/table/Store/Provide.d.ts +4 -4
  715. package/lib/table/Store/Provide.js +103 -117
  716. package/lib/table/Table.d.ts +5 -2
  717. package/lib/table/Table.js +592 -602
  718. package/lib/table/TableSearch.d.ts +24 -0
  719. package/lib/table/TableSearch.js +61 -0
  720. package/lib/table/TableToolbar.d.ts +22 -0
  721. package/lib/table/TableToolbar.js +55 -0
  722. package/lib/table/components/Alert/index.d.ts +1 -1
  723. package/lib/table/components/Alert/index.js +41 -40
  724. package/lib/table/components/Alert/style.d.ts +1 -1
  725. package/lib/table/components/Alert/style.js +28 -28
  726. package/lib/table/components/ColumnSetting/index.d.ts +1 -1
  727. package/lib/table/components/ColumnSetting/index.js +230 -224
  728. package/lib/table/components/ColumnSetting/style.d.ts +1 -1
  729. package/lib/table/components/ColumnSetting/style.js +86 -72
  730. package/lib/table/components/DragSortTable/index.d.ts +1 -1
  731. package/lib/table/components/DragSortTable/index.js +64 -78
  732. package/lib/table/components/DragSortTable/style.d.ts +1 -1
  733. package/lib/table/components/DragSortTable/style.js +20 -20
  734. package/lib/table/components/Dropdown/index.js +42 -48
  735. package/lib/table/components/EditableTable/CellEditorTable.js +24 -32
  736. package/lib/table/components/EditableTable/RowEditorTable.js +23 -28
  737. package/lib/table/components/EditableTable/index.js +598 -299
  738. package/lib/table/components/Form/FormRender.js +99 -104
  739. package/lib/table/components/Form/index.d.ts +4 -19
  740. package/lib/table/components/Form/index.js +113 -159
  741. package/lib/table/components/ListToolBar/HeaderMenu.js +42 -51
  742. package/lib/table/components/ListToolBar/index.js +123 -148
  743. package/lib/table/components/ListToolBar/style.d.ts +1 -1
  744. package/lib/table/components/ListToolBar/style.js +127 -118
  745. package/lib/table/components/ToolBar/DensityIcon.js +10 -9
  746. package/lib/table/components/ToolBar/FullscreenIcon.js +5 -10
  747. package/lib/table/components/ToolBar/index.d.ts +2 -8
  748. package/lib/table/components/ToolBar/index.js +154 -194
  749. package/lib/table/index.js +27 -27
  750. package/lib/table/style/index.d.ts +1 -1
  751. package/lib/table/style/index.js +144 -113
  752. package/lib/table/typing.d.ts +13 -6
  753. package/lib/table/useFetchData.js +202 -347
  754. package/lib/table/utils/cellRenderToFromItem.js +106 -120
  755. package/lib/table/utils/columnRender.js +65 -54
  756. package/lib/table/utils/columnSort.js +24 -23
  757. package/lib/table/utils/genProColumnToColumn.d.ts +13 -9
  758. package/lib/table/utils/genProColumnToColumn.js +121 -99
  759. package/lib/table/utils/index.d.ts +12 -0
  760. package/lib/table/utils/index.js +129 -181
  761. package/lib/table/utils/useDragSort.d.ts +1 -1
  762. package/lib/table/utils/useDragSort.js +99 -93
  763. package/lib/table/utils/usePageInfo.d.ts +6 -0
  764. package/lib/table/utils/usePageInfo.js +61 -0
  765. package/lib/utils/components/DropdownFooter/index.js +25 -23
  766. package/lib/utils/components/DropdownFooter/style.d.ts +1 -1
  767. package/lib/utils/components/DropdownFooter/style.js +16 -16
  768. package/lib/utils/components/ErrorBoundary/index.js +28 -50
  769. package/lib/utils/components/FieldLabel/index.js +70 -71
  770. package/lib/utils/components/FieldLabel/style.d.ts +1 -1
  771. package/lib/utils/components/FieldLabel/style.js +104 -82
  772. package/lib/utils/components/FilterDropdown/index.d.ts +11 -0
  773. package/lib/utils/components/FilterDropdown/index.js +44 -33
  774. package/lib/utils/components/FilterDropdown/style.d.ts +1 -1
  775. package/lib/utils/components/FilterDropdown/style.js +19 -17
  776. package/lib/utils/components/InlineErrorFormItem/index.js +80 -80
  777. package/lib/utils/components/InlineErrorFormItem/style.d.ts +1 -1
  778. package/lib/utils/components/InlineErrorFormItem/style.js +56 -50
  779. package/lib/utils/components/LabelIconTip/index.js +30 -32
  780. package/lib/utils/components/LabelIconTip/style.d.ts +1 -1
  781. package/lib/utils/components/LabelIconTip/style.js +36 -36
  782. package/lib/utils/components/ProFormContext/index.js +1 -1
  783. package/lib/utils/conversionMomentValue/index.js +22 -23
  784. package/lib/utils/dateArrayFormatter/index.js +11 -15
  785. package/lib/utils/genCopyable/index.js +75 -33
  786. package/lib/utils/getFieldPropsOrFormItemProps/index.js +3 -2
  787. package/lib/utils/hooks/useDebounceFn/index.js +18 -52
  788. package/lib/utils/hooks/useDebounceValue/index.js +7 -17
  789. package/lib/utils/hooks/useDeepCompareEffect/index.js +7 -19
  790. package/lib/utils/hooks/useDocumentTitle/index.js +2 -2
  791. package/lib/utils/hooks/useFetchData/index.js +36 -65
  792. package/lib/utils/hooks/useForceRender/index.js +2 -10
  793. package/lib/utils/hooks/useLatest/index.js +4 -3
  794. package/lib/utils/hooks/usePrevious/index.js +5 -4
  795. package/lib/utils/hooks/useReactiveRef/index.js +2 -2
  796. package/lib/utils/hooks/useRefCallback/index.js +3 -3
  797. package/lib/utils/hooks/useRefFunction/index.js +6 -11
  798. package/lib/utils/index.d.ts +1 -2
  799. package/lib/utils/index.js +57 -65
  800. package/lib/utils/isBrowser/index.js +4 -3
  801. package/lib/utils/isDeepEqualReact/index.js +9 -45
  802. package/lib/utils/isDropdownValueType/index.js +4 -3
  803. package/lib/utils/isNil/index.js +2 -3
  804. package/lib/utils/isUrl/index.js +4 -3
  805. package/lib/utils/merge/index.js +12 -14
  806. package/lib/utils/nanoid/index.js +7 -7
  807. package/lib/utils/omitBoolean/index.js +3 -2
  808. package/lib/utils/omitUndefined/index.js +5 -4
  809. package/lib/utils/omitUndefinedAndEmptyArr/index.js +6 -6
  810. package/lib/utils/parseValueToMoment/index.js +5 -8
  811. package/lib/utils/pickProFormItemProps/index.js +3 -3
  812. package/lib/utils/pickProProps/index.js +6 -7
  813. package/lib/utils/proFieldParsingText/index.js +90 -100
  814. package/lib/utils/runFunction/index.js +2 -5
  815. package/lib/utils/stringify/index.js +2 -2
  816. package/lib/utils/transformKeySubmitValue/index.js +101 -117
  817. package/lib/utils/typing.d.ts +1 -1
  818. package/lib/utils/useEditableArray/index.d.ts +9 -7
  819. package/lib/utils/useEditableArray/index.js +791 -700
  820. package/lib/utils/useEditableMap/index.d.ts +1 -1
  821. package/lib/utils/useEditableMap/index.js +147 -137
  822. package/lib/utils/useMediaQuery/index.js +19 -19
  823. package/lib/utils/useMediaQuery/query.js +14 -19
  824. package/lib/version.js +1 -1
  825. package/package.json +34 -45
  826. package/es/utils/useMountMergeState/index.d.ts +0 -2
  827. package/es/utils/useMountMergeState/index.js +0 -2
  828. package/lib/utils/useMountMergeState/index.d.ts +0 -2
  829. package/lib/utils/useMountMergeState/index.js +0 -12
@@ -1,8 +1,6 @@
1
- import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
2
- import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
3
1
  import { Keyframes } from '@ant-design/cssinjs';
4
2
  import { useStyle as useAntdStyle } from "../../../../provider";
5
- export var proLayoutTitleHide = new Keyframes('antBadgeLoadingCircle', {
3
+ export const proLayoutTitleHide = new Keyframes('antBadgeLoadingCircle', {
6
4
  '0%': {
7
5
  display: 'none',
8
6
  opacity: 0,
@@ -16,170 +14,190 @@ export var proLayoutTitleHide = new Keyframes('antBadgeLoadingCircle', {
16
14
  opacity: 1
17
15
  }
18
16
  });
19
- var genSiderMenuStyle = function genSiderMenuStyle(token) {
20
- var _token$layout, _token$layout2, _token$layout3, _token$layout4, _token$layout5, _token$layout6, _token$layout7, _token$layout8, _token$layout9, _token$layout10, _token$layout11, _token$layout12;
21
- return _defineProperty({}, "".concat(token.proComponentsCls, "-layout"), _defineProperty(_defineProperty(_defineProperty({}, "".concat(token.antCls, "-layout-sider").concat(token.componentCls), {
22
- background: ((_token$layout = token.layout) === null || _token$layout === void 0 || (_token$layout = _token$layout.sider) === null || _token$layout === void 0 ? void 0 : _token$layout.colorMenuBackground) || 'transparent'
23
- }), token.componentCls, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
24
- position: 'relative',
25
- boxSizing: 'border-box',
26
- '&-menu': {
27
- position: 'relative',
28
- zIndex: 10,
29
- minHeight: '100%'
30
- }
31
- }, "& ".concat(token.antCls, "-layout-sider-children"), {
32
- position: 'relative',
33
- display: 'flex',
34
- flexDirection: 'column',
35
- height: '100%',
36
- paddingInline: (_token$layout2 = token.layout) === null || _token$layout2 === void 0 || (_token$layout2 = _token$layout2.sider) === null || _token$layout2 === void 0 ? void 0 : _token$layout2.paddingInlineLayoutMenu,
37
- paddingBlock: (_token$layout3 = token.layout) === null || _token$layout3 === void 0 || (_token$layout3 = _token$layout3.sider) === null || _token$layout3 === void 0 ? void 0 : _token$layout3.paddingBlockLayoutMenu,
38
- borderInlineEnd: "1px solid ".concat(token.colorSplit),
39
- marginInlineEnd: -1
40
- }), "".concat(token.antCls, "-menu"), _defineProperty(_defineProperty({}, "".concat(token.antCls, "-menu-item-group-title"), {
41
- fontSize: token.fontSizeSM,
42
- paddingBottom: 4
43
- }), "".concat(token.antCls, "-menu-item:not(").concat(token.antCls, "-menu-item-selected):hover"), {
44
- color: (_token$layout4 = token.layout) === null || _token$layout4 === void 0 || (_token$layout4 = _token$layout4.sider) === null || _token$layout4 === void 0 ? void 0 : _token$layout4.colorTextMenuItemHover
45
- })), '&-logo', {
46
- position: 'relative',
47
- display: 'flex',
48
- alignItems: 'center',
49
- justifyContent: 'space-between',
50
- paddingInline: 12,
51
- paddingBlock: 16,
52
- color: (_token$layout5 = token.layout) === null || _token$layout5 === void 0 || (_token$layout5 = _token$layout5.sider) === null || _token$layout5 === void 0 ? void 0 : _token$layout5.colorTextMenu,
53
- cursor: 'pointer',
54
- borderBlockEnd: "1px solid ".concat((_token$layout6 = token.layout) === null || _token$layout6 === void 0 || (_token$layout6 = _token$layout6.sider) === null || _token$layout6 === void 0 ? void 0 : _token$layout6.colorMenuItemDivider),
55
- '> a': {
56
- display: 'flex',
57
- alignItems: 'center',
58
- justifyContent: 'center',
59
- minHeight: 22,
60
- fontSize: 22,
61
- '> img': {
62
- display: 'inline-block',
63
- height: 22,
64
- verticalAlign: 'middle'
65
- },
66
- '> h1': {
67
- display: 'inline-block',
68
- height: 22,
69
- marginBlock: 0,
70
- marginInlineEnd: 0,
71
- marginInlineStart: 6,
72
- color: (_token$layout7 = token.layout) === null || _token$layout7 === void 0 || (_token$layout7 = _token$layout7.sider) === null || _token$layout7 === void 0 ? void 0 : _token$layout7.colorTextMenuTitle,
73
- animationName: proLayoutTitleHide,
74
- animationDuration: '.4s',
75
- animationTimingFunction: 'ease',
76
- fontWeight: 600,
77
- fontSize: 16,
78
- lineHeight: '22px',
79
- verticalAlign: 'middle'
80
- }
81
- },
82
- '&-collapsed': _defineProperty({
83
- flexDirection: 'column-reverse',
84
- margin: 0,
85
- padding: 12
86
- }, "".concat(token.proComponentsCls, "-layout-apps-icon"), {
87
- marginBlockEnd: 8,
88
- fontSize: 16,
89
- transition: 'font-size 0.2s ease-in-out,color 0.2s ease-in-out'
90
- })
91
- }), '&-actions', {
92
- display: 'flex',
93
- alignItems: 'center',
94
- justifyContent: 'space-between',
95
- marginBlock: 4,
96
- marginInline: 0,
97
- color: (_token$layout8 = token.layout) === null || _token$layout8 === void 0 || (_token$layout8 = _token$layout8.sider) === null || _token$layout8 === void 0 ? void 0 : _token$layout8.colorTextMenu,
98
- '&-collapsed': {
99
- flexDirection: 'column-reverse',
100
- paddingBlock: 0,
101
- paddingInline: 8,
102
- fontSize: 16,
103
- transition: 'font-size 0.3s ease-in-out'
104
- },
105
- '&-list': {
106
- color: (_token$layout9 = token.layout) === null || _token$layout9 === void 0 || (_token$layout9 = _token$layout9.sider) === null || _token$layout9 === void 0 ? void 0 : _token$layout9.colorTextMenuSecondary,
107
- '&-collapsed': {
108
- marginBlockEnd: 8,
109
- animationName: 'none'
17
+ const genSiderMenuStyle = token => {
18
+ return {
19
+ [`${token.proComponentsCls}-layout`]: {
20
+ [`${token.antCls}-layout-sider${token.componentCls}`]: {
21
+ background: token.layout?.sider?.colorMenuBackground || 'transparent'
110
22
  },
111
- '&-item': {
112
- paddingInline: 6,
113
- paddingBlock: 6,
114
- lineHeight: '16px',
115
- fontSize: 16,
116
- cursor: 'pointer',
117
- borderRadius: token.borderRadius,
118
- '&:hover': {
119
- background: token.colorBgTextHover
23
+ [token.componentCls]: {
24
+ position: 'relative',
25
+ boxSizing: 'border-box',
26
+ '&-menu': {
27
+ position: 'relative',
28
+ zIndex: 10,
29
+ minHeight: '100%'
30
+ },
31
+ [`& ${token.antCls}-layout-sider-children`]: {
32
+ position: 'relative',
33
+ display: 'flex',
34
+ flexDirection: 'column',
35
+ height: '100%',
36
+ paddingInline: token.layout?.sider?.paddingInlineLayoutMenu,
37
+ paddingBlock: token.layout?.sider?.paddingBlockLayoutMenu,
38
+ borderInlineEnd: `1px solid ${token.colorSplit}`,
39
+ marginInlineEnd: -1
40
+ },
41
+ [`${token.antCls}-menu`]: {
42
+ [`${token.antCls}-menu-item-group-title`]: {
43
+ fontSize: token.fontSizeSM,
44
+ paddingBottom: 4
45
+ },
46
+ [`${token.antCls}-menu-item:not(${token.antCls}-menu-item-selected):hover`]: {
47
+ color: token.layout?.sider?.colorTextMenuItemHover
48
+ }
49
+ },
50
+ '&-logo': {
51
+ position: 'relative',
52
+ display: 'flex',
53
+ alignItems: 'center',
54
+ justifyContent: 'space-between',
55
+ paddingInline: 12,
56
+ paddingBlock: 16,
57
+ color: token.layout?.sider?.colorTextMenu,
58
+ cursor: 'pointer',
59
+ borderBlockEnd: `1px solid ${token.layout?.sider?.colorMenuItemDivider}`,
60
+ '> a': {
61
+ display: 'flex',
62
+ alignItems: 'center',
63
+ justifyContent: 'center',
64
+ minHeight: 22,
65
+ fontSize: 22,
66
+ '> img': {
67
+ display: 'inline-block',
68
+ height: 22,
69
+ verticalAlign: 'middle'
70
+ },
71
+ '> h1': {
72
+ display: 'inline-block',
73
+ height: 22,
74
+ marginBlock: 0,
75
+ marginInlineEnd: 0,
76
+ marginInlineStart: 6,
77
+ color: token.layout?.sider?.colorTextMenuTitle,
78
+ animationName: proLayoutTitleHide,
79
+ animationDuration: '.4s',
80
+ animationTimingFunction: 'ease',
81
+ fontWeight: 600,
82
+ fontSize: 16,
83
+ lineHeight: '22px',
84
+ verticalAlign: 'middle'
85
+ }
86
+ },
87
+ '&-collapsed': {
88
+ flexDirection: 'column-reverse',
89
+ margin: 0,
90
+ padding: 12,
91
+ [`${token.proComponentsCls}-layout-apps-icon`]: {
92
+ marginBlockEnd: 8,
93
+ fontSize: 16,
94
+ transition: 'font-size 0.2s ease-in-out,color 0.2s ease-in-out'
95
+ }
96
+ }
97
+ },
98
+ '&-actions': {
99
+ display: 'flex',
100
+ alignItems: 'center',
101
+ justifyContent: 'space-between',
102
+ marginBlock: 4,
103
+ marginInline: 0,
104
+ color: token.layout?.sider?.colorTextMenu,
105
+ '&-collapsed': {
106
+ flexDirection: 'column-reverse',
107
+ paddingBlock: 0,
108
+ paddingInline: 8,
109
+ fontSize: 16,
110
+ transition: 'font-size 0.3s ease-in-out'
111
+ },
112
+ '&-list': {
113
+ color: token.layout?.sider?.colorTextMenuSecondary,
114
+ '&-collapsed': {
115
+ marginBlockEnd: 8,
116
+ animationName: 'none'
117
+ },
118
+ '&-item': {
119
+ paddingInline: 6,
120
+ paddingBlock: 6,
121
+ lineHeight: '16px',
122
+ fontSize: 16,
123
+ cursor: 'pointer',
124
+ borderRadius: token.borderRadius,
125
+ '&:hover': {
126
+ background: token.colorBgTextHover
127
+ }
128
+ }
129
+ },
130
+ '&-avatar': {
131
+ fontSize: 14,
132
+ paddingInline: 8,
133
+ paddingBlock: 8,
134
+ display: 'flex',
135
+ alignItems: 'center',
136
+ gap: token.marginXS,
137
+ borderRadius: token.borderRadius,
138
+ '& *': {
139
+ cursor: 'pointer'
140
+ },
141
+ '&:hover': {
142
+ background: token.colorBgTextHover
143
+ }
144
+ }
145
+ },
146
+ '&-hide-menu-collapsed': {
147
+ insetInlineStart: `-${token.proLayoutCollapsedWidth - 12}px`,
148
+ position: 'absolute'
149
+ },
150
+ '&-extra': {
151
+ marginBlockEnd: 16,
152
+ marginBlock: 0,
153
+ marginInline: 16,
154
+ '&-no-logo': {
155
+ marginBlockStart: 16
156
+ }
157
+ },
158
+ '&-links': {
159
+ width: '100%',
160
+ ul: {
161
+ height: 'auto'
162
+ }
163
+ },
164
+ '&-link-menu': {
165
+ border: 'none',
166
+ boxShadow: 'none',
167
+ background: 'transparent'
168
+ },
169
+ '&-footer': {
170
+ color: token.layout?.sider?.colorTextMenuSecondary,
171
+ paddingBlockEnd: 16,
172
+ fontSize: token.fontSize,
173
+ animationName: proLayoutTitleHide,
174
+ animationDuration: '.4s',
175
+ animationTimingFunction: 'ease'
120
176
  }
121
- }
122
- },
123
- '&-avatar': {
124
- fontSize: 14,
125
- paddingInline: 8,
126
- paddingBlock: 8,
127
- display: 'flex',
128
- alignItems: 'center',
129
- gap: token.marginXS,
130
- borderRadius: token.borderRadius,
131
- '& *': {
132
- cursor: 'pointer'
133
177
  },
134
- '&:hover': {
135
- background: token.colorBgTextHover
178
+ [`${token.componentCls}${token.componentCls}-fixed`]: {
179
+ position: 'fixed',
180
+ insetBlockStart: 0,
181
+ insetInlineStart: 0,
182
+ zIndex: '100',
183
+ height: '100%',
184
+ '&-mix': {
185
+ height: `calc(100% - ${token.layout?.header?.heightLayoutHeader || 56}px)`,
186
+ insetBlockStart: `${token.layout?.header?.heightLayoutHeader || 56}px`
187
+ }
136
188
  }
137
189
  }
138
- }), '&-hide-menu-collapsed', {
139
- insetInlineStart: "-".concat(token.proLayoutCollapsedWidth - 12, "px"),
140
- position: 'absolute'
141
- }), '&-extra', {
142
- marginBlockEnd: 16,
143
- marginBlock: 0,
144
- marginInline: 16,
145
- '&-no-logo': {
146
- marginBlockStart: 16
147
- }
148
- }), '&-links', {
149
- width: '100%',
150
- ul: {
151
- height: 'auto'
152
- }
153
- }), '&-link-menu', {
154
- border: 'none',
155
- boxShadow: 'none',
156
- background: 'transparent'
157
- }), '&-footer', {
158
- color: (_token$layout10 = token.layout) === null || _token$layout10 === void 0 || (_token$layout10 = _token$layout10.sider) === null || _token$layout10 === void 0 ? void 0 : _token$layout10.colorTextMenuSecondary,
159
- paddingBlockEnd: 16,
160
- fontSize: token.fontSize,
161
- animationName: proLayoutTitleHide,
162
- animationDuration: '.4s',
163
- animationTimingFunction: 'ease'
164
- })), "".concat(token.componentCls).concat(token.componentCls, "-fixed"), {
165
- position: 'fixed',
166
- insetBlockStart: 0,
167
- insetInlineStart: 0,
168
- zIndex: '100',
169
- height: '100%',
170
- '&-mix': {
171
- height: "calc(100% - ".concat(((_token$layout11 = token.layout) === null || _token$layout11 === void 0 || (_token$layout11 = _token$layout11.header) === null || _token$layout11 === void 0 ? void 0 : _token$layout11.heightLayoutHeader) || 56, "px)"),
172
- insetBlockStart: "".concat(((_token$layout12 = token.layout) === null || _token$layout12 === void 0 || (_token$layout12 = _token$layout12.header) === null || _token$layout12 === void 0 ? void 0 : _token$layout12.heightLayoutHeader) || 56, "px")
173
- }
174
- }));
190
+ };
175
191
  };
176
- export function useStyle(prefixCls, _ref2) {
177
- var proLayoutCollapsedWidth = _ref2.proLayoutCollapsedWidth;
178
- return useAntdStyle('ProLayoutSiderMenu', function (token) {
179
- var siderMenuToken = _objectSpread(_objectSpread({}, token), {}, {
180
- componentCls: ".".concat(prefixCls),
181
- proLayoutCollapsedWidth: proLayoutCollapsedWidth
182
- });
192
+ export function useStyle(prefixCls, {
193
+ proLayoutCollapsedWidth
194
+ }) {
195
+ return useAntdStyle('ProLayoutSiderMenu', token => {
196
+ const siderMenuToken = {
197
+ ...token,
198
+ componentCls: `.${prefixCls}`,
199
+ proLayoutCollapsedWidth
200
+ };
183
201
  return [genSiderMenuStyle(siderMenuToken)];
184
202
  });
185
203
  }
@@ -5,6 +5,6 @@ export interface ProLayoutBaseMenuToken extends ProAliasToken {
5
5
  componentCls: string;
6
6
  }
7
7
  export declare function useStyle(prefixCls: string, mode: MenuMode | undefined): {
8
- wrapSSR: (node: import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>>) => import("react").JSX.Element;
8
+ wrapSSR: (node: import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>>) => import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>>;
9
9
  hashId: string;
10
10
  };
@@ -1,117 +1,155 @@
1
- import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
2
- import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
3
1
  import { useStyle as useAntdStyle } from "../../../../provider";
4
- var genProLayoutBaseMenuStyle = function genProLayoutBaseMenuStyle(token, mode) {
5
- var _token$layout, _token$layout2;
6
- var menuToken = mode.includes('horizontal') ? (_token$layout = token.layout) === null || _token$layout === void 0 ? void 0 : _token$layout.header : (_token$layout2 = token.layout) === null || _token$layout2 === void 0 ? void 0 : _token$layout2.sider;
7
- return _objectSpread(_objectSpread(_defineProperty({}, "".concat(token.componentCls), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
8
- background: 'transparent',
9
- color: menuToken === null || menuToken === void 0 ? void 0 : menuToken.colorTextMenu,
10
- border: 'none'
11
- }, "".concat(token.componentCls, "-menu-item"), {
12
- transition: 'none !important'
13
- }), "".concat(token.componentCls, "-submenu-has-icon"), _defineProperty({}, "> ".concat(token.antCls, "-menu-sub"), {
14
- paddingInlineStart: 10
15
- })), "".concat(token.antCls, "-menu-title-content"), {
16
- width: '100%',
17
- height: '100%',
18
- display: 'inline-flex'
19
- }), "".concat(token.antCls, "-menu-title-content"), {
20
- '&:first-child': {
21
- width: '100%'
2
+ const genProLayoutBaseMenuStyle = (token, mode) => {
3
+ const menuToken = mode.includes('horizontal') ? token.layout?.header : token.layout?.sider;
4
+ return {
5
+ [`${token.componentCls}`]: {
6
+ background: 'transparent',
7
+ color: menuToken?.colorTextMenu,
8
+ border: 'none',
9
+ [`${token.componentCls}-menu-item`]: {
10
+ transition: 'none !important'
11
+ },
12
+ [`${token.componentCls}-submenu-has-icon`]: {
13
+ [`> ${token.antCls}-menu-sub`]: {
14
+ paddingInlineStart: 10
15
+ }
16
+ },
17
+ [`${token.antCls}-menu-title-content`]: {
18
+ width: '100%',
19
+ height: '100%',
20
+ display: 'inline-flex',
21
+ '&:first-child': {
22
+ width: '100%'
23
+ }
24
+ },
25
+ [`${token.componentCls}-item-icon`]: {
26
+ display: 'flex',
27
+ alignItems: 'center'
28
+ },
29
+ [`&&-collapsed`]: {
30
+ [`${token.antCls}-menu-item,
31
+ ${token.antCls}-menu-item-group > ${token.antCls}-menu-item-group-list > ${token.antCls}-menu-item,
32
+ ${token.antCls}-menu-item-group > ${token.antCls}-menu-item-group-list > ${token.antCls}-menu-submenu > ${token.antCls}-menu-submenu-title,
33
+ ${token.antCls}-menu-submenu > ${token.antCls}-menu-submenu-title`]: {
34
+ paddingInline: '0 !important',
35
+ marginBlock: '4px !important'
36
+ },
37
+ [`${token.antCls}-menu-item-group > ${token.antCls}-menu-item-group-list > ${token.antCls}-menu-submenu-selected > ${token.antCls}-menu-submenu-title,
38
+ ${token.antCls}-menu-submenu-selected > ${token.antCls}-menu-submenu-title`]: {
39
+ backgroundColor: menuToken?.colorBgMenuItemSelected,
40
+ borderRadius: token.borderRadiusLG
41
+ },
42
+ [`${token.componentCls}-group`]: {
43
+ [`${token.antCls}-menu-item-group-title`]: {
44
+ paddingInline: 0
45
+ }
46
+ }
47
+ },
48
+ '&-item-title': {
49
+ display: 'flex',
50
+ flexDirection: 'row',
51
+ alignItems: 'center',
52
+ gap: token.marginXS,
53
+ width: '100%',
54
+ [`${token.componentCls}-item-text`]: {
55
+ maxWidth: '100%',
56
+ textOverflow: 'ellipsis',
57
+ overflow: 'hidden',
58
+ wordBreak: 'break-all',
59
+ whiteSpace: 'nowrap'
60
+ },
61
+ '&-collapsed': {
62
+ minWidth: 40,
63
+ height: 40,
64
+ [`${token.componentCls}-item-icon`]: {
65
+ height: '16px',
66
+ width: '16px',
67
+ lineHeight: '16px !important',
68
+ '.anticon': {
69
+ lineHeight: '16px !important',
70
+ height: '16px'
71
+ }
72
+ },
73
+ [`${token.componentCls}-item-text-has-icon`]: {
74
+ display: 'none !important'
75
+ }
76
+ },
77
+ '&-collapsed-level-0': {
78
+ flexDirection: 'column',
79
+ justifyContent: 'center'
80
+ },
81
+ [`&${token.componentCls}-group-item-title`]: {
82
+ gap: token.marginXS,
83
+ height: 18,
84
+ overflow: 'hidden'
85
+ },
86
+ [`&${token.componentCls}-item-collapsed-show-title`]: {
87
+ lineHeight: '16px',
88
+ gap: 0,
89
+ [`&${token.componentCls}-item-title-collapsed`]: {
90
+ display: 'flex',
91
+ [`${token.componentCls}-item-icon`]: {
92
+ height: '16px',
93
+ width: '16px',
94
+ lineHeight: '16px !important',
95
+ '.anticon': {
96
+ lineHeight: '16px!important',
97
+ height: '16px'
98
+ }
99
+ },
100
+ [`${token.componentCls}-item-text`]: {
101
+ opacity: '1 !important',
102
+ display: 'inline !important',
103
+ textAlign: 'center',
104
+ fontSize: 12,
105
+ height: 12,
106
+ lineHeight: '12px',
107
+ overflow: 'hidden',
108
+ textOverflow: 'ellipsis',
109
+ whiteSpace: 'nowrap',
110
+ width: '100%',
111
+ margin: 0,
112
+ padding: 0,
113
+ marginBlockStart: 4
114
+ }
115
+ }
116
+ }
117
+ },
118
+ '&-group': {
119
+ [`${token.antCls}-menu-item-group-title`]: {
120
+ fontSize: 12,
121
+ color: token.colorTextLabel,
122
+ '.anticon': {
123
+ marginInlineEnd: 8
124
+ }
125
+ }
126
+ },
127
+ '&-group-divider': {
128
+ color: token.colorTextSecondary,
129
+ fontSize: 12,
130
+ lineHeight: 20
131
+ }
132
+ },
133
+ ...(mode.includes('horizontal') ? {} : {
134
+ [`${token.antCls}-menu-submenu${token.antCls}-menu-submenu-popup`]: {
135
+ [`${token.componentCls}-item-title`]: {
136
+ alignItems: 'flex-start'
137
+ }
138
+ }
139
+ }),
140
+ [`${token.antCls}-menu-submenu-popup`]: {
141
+ backgroundColor: 'rgba(255, 255, 255, 0.42)',
142
+ '-webkit-backdrop-filter': 'blur(8px)',
143
+ backdropFilter: 'blur(8px)'
22
144
  }
23
- }), "".concat(token.componentCls, "-item-icon"), {
24
- display: 'flex',
25
- alignItems: 'center'
26
- }), "&&-collapsed", _defineProperty(_defineProperty(_defineProperty({}, "".concat(token.antCls, "-menu-item, \n ").concat(token.antCls, "-menu-item-group > ").concat(token.antCls, "-menu-item-group-list > ").concat(token.antCls, "-menu-item, \n ").concat(token.antCls, "-menu-item-group > ").concat(token.antCls, "-menu-item-group-list > ").concat(token.antCls, "-menu-submenu > ").concat(token.antCls, "-menu-submenu-title, \n ").concat(token.antCls, "-menu-submenu > ").concat(token.antCls, "-menu-submenu-title"), {
27
- paddingInline: '0 !important',
28
- marginBlock: '4px !important'
29
- }), "".concat(token.antCls, "-menu-item-group > ").concat(token.antCls, "-menu-item-group-list > ").concat(token.antCls, "-menu-submenu-selected > ").concat(token.antCls, "-menu-submenu-title, \n ").concat(token.antCls, "-menu-submenu-selected > ").concat(token.antCls, "-menu-submenu-title"), {
30
- backgroundColor: menuToken === null || menuToken === void 0 ? void 0 : menuToken.colorBgMenuItemSelected,
31
- borderRadius: token.borderRadiusLG
32
- }), "".concat(token.componentCls, "-group"), _defineProperty({}, "".concat(token.antCls, "-menu-item-group-title"), {
33
- paddingInline: 0
34
- }))), '&-item-title', _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
35
- display: 'flex',
36
- flexDirection: 'row',
37
- alignItems: 'center',
38
- gap: token.marginXS
39
- }, "".concat(token.componentCls, "-item-text"), {
40
- maxWidth: '100%',
41
- textOverflow: 'ellipsis',
42
- overflow: 'hidden',
43
- wordBreak: 'break-all',
44
- whiteSpace: 'nowrap'
45
- }), '&-collapsed', _defineProperty(_defineProperty({
46
- minWidth: 40,
47
- height: 40
48
- }, "".concat(token.componentCls, "-item-icon"), {
49
- height: '16px',
50
- width: '16px',
51
- lineHeight: '16px !important',
52
- '.anticon': {
53
- lineHeight: '16px !important',
54
- height: '16px'
55
- }
56
- }), "".concat(token.componentCls, "-item-text-has-icon"), {
57
- display: 'none !important'
58
- })), '&-collapsed-level-0', {
59
- flexDirection: 'column',
60
- justifyContent: 'center'
61
- }), "&".concat(token.componentCls, "-group-item-title"), {
62
- gap: token.marginXS,
63
- height: 18,
64
- overflow: 'hidden'
65
- }), "&".concat(token.componentCls, "-item-collapsed-show-title"), _defineProperty({
66
- lineHeight: '16px',
67
- gap: 0
68
- }, "&".concat(token.componentCls, "-item-title-collapsed"), _defineProperty(_defineProperty({
69
- display: 'flex'
70
- }, "".concat(token.componentCls, "-item-icon"), {
71
- height: '16px',
72
- width: '16px',
73
- lineHeight: '16px !important',
74
- '.anticon': {
75
- lineHeight: '16px!important',
76
- height: '16px'
77
- }
78
- }), "".concat(token.componentCls, "-item-text"), {
79
- opacity: '1 !important',
80
- display: 'inline !important',
81
- textAlign: 'center',
82
- fontSize: 12,
83
- height: 12,
84
- lineHeight: '12px',
85
- overflow: 'hidden',
86
- textOverflow: 'ellipsis',
87
- whiteSpace: 'nowrap',
88
- width: '100%',
89
- margin: 0,
90
- padding: 0,
91
- marginBlockStart: 4
92
- })))), '&-group', _defineProperty({}, "".concat(token.antCls, "-menu-item-group-title"), {
93
- fontSize: 12,
94
- color: token.colorTextLabel,
95
- '.anticon': {
96
- marginInlineEnd: 8
97
- }
98
- })), '&-group-divider', {
99
- color: token.colorTextSecondary,
100
- fontSize: 12,
101
- lineHeight: 20
102
- })), mode.includes('horizontal') ? {} : _defineProperty({}, "".concat(token.antCls, "-menu-submenu").concat(token.antCls, "-menu-submenu-popup"), _defineProperty({}, "".concat(token.componentCls, "-item-title"), {
103
- alignItems: 'flex-start'
104
- }))), {}, _defineProperty({}, "".concat(token.antCls, "-menu-submenu-popup"), {
105
- backgroundColor: 'rgba(255, 255, 255, 0.42)',
106
- '-webkit-backdrop-filter': 'blur(8px)',
107
- backdropFilter: 'blur(8px)'
108
- }));
145
+ };
109
146
  };
110
147
  export function useStyle(prefixCls, mode) {
111
- return useAntdStyle('ProLayoutBaseMenu' + mode, function (token) {
112
- var proLayoutMenuToken = _objectSpread(_objectSpread({}, token), {}, {
113
- componentCls: ".".concat(prefixCls)
114
- });
148
+ return useAntdStyle('ProLayoutBaseMenu' + mode, token => {
149
+ const proLayoutMenuToken = {
150
+ ...token,
151
+ componentCls: `.${prefixCls}`
152
+ };
115
153
  return [genProLayoutBaseMenuStyle(proLayoutMenuToken, mode || 'inline')];
116
154
  });
117
155
  }
@@ -8,6 +8,6 @@ export declare function useStylish(prefixCls: string, { stylish, proLayoutCollap
8
8
  stylish?: GenerateStyle<SiderMenuToken>;
9
9
  proLayoutCollapsedWidth: number;
10
10
  }): {
11
- wrapSSR: (node: import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>>) => import("react").JSX.Element;
11
+ wrapSSR: (node: import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>>) => import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>>;
12
12
  hashId: string;
13
13
  };
@@ -1,15 +1,19 @@
1
- import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
2
- import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
3
1
  import { useStyle as useAntdStyle } from "../../../../provider";
4
- export function useStylish(prefixCls, _ref) {
5
- var stylish = _ref.stylish,
6
- proLayoutCollapsedWidth = _ref.proLayoutCollapsedWidth;
7
- return useAntdStyle('ProLayoutSiderMenuStylish', function (token) {
8
- var siderMenuToken = _objectSpread(_objectSpread({}, token), {}, {
9
- componentCls: ".".concat(prefixCls),
10
- proLayoutCollapsedWidth: proLayoutCollapsedWidth
11
- });
2
+ export function useStylish(prefixCls, {
3
+ stylish,
4
+ proLayoutCollapsedWidth
5
+ }) {
6
+ return useAntdStyle('ProLayoutSiderMenuStylish', token => {
7
+ const siderMenuToken = {
8
+ ...token,
9
+ componentCls: `.${prefixCls}`,
10
+ proLayoutCollapsedWidth
11
+ };
12
12
  if (!stylish) return [];
13
- return [_defineProperty({}, "div".concat(token.proComponentsCls, "-layout"), _defineProperty({}, "".concat(siderMenuToken.componentCls), stylish === null || stylish === void 0 ? void 0 : stylish(siderMenuToken)))];
13
+ return [{
14
+ [`div${token.proComponentsCls}-layout`]: {
15
+ [`${siderMenuToken.componentCls}`]: stylish?.(siderMenuToken)
16
+ }
17
+ }];
14
18
  });
15
19
  }