@pisell/materials 6.11.10 → 6.11.12

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 (229) hide show
  1. package/build/lowcode/assets-daily.json +11 -11
  2. package/build/lowcode/assets-dev.json +2 -2
  3. package/build/lowcode/assets-prod.json +11 -11
  4. package/build/lowcode/index.js +1 -1
  5. package/build/lowcode/meta.js +7 -7
  6. package/build/lowcode/preview.js +9 -9
  7. package/build/lowcode/render/default/view.css +1 -1
  8. package/build/lowcode/render/default/view.js +21 -21
  9. package/build/lowcode/view.css +1 -1
  10. package/build/lowcode/view.js +18 -18
  11. package/es/components/PisellCards/components/MultilevelCard/components/PanelWrapper.d.ts +7 -0
  12. package/es/components/PisellProcedure/PisellProcedure.d.ts +22 -0
  13. package/es/components/PisellProcedure/PisellProcedure.stories.d.ts +163 -0
  14. package/es/components/PisellProcedure/components/ProcedureBody.d.ts +41 -0
  15. package/es/components/PisellProcedure/components/ProcedureFooter.d.ts +38 -0
  16. package/es/components/PisellProcedure/components/ProcedureHeader.d.ts +34 -0
  17. package/es/components/PisellProcedure/components/index.d.ts +12 -0
  18. package/es/components/PisellProcedure/index.d.ts +5 -0
  19. package/es/components/PisellSuperTabs/PisellSuperTabs.d.ts +8 -0
  20. package/es/components/PisellSuperTabs/hooks/index.d.ts +1 -0
  21. package/es/components/PisellSuperTabs/hooks/useTabsState.d.ts +7 -0
  22. package/es/components/PisellSuperTabs/index.d.ts +3 -0
  23. package/es/components/PisellSuperTabs/types.d.ts +212 -0
  24. package/es/components/PisellTabbar/constants.d.ts +47 -0
  25. package/es/components/PisellTabbar/hooks/index.d.ts +2 -0
  26. package/es/components/PisellTabbar/hooks/useActiveKey.d.ts +55 -0
  27. package/es/components/PisellTabbar/hooks/useExpand.d.ts +42 -0
  28. package/es/components/PisellTabbar/template/Template1/constants.d.ts +10 -0
  29. package/es/components/PisellTabbar/template/Template1/utils/index.d.ts +35 -0
  30. package/es/components/PisellTabbar/types.d.ts +90 -0
  31. package/es/components/PisellTabbar/utils/index.d.ts +69 -0
  32. package/es/components/dataSourceComponents/dataSourceForm/utils.d.ts +1 -1
  33. package/es/components/dataSourceComponents/dataSourceTable/hooks/useDrawerState.d.ts +1 -0
  34. package/es/components/dataSourceComponents/dataSourceTable/hooks/useTableProps.d.ts +3 -3
  35. package/es/components/dataSourceComponents/fields/Input.Mobile/serve.d.ts +26 -0
  36. package/es/components/dataSourceComponents/fields/Input.Subdomain/index.d.ts +1 -1
  37. package/es/components/dataSourceComponents/fields/Select/index.d.ts +1 -1
  38. package/es/components/dataSourceComponents/fields/Translation/BaseTranslation.d.ts +5 -0
  39. package/es/components/dataSourceComponents/fields/Translation/type.d.ts +21 -0
  40. package/es/components/dataSourceComponents/fields/index.d.ts +15 -15
  41. package/es/components/dataSourceComponents/provider/variables/VariablesContext.d.ts +15 -0
  42. package/es/components/drag-sort-tree/TreeItem/index.d.ts +19 -0
  43. package/es/components/pisellAdjustPrice/status.d.ts +32 -0
  44. package/es/components/pisellDateTimeDisplay/PisellDateTimeDisplay.js +0 -2
  45. package/es/components/pisellDateTimeDisplay/formats/dateTimeDisplayFormats.js +5 -5
  46. package/es/components/pisellGridPro/index.d.ts +4 -0
  47. package/es/components/pisellLookup/components/LookupTrigger.d.ts +3 -0
  48. package/es/components/pisellLookup/components/LookupTrigger.js +16 -13
  49. package/es/components/pisellMetricCard/PisellMetricCard.stories.d.ts +17 -0
  50. package/es/components/pisellMetricCard/components/index.d.ts +7 -0
  51. package/es/components/pisellMetricCard/index.d.ts +6 -0
  52. package/es/components/pisellMultipleSelect/PisellMultipleSelect.less +15 -7
  53. package/es/components/pisellRecordBoard/PisellRecordBoard.js +47 -14
  54. package/es/components/pisellRecordBoard/PisellRecordBoard.stories.d.ts +8 -0
  55. package/es/components/pisellRecordBoard/PisellRecordBoard.stories.js +482 -249
  56. package/es/components/pisellRecordBoard/layouts/GridLayout/Grid.js +121 -16
  57. package/es/components/pisellRecordBoard/layouts/GridLayout/Grid.less +38 -0
  58. package/es/components/pisellRecordBoard/shellFrame/ColumnSetting/ColumnSettingPopover.d.ts +4 -2
  59. package/es/components/pisellRecordBoard/shellFrame/ColumnSetting/ColumnSettingPopover.js +92 -13
  60. package/es/components/pisellRecordBoard/shellFrame/ColumnSetting/index.js +7 -3
  61. package/es/components/pisellRecordBoard/shellFrame/Pagination/index.js +1 -1
  62. package/es/components/pisellRecordBoard/shellFrame/ToolBar/index.js +9 -3
  63. package/es/components/pisellRecordBoard/shellFrame/ToolBarReset/index.js +6 -2
  64. package/es/components/pisellRecordBoard/utils/recordBoardColumns.d.ts +21 -0
  65. package/es/components/pisellRecordBoard/utils/recordBoardColumns.js +112 -15
  66. package/es/components/pisellSingleSelect/PisellSingleSelect.less +15 -0
  67. package/es/components/pisellSort/index.d.ts +4 -0
  68. package/es/components/pisellStatisticList/index.d.ts +22 -0
  69. package/es/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.js +2 -2
  70. package/es/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.stories.d.ts +61 -0
  71. package/es/components/pisellTimeRangeDisplay/index.d.ts +3 -0
  72. package/es/components/productCard/cartSkuCard/components/Gift/index.d.ts +5 -0
  73. package/es/components/productCard/cartSkuCard/components/Gift/index.js +60 -0
  74. package/es/components/productCard/cartSkuCard/components/Gift/index.less +84 -0
  75. package/es/components/productCard/cartSkuCard/components/Gift/types.d.ts +29 -0
  76. package/es/components/productCard/cartSkuCard/components/Gift/types.js +1 -0
  77. package/es/components/productCard/cartSkuCard/components/Promotion/index.d.ts +7 -0
  78. package/es/components/productCard/cartSkuCard/components/Promotion/index.js +24 -0
  79. package/es/components/productCard/cartSkuCard/components/Promotion/index.less +16 -0
  80. package/es/components/productCard/cartSkuCard/components/basicInfo/index.d.ts +4 -0
  81. package/es/components/productCard/cartSkuCard/components/basicInfo/index.js +41 -6
  82. package/es/components/productCard/cartSkuCard/components/basicInfo/index.less +66 -1
  83. package/es/components/productCard/cartSkuCard/components/packages/index.js +1 -0
  84. package/es/components/productCard/cartSkuCard/index.d.ts +1 -1
  85. package/es/components/productCard/cartSkuCard/index.js +44 -7
  86. package/es/components/productCard/cartSkuCard/locales.d.ts +178 -0
  87. package/es/components/productCard/cartSkuCard/locales.js +30 -5
  88. package/es/components/productCard/components/Header/EditButton/index.d.ts +1 -1
  89. package/es/components/productCard/components/Header/EditButton/index.js +3 -1
  90. package/es/components/productCard/status.d.ts +32 -0
  91. package/es/components/productCard/status.js +3 -0
  92. package/es/components/productCard/types.d.ts +95 -0
  93. package/es/components/select/index.d.ts +9 -0
  94. package/es/components/select/index.less +18 -2
  95. package/es/components/table/Table/fields/image/index.d.ts +1 -0
  96. package/es/components/table/Table/fields/pSwitch/index.d.ts +1 -0
  97. package/es/components/table/Table/fields/select/Edit/index.d.ts +4 -0
  98. package/es/components/table/Table/utils.d.ts +1 -1
  99. package/es/components/virtual-keyboard/Amount/themeConfig.d.ts +32 -0
  100. package/es/components/virtual-keyboard/Keyboard/index.d.ts +21 -0
  101. package/es/components/virtual-keyboard/Number/themeConfig.d.ts +32 -0
  102. package/es/components/virtual-keyboard/VirtualKeyInput/index.d.ts +13 -0
  103. package/es/components/virtualInput/BaseVirtualInput/index.less +2 -2
  104. package/es/components/virtualInput/index.js +6 -2
  105. package/es/hooks/useThemeTokens.js +20 -0
  106. package/es/index.d.ts +1 -0
  107. package/es/locales/en-US.d.ts +2 -0
  108. package/es/locales/en-US.js +2 -0
  109. package/es/locales/ja.d.ts +2 -0
  110. package/es/locales/ja.js +2 -0
  111. package/es/locales/pt.d.ts +2 -0
  112. package/es/locales/pt.js +2 -0
  113. package/es/locales/zh-CN.d.ts +2 -0
  114. package/es/locales/zh-CN.js +2 -0
  115. package/es/locales/zh-TW.d.ts +2 -0
  116. package/es/locales/zh-TW.js +2 -0
  117. package/lib/components/PisellCards/components/MultilevelCard/components/PanelWrapper.d.ts +7 -0
  118. package/lib/components/PisellProcedure/PisellProcedure.d.ts +22 -0
  119. package/lib/components/PisellProcedure/PisellProcedure.stories.d.ts +163 -0
  120. package/lib/components/PisellProcedure/components/ProcedureBody.d.ts +41 -0
  121. package/lib/components/PisellProcedure/components/ProcedureFooter.d.ts +38 -0
  122. package/lib/components/PisellProcedure/components/ProcedureHeader.d.ts +34 -0
  123. package/lib/components/PisellProcedure/components/index.d.ts +12 -0
  124. package/lib/components/PisellProcedure/index.d.ts +5 -0
  125. package/lib/components/PisellSuperTabs/PisellSuperTabs.d.ts +8 -0
  126. package/lib/components/PisellSuperTabs/hooks/index.d.ts +1 -0
  127. package/lib/components/PisellSuperTabs/hooks/useTabsState.d.ts +7 -0
  128. package/lib/components/PisellSuperTabs/index.d.ts +3 -0
  129. package/lib/components/PisellSuperTabs/types.d.ts +212 -0
  130. package/lib/components/PisellTabbar/constants.d.ts +47 -0
  131. package/lib/components/PisellTabbar/hooks/index.d.ts +2 -0
  132. package/lib/components/PisellTabbar/hooks/useActiveKey.d.ts +55 -0
  133. package/lib/components/PisellTabbar/hooks/useExpand.d.ts +42 -0
  134. package/lib/components/PisellTabbar/template/Template1/constants.d.ts +10 -0
  135. package/lib/components/PisellTabbar/template/Template1/utils/index.d.ts +35 -0
  136. package/lib/components/PisellTabbar/types.d.ts +90 -0
  137. package/lib/components/PisellTabbar/utils/index.d.ts +69 -0
  138. package/lib/components/dataSourceComponents/dataSourceForm/utils.d.ts +1 -1
  139. package/lib/components/dataSourceComponents/dataSourceTable/hooks/useDrawerState.d.ts +1 -0
  140. package/lib/components/dataSourceComponents/dataSourceTable/hooks/useTableProps.d.ts +3 -3
  141. package/lib/components/dataSourceComponents/fields/Input.Mobile/serve.d.ts +26 -0
  142. package/lib/components/dataSourceComponents/fields/Input.Subdomain/index.d.ts +1 -1
  143. package/lib/components/dataSourceComponents/fields/Select/index.d.ts +1 -1
  144. package/lib/components/dataSourceComponents/fields/Translation/BaseTranslation.d.ts +5 -0
  145. package/lib/components/dataSourceComponents/fields/Translation/type.d.ts +21 -0
  146. package/lib/components/dataSourceComponents/fields/index.d.ts +15 -15
  147. package/lib/components/dataSourceComponents/provider/variables/VariablesContext.d.ts +15 -0
  148. package/lib/components/drag-sort-tree/TreeItem/index.d.ts +19 -0
  149. package/lib/components/pisellAdjustPrice/status.d.ts +32 -0
  150. package/lib/components/pisellDateTimeDisplay/PisellDateTimeDisplay.js +0 -2
  151. package/lib/components/pisellDateTimeDisplay/formats/dateTimeDisplayFormats.js +3 -3
  152. package/lib/components/pisellGridPro/index.d.ts +4 -0
  153. package/lib/components/pisellLookup/components/LookupTrigger.d.ts +3 -0
  154. package/lib/components/pisellLookup/components/LookupTrigger.js +8 -8
  155. package/lib/components/pisellMetricCard/PisellMetricCard.stories.d.ts +17 -0
  156. package/lib/components/pisellMetricCard/components/index.d.ts +7 -0
  157. package/lib/components/pisellMetricCard/index.d.ts +6 -0
  158. package/lib/components/pisellMultipleSelect/PisellMultipleSelect.less +15 -7
  159. package/lib/components/pisellRecordBoard/PisellRecordBoard.js +39 -9
  160. package/lib/components/pisellRecordBoard/PisellRecordBoard.stories.d.ts +8 -0
  161. package/lib/components/pisellRecordBoard/PisellRecordBoard.stories.js +159 -0
  162. package/lib/components/pisellRecordBoard/layouts/GridLayout/Grid.js +94 -9
  163. package/lib/components/pisellRecordBoard/layouts/GridLayout/Grid.less +38 -0
  164. package/lib/components/pisellRecordBoard/shellFrame/ColumnSetting/ColumnSettingPopover.d.ts +4 -2
  165. package/lib/components/pisellRecordBoard/shellFrame/ColumnSetting/ColumnSettingPopover.js +88 -3
  166. package/lib/components/pisellRecordBoard/shellFrame/ColumnSetting/index.js +6 -2
  167. package/lib/components/pisellRecordBoard/shellFrame/Pagination/index.js +1 -1
  168. package/lib/components/pisellRecordBoard/shellFrame/ToolBar/index.js +9 -1
  169. package/lib/components/pisellRecordBoard/shellFrame/ToolBarReset/index.js +3 -2
  170. package/lib/components/pisellRecordBoard/utils/recordBoardColumns.d.ts +21 -0
  171. package/lib/components/pisellRecordBoard/utils/recordBoardColumns.js +60 -0
  172. package/lib/components/pisellSingleSelect/PisellSingleSelect.less +15 -0
  173. package/lib/components/pisellSort/index.d.ts +4 -0
  174. package/lib/components/pisellStatisticList/index.d.ts +22 -0
  175. package/lib/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.js +1 -1
  176. package/lib/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.stories.d.ts +61 -0
  177. package/lib/components/pisellTimeRangeDisplay/index.d.ts +3 -0
  178. package/lib/components/productCard/cartSkuCard/components/Gift/index.d.ts +5 -0
  179. package/lib/components/productCard/cartSkuCard/components/Gift/index.js +62 -0
  180. package/lib/components/productCard/cartSkuCard/components/Gift/index.less +84 -0
  181. package/lib/components/productCard/cartSkuCard/components/Gift/types.d.ts +29 -0
  182. package/lib/components/productCard/cartSkuCard/components/Gift/types.js +17 -0
  183. package/lib/components/productCard/cartSkuCard/components/Promotion/index.d.ts +7 -0
  184. package/lib/components/productCard/cartSkuCard/components/Promotion/index.js +63 -0
  185. package/lib/components/productCard/cartSkuCard/components/Promotion/index.less +16 -0
  186. package/lib/components/productCard/cartSkuCard/components/basicInfo/index.d.ts +4 -0
  187. package/lib/components/productCard/cartSkuCard/components/basicInfo/index.js +20 -3
  188. package/lib/components/productCard/cartSkuCard/components/basicInfo/index.less +66 -1
  189. package/lib/components/productCard/cartSkuCard/components/packages/index.js +1 -1
  190. package/lib/components/productCard/cartSkuCard/index.d.ts +1 -1
  191. package/lib/components/productCard/cartSkuCard/index.js +42 -6
  192. package/lib/components/productCard/cartSkuCard/locales.d.ts +178 -0
  193. package/lib/components/productCard/cartSkuCard/locales.js +20 -5
  194. package/lib/components/productCard/components/Header/EditButton/index.d.ts +1 -1
  195. package/lib/components/productCard/components/Header/EditButton/index.js +2 -1
  196. package/lib/components/productCard/status.d.ts +32 -0
  197. package/lib/components/productCard/status.js +3 -0
  198. package/lib/components/productCard/types.d.ts +95 -0
  199. package/lib/components/select/index.d.ts +9 -0
  200. package/lib/components/select/index.less +18 -2
  201. package/lib/components/table/Table/fields/image/index.d.ts +1 -0
  202. package/lib/components/table/Table/fields/pSwitch/index.d.ts +1 -0
  203. package/lib/components/table/Table/fields/select/Edit/index.d.ts +4 -0
  204. package/lib/components/table/Table/utils.d.ts +1 -1
  205. package/lib/components/virtual-keyboard/Amount/themeConfig.d.ts +32 -0
  206. package/lib/components/virtual-keyboard/Keyboard/index.d.ts +21 -0
  207. package/lib/components/virtual-keyboard/Number/themeConfig.d.ts +32 -0
  208. package/lib/components/virtual-keyboard/VirtualKeyInput/index.d.ts +13 -0
  209. package/lib/components/virtualInput/BaseVirtualInput/index.less +2 -2
  210. package/lib/components/virtualInput/index.js +7 -1
  211. package/lib/hooks/useThemeTokens.js +40 -0
  212. package/lib/index.d.ts +1 -0
  213. package/lib/locales/en-US.d.ts +2 -0
  214. package/lib/locales/en-US.js +2 -0
  215. package/lib/locales/ja.d.ts +2 -0
  216. package/lib/locales/ja.js +2 -0
  217. package/lib/locales/pt.d.ts +2 -0
  218. package/lib/locales/pt.js +2 -0
  219. package/lib/locales/zh-CN.d.ts +2 -0
  220. package/lib/locales/zh-CN.js +2 -0
  221. package/lib/locales/zh-TW.d.ts +2 -0
  222. package/lib/locales/zh-TW.js +2 -0
  223. package/package.json +3 -3
  224. package/es/components/pisellDateTimeDisplay/formats/dateTimeDisplayFormats.d.ts +0 -7
  225. package/es/components/pisellDateTimeDisplay/formats/index.d.ts +0 -1
  226. package/es/components/virtualInput/index.d.ts +0 -24
  227. package/lib/components/pisellDateTimeDisplay/formats/dateTimeDisplayFormats.d.ts +0 -7
  228. package/lib/components/pisellDateTimeDisplay/formats/index.d.ts +0 -1
  229. package/lib/components/virtualInput/index.d.ts +0 -24
@@ -36,10 +36,12 @@ __export(PisellRecordBoard_stories_exports, {
36
36
  GridLayoutFull: () => GridLayoutFull,
37
37
  GridLayoutToolBarSearchInput: () => GridLayoutToolBarSearchInput,
38
38
  GridLayoutToolBarSortAndFilter: () => GridLayoutToolBarSortAndFilter,
39
+ GridLayoutWithCollapseUniformColumns: () => GridLayoutWithCollapseUniformColumns,
39
40
  GridLayoutWithColumnType: () => GridLayoutWithColumnType,
40
41
  GridLayoutWithPisellFindInToolBar: () => GridLayoutWithPisellFindInToolBar,
41
42
  GridLayoutWithQuickFilterOnLeft: () => GridLayoutWithQuickFilterOnLeft,
42
43
  GridLayoutWithTable: () => GridLayoutWithTable,
44
+ GridLayoutWithUniformCompare: () => GridLayoutWithUniformCompare,
43
45
  GridWithMultiplePages: () => GridWithMultiplePages,
44
46
  GridWithOnRow: () => GridWithOnRow,
45
47
  Placeholder: () => Placeholder,
@@ -542,6 +544,161 @@ var GridWithMultiplePages = {
542
544
  ));
543
545
  }
544
546
  };
547
+ var GridLayoutWithCollapseUniformColumns = {
548
+ parameters: {
549
+ docs: {
550
+ description: {
551
+ story: "grid.collapseUniformColumns: true 时,当前页某列全部同值或全部为空则隐藏该列,在表格上方显示总结区。本示例数据当前页「支付状态」均为已支付、「备注」均为空,故两列折叠并出现在总结区。"
552
+ }
553
+ }
554
+ },
555
+ render: function GridLayoutWithCollapseUniformColumnsRender() {
556
+ const [pageNumber, setPageNumber] = (0, import_react.useState)(1);
557
+ const [pageSize, setPageSize] = (0, import_react.useState)(10);
558
+ const [selectedKeys, setSelectedKeys] = (0, import_react.useState)([]);
559
+ const [selectedRows, setSelectedRows] = (0, import_react.useState)([]);
560
+ const uniformData = (0, import_react.useMemo)(
561
+ () => Array.from({ length: 8 }, (_, i) => ({
562
+ id: `u-${i + 1}`,
563
+ orderNo: `U${String(10001 + i).padStart(6, "0")}`,
564
+ payStatus: "paid",
565
+ amount: 100 + i * 10,
566
+ note: ""
567
+ })),
568
+ []
569
+ );
570
+ const total = uniformData.length;
571
+ const data = (0, import_react.useMemo)(() => {
572
+ const start = (pageNumber - 1) * pageSize;
573
+ return uniformData.slice(start, start + pageSize);
574
+ }, [pageNumber, pageSize, uniformData]);
575
+ const columnsUniform = [
576
+ { title: "订单号", dataIndex: "orderNo", key: "orderNo", width: 140 },
577
+ { title: "支付状态", dataIndex: "payStatus", key: "payStatus", width: 120 },
578
+ { title: "订单金额", dataIndex: "amount", key: "amount", width: 120 },
579
+ { title: "备注", dataIndex: "note", key: "note", width: 160 }
580
+ ];
581
+ const value = (0, import_react.useMemo)(
582
+ () => ({
583
+ data,
584
+ loading: false,
585
+ total,
586
+ pagination: { pageNumber, pageSize },
587
+ onPageChange: (num, size) => {
588
+ setPageNumber(num);
589
+ setPageSize(size);
590
+ },
591
+ searchParams: {},
592
+ onSearch: () => {
593
+ },
594
+ onReset: () => {
595
+ },
596
+ layoutType: "grid",
597
+ rowKey: "id"
598
+ }),
599
+ [data, total, pageNumber, pageSize]
600
+ );
601
+ return /* @__PURE__ */ import_react.default.createElement("div", { style: { padding: 16, background: "#f5f5f5", minHeight: 400 } }, /* @__PURE__ */ import_react.default.createElement(
602
+ import_index.default,
603
+ {
604
+ rowKey: "id",
605
+ ...value,
606
+ grid: {
607
+ columns: columnsUniform,
608
+ scroll: { x: 600 },
609
+ collapseUniformColumns: true,
610
+ selectedKeys,
611
+ selectedRows,
612
+ onSelectionChange: (keys, rows) => {
613
+ setSelectedKeys(keys);
614
+ setSelectedRows(rows);
615
+ }
616
+ }
617
+ },
618
+ /* @__PURE__ */ import_react.default.createElement(import_index.default.ShellFrame, null, /* @__PURE__ */ import_react.default.createElement(import_index.default.GridLayout, null))
619
+ ));
620
+ }
621
+ };
622
+ var GridLayoutWithUniformCompare = {
623
+ parameters: {
624
+ docs: {
625
+ description: {
626
+ story: "列「支付分类」的 dataIndex 取值为对象 { id, name }。通过 uniformCompare(value, record) 返回 String(value.id) 参与比较,当前页全部为同一 id 时该列折叠,总结区优先用列 render 展示(如「已支付」)。"
627
+ }
628
+ }
629
+ },
630
+ render: function GridLayoutWithUniformCompareRender() {
631
+ const [pageNumber, setPageNumber] = (0, import_react.useState)(1);
632
+ const [pageSize, setPageSize] = (0, import_react.useState)(10);
633
+ const [selectedKeys, setSelectedKeys] = (0, import_react.useState)([]);
634
+ const [selectedRows, setSelectedRows] = (0, import_react.useState)([]);
635
+ const uniformCompareData = (0, import_react.useMemo)(
636
+ () => Array.from({ length: 6 }, (_, i) => ({
637
+ id: `uc-${i + 1}`,
638
+ orderNo: `UC${String(20001 + i).padStart(6, "0")}`,
639
+ payCategory: { id: 1, name: "已支付" },
640
+ amount: 50 + i * 5
641
+ })),
642
+ []
643
+ );
644
+ const total = uniformCompareData.length;
645
+ const data = (0, import_react.useMemo)(() => {
646
+ const start = (pageNumber - 1) * pageSize;
647
+ return uniformCompareData.slice(start, start + pageSize);
648
+ }, [pageNumber, pageSize, uniformCompareData]);
649
+ const columnsWithUniformCompare = [
650
+ { title: "订单号", dataIndex: "orderNo", key: "orderNo", width: 140 },
651
+ {
652
+ title: "支付分类",
653
+ dataIndex: "payCategory",
654
+ key: "payCategory",
655
+ width: 120,
656
+ uniformCompare: (value2) => value2 != null && typeof value2 === "object" && "id" in value2 && value2.id != null ? String(value2.id) : void 0,
657
+ render: (value2) => (value2 == null ? void 0 : value2.name) != null ? value2.name : "-"
658
+ },
659
+ { title: "订单金额", dataIndex: "amount", key: "amount", width: 120 }
660
+ ];
661
+ const value = (0, import_react.useMemo)(
662
+ () => ({
663
+ data,
664
+ loading: false,
665
+ total,
666
+ pagination: { pageNumber, pageSize },
667
+ onPageChange: (num, size) => {
668
+ setPageNumber(num);
669
+ setPageSize(size);
670
+ },
671
+ searchParams: {},
672
+ onSearch: () => {
673
+ },
674
+ onReset: () => {
675
+ },
676
+ layoutType: "grid",
677
+ rowKey: "id"
678
+ }),
679
+ [data, total, pageNumber, pageSize]
680
+ );
681
+ return /* @__PURE__ */ import_react.default.createElement("div", { style: { padding: 16, background: "#f5f5f5", minHeight: 400 } }, /* @__PURE__ */ import_react.default.createElement(
682
+ import_index.default,
683
+ {
684
+ rowKey: "id",
685
+ ...value,
686
+ grid: {
687
+ columns: columnsWithUniformCompare,
688
+ scroll: { x: 450 },
689
+ collapseUniformColumns: true,
690
+ selectedKeys,
691
+ selectedRows,
692
+ onSelectionChange: (keys, rows) => {
693
+ setSelectedKeys(keys);
694
+ setSelectedRows(rows);
695
+ }
696
+ }
697
+ },
698
+ /* @__PURE__ */ import_react.default.createElement(import_index.default.ShellFrame, null, /* @__PURE__ */ import_react.default.createElement(import_index.default.GridLayout, null))
699
+ ));
700
+ }
701
+ };
545
702
  var GridWithOnRow = {
546
703
  parameters: {
547
704
  docs: {
@@ -1502,10 +1659,12 @@ var SearchAndGridOnly = {
1502
1659
  GridLayoutFull,
1503
1660
  GridLayoutToolBarSearchInput,
1504
1661
  GridLayoutToolBarSortAndFilter,
1662
+ GridLayoutWithCollapseUniformColumns,
1505
1663
  GridLayoutWithColumnType,
1506
1664
  GridLayoutWithPisellFindInToolBar,
1507
1665
  GridLayoutWithQuickFilterOnLeft,
1508
1666
  GridLayoutWithTable,
1667
+ GridLayoutWithUniformCompare,
1509
1668
  GridWithMultiplePages,
1510
1669
  GridWithOnRow,
1511
1670
  Placeholder,
@@ -36,6 +36,7 @@ var import_react = __toESM(require("react"));
36
36
  var import_antd = require("antd");
37
37
  var import_useRecordBoardContext = require("../../hooks/useRecordBoardContext");
38
38
  var import_recordBoardColumns = require("../../utils/recordBoardColumns");
39
+ var import_locales = require("../../../../locales");
39
40
  var import_Grid = require("./Grid.less");
40
41
  function getRowKey(record, rowKey) {
41
42
  if (typeof rowKey === "function") {
@@ -68,7 +69,10 @@ var CONTEXT_ONLY_KEYS = [
68
69
  "size",
69
70
  "defaultHiddenColumnKeys",
70
71
  "scrollAreaHeight",
71
- "setScrollAreaHeight"
72
+ "setScrollAreaHeight",
73
+ "collapseUniformColumns",
74
+ "columnOrder",
75
+ "onColumnOrderChange"
72
76
  ];
73
77
  var RecordBoardGridView = (props) => {
74
78
  const ctx = (0, import_useRecordBoardContext.useRecordBoardContext)({ displayName: "grid" });
@@ -81,13 +85,60 @@ var RecordBoardGridView = (props) => {
81
85
  } = props;
82
86
  const rawColumns = columnsProp ?? ctx.columns ?? [];
83
87
  const columnVisibility = ctx.columnVisibility;
84
- const columns = (0, import_react.useMemo)(() => {
85
- const list = rawColumns;
86
- const visible = columnVisibility == null ? list : list.filter(
88
+ const columnOrder = ctx.columnOrder;
89
+ const collapseUniformColumns = ctx.collapseUniformColumns !== false;
90
+ const summaryRef = (0, import_react.useRef)(null);
91
+ const [uniformSummaryHeight, setUniformSummaryHeight] = (0, import_react.useState)(0);
92
+ const {
93
+ columns,
94
+ uniformSummaryItems: summaryItems,
95
+ processedColumnsForSummary
96
+ } = (0, import_react.useMemo)(() => {
97
+ let list = rawColumns;
98
+ if (Array.isArray(columnOrder) && columnOrder.length > 0) {
99
+ const keyToCol = new Map(
100
+ list.map((c) => [(0, import_recordBoardColumns.getRecordBoardColumnKey)(c), c])
101
+ );
102
+ const ordered = [];
103
+ for (const key of columnOrder) {
104
+ const col = keyToCol.get(key);
105
+ if (col) ordered.push(col);
106
+ }
107
+ list.forEach((col) => {
108
+ const key = (0, import_recordBoardColumns.getRecordBoardColumnKey)(col);
109
+ if (!columnOrder.includes(key)) ordered.push(col);
110
+ });
111
+ list = ordered;
112
+ }
113
+ const visibleByUser = columnVisibility == null ? list : list.filter(
87
114
  (col) => columnVisibility[(0, import_recordBoardColumns.getRecordBoardColumnKey)(col)] !== false
88
115
  );
89
- return (0, import_recordBoardColumns.processColumnsForGrid)(visible);
90
- }, [rawColumns, columnVisibility]);
116
+ const data = ctx.data ?? [];
117
+ const shouldCollapseUniform = collapseUniformColumns && data.length > 5;
118
+ if (!shouldCollapseUniform) {
119
+ return {
120
+ columns: (0, import_recordBoardColumns.processColumnsForGrid)(visibleByUser),
121
+ uniformSummaryItems: [],
122
+ processedColumnsForSummary: void 0
123
+ };
124
+ }
125
+ const processedAllVisible = (0, import_recordBoardColumns.processColumnsForGrid)(visibleByUser);
126
+ const { uniformHiddenColumnKeys, summaryItems: items } = (0, import_recordBoardColumns.computeUniformColumnSummary)(data, visibleByUser);
127
+ const columnsForTable = processedAllVisible.filter(
128
+ (col) => !uniformHiddenColumnKeys.includes((0, import_recordBoardColumns.getRecordBoardColumnKey)(col))
129
+ );
130
+ return {
131
+ columns: columnsForTable,
132
+ uniformSummaryItems: items,
133
+ processedColumnsForSummary: items.length > 0 ? processedAllVisible : void 0
134
+ };
135
+ }, [
136
+ rawColumns,
137
+ columnVisibility,
138
+ columnOrder,
139
+ collapseUniformColumns,
140
+ ctx.data
141
+ ]);
91
142
  const tableRowKey = (0, import_react.useMemo)(() => {
92
143
  const key = ctx.rowKey ?? rowKeyProp ?? "id";
93
144
  return typeof key === "function" ? key : (record) => getRowKey(record, typeof key === "string" ? key : String(key));
@@ -107,6 +158,23 @@ var RecordBoardGridView = (props) => {
107
158
  }
108
159
  };
109
160
  }, [ctx.selectedKeys, ctx.onSelectionChange, rowSelectionConfig]);
161
+ (0, import_react.useEffect)(() => {
162
+ if (summaryItems.length === 0) {
163
+ setUniformSummaryHeight(0);
164
+ return;
165
+ }
166
+ const el = summaryRef.current;
167
+ if (!el) return;
168
+ const ro = new ResizeObserver((entries) => {
169
+ const entry = entries[0];
170
+ if (entry) setUniformSummaryHeight(entry.contentRect.height);
171
+ });
172
+ ro.observe(el);
173
+ return () => {
174
+ ro.disconnect();
175
+ setUniformSummaryHeight(0);
176
+ };
177
+ }, [summaryItems.length]);
110
178
  const gridTableProps = (0, import_react.useMemo)(() => {
111
179
  const picked = {};
112
180
  Object.keys(ctx).forEach((k) => {
@@ -134,9 +202,10 @@ var RecordBoardGridView = (props) => {
134
202
  const scrollX = isEmpty && scroll && typeof scroll.x !== "number" ? sumColumnWidths : scroll == null ? void 0 : scroll.x;
135
203
  if ((scroll == null ? void 0 : scroll.autoCalc) && typeof ctx.scrollAreaHeight === "number") {
136
204
  const wrapHeight = ctx.scrollAreaHeight;
205
+ const reservedHeight = 40 + uniformSummaryHeight + 24;
137
206
  return {
138
207
  x: scrollX ?? sumColumnWidths,
139
- y: Math.max(wrapHeight - 40, 100),
208
+ y: Math.max(wrapHeight - reservedHeight, 100),
140
209
  scrollToFirstRowOnChange: scroll.scrollToFirstRowOnChange
141
210
  };
142
211
  }
@@ -159,9 +228,25 @@ var RecordBoardGridView = (props) => {
159
228
  ctx.pagination,
160
229
  columns,
161
230
  sumColumnWidths,
162
- isEmpty
231
+ isEmpty,
232
+ uniformSummaryHeight
163
233
  ]);
164
- return /* @__PURE__ */ import_react.default.createElement("div", { "data-layout-slot": "grid", className: "pisell-lowcode-record-board-grid" }, /* @__PURE__ */ import_react.default.createElement(
234
+ return /* @__PURE__ */ import_react.default.createElement("div", { "data-layout-slot": "grid", className: "pisell-lowcode-record-board-grid" }, summaryItems.length > 0 && /* @__PURE__ */ import_react.default.createElement("div", { ref: summaryRef, className: "pisell-record-board-uniform-summary" }, summaryItems.map((item) => {
235
+ const processedCol = processedColumnsForSummary == null ? void 0 : processedColumnsForSummary.find(
236
+ (c) => (0, import_recordBoardColumns.getRecordBoardColumnKey)(c) === item.columnKey
237
+ );
238
+ const useRender = typeof (processedCol == null ? void 0 : processedCol.render) === "function";
239
+ const content = useRender ? processedCol.render(item.cellValue, item.record ?? {}, 0) : item.type === "empty" ? (0, import_locales.getText)("record-board-uniform-summary-empty") : item.displayValue ?? (0, import_locales.getText)("record-board-uniform-summary-same");
240
+ return /* @__PURE__ */ import_react.default.createElement(
241
+ "div",
242
+ {
243
+ key: item.columnKey,
244
+ className: "pisell-record-board-uniform-summary-item"
245
+ },
246
+ /* @__PURE__ */ import_react.default.createElement("span", { className: "pisell-record-board-uniform-summary-label" }, item.title),
247
+ /* @__PURE__ */ import_react.default.createElement("span", { className: "pisell-record-board-uniform-summary-value" }, content)
248
+ );
249
+ })), /* @__PURE__ */ import_react.default.createElement(
165
250
  import_antd.Table,
166
251
  {
167
252
  ...rest,
@@ -7,6 +7,44 @@
7
7
  }
8
8
  }
9
9
 
10
+ // 同值列折叠时的总结区样式(参考 Figma 12840-86869)
11
+ .pisell-record-board-uniform-summary {
12
+ display: flex;
13
+ flex-wrap: nowrap;
14
+ align-items: center;
15
+ gap: 32px;
16
+ min-height: 44px;
17
+ padding: 12px 24px;
18
+ background: #f2f4f7;
19
+ border-bottom: 1px solid #eaecf0;
20
+ border-radius: 8px 8px 0 0;
21
+
22
+ .pisell-record-board-uniform-summary-item {
23
+ display: flex;
24
+ align-items: center;
25
+ gap: 4px;
26
+ flex-shrink: 0;
27
+ }
28
+
29
+ .pisell-record-board-uniform-summary-label {
30
+ font-family: inherit;
31
+ font-size: 12px;
32
+ font-weight: 500;
33
+ line-height: 18px;
34
+ color: #475467;
35
+ white-space: nowrap;
36
+ }
37
+
38
+ .pisell-record-board-uniform-summary-value {
39
+ font-family: inherit;
40
+ font-size: 12px;
41
+ font-weight: 500;
42
+ line-height: 18px;
43
+ color: #475467;
44
+ white-space: nowrap;
45
+ }
46
+ }
47
+
10
48
  // 纯 CSS 占满高度:滚动发生在 .pisell-record-board-scroll-body,表头 sticky 固定;高度传到 table
11
49
  .pisell-record-board-scroll-body .pisell-lowcode-record-board-grid {
12
50
  height: 100%;
@@ -1,6 +1,5 @@
1
1
  /**
2
- * 列显示隐藏弹层内容(仅控制列展示显隐,不控制 filter/sort)。
3
- * 参考 table Actions ColumnsSetting PopoverContent,去掉拖拽排序。
2
+ * 列显示隐藏弹层内容:显隐切换 + 拖拽排序(参考 table Actions ColumnsSetting PopoverContent)。
4
3
  */
5
4
  import React from 'react';
6
5
  import type { RecordBoardColumnType } from '../../types';
@@ -8,6 +7,9 @@ export interface ColumnSettingPopoverProps {
8
7
  columns: RecordBoardColumnType[];
9
8
  columnVisibility: Record<string, boolean>;
10
9
  onColumnVisibilityChange: (visibility: Record<string, boolean>) => void;
10
+ /** 列 key 顺序(拖拽排序后持久化);未传则按 columns 顺序 */
11
+ columnOrder?: string[] | null;
12
+ onColumnOrderChange?: (columnKeys: string[]) => void;
11
13
  }
12
14
  declare const ColumnSettingPopover: React.FC<ColumnSettingPopoverProps>;
13
15
  export default ColumnSettingPopover;
@@ -34,8 +34,10 @@ __export(ColumnSettingPopover_exports, {
34
34
  module.exports = __toCommonJS(ColumnSettingPopover_exports);
35
35
  var import_react = __toESM(require("react"));
36
36
  var import_classnames = __toESM(require("classnames"));
37
+ var import_DotsSix = __toESM(require("@pisell/icon/es/DotsSix"));
37
38
  var import_icons = require("@ant-design/icons");
38
39
  var import_locales = require("../../../../locales");
40
+ var import_DragSortList = __toESM(require("../../../DragSortList"));
39
41
  var import_recordBoardColumns = require("../../utils/recordBoardColumns");
40
42
  var prefix = "pisell-lowcode-";
41
43
  function getColumnTitle(column) {
@@ -46,12 +48,94 @@ function getColumnTitle(column) {
46
48
  var ColumnSettingPopover = ({
47
49
  columns,
48
50
  columnVisibility,
49
- onColumnVisibilityChange
51
+ onColumnVisibilityChange,
52
+ columnOrder,
53
+ onColumnOrderChange
50
54
  }) => {
55
+ const orderedColumns = (0, import_react.useMemo)(() => {
56
+ if (!Array.isArray(columnOrder) || columnOrder.length === 0) return columns;
57
+ const keyToCol = new Map(
58
+ columns.map((c) => [(0, import_recordBoardColumns.getRecordBoardColumnKey)(c), c])
59
+ );
60
+ const result = [];
61
+ for (const key of columnOrder) {
62
+ const col = keyToCol.get(key);
63
+ if (col) result.push(col);
64
+ }
65
+ columns.forEach((col) => {
66
+ const key = (0, import_recordBoardColumns.getRecordBoardColumnKey)(col);
67
+ if (!columnOrder.includes(key)) result.push(col);
68
+ });
69
+ return result;
70
+ }, [columns, columnOrder]);
51
71
  const handleToggle = (colKey, isShow) => {
52
72
  onColumnVisibilityChange({ [colKey]: isShow });
53
73
  };
54
- return /* @__PURE__ */ import_react.default.createElement("div", { className: `${prefix}table-action-column-popover-content-wrap` }, /* @__PURE__ */ import_react.default.createElement("div", { className: `${prefix}table-action-column-header` }, /* @__PURE__ */ import_react.default.createElement("span", { className: `${prefix}table-action-column-header-title` }, (0, import_locales.getText)("table-action-column-title"))), /* @__PURE__ */ import_react.default.createElement("div", { className: `${prefix}table-action-column-content` }, columns.map((col) => {
74
+ const handleOrderChange = (list) => {
75
+ onColumnOrderChange == null ? void 0 : onColumnOrderChange(
76
+ list.map((c) => (0, import_recordBoardColumns.getRecordBoardColumnKey)(c)).filter(Boolean)
77
+ );
78
+ };
79
+ const listContent = /* @__PURE__ */ import_react.default.createElement("div", { className: `${prefix}table-action-column-content` }, typeof onColumnOrderChange === "function" ? /* @__PURE__ */ import_react.default.createElement(
80
+ import_DragSortList.default,
81
+ {
82
+ list: orderedColumns,
83
+ rowKey: (col) => (0, import_recordBoardColumns.getRecordBoardColumnKey)(col) || "",
84
+ onChange: handleOrderChange
85
+ },
86
+ ({
87
+ item: col,
88
+ index,
89
+ style,
90
+ props,
91
+ attributes,
92
+ setActivatorNodeRef,
93
+ listeners
94
+ }) => {
95
+ const colKey = (0, import_recordBoardColumns.getRecordBoardColumnKey)(col);
96
+ const isShow = columnVisibility[colKey] !== false;
97
+ return /* @__PURE__ */ import_react.default.createElement(
98
+ "div",
99
+ {
100
+ key: colKey,
101
+ ...attributes,
102
+ ref: props.ref,
103
+ style,
104
+ className: `${prefix}table-action-column-drag-item`
105
+ },
106
+ /* @__PURE__ */ import_react.default.createElement(
107
+ import_DotsSix.default,
108
+ {
109
+ ref: setActivatorNodeRef,
110
+ ...listeners,
111
+ style: { touchAction: "none" },
112
+ className: `${prefix}table-action-column-drag-bar`
113
+ }
114
+ ),
115
+ /* @__PURE__ */ import_react.default.createElement("div", { className: `${prefix}table-action-column-drag-item-right` }, /* @__PURE__ */ import_react.default.createElement(
116
+ "span",
117
+ {
118
+ className: (0, import_classnames.default)(
119
+ `${prefix}table-action-column-drag-item-right-text`,
120
+ {
121
+ [`${prefix}table-action-column-drag-item-right-text-hidden`]: !isShow
122
+ }
123
+ )
124
+ },
125
+ getColumnTitle(col)
126
+ ), /* @__PURE__ */ import_react.default.createElement(
127
+ "span",
128
+ {
129
+ className: `${prefix}table-action-column-drag-item-right-icon-wrap`,
130
+ onClick: () => handleToggle(colKey, !isShow),
131
+ role: "button",
132
+ "aria-label": isShow ? "hide" : "show"
133
+ },
134
+ isShow ? /* @__PURE__ */ import_react.default.createElement(import_icons.EyeOutlined, null) : /* @__PURE__ */ import_react.default.createElement(import_icons.EyeInvisibleOutlined, null)
135
+ ))
136
+ );
137
+ }
138
+ ) : orderedColumns.map((col) => {
55
139
  const colKey = (0, import_recordBoardColumns.getRecordBoardColumnKey)(col);
56
140
  const isShow = columnVisibility[colKey] !== false;
57
141
  return /* @__PURE__ */ import_react.default.createElement(
@@ -83,6 +167,7 @@ var ColumnSettingPopover = ({
83
167
  isShow ? /* @__PURE__ */ import_react.default.createElement(import_icons.EyeOutlined, null) : /* @__PURE__ */ import_react.default.createElement(import_icons.EyeInvisibleOutlined, null)
84
168
  ))
85
169
  );
86
- })));
170
+ }));
171
+ return /* @__PURE__ */ import_react.default.createElement("div", { className: `${prefix}table-action-column-popover-content-wrap` }, /* @__PURE__ */ import_react.default.createElement("div", { className: `${prefix}table-action-column-header` }, /* @__PURE__ */ import_react.default.createElement("span", { className: `${prefix}table-action-column-header-title` }, (0, import_locales.getText)("table-action-column-title"))), listContent);
87
172
  };
88
173
  var ColumnSettingPopover_default = ColumnSettingPopover;
@@ -45,6 +45,8 @@ var RecordBoardColumnSetting = () => {
45
45
  const gridColumns = (_b = (_a = ctx.childComponentProps) == null ? void 0 : _a.grid) == null ? void 0 : _b.columns;
46
46
  const columnVisibility = ctx.columnVisibility ?? {};
47
47
  const onColumnVisibilityChange = ctx.onColumnVisibilityChange;
48
+ const columnOrder = ctx.columnOrder ?? null;
49
+ const onColumnOrderChange = ctx.onColumnOrderChange;
48
50
  const content = (0, import_react.useMemo)(() => {
49
51
  if (!Array.isArray(gridColumns) || gridColumns.length === 0 || typeof onColumnVisibilityChange !== "function") {
50
52
  return null;
@@ -54,10 +56,12 @@ var RecordBoardColumnSetting = () => {
54
56
  {
55
57
  columns: gridColumns,
56
58
  columnVisibility,
57
- onColumnVisibilityChange
59
+ onColumnVisibilityChange,
60
+ columnOrder,
61
+ onColumnOrderChange
58
62
  }
59
63
  );
60
- }, [gridColumns, columnVisibility, onColumnVisibilityChange]);
64
+ }, [gridColumns, columnVisibility, onColumnVisibilityChange, columnOrder, onColumnOrderChange]);
61
65
  const hasHiddenColumns = (0, import_react.useMemo)(() => {
62
66
  if (!Array.isArray(gridColumns)) return false;
63
67
  return gridColumns.some(
@@ -38,7 +38,7 @@ var import_index = require("./index.less");
38
38
  var import_useRecordBoardContext = require("../../hooks/useRecordBoardContext");
39
39
  var defaultPagination = {
40
40
  pageNumber: 1,
41
- pageSize: 10
41
+ pageSize: 50
42
42
  };
43
43
  var RecordBoardPagination = (props) => {
44
44
  var _a;
@@ -163,13 +163,19 @@ var RecordBoardToolBar = (props) => {
163
163
  ])
164
164
  );
165
165
  otherFilter = otherFilter.map((item) => {
166
+ var _a2, _b2;
166
167
  const key = item.key ?? item.name ?? "";
167
168
  const configItem = configMap.get(key);
168
169
  if (!configItem) return item;
169
170
  return {
170
171
  ...configItem,
171
172
  ...item,
172
- other: { ...configItem == null ? void 0 : configItem.other, ...item == null ? void 0 : item.other }
173
+ label: configItem.label ?? item.label,
174
+ other: {
175
+ ...configItem == null ? void 0 : configItem.other,
176
+ ...item == null ? void 0 : item.other,
177
+ placeholder: ((_a2 = configItem == null ? void 0 : configItem.other) == null ? void 0 : _a2.placeholder) ?? ((_b2 = item == null ? void 0 : item.other) == null ? void 0 : _b2.placeholder)
178
+ }
173
179
  };
174
180
  });
175
181
  }
@@ -205,9 +211,11 @@ var RecordBoardToolBar = (props) => {
205
211
  },
206
212
  [onSearch, searchParams]
207
213
  );
214
+ const filterResetKey = ctx.filterResetKey ?? 0;
208
215
  const filterNode = hideFilter ? null : /* @__PURE__ */ import_react.default.createElement(
209
216
  import_pisellFilter.default,
210
217
  {
218
+ key: `record-board-filter-${filterResetKey}`,
211
219
  value: filterValueForPisellFilter,
212
220
  onChange: handleFilterChange,
213
221
  hasForm: true,
@@ -52,8 +52,9 @@ var ToolBarReset = ({
52
52
  children
53
53
  }) => {
54
54
  const defaultResetText = getResetButtonText();
55
- const { searchParams, onSearch, onReset } = (0, import_useRecordBoardContext.useRecordBoardContext)();
55
+ const { searchParams, onSearch, onReset, setFilterResetKey } = (0, import_useRecordBoardContext.useRecordBoardContext)();
56
56
  const handleReset = (0, import_react.useCallback)(() => {
57
+ setFilterResetKey == null ? void 0 : setFilterResetKey((prev) => prev + 1);
57
58
  const currentFilter = searchParams == null ? void 0 : searchParams[FILTER_PARAMS_FIELD];
58
59
  const nextParams = {
59
60
  ...searchParams,
@@ -67,7 +68,7 @@ var ToolBarReset = ({
67
68
  };
68
69
  onSearch(nextParams);
69
70
  onReset == null ? void 0 : onReset();
70
- }, [searchParams, onSearch, onReset]);
71
+ }, [searchParams, onSearch, onReset, setFilterResetKey]);
71
72
  return /* @__PURE__ */ import_react.default.createElement(
72
73
  import_antd.Button,
73
74
  {
@@ -3,6 +3,27 @@ import type { FilterValueType } from '../../filter/components/FilterButton/types
3
3
  import type { SortItemProps } from '../../sort/types';
4
4
  /** 获取列唯一 key,供列显示隐藏等使用 */
5
5
  export declare function getRecordBoardColumnKey(column: RecordBoardColumnType): string;
6
+ export interface UniformColumnSummaryItem {
7
+ columnKey: string;
8
+ title: string;
9
+ type: 'uniform' | 'empty';
10
+ /** 无 render 时的回退展示 */
11
+ displayValue?: string;
12
+ /** 仅用于判断是否相等的值(uniformCompare 的返回值或 dataIndex 取值),不参与 render */
13
+ value?: any;
14
+ /** 表格里该列单元格的值(dataIndex 从 record 取值),传给 render 的与表格单元格一致 */
15
+ cellValue?: any;
16
+ /** 代表行(如首行),供列 render 使用 */
17
+ record?: any;
18
+ }
19
+ /**
20
+ * 根据当前页 data 计算:哪些列「全列同值」或「全空」应隐藏,以及总结区展示项。
21
+ * 仅当 grid.collapseUniformColumns 为 true 时使用。
22
+ */
23
+ export declare function computeUniformColumnSummary(data: any[], columns: RecordBoardColumnType[]): {
24
+ uniformHiddenColumnKeys: string[];
25
+ summaryItems: UniformColumnSummaryItem[];
26
+ };
6
27
  /**
7
28
  * 处理列配置:对带 type 的列注入基于 Pisell 组件的 render,其余列保持不变。
8
29
  * 有 type 时若列上传入了 render 则优先使用(覆盖自动派生)。