@teamix/pro 1.5.1-aplha.0 → 1.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (445) hide show
  1. package/dist/pro.css +1 -1
  2. package/dist/pro.js +65730 -78948
  3. package/dist/pro.min.css +1 -1
  4. package/dist/pro.min.js +1 -1
  5. package/es/actions/base.d.ts +24 -0
  6. package/es/actions/confirm.d.ts +7 -0
  7. package/es/actions/danger-confirm.d.ts +7 -0
  8. package/es/actions/danger-pop-confirm.d.ts +5 -0
  9. package/es/actions/dialog-component.d.ts +10 -0
  10. package/es/actions/dialog-component.js +7 -1
  11. package/es/actions/dialog-form.d.ts +29 -0
  12. package/es/actions/dialog-form.js +3 -5
  13. package/es/actions/dialog-info.d.ts +9 -0
  14. package/es/actions/dialog-table.d.ts +9 -0
  15. package/es/actions/dialog.d.ts +40 -0
  16. package/es/actions/dialog.js +1 -1
  17. package/es/actions/drawer-form.d.ts +6 -0
  18. package/es/actions/drawer-info.d.ts +6 -0
  19. package/es/actions/drawer-table.d.ts +6 -0
  20. package/es/actions/drawer.d.ts +6 -0
  21. package/es/actions/error.d.ts +7 -0
  22. package/es/actions/index.d.ts +111 -0
  23. package/es/actions/index.js +23 -32
  24. package/es/actions/index.scss +5 -0
  25. package/es/actions/link.d.ts +8 -0
  26. package/es/actions/notice.d.ts +7 -0
  27. package/es/actions/pop-confirm.d.ts +9 -0
  28. package/es/actions/request.d.ts +9 -0
  29. package/es/actions/request.js +2 -2
  30. package/es/actions/utils.d.ts +1 -0
  31. package/es/card/card-container.d.ts +18 -0
  32. package/es/card/card-container.js +9 -9
  33. package/es/card/divider.d.ts +6 -0
  34. package/es/card/divider.js +6 -2
  35. package/es/card/index.d.ts +109 -0
  36. package/es/card/index.js +8 -14
  37. package/es/card/index.scss +7 -0
  38. package/es/card/selectable.d.ts +13 -0
  39. package/es/card/selectable.js +6 -2
  40. package/es/card/tab.d.ts +6 -0
  41. package/es/card/tab.js +6 -2
  42. package/es/card/utils.d.ts +9 -0
  43. package/es/field/index.d.ts +3 -0
  44. package/es/form/Components/Editable/index.d.ts +20 -0
  45. package/es/form/Components/Editable/index.js +1 -1
  46. package/es/form/Components/FormGroup/index.d.ts +13 -0
  47. package/es/form/Components/FormGroup/index.js +3 -5
  48. package/es/form/Components/LightFilter/componentMap.d.ts +3 -0
  49. package/es/form/Components/LightFilter/index.d.ts +17 -0
  50. package/es/form/Components/LightFilter/index.js +2 -8
  51. package/es/form/Components/ProField/index.d.ts +2 -0
  52. package/es/form/Components/ProField/index.js +6 -2
  53. package/es/form/Components/ProField/mapDateFormat.d.ts +3 -0
  54. package/es/form/Components/Text/index.d.ts +7 -0
  55. package/es/form/Components/Text/index.js +6 -2
  56. package/es/form/Filter/AdvancedFilter.d.ts +7 -0
  57. package/es/form/Filter/AdvancedFilter.js +15 -18
  58. package/es/form/Filter/Layout.d.ts +5 -0
  59. package/es/form/Filter/LightFilter.d.ts +7 -0
  60. package/es/form/Filter/LightFilter.js +10 -13
  61. package/es/form/Filter/SimpleFilter.d.ts +7 -0
  62. package/es/form/Filter/SimpleFilter.js +6 -10
  63. package/es/form/Filter/index.d.ts +9 -0
  64. package/es/form/Filter/index.js +10 -7
  65. package/es/form/Filter/index2.d.ts +13 -0
  66. package/es/form/Filter/index2.js +17 -21
  67. package/es/form/Filter/useBindUrl.d.ts +2 -0
  68. package/es/form/Filter/useSpecialProps.d.ts +6 -0
  69. package/es/form/ProForm/addCascadeEffect.d.ts +2 -0
  70. package/es/form/ProForm/customComponent.d.ts +3 -0
  71. package/es/form/ProForm/index.d.ts +5 -0
  72. package/es/form/ProForm/index.js +2 -4
  73. package/es/form/ProForm/useAutoLayout.d.ts +9 -0
  74. package/es/form/ProForm/useAutoSubmit.d.ts +6 -0
  75. package/es/form/ProForm/useFieldRequest.d.ts +5 -0
  76. package/es/form/ProForm/useFormDisplayValues.d.ts +4 -0
  77. package/es/form/ProForm/useFormDisplayValues.js +1 -1
  78. package/es/form/ProForm/useInitialRequest.d.ts +6 -0
  79. package/es/form/SchemaForm/adapterComponent.d.ts +5 -0
  80. package/es/form/SchemaForm/adapterDecorator.d.ts +6 -0
  81. package/es/form/SchemaForm/adapterType.d.ts +5 -0
  82. package/es/form/SchemaForm/index.d.ts +4 -0
  83. package/es/form/SchemaForm/initializeArrayCards.d.ts +3 -0
  84. package/es/form/SchemaForm/initializeArrayCollapse.d.ts +3 -0
  85. package/es/form/SchemaForm/initializeArrayItems.d.ts +3 -0
  86. package/es/form/SchemaForm/initializeArrayTable.d.ts +3 -0
  87. package/es/form/SchemaForm/initializeDataSource.d.ts +15 -0
  88. package/es/form/SchemaForm/initializeFormButton.d.ts +3 -0
  89. package/es/form/SchemaForm/initializeFormCollapse.d.ts +3 -0
  90. package/es/form/SchemaForm/initializeFormGroup.d.ts +3 -0
  91. package/es/form/SchemaForm/initializeFormStep.d.ts +5 -0
  92. package/es/form/SchemaForm/initializeFormTab.d.ts +3 -0
  93. package/es/form/SchemaForm/initializeReactions.d.ts +2 -0
  94. package/es/form/SchemaForm/initializeRequest.d.ts +11 -0
  95. package/es/form/SchemaForm/initializeRules.d.ts +11 -0
  96. package/es/form/SchemaForm/initializeSelectTable.d.ts +3 -0
  97. package/es/form/SchemaForm/reactions.d.ts +6 -0
  98. package/es/form/SchemaForm/reactions.js +1 -2
  99. package/es/form/docs/ActionResponse.d.ts +7 -0
  100. package/es/form/fieldTypeMap.d.ts +7 -0
  101. package/es/form/index.d.ts +125 -0
  102. package/es/form/locales/validate.d.ts +159 -0
  103. package/es/form/schemaNameMap.d.ts +5 -0
  104. package/es/form/typing.d.ts +192 -0
  105. package/es/form/utils.d.ts +55 -0
  106. package/es/form/utils.js +1 -8
  107. package/es/form/warning.d.ts +3 -0
  108. package/es/hooks/index.d.ts +2 -0
  109. package/es/index-without-icon.d.ts +32 -0
  110. package/es/index.d.ts +32 -0
  111. package/es/index.js +1 -1
  112. package/es/info/components/InfoGroup/index.d.ts +5 -0
  113. package/es/info/components/InfoGroup/index.js +6 -2
  114. package/es/info/components/InfoValueItem/index.d.ts +5 -0
  115. package/es/info/components/InfoValueItem/index.js +21 -23
  116. package/es/info/components/ProInfoItem/index.d.ts +5 -0
  117. package/es/info/components/baseInfo/index.d.ts +8 -0
  118. package/es/info/components/headerInfo/index.d.ts +8 -0
  119. package/es/info/components/tableInfo/index.d.ts +7 -0
  120. package/es/info/components/tableInfo/index.js +4 -5
  121. package/es/info/index.d.ts +10 -0
  122. package/es/info/index.js +5 -8
  123. package/es/info/typing.d.ts +218 -0
  124. package/es/info/utils/index.d.ts +20 -0
  125. package/es/info/utils/layout.d.ts +2 -0
  126. package/es/info/utils/utils.d.ts +1 -0
  127. package/es/layout/index.d.ts +2 -0
  128. package/es/nocode/configurators/Card.d.ts +3 -0
  129. package/es/nocode/configurators/PageHeader.d.ts +3 -0
  130. package/es/nocode/configurators/ProTable.d.ts +3 -0
  131. package/es/nocode/configurators/common.d.ts +280 -0
  132. package/es/nocode/configurators/index.d.ts +15 -0
  133. package/es/nocode/configurators/map.d.ts +2 -0
  134. package/es/nocode/index.d.ts +8 -0
  135. package/es/nocode/index.js +2 -2
  136. package/es/nocode/pages/editor.d.ts +12 -0
  137. package/es/nocode/pages/index.d.ts +14 -0
  138. package/es/nocode/pages/index.js +3 -4
  139. package/es/nocode/pages/playground.d.ts +11 -0
  140. package/es/nocode/pages/playground.js +7 -3
  141. package/es/nocode/pages/renderer.d.ts +10 -0
  142. package/es/nocode/pages/renderer.js +8 -4
  143. package/es/nocode/playground.d.ts +14 -0
  144. package/es/nocode/playground.js +6 -2
  145. package/es/page-container/index.d.ts +3 -0
  146. package/es/page-header/index.d.ts +74 -0
  147. package/es/page-header/index.js +7 -12
  148. package/es/sidebar/components/sidebar-container/index.d.ts +5 -0
  149. package/es/sidebar/components/sidebar-container/index.js +9 -5
  150. package/es/sidebar/components/tree/index.d.ts +6 -0
  151. package/es/sidebar/components/tree/index.js +6 -2
  152. package/es/sidebar/components/tree-node/components/HoverTooltip/index.d.ts +15 -0
  153. package/es/sidebar/components/tree-node/components/HoverTooltip/index.js +6 -2
  154. package/es/sidebar/components/tree-node/components/IconAction/index.d.ts +12 -0
  155. package/es/sidebar/components/tree-node/components/IconAction/index.js +2 -4
  156. package/es/sidebar/components/tree-node/components/IconSwitch/index.d.ts +23 -0
  157. package/es/sidebar/components/tree-node/components/IconSwitch/index.scss +1 -1
  158. package/es/sidebar/components/tree-node/index.d.ts +7 -0
  159. package/es/sidebar/components/tree-node/index.js +18 -21
  160. package/es/sidebar/index.d.ts +9 -0
  161. package/es/sidebar/index.js +8 -4
  162. package/es/sidebar/typing.d.ts +141 -0
  163. package/es/sidebar/utils/action-ref.d.ts +3 -0
  164. package/es/sidebar/utils/index.d.ts +361 -0
  165. package/es/sidebar/utils/index.js +11 -11
  166. package/es/skeleton/index.d.ts +3 -0
  167. package/es/table/components/CardView/index.d.ts +5 -0
  168. package/es/table/components/CardView/index.js +446 -0
  169. package/es/table/components/CardView/index.scss +46 -0
  170. package/es/table/components/EmptyContent/index.d.ts +2 -0
  171. package/es/table/components/Filter/index.d.ts +10 -0
  172. package/es/table/components/Filter/index.js +21 -14
  173. package/es/table/components/Layout/index.d.ts +5 -0
  174. package/es/table/components/Layout/index.js +8 -10
  175. package/es/table/components/LoadMore/index.d.ts +20 -0
  176. package/es/table/components/LoadMore/index.js +107 -0
  177. package/es/table/components/LoadMore/index.scss +19 -0
  178. package/es/table/components/Pagination/index.d.ts +7 -0
  179. package/es/table/components/Pagination/index.js +14 -10
  180. package/es/table/components/QuickAction/index.d.ts +11 -0
  181. package/es/table/components/QuickAction/index.js +2 -4
  182. package/es/table/components/ToolBar/CardSwitch.d.ts +8 -0
  183. package/es/table/components/ToolBar/CardSwitch.js +63 -0
  184. package/es/table/components/ToolBar/DensityIcon.d.ts +4 -0
  185. package/es/table/components/ToolBar/DensityIcon.js +3 -2
  186. package/es/table/components/ToolBar/FilterColumnIcon.d.ts +4 -0
  187. package/es/table/components/ToolBar/FilterColumnIcon.js +13 -2
  188. package/es/table/components/ToolBar/FullScreenIcon.d.ts +4 -0
  189. package/es/table/components/ToolBar/Fullscreen.d.ts +10 -0
  190. package/es/table/components/ToolBar/Fullscreen.js +15 -2
  191. package/es/table/components/ToolBar/RefreshIcon.d.ts +4 -0
  192. package/es/table/components/ToolBar/RefreshIcon.js +1 -2
  193. package/es/table/components/ToolBar/index.d.ts +5 -0
  194. package/es/table/components/ToolBar/index.js +69 -34
  195. package/es/table/components/ToolBar/index.scss +10 -1
  196. package/es/table/index.d.ts +5 -0
  197. package/es/table/index.js +150 -59
  198. package/es/table/typing.d.ts +371 -0
  199. package/es/table/utils/columnRender.d.ts +13 -0
  200. package/es/table/utils/columnRender.js +28 -28
  201. package/es/table/utils/genProColumnToColumn.d.ts +13 -0
  202. package/es/table/utils/genProColumnToColumn.js +4 -2
  203. package/es/table/utils/getTableProps.d.ts +2 -0
  204. package/es/table/utils/getTableSortIcons.d.ts +3 -0
  205. package/es/table/utils/index.d.ts +19 -0
  206. package/es/table/utils/index.js +2 -2
  207. package/es/table/utils/pureColumnRender.d.ts +9 -0
  208. package/es/table/utils/pureColumnRender.js +2 -4
  209. package/es/table/utils/pureGenProColumnToColumn.d.ts +7 -0
  210. package/es/table/utils/pureGenProColumnToColumn.js +1 -1
  211. package/es/table/utils/useTableSelection.d.ts +3 -0
  212. package/es/templates/Detail/index.d.ts +2 -0
  213. package/es/templates/Form/index.d.ts +2 -0
  214. package/es/templates/List/index.d.ts +9 -0
  215. package/es/templates/List/index.js +8 -4
  216. package/es/templates/index.d.ts +3 -0
  217. package/es/templates/index.js +1 -2
  218. package/es/timeline/ProTimeLineItem/index.d.ts +5 -0
  219. package/es/timeline/ProTimeLineItem/index.js +6 -2
  220. package/es/timeline/index.d.ts +10 -0
  221. package/es/timeline/index.js +7 -3
  222. package/es/timeline/typing.d.ts +106 -0
  223. package/es/utils/index.d.ts +3 -0
  224. package/es/utils/message.d.ts +3 -0
  225. package/es/utils/message.js +7 -3
  226. package/lib/actions/base.d.ts +24 -0
  227. package/lib/actions/confirm.d.ts +7 -0
  228. package/lib/actions/danger-confirm.d.ts +7 -0
  229. package/lib/actions/danger-pop-confirm.d.ts +5 -0
  230. package/lib/actions/dialog-component.d.ts +10 -0
  231. package/lib/actions/dialog-component.js +7 -1
  232. package/lib/actions/dialog-form.d.ts +29 -0
  233. package/lib/actions/dialog-form.js +3 -5
  234. package/lib/actions/dialog-info.d.ts +9 -0
  235. package/lib/actions/dialog-table.d.ts +9 -0
  236. package/lib/actions/dialog.d.ts +40 -0
  237. package/lib/actions/dialog.js +1 -1
  238. package/lib/actions/drawer-form.d.ts +6 -0
  239. package/lib/actions/drawer-info.d.ts +6 -0
  240. package/lib/actions/drawer-table.d.ts +6 -0
  241. package/lib/actions/drawer.d.ts +6 -0
  242. package/lib/actions/error.d.ts +7 -0
  243. package/lib/actions/index.d.ts +111 -0
  244. package/lib/actions/index.js +23 -32
  245. package/lib/actions/index.scss +5 -0
  246. package/lib/actions/link.d.ts +8 -0
  247. package/lib/actions/notice.d.ts +7 -0
  248. package/lib/actions/pop-confirm.d.ts +9 -0
  249. package/lib/actions/request.d.ts +9 -0
  250. package/lib/actions/utils.d.ts +1 -0
  251. package/lib/card/card-container.d.ts +18 -0
  252. package/lib/card/card-container.js +7 -5
  253. package/lib/card/divider.d.ts +6 -0
  254. package/lib/card/divider.js +6 -2
  255. package/lib/card/index.d.ts +109 -0
  256. package/lib/card/index.js +7 -14
  257. package/lib/card/index.scss +7 -0
  258. package/lib/card/selectable.d.ts +13 -0
  259. package/lib/card/selectable.js +6 -2
  260. package/lib/card/tab.d.ts +6 -0
  261. package/lib/card/tab.js +6 -2
  262. package/lib/card/utils.d.ts +9 -0
  263. package/lib/field/index.d.ts +3 -0
  264. package/lib/form/Components/Editable/index.d.ts +20 -0
  265. package/lib/form/Components/Editable/index.js +1 -1
  266. package/lib/form/Components/FormGroup/index.d.ts +13 -0
  267. package/lib/form/Components/FormGroup/index.js +3 -5
  268. package/lib/form/Components/LightFilter/componentMap.d.ts +3 -0
  269. package/lib/form/Components/LightFilter/index.d.ts +17 -0
  270. package/lib/form/Components/LightFilter/index.js +2 -8
  271. package/lib/form/Components/ProField/index.d.ts +2 -0
  272. package/lib/form/Components/ProField/index.js +6 -2
  273. package/lib/form/Components/ProField/mapDateFormat.d.ts +3 -0
  274. package/lib/form/Components/Text/index.d.ts +7 -0
  275. package/lib/form/Components/Text/index.js +6 -2
  276. package/lib/form/Filter/AdvancedFilter.d.ts +7 -0
  277. package/lib/form/Filter/AdvancedFilter.js +14 -17
  278. package/lib/form/Filter/Layout.d.ts +5 -0
  279. package/lib/form/Filter/LightFilter.d.ts +7 -0
  280. package/lib/form/Filter/LightFilter.js +9 -12
  281. package/lib/form/Filter/SimpleFilter.d.ts +7 -0
  282. package/lib/form/Filter/SimpleFilter.js +5 -8
  283. package/lib/form/Filter/index.d.ts +9 -0
  284. package/lib/form/Filter/index.js +9 -6
  285. package/lib/form/Filter/index2.d.ts +13 -0
  286. package/lib/form/Filter/index2.js +17 -21
  287. package/lib/form/Filter/useBindUrl.d.ts +2 -0
  288. package/lib/form/Filter/useSpecialProps.d.ts +6 -0
  289. package/lib/form/ProForm/addCascadeEffect.d.ts +2 -0
  290. package/lib/form/ProForm/customComponent.d.ts +3 -0
  291. package/lib/form/ProForm/index.d.ts +5 -0
  292. package/lib/form/ProForm/index.js +2 -4
  293. package/lib/form/ProForm/useAutoLayout.d.ts +9 -0
  294. package/lib/form/ProForm/useAutoSubmit.d.ts +6 -0
  295. package/lib/form/ProForm/useFieldRequest.d.ts +5 -0
  296. package/lib/form/ProForm/useFormDisplayValues.d.ts +4 -0
  297. package/lib/form/ProForm/useInitialRequest.d.ts +6 -0
  298. package/lib/form/SchemaForm/adapterComponent.d.ts +5 -0
  299. package/lib/form/SchemaForm/adapterDecorator.d.ts +6 -0
  300. package/lib/form/SchemaForm/adapterType.d.ts +5 -0
  301. package/lib/form/SchemaForm/index.d.ts +4 -0
  302. package/lib/form/SchemaForm/initializeArrayCards.d.ts +3 -0
  303. package/lib/form/SchemaForm/initializeArrayCollapse.d.ts +3 -0
  304. package/lib/form/SchemaForm/initializeArrayItems.d.ts +3 -0
  305. package/lib/form/SchemaForm/initializeArrayTable.d.ts +3 -0
  306. package/lib/form/SchemaForm/initializeDataSource.d.ts +15 -0
  307. package/lib/form/SchemaForm/initializeFormButton.d.ts +3 -0
  308. package/lib/form/SchemaForm/initializeFormCollapse.d.ts +3 -0
  309. package/lib/form/SchemaForm/initializeFormGroup.d.ts +3 -0
  310. package/lib/form/SchemaForm/initializeFormStep.d.ts +5 -0
  311. package/lib/form/SchemaForm/initializeFormTab.d.ts +3 -0
  312. package/lib/form/SchemaForm/initializeReactions.d.ts +2 -0
  313. package/lib/form/SchemaForm/initializeRequest.d.ts +11 -0
  314. package/lib/form/SchemaForm/initializeRules.d.ts +11 -0
  315. package/lib/form/SchemaForm/initializeSelectTable.d.ts +3 -0
  316. package/lib/form/SchemaForm/reactions.d.ts +6 -0
  317. package/lib/form/docs/ActionResponse.d.ts +7 -0
  318. package/lib/form/fieldTypeMap.d.ts +7 -0
  319. package/lib/form/index.d.ts +125 -0
  320. package/lib/form/locales/validate.d.ts +159 -0
  321. package/lib/form/schemaNameMap.d.ts +5 -0
  322. package/lib/form/typing.d.ts +192 -0
  323. package/lib/form/typing.js +5 -1
  324. package/lib/form/utils.d.ts +55 -0
  325. package/lib/form/utils.js +0 -7
  326. package/lib/form/warning.d.ts +3 -0
  327. package/lib/hooks/index.d.ts +2 -0
  328. package/lib/index-without-icon.d.ts +32 -0
  329. package/lib/index.d.ts +32 -0
  330. package/lib/index.js +1 -1
  331. package/lib/info/components/InfoGroup/index.d.ts +5 -0
  332. package/lib/info/components/InfoGroup/index.js +6 -2
  333. package/lib/info/components/InfoValueItem/index.d.ts +5 -0
  334. package/lib/info/components/InfoValueItem/index.js +21 -23
  335. package/lib/info/components/ProInfoItem/index.d.ts +5 -0
  336. package/lib/info/components/baseInfo/index.d.ts +8 -0
  337. package/lib/info/components/headerInfo/index.d.ts +8 -0
  338. package/lib/info/components/tableInfo/index.d.ts +7 -0
  339. package/lib/info/components/tableInfo/index.js +4 -5
  340. package/lib/info/index.d.ts +10 -0
  341. package/lib/info/index.js +5 -8
  342. package/lib/info/typing.d.ts +218 -0
  343. package/lib/info/typing.js +5 -1
  344. package/lib/info/utils/index.d.ts +20 -0
  345. package/lib/info/utils/layout.d.ts +2 -0
  346. package/lib/info/utils/utils.d.ts +1 -0
  347. package/lib/layout/index.d.ts +2 -0
  348. package/lib/nocode/configurators/Card.d.ts +3 -0
  349. package/lib/nocode/configurators/PageHeader.d.ts +3 -0
  350. package/lib/nocode/configurators/ProTable.d.ts +3 -0
  351. package/lib/nocode/configurators/common.d.ts +280 -0
  352. package/lib/nocode/configurators/index.d.ts +15 -0
  353. package/lib/nocode/configurators/map.d.ts +2 -0
  354. package/lib/nocode/index.d.ts +8 -0
  355. package/lib/nocode/pages/editor.d.ts +12 -0
  356. package/lib/nocode/pages/index.d.ts +14 -0
  357. package/lib/nocode/pages/index.js +2 -2
  358. package/lib/nocode/pages/playground.d.ts +11 -0
  359. package/lib/nocode/pages/playground.js +7 -3
  360. package/lib/nocode/pages/renderer.d.ts +10 -0
  361. package/lib/nocode/pages/renderer.js +8 -4
  362. package/lib/nocode/playground.d.ts +14 -0
  363. package/lib/nocode/playground.js +6 -2
  364. package/lib/page-container/index.d.ts +3 -0
  365. package/lib/page-header/index.d.ts +74 -0
  366. package/lib/page-header/index.js +6 -12
  367. package/lib/sidebar/components/sidebar-container/index.d.ts +5 -0
  368. package/lib/sidebar/components/sidebar-container/index.js +9 -5
  369. package/lib/sidebar/components/tree/index.d.ts +6 -0
  370. package/lib/sidebar/components/tree/index.js +6 -2
  371. package/lib/sidebar/components/tree-node/components/HoverTooltip/index.d.ts +15 -0
  372. package/lib/sidebar/components/tree-node/components/HoverTooltip/index.js +6 -2
  373. package/lib/sidebar/components/tree-node/components/IconAction/index.d.ts +12 -0
  374. package/lib/sidebar/components/tree-node/components/IconAction/index.js +2 -4
  375. package/lib/sidebar/components/tree-node/components/IconSwitch/index.d.ts +23 -0
  376. package/lib/sidebar/components/tree-node/components/IconSwitch/index.scss +1 -1
  377. package/lib/sidebar/components/tree-node/index.d.ts +7 -0
  378. package/lib/sidebar/components/tree-node/index.js +18 -21
  379. package/lib/sidebar/index.d.ts +9 -0
  380. package/lib/sidebar/index.js +17 -4
  381. package/lib/sidebar/typing.d.ts +141 -0
  382. package/lib/sidebar/typing.js +5 -1
  383. package/lib/sidebar/utils/action-ref.d.ts +3 -0
  384. package/lib/sidebar/utils/index.d.ts +361 -0
  385. package/lib/sidebar/utils/index.js +11 -11
  386. package/lib/skeleton/index.d.ts +3 -0
  387. package/lib/table/components/CardView/index.d.ts +5 -0
  388. package/lib/table/components/CardView/index.js +468 -0
  389. package/lib/table/components/CardView/index.scss +46 -0
  390. package/lib/table/components/EmptyContent/index.d.ts +2 -0
  391. package/lib/table/components/Filter/index.d.ts +10 -0
  392. package/lib/table/components/Filter/index.js +21 -14
  393. package/lib/table/components/Layout/index.d.ts +5 -0
  394. package/lib/table/components/Layout/index.js +9 -11
  395. package/lib/table/components/LoadMore/index.d.ts +20 -0
  396. package/lib/table/components/LoadMore/index.js +128 -0
  397. package/lib/table/components/LoadMore/index.scss +19 -0
  398. package/lib/table/components/Pagination/index.d.ts +7 -0
  399. package/lib/table/components/Pagination/index.js +14 -10
  400. package/lib/table/components/QuickAction/index.d.ts +11 -0
  401. package/lib/table/components/QuickAction/index.js +2 -4
  402. package/lib/table/components/ToolBar/CardSwitch.d.ts +8 -0
  403. package/lib/table/components/ToolBar/CardSwitch.js +82 -0
  404. package/lib/table/components/ToolBar/DensityIcon.d.ts +4 -0
  405. package/lib/table/components/ToolBar/DensityIcon.js +3 -2
  406. package/lib/table/components/ToolBar/FilterColumnIcon.d.ts +4 -0
  407. package/lib/table/components/ToolBar/FilterColumnIcon.js +13 -2
  408. package/lib/table/components/ToolBar/FullScreenIcon.d.ts +4 -0
  409. package/lib/table/components/ToolBar/Fullscreen.d.ts +10 -0
  410. package/lib/table/components/ToolBar/Fullscreen.js +15 -2
  411. package/lib/table/components/ToolBar/RefreshIcon.d.ts +4 -0
  412. package/lib/table/components/ToolBar/RefreshIcon.js +1 -2
  413. package/lib/table/components/ToolBar/index.d.ts +5 -0
  414. package/lib/table/components/ToolBar/index.js +70 -33
  415. package/lib/table/components/ToolBar/index.scss +10 -1
  416. package/lib/table/index.d.ts +5 -0
  417. package/lib/table/index.js +153 -60
  418. package/lib/table/typing.d.ts +371 -0
  419. package/lib/table/typing.js +5 -1
  420. package/lib/table/utils/columnRender.d.ts +13 -0
  421. package/lib/table/utils/columnRender.js +28 -28
  422. package/lib/table/utils/genProColumnToColumn.d.ts +13 -0
  423. package/lib/table/utils/genProColumnToColumn.js +3 -1
  424. package/lib/table/utils/getTableProps.d.ts +2 -0
  425. package/lib/table/utils/getTableSortIcons.d.ts +3 -0
  426. package/lib/table/utils/index.d.ts +19 -0
  427. package/lib/table/utils/pureColumnRender.d.ts +9 -0
  428. package/lib/table/utils/pureColumnRender.js +1 -3
  429. package/lib/table/utils/pureGenProColumnToColumn.d.ts +7 -0
  430. package/lib/table/utils/useTableSelection.d.ts +3 -0
  431. package/lib/templates/Detail/index.d.ts +2 -0
  432. package/lib/templates/Form/index.d.ts +2 -0
  433. package/lib/templates/List/index.d.ts +9 -0
  434. package/lib/templates/List/index.js +8 -4
  435. package/lib/templates/index.d.ts +3 -0
  436. package/lib/timeline/ProTimeLineItem/index.d.ts +5 -0
  437. package/lib/timeline/ProTimeLineItem/index.js +6 -2
  438. package/lib/timeline/index.d.ts +10 -0
  439. package/lib/timeline/index.js +7 -3
  440. package/lib/timeline/typing.d.ts +106 -0
  441. package/lib/timeline/typing.js +5 -1
  442. package/lib/utils/index.d.ts +3 -0
  443. package/lib/utils/message.d.ts +3 -0
  444. package/lib/utils/message.js +7 -3
  445. package/package.json +1 -1
@@ -11,7 +11,7 @@ var _utils = require("@teamix/utils");
11
11
 
12
12
  var _field = require("../../../field");
13
13
 
14
- var _actions2 = require("../../../actions");
14
+ var _actions = require("../../../actions");
15
15
 
16
16
  var _form = require("../../../form");
17
17
 
@@ -29,8 +29,6 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
29
29
 
30
30
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
31
31
 
32
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
33
-
34
32
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
35
33
 
36
34
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
@@ -60,9 +58,9 @@ var Layout = function Layout(props) {
60
58
 
61
59
 
62
60
  var renderMainAction = function renderMainAction() {
63
- var _actions;
61
+ var _mainAction$actions;
64
62
 
65
- if (_typeof(mainAction) === 'object' && (mainAction === null || mainAction === void 0 ? void 0 : (_actions = mainAction.actions) === null || _actions === void 0 ? void 0 : _actions.length) > 0) {
63
+ if (_typeof(mainAction) === 'object' && (mainAction === null || mainAction === void 0 ? void 0 : (_mainAction$actions = mainAction.actions) === null || _mainAction$actions === void 0 ? void 0 : _mainAction$actions.length) > 0) {
66
64
  // 判断 actions 是否 visible 都为 false,是的话也不渲染
67
65
  var isEmptyActions = mainAction === null || mainAction === void 0 ? void 0 : mainAction.actions.every(function (action) {
68
66
  return (action === null || action === void 0 ? void 0 : action.visible) === false;
@@ -79,7 +77,7 @@ var Layout = function Layout(props) {
79
77
  };
80
78
  return /*#__PURE__*/_react.default.createElement("div", {
81
79
  className: cls('main-action')
82
- }, /*#__PURE__*/_react.default.createElement(_actions2.ProActionGroup, _extends({}, mainAction, {
80
+ }, /*#__PURE__*/_react.default.createElement(_actions.ProActionGroup, _objectSpread(_objectSpread({}, mainAction), {}, {
83
81
  context: _objectSpread(_objectSpread({}, defaultContext), mainAction.context),
84
82
  "data-teamix-spm": dataTeamixSpm ? "".concat(dataTeamixSpm, "-mainAction") : undefined
85
83
  })));
@@ -94,7 +92,7 @@ var Layout = function Layout(props) {
94
92
  actionRef: actionRef,
95
93
  quickAction: extra,
96
94
  rowSelection: rowSelection
97
- }), /*#__PURE__*/_react.default.createElement(_ToolBar.default, _extends({
95
+ }), /*#__PURE__*/_react.default.createElement(_ToolBar.default, _objectSpread({
98
96
  actionRef: actionRef,
99
97
  toolBar: toolBar
100
98
  }, otherProps)));
@@ -109,7 +107,7 @@ var Layout = function Layout(props) {
109
107
 
110
108
  if ( /*#__PURE__*/(0, _react.isValidElement)(dataFilter === null || dataFilter === void 0 ? void 0 : dataFilter.content)) {
111
109
  // 自定义渲染内容
112
- return /*#__PURE__*/_react.default.createElement(_form.QueryFilterLayout, _extends({
110
+ return /*#__PURE__*/_react.default.createElement(_form.QueryFilterLayout, _objectSpread({
113
111
  onExpand: function onExpand(expand) {
114
112
  // 全屏模式下展开收起过滤器需要重新计算tableMaxHeight
115
113
  setTimeout(function () {
@@ -126,7 +124,7 @@ var Layout = function Layout(props) {
126
124
  addonAfter: renderAddonAfter()
127
125
  }, dataFilter));
128
126
  } else if ((dataFilter === null || dataFilter === void 0 ? void 0 : (_dataFilter$schema2 = dataFilter.schema) === null || _dataFilter$schema2 === void 0 ? void 0 : _dataFilter$schema2.length) >= 0) {
129
- return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_form.QueryFilter, _extends({
127
+ return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_form.QueryFilter, _objectSpread({
130
128
  formRef: dataFilterFormRef,
131
129
  onExpand: function onExpand(expand) {
132
130
  // 全屏模式下展开收起过滤器需要重新计算tableMaxHeight
@@ -171,7 +169,7 @@ var Layout = function Layout(props) {
171
169
  className: cls('wrapper')
172
170
  }, /*#__PURE__*/_react.default.createElement("div", {
173
171
  className: cls('left')
174
- }, header && /*#__PURE__*/_react.default.createElement(_field.Header, header)), /*#__PURE__*/_react.default.createElement("div", {
172
+ }, header && /*#__PURE__*/_react.default.createElement(_field.Header, _objectSpread({}, header))), /*#__PURE__*/_react.default.createElement("div", {
175
173
  className: cls('right')
176
174
  }, extra && /*#__PURE__*/_react.default.createElement(_QuickAction.default, {
177
175
  actionRef: actionRef,
@@ -185,7 +183,7 @@ var Layout = function Layout(props) {
185
183
  className: cls('wrapper')
186
184
  }, /*#__PURE__*/_react.default.createElement("div", {
187
185
  className: cls('left')
188
- }, header && /*#__PURE__*/_react.default.createElement(_field.Header, header)), /*#__PURE__*/_react.default.createElement("div", {
186
+ }, header && /*#__PURE__*/_react.default.createElement(_field.Header, _objectSpread({}, header))), /*#__PURE__*/_react.default.createElement("div", {
189
187
  className: cls('right')
190
188
  }, extra && /*#__PURE__*/_react.default.createElement(_QuickAction.default, {
191
189
  actionRef: actionRef,
@@ -0,0 +1,20 @@
1
+ import React from 'react';
2
+ import './index.scss';
3
+ export declare type LoadMoreProps = {
4
+ /** 内容 **/
5
+ children?: React.ReactNode;
6
+ /** 加载状态 受控 **/
7
+ loadState?: 'loading' | 'loadMore' | 'noMore' | 'none';
8
+ /** 滚动条滚动到底部触发事件 **/
9
+ onScrollBottom?: () => void;
10
+ /** 加载状态改变回调 **/
11
+ onChangeLoadState?: (state: LoadMoreProps['loadState']) => void;
12
+ /** 点击加载更多回调 **/
13
+ onLoadMore?: () => void;
14
+ /** 滚动区域高度 **/
15
+ scrollHeight?: number | string;
16
+ /** 当前滚动区域位置 **/
17
+ scrollPosition?: number;
18
+ };
19
+ declare const LoadMore: React.FC<LoadMoreProps>;
20
+ export default LoadMore;
@@ -0,0 +1,128 @@
1
+ "use strict";
2
+
3
+ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
+
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
8
+ exports.default = void 0;
9
+
10
+ var _react = _interopRequireWildcard(require("react"));
11
+
12
+ var _utils = require("@teamix/utils");
13
+
14
+ require("./index.scss");
15
+
16
+ var _icon = _interopRequireDefault(require("@teamix/icon"));
17
+
18
+ var _lodash = _interopRequireDefault(require("lodash.debounce"));
19
+
20
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
21
+
22
+ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
23
+
24
+ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
25
+
26
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
27
+
28
+ 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."); }
29
+
30
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
31
+
32
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
33
+
34
+ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
35
+
36
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
37
+
38
+ var cls = (0, _utils.usePrefixCls)('teamix-pro-load-more');
39
+
40
+ var LoadMore = function LoadMore(props) {
41
+ var children = props.children,
42
+ onChangeLoadState = props.onChangeLoadState,
43
+ onLoadMore = props.onLoadMore,
44
+ scrollHeight = props.scrollHeight,
45
+ onScrollBottom = props.onScrollBottom,
46
+ loadStateProp = props.loadState,
47
+ scrollPositionProp = props.scrollPosition;
48
+ var scrollDom = (0, _react.useRef)(null); // 加载状态
49
+
50
+ var _useState = (0, _react.useState)('loadMore'),
51
+ _useState2 = _slicedToArray(_useState, 2),
52
+ loadState = _useState2[0],
53
+ setLoadState = _useState2[1];
54
+
55
+ (0, _react.useEffect)(function () {
56
+ var _scrollDom$current;
57
+
58
+ scrollDom === null || scrollDom === void 0 ? void 0 : (_scrollDom$current = scrollDom.current) === null || _scrollDom$current === void 0 ? void 0 : _scrollDom$current.addEventListener('scroll', (0, _lodash.default)(function (e) {
59
+ var _e$target, _e$target2, _e$target3;
60
+
61
+ var scrollTop = e === null || e === void 0 ? void 0 : (_e$target = e.target) === null || _e$target === void 0 ? void 0 : _e$target.scrollTop;
62
+ var clientHeight = e === null || e === void 0 ? void 0 : (_e$target2 = e.target) === null || _e$target2 === void 0 ? void 0 : _e$target2.clientHeight;
63
+ var scrollHeight = e === null || e === void 0 ? void 0 : (_e$target3 = e.target) === null || _e$target3 === void 0 ? void 0 : _e$target3.scrollHeight;
64
+
65
+ if (scrollTop + clientHeight + 5 >= scrollHeight) {
66
+ onScrollBottom === null || onScrollBottom === void 0 ? void 0 : onScrollBottom();
67
+ }
68
+ }, 100));
69
+ }, []);
70
+ (0, _react.useEffect)(function () {
71
+ setLoadState(loadStateProp);
72
+ }, [loadStateProp]); // 更改加载状态
73
+
74
+ var onLoadState = function onLoadState(state) {
75
+ setLoadState(state);
76
+
77
+ if (state === 'loading') {
78
+ onLoadMore === null || onLoadMore === void 0 ? void 0 : onLoadMore();
79
+ }
80
+
81
+ onChangeLoadState === null || onChangeLoadState === void 0 ? void 0 : onChangeLoadState(state);
82
+ }; // 渲染加载更多和正在加载区域
83
+
84
+
85
+ var renderLoadMore = function renderLoadMore() {
86
+ if (loadState === 'loadMore') {
87
+ return /*#__PURE__*/_react.default.createElement("div", {
88
+ className: cls('bottom-text'),
89
+ onClick: function onClick() {
90
+ return onLoadState('loading');
91
+ }
92
+ }, /*#__PURE__*/_react.default.createElement(_icon.default, {
93
+ type: "down-line",
94
+ size: "small",
95
+ className: cls('bottom-text-icon')
96
+ }), "\u52A0\u8F7D\u66F4\u591A");
97
+ }
98
+
99
+ if (loadState === 'loading') {
100
+ return /*#__PURE__*/_react.default.createElement("div", {
101
+ className: cls('bottom-text')
102
+ }, /*#__PURE__*/_react.default.createElement(_icon.default, {
103
+ type: "loading-line",
104
+ size: "small",
105
+ className: cls('bottom-text-icon')
106
+ }), "\u52A0\u8F7D\u4E2D");
107
+ }
108
+
109
+ if (loadState === 'noMore') {
110
+ return /*#__PURE__*/_react.default.createElement("div", {
111
+ className: cls('bottom-text')
112
+ }, "\u6CA1\u6709\u66F4\u591A\u4E86");
113
+ }
114
+
115
+ return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null);
116
+ };
117
+
118
+ return /*#__PURE__*/_react.default.createElement("div", {
119
+ className: cls(),
120
+ style: {
121
+ height: scrollHeight !== null && scrollHeight !== void 0 ? scrollHeight : 'auto'
122
+ },
123
+ ref: scrollDom
124
+ }, children, renderLoadMore());
125
+ };
126
+
127
+ var _default = LoadMore;
128
+ exports.default = _default;
@@ -0,0 +1,19 @@
1
+ .teamix-pro-load-more {
2
+ overflow-y: auto;
3
+ overflow-x: hidden;
4
+
5
+ &-bottom-text {
6
+ text-align: center;
7
+ margin-top: 16px;
8
+ margin-bottom: 16px;
9
+ cursor: pointer;
10
+ color: var(--color-brand1-5);
11
+ display: flex;
12
+ align-items: center;
13
+ justify-content: center;
14
+ }
15
+
16
+ &-bottom-text-icon {
17
+ margin-right: 4px;
18
+ }
19
+ }
@@ -0,0 +1,7 @@
1
+ import { PaginationProps } from '@alicloudfe/components/types/pagination';
2
+ import { responsivePaginationType } from '../../typing';
3
+ import './index.scss';
4
+ declare const _default: (props: PaginationProps & {
5
+ responsivePaginationType?: responsivePaginationType;
6
+ }) => JSX.Element;
7
+ export default _default;
@@ -23,7 +23,11 @@ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "functio
23
23
 
24
24
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
25
25
 
26
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
26
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
27
+
28
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
29
+
30
+ function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
27
31
 
28
32
  function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
29
33
 
@@ -99,8 +103,8 @@ var _default = function _default(props) {
99
103
  onVisibleChange: function onVisibleChange(visible) {
100
104
  return setVisible(visible);
101
105
  },
102
- align: "t" // triggerType="click"
103
- ,
106
+ align: "t",
107
+ // triggerType="click"
104
108
  trigger: /*#__PURE__*/_react.default.createElement(_components.Button, {
105
109
  text: true,
106
110
  onMouseEnter: function onMouseEnter() {
@@ -199,8 +203,8 @@ var _default = function _default(props) {
199
203
  }
200
204
  }, "/"), getTotalPage(total, pageSize)), /*#__PURE__*/_react.default.createElement(_components.Button, {
201
205
  className: basePrefix('next', 'pagination-item'),
202
- onClick: handleNextClick //@ts-ignore
203
- ,
206
+ onClick: handleNextClick,
207
+ //@ts-ignore
204
208
  disabled: total && Number(currentPage) >= getTotalPage(total, pageSize)
205
209
  }, /*#__PURE__*/_react.default.createElement(_components.Icon, {
206
210
  size: "small",
@@ -211,7 +215,7 @@ var _default = function _default(props) {
211
215
  var renderMiniPagination = function renderMiniPagination() {
212
216
  if (total && pageSize) {
213
217
  if (total / pageSize <= 2) {
214
- return /*#__PURE__*/_react.default.createElement(_components.Pagination, _extends({}, commonPaginationProps, {
218
+ return /*#__PURE__*/_react.default.createElement(_components.Pagination, _objectSpread(_objectSpread({}, commonPaginationProps), {}, {
215
219
  type: "simple"
216
220
  }, otherProps));
217
221
  } else {
@@ -225,7 +229,7 @@ var _default = function _default(props) {
225
229
  var renderPagination = function renderPagination() {
226
230
  switch (responsivePaginationType || responsiveProps) {
227
231
  case 'normal':
228
- return /*#__PURE__*/_react.default.createElement(_components.Pagination, _extends({}, commonPaginationProps, {
232
+ return /*#__PURE__*/_react.default.createElement(_components.Pagination, _objectSpread(_objectSpread({}, commonPaginationProps), {}, {
229
233
  totalRender: function totalRender(total) {
230
234
  return (0, _utils.getMessage)('total', {
231
235
  total: new Intl.NumberFormat().format(total)
@@ -234,7 +238,7 @@ var _default = function _default(props) {
234
238
  }, otherProps));
235
239
 
236
240
  case 'simple':
237
- return /*#__PURE__*/_react.default.createElement(_components.Pagination, _extends({}, commonPaginationProps, {
241
+ return /*#__PURE__*/_react.default.createElement(_components.Pagination, _objectSpread(_objectSpread({}, commonPaginationProps), {}, {
238
242
  pageShowCount: 3,
239
243
  totalRender: function totalRender(total) {
240
244
  return (0, _utils.getMessage)('total', {
@@ -244,7 +248,7 @@ var _default = function _default(props) {
244
248
  }, otherProps));
245
249
 
246
250
  case 'small':
247
- return /*#__PURE__*/_react.default.createElement(_components.Pagination, _extends({}, commonPaginationProps, {
251
+ return /*#__PURE__*/_react.default.createElement(_components.Pagination, _objectSpread(_objectSpread({}, commonPaginationProps), {}, {
248
252
  pageShowCount: 3,
249
253
  pageSizeSelector: false,
250
254
  totalRender: function totalRender(total) {
@@ -256,7 +260,7 @@ var _default = function _default(props) {
256
260
  return renderMiniPagination();
257
261
 
258
262
  default:
259
- return /*#__PURE__*/_react.default.createElement(_components.Pagination, _extends({}, commonPaginationProps, otherProps));
263
+ return /*#__PURE__*/_react.default.createElement(_components.Pagination, _objectSpread(_objectSpread({}, commonPaginationProps), otherProps));
260
264
  }
261
265
  };
262
266
 
@@ -0,0 +1,11 @@
1
+ import React from 'react';
2
+ import { ProActionButtonProps } from '../../../actions';
3
+ import { ProTableActionType, innerRowSelectionType, rowSelectionType } from '../../typing';
4
+ interface QuickActionProps {
5
+ quickAction?: ProActionButtonProps | React.ReactNode | React.ReactNode[];
6
+ actionRef: React.MutableRefObject<ProTableActionType | undefined>;
7
+ rowSelection?: innerRowSelectionType | rowSelectionType;
8
+ dataTeamixSpm?: string;
9
+ }
10
+ declare const QuickAction: React.FC<QuickActionProps>;
11
+ export default QuickAction;
@@ -13,8 +13,6 @@ var _actions = _interopRequireDefault(require("../../../actions"));
13
13
 
14
14
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
15
15
 
16
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
17
-
18
16
  function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
19
17
 
20
18
  function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
@@ -36,10 +34,10 @@ var QuickAction = function QuickAction(props) {
36
34
  };
37
35
  return /*#__PURE__*/_react.default.createElement("div", {
38
36
  className: "teamix-pro-table-layout-quick-action"
39
- }, /*#__PURE__*/_react.default.createElement(_actions.default, _extends({
37
+ }, /*#__PURE__*/_react.default.createElement(_actions.default, _objectSpread(_objectSpread({
40
38
  type: "primary",
41
39
  text: true
42
- }, quickAction, {
40
+ }, quickAction), {}, {
43
41
  context: _objectSpread(_objectSpread({}, defaultContext), quickAction.context)
44
42
  })));
45
43
  }
@@ -0,0 +1,8 @@
1
+ /**
2
+ * 切换 table card 视角
3
+ */
4
+ import React from 'react';
5
+ import { ProTableLayoutProps } from '../../typing';
6
+ import './index.scss';
7
+ declare const CardSwitch: React.FC<ProTableLayoutProps>;
8
+ export default CardSwitch;
@@ -0,0 +1,82 @@
1
+ "use strict";
2
+
3
+ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
+
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
8
+ exports.default = void 0;
9
+
10
+ var _react = _interopRequireWildcard(require("react"));
11
+
12
+ var _components = require("@alicloudfe/components");
13
+
14
+ var _icon = _interopRequireDefault(require("@teamix/icon"));
15
+
16
+ var _utils = require("@teamix/utils");
17
+
18
+ require("./index.scss");
19
+
20
+ var _utils2 = require("../../utils");
21
+
22
+ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
23
+
24
+ function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
25
+
26
+ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
27
+
28
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
29
+
30
+ 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."); }
31
+
32
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
33
+
34
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; }
35
+
36
+ function _iterableToArrayLimit(arr, i) { var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"]; if (_i == null) return; var _arr = []; var _n = true; var _d = false; var _s, _e; try { for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; }
37
+
38
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
39
+
40
+ var RadioGroup = _components.Radio.Group;
41
+ var cls = (0, _utils.usePrefixCls)('teamix-pro-table-toolbar-switch-card');
42
+
43
+ var CardSwitch = function CardSwitch(props) {
44
+ var actionRef = props.actionRef,
45
+ defaultView = props.defaultView; // 选择视角
46
+
47
+ var _useState = (0, _react.useState)(defaultView !== null && defaultView !== void 0 ? defaultView : 'table'),
48
+ _useState2 = _slicedToArray(_useState, 2),
49
+ radioView = _useState2[0],
50
+ setRadioView = _useState2[1]; // 选择视角回调
51
+
52
+
53
+ var onRadioViewChange = function onRadioViewChange(value) {
54
+ var _actionRef$current, _actionRef$current$sw;
55
+
56
+ setRadioView(value);
57
+ (_actionRef$current = actionRef.current) === null || _actionRef$current === void 0 ? void 0 : (_actionRef$current$sw = _actionRef$current.switchView) === null || _actionRef$current$sw === void 0 ? void 0 : _actionRef$current$sw.call(_actionRef$current, value);
58
+ (0, _utils2.emit)('cardSwitchChange', value);
59
+ };
60
+
61
+ return /*#__PURE__*/_react.default.createElement(RadioGroup, {
62
+ shape: "button",
63
+ value: radioView,
64
+ onChange: onRadioViewChange,
65
+ className: cls()
66
+ }, /*#__PURE__*/_react.default.createElement(_components.Radio, {
67
+ id: "banana",
68
+ value: "table"
69
+ }, /*#__PURE__*/_react.default.createElement(_icon.default, {
70
+ type: "menu-line",
71
+ size: "small"
72
+ })), /*#__PURE__*/_react.default.createElement(_components.Radio, {
73
+ id: "watermelon",
74
+ value: "card"
75
+ }, /*#__PURE__*/_react.default.createElement(_icon.default, {
76
+ type: "all-line",
77
+ size: "small"
78
+ })));
79
+ };
80
+
81
+ var _default = CardSwitch;
82
+ exports.default = _default;
@@ -0,0 +1,4 @@
1
+ import { ProTableLayoutProps } from '../../typing';
2
+ import './index.scss';
3
+ declare const DensityIcon: (props: ProTableLayoutProps) => JSX.Element;
4
+ export default DensityIcon;
@@ -86,6 +86,7 @@ var DensityIcon = function DensityIcon(props) {
86
86
  var renderDropdown = function renderDropdown() {
87
87
  return /*#__PURE__*/_react.default.createElement("span", null, /*#__PURE__*/_react.default.createElement(_components.Dropdown // safeNode={() => sizeMenuRef.current || document}
88
88
  , {
89
+ // safeNode={() => sizeMenuRef.current || document}
89
90
  trigger: /*#__PURE__*/_react.default.createElement(_components.Button, {
90
91
  iconSize: "small",
91
92
  className: cls()
@@ -99,8 +100,8 @@ var DensityIcon = function DensityIcon(props) {
99
100
  setTooltipVisible(false);
100
101
  setDropdownVisible(state);
101
102
  },
102
- triggerType: ['click'] // key={index}
103
- ,
103
+ triggerType: ['click'],
104
+ // key={index}
104
105
  align: "tr br"
105
106
  }, /*#__PURE__*/_react.default.createElement("div", null, /*#__PURE__*/_react.default.createElement(_components.Menu, null, /*#__PURE__*/_react.default.createElement(RadioItem, {
106
107
  key: "medium",
@@ -0,0 +1,4 @@
1
+ import { ProTableLayoutProps } from '../../typing';
2
+ import './index.scss';
3
+ declare const FilterColumnIcon: (props: ProTableLayoutProps) => JSX.Element;
4
+ export default FilterColumnIcon;
@@ -109,7 +109,13 @@ var FilterColumnIcon = function FilterColumnIcon(props) {
109
109
  var _useState9 = (0, _react.useState)(false),
110
110
  _useState10 = _slicedToArray(_useState9, 2),
111
111
  dropdownVisible = _useState10[0],
112
- setDropdownVisible = _useState10[1];
112
+ setDropdownVisible = _useState10[1]; // 视角
113
+
114
+
115
+ var _useState11 = (0, _react.useState)('table'),
116
+ _useState12 = _slicedToArray(_useState11, 2),
117
+ cardView = _useState12[0],
118
+ setCardView = _useState12[1];
113
119
 
114
120
  (0, _react.useEffect)(function () {
115
121
  _utils2.on === null || _utils2.on === void 0 ? void 0 : (0, _utils2.on)(function (stateFilterColumns) {
@@ -127,8 +133,12 @@ var FilterColumnIcon = function FilterColumnIcon(props) {
127
133
  setNewColumns(stateColumns);
128
134
  }
129
135
  }, 'refreshFilterState');
136
+ _utils2.on === null || _utils2.on === void 0 ? void 0 : (0, _utils2.on)(function (view) {
137
+ setCardView(view);
138
+ }, 'cardSwitchChange');
130
139
  return function () {
131
140
  (0, _utils2.off)('refreshFilterState');
141
+ (0, _utils2.off)('cardSwitchChange');
132
142
  };
133
143
  });
134
144
  (0, _react.useEffect)(function () {
@@ -295,7 +305,8 @@ var FilterColumnIcon = function FilterColumnIcon(props) {
295
305
  }, /*#__PURE__*/_react.default.createElement(CheckboxItem, {
296
306
  indeterminate: indeterminate,
297
307
  checked: allVisible,
298
- onChange: onChangeAllColumns
308
+ onChange: onChangeAllColumns,
309
+ disabled: cardView === 'card'
299
310
  }, (0, _utils.getMessage)('selectAll'), /*#__PURE__*/_react.default.createElement(_components.Button, {
300
311
  onClick: restColumns,
301
312
  className: cls({
@@ -0,0 +1,4 @@
1
+ import { ProTableLayoutProps } from '../../typing';
2
+ import './index.scss';
3
+ declare const FullScreenIcon: (props: ProTableLayoutProps) => JSX.Element;
4
+ export default FullScreenIcon;
@@ -0,0 +1,10 @@
1
+ import React from 'react';
2
+ import './index.scss';
3
+ import { ProTableActionType } from '../../typing';
4
+ declare type ProTableFullScreenProps = {
5
+ children: (isFullScreen: boolean) => React.ReactNode | React.ReactNode;
6
+ visible: boolean;
7
+ actionRef: React.MutableRefObject<ProTableActionType | undefined>;
8
+ };
9
+ declare const FullScreen: React.FC<ProTableFullScreenProps>;
10
+ export default FullScreen;
@@ -45,6 +45,8 @@ var FullScreen = function FullScreen(props) {
45
45
  }, [visible, actionRef]);
46
46
 
47
47
  var afterClose = function afterClose() {
48
+ var _document;
49
+
48
50
  // 判断全屏前后筛选表单值是否有改变
49
51
  var n = JSON.stringify((0, _utils.getValidValues)(normalDataFilterForm === null || normalDataFilterForm === void 0 ? void 0 : normalDataFilterForm.values));
50
52
  var f = JSON.stringify((0, _utils.getValidValues)(fullscreenDataFilterForm === null || fullscreenDataFilterForm === void 0 ? void 0 : fullscreenDataFilterForm.values));
@@ -58,11 +60,17 @@ var FullScreen = function FullScreen(props) {
58
60
  } // 关闭全屏后,关闭全屏表单onFilter
59
61
 
60
62
 
61
- filterEnableRef.current.fullscreen = false;
63
+ filterEnableRef.current.fullscreen = false; // 移除类名
64
+
65
+ if (document && ((_document = document) === null || _document === void 0 ? void 0 : _document.body)) {
66
+ document.body.classList.remove('teamix-pro-table-fullscreen');
67
+ }
62
68
  }; // 全屏开启之后
63
69
 
64
70
 
65
71
  var afterOpen = function afterOpen() {
72
+ var _document2;
73
+
66
74
  // 判断全屏前后筛选表单值是否有改变
67
75
  var n = JSON.stringify((0, _utils.getValidValues)(normalDataFilterForm === null || normalDataFilterForm === void 0 ? void 0 : normalDataFilterForm.values));
68
76
  var f = JSON.stringify((0, _utils.getValidValues)(fullscreenDataFilterForm === null || fullscreenDataFilterForm === void 0 ? void 0 : fullscreenDataFilterForm.values));
@@ -76,7 +84,12 @@ var FullScreen = function FullScreen(props) {
76
84
  } // 全屏后,关闭普通表单onFilter
77
85
 
78
86
 
79
- filterEnableRef.current.normal = false; // 消息提示
87
+ filterEnableRef.current.normal = false; // 为 body 添加类名,用于判断是否全屏
88
+
89
+ if (document && ((_document2 = document) === null || _document2 === void 0 ? void 0 : _document2.body)) {
90
+ document.body.classList.add('teamix-pro-table-fullscreen');
91
+ } // 消息提示
92
+
80
93
 
81
94
  _components.Message.show({
82
95
  type: 'notice',
@@ -0,0 +1,4 @@
1
+ import { ProTableLayoutProps } from '../../typing';
2
+ import './index.scss';
3
+ declare const LayoutIcon: (props: ProTableLayoutProps) => JSX.Element;
4
+ export default LayoutIcon;
@@ -52,8 +52,7 @@ var LayoutIcon = function LayoutIcon(props) {
52
52
  size: "small",
53
53
  type: "refresh-line"
54
54
  })),
55
- align: "t" // align={fullscreen ? 'b' : 't'}
56
-
55
+ align: "t"
57
56
  }, (0, _utils.getMessage)('refresh'));
58
57
  };
59
58
 
@@ -0,0 +1,5 @@
1
+ import React from 'react';
2
+ import { ProTableLayoutProps } from '../../typing';
3
+ import './index.scss';
4
+ declare const ToolBar: React.FC<ProTableLayoutProps>;
5
+ export default ToolBar;