3h1-ui 3.0.0-next.80 → 3.0.0-next.81

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.
package/es/index.js CHANGED
@@ -31302,7 +31302,7 @@ const useColumns$1 = (propsRef, getPaginationRef, tableAction2, wrapRef) => {
31302
31302
  var _a2, _b;
31303
31303
  const isSummaryCol = (_b = (_a2 = unref(propsRef).summaryTotalFields) == null ? void 0 : _a2.includes) == null ? void 0 : _b.call(_a2, column2.dataIndex);
31304
31304
  const summaryFormat = (text) => {
31305
- return text ? isNumber$2(+text) && !isNaN(+text) ? (+text).toFixed(unref(propsRef).summaryPrecision).replace(/(\d)(?=(\d{3})+\.)/g, "$1,") : text : "";
31305
+ return text || isNumber$2(text) ? isNumber$2(+text) && !isNaN(+text) ? (+text).toFixed(unref(propsRef).summaryPrecision).replace(/(\d)(?=(\d{3})+\.)/g, "$1,") : text : text;
31306
31306
  };
31307
31307
  const {
31308
31308
  slots,
@@ -32384,26 +32384,30 @@ const ShyTable = /* @__PURE__ */ defineComponent({
32384
32384
  };
32385
32385
  const isShowSummary = () => {
32386
32386
  var _a2, _b;
32387
- let _slot2;
32388
- return ((_a2 = getDataSourceRef.value) == null ? void 0 : _a2.length) && ((_b = getProps.value) == null ? void 0 : _b.showSummaryTotal) ? createVNode(TableSummary, null, {
32389
- default: () => [createVNode(TableSummaryRow, null, _isSlot$2(_slot2 = getColumnsSummary.value.map((item, index2) => {
32390
- if (index2 === 0)
32391
- return createVNode(TableSummaryCell, {
32392
- "class": `${prefixCls2}-summary-cell-first`,
32393
- "align": "center",
32394
- "index": 0
32395
- }, {
32396
- default: () => [createTextVNode("总计")]
32397
- });
32398
- return createVNode(TableSummaryCell, {
32399
- "index": index2
32400
- }, {
32401
- default: () => [summaryTotalData.value[item.dataIndex]]
32387
+ return ((_a2 = getDataSourceRef.value) == null ? void 0 : _a2.length) && ((_b = getProps.value) == null ? void 0 : _b.showSummaryTotal) ? {
32388
+ summary: () => {
32389
+ let _slot2;
32390
+ return createVNode(TableSummary, null, {
32391
+ default: () => [createVNode(TableSummaryRow, null, _isSlot$2(_slot2 = getColumnsSummary.value.map((item, index2) => {
32392
+ if (index2 === 0)
32393
+ return createVNode(TableSummaryCell, {
32394
+ "class": `${prefixCls2}-summary-cell-first`,
32395
+ "align": "center",
32396
+ "index": 0
32397
+ }, {
32398
+ default: () => [createTextVNode("总计")]
32399
+ });
32400
+ return createVNode(TableSummaryCell, {
32401
+ "index": index2
32402
+ }, {
32403
+ default: () => [summaryTotalData.value[item.dataIndex]]
32404
+ });
32405
+ })) ? _slot2 : {
32406
+ default: () => [_slot2]
32407
+ })]
32402
32408
  });
32403
- })) ? _slot2 : {
32404
- default: () => [_slot2]
32405
- })]
32406
- }) : null;
32409
+ }
32410
+ } : null;
32407
32411
  };
32408
32412
  const isShowHeader = () => {
32409
32413
  return getBindValues.value.isShowHeader ? getHeaderProps.value : {};
@@ -32473,7 +32477,7 @@ const ShyTable = /* @__PURE__ */ defineComponent({
32473
32477
  var _a2;
32474
32478
  return (_a2 = slots == null ? void 0 : slots.bodyCell) == null ? void 0 : _a2.call(slots, data || {});
32475
32479
  },
32476
- summary: isShowSummary,
32480
+ ...isShowSummary(),
32477
32481
  ...getAfterIgnoreSlots(slots)
32478
32482
  }), isShowFooter()]);
32479
32483
  };
package/es/style.css CHANGED
@@ -2858,6 +2858,17 @@ html[data-theme='light'][data-v-d388ea3f] {
2858
2858
  padding-left: 0;
2859
2859
  padding-right: 20px;
2860
2860
  }
2861
+ .shy-ant-table .ant-table-summary {
2862
+ position: sticky;
2863
+ left: 0;
2864
+ bottom: 0;
2865
+ }
2866
+ .shy-ant-table .ant-table-summary td {
2867
+ border-top: 1px solid var(--gray-1);
2868
+ }
2869
+ .shy-ant-table .ant-table-body:has(.ant-table-summary) .ant-table-tbody tr:nth-last-child(1) td {
2870
+ border-bottom: none;
2871
+ }
2861
2872
  .shy-ant-table-column-tag {
2862
2873
  display: flex;
2863
2874
  gap: 8px;
package/lib/index.js CHANGED
@@ -31326,7 +31326,7 @@ const useColumns$1 = (propsRef, getPaginationRef, tableAction2, wrapRef) => {
31326
31326
  var _a2, _b;
31327
31327
  const isSummaryCol = (_b = (_a2 = vue.unref(propsRef).summaryTotalFields) == null ? void 0 : _a2.includes) == null ? void 0 : _b.call(_a2, column2.dataIndex);
31328
31328
  const summaryFormat = (text) => {
31329
- return text ? utils.isNumber(+text) && !isNaN(+text) ? (+text).toFixed(vue.unref(propsRef).summaryPrecision).replace(/(\d)(?=(\d{3})+\.)/g, "$1,") : text : "";
31329
+ return text || utils.isNumber(text) ? utils.isNumber(+text) && !isNaN(+text) ? (+text).toFixed(vue.unref(propsRef).summaryPrecision).replace(/(\d)(?=(\d{3})+\.)/g, "$1,") : text : text;
31330
31330
  };
31331
31331
  const {
31332
31332
  slots,
@@ -32408,26 +32408,30 @@ const ShyTable = /* @__PURE__ */ vue.defineComponent({
32408
32408
  };
32409
32409
  const isShowSummary = () => {
32410
32410
  var _a2, _b;
32411
- let _slot2;
32412
- return ((_a2 = getDataSourceRef.value) == null ? void 0 : _a2.length) && ((_b = getProps.value) == null ? void 0 : _b.showSummaryTotal) ? vue.createVNode(antDesignVue.TableSummary, null, {
32413
- default: () => [vue.createVNode(antDesignVue.TableSummaryRow, null, _isSlot$2(_slot2 = getColumnsSummary.value.map((item, index2) => {
32414
- if (index2 === 0)
32415
- return vue.createVNode(antDesignVue.TableSummaryCell, {
32416
- "class": `${prefixCls2}-summary-cell-first`,
32417
- "align": "center",
32418
- "index": 0
32419
- }, {
32420
- default: () => [vue.createTextVNode("总计")]
32421
- });
32422
- return vue.createVNode(antDesignVue.TableSummaryCell, {
32423
- "index": index2
32424
- }, {
32425
- default: () => [summaryTotalData.value[item.dataIndex]]
32411
+ return ((_a2 = getDataSourceRef.value) == null ? void 0 : _a2.length) && ((_b = getProps.value) == null ? void 0 : _b.showSummaryTotal) ? {
32412
+ summary: () => {
32413
+ let _slot2;
32414
+ return vue.createVNode(antDesignVue.TableSummary, null, {
32415
+ default: () => [vue.createVNode(antDesignVue.TableSummaryRow, null, _isSlot$2(_slot2 = getColumnsSummary.value.map((item, index2) => {
32416
+ if (index2 === 0)
32417
+ return vue.createVNode(antDesignVue.TableSummaryCell, {
32418
+ "class": `${prefixCls2}-summary-cell-first`,
32419
+ "align": "center",
32420
+ "index": 0
32421
+ }, {
32422
+ default: () => [vue.createTextVNode("总计")]
32423
+ });
32424
+ return vue.createVNode(antDesignVue.TableSummaryCell, {
32425
+ "index": index2
32426
+ }, {
32427
+ default: () => [summaryTotalData.value[item.dataIndex]]
32428
+ });
32429
+ })) ? _slot2 : {
32430
+ default: () => [_slot2]
32431
+ })]
32426
32432
  });
32427
- })) ? _slot2 : {
32428
- default: () => [_slot2]
32429
- })]
32430
- }) : null;
32433
+ }
32434
+ } : null;
32431
32435
  };
32432
32436
  const isShowHeader = () => {
32433
32437
  return getBindValues.value.isShowHeader ? getHeaderProps.value : {};
@@ -32497,7 +32501,7 @@ const ShyTable = /* @__PURE__ */ vue.defineComponent({
32497
32501
  var _a2;
32498
32502
  return (_a2 = slots == null ? void 0 : slots.bodyCell) == null ? void 0 : _a2.call(slots, data || {});
32499
32503
  },
32500
- summary: isShowSummary,
32504
+ ...isShowSummary(),
32501
32505
  ...getAfterIgnoreSlots(slots)
32502
32506
  }), isShowFooter()]);
32503
32507
  };
package/lib/style.css CHANGED
@@ -2858,6 +2858,17 @@ html[data-theme='light'][data-v-d388ea3f] {
2858
2858
  padding-left: 0;
2859
2859
  padding-right: 20px;
2860
2860
  }
2861
+ .shy-ant-table .ant-table-summary {
2862
+ position: sticky;
2863
+ left: 0;
2864
+ bottom: 0;
2865
+ }
2866
+ .shy-ant-table .ant-table-summary td {
2867
+ border-top: 1px solid var(--gray-1);
2868
+ }
2869
+ .shy-ant-table .ant-table-body:has(.ant-table-summary) .ant-table-tbody tr:nth-last-child(1) td {
2870
+ border-bottom: none;
2871
+ }
2861
2872
  .shy-ant-table-column-tag {
2862
2873
  display: flex;
2863
2874
  gap: 8px;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "3h1-ui",
3
- "version": "3.0.0-next.80",
3
+ "version": "3.0.0-next.81",
4
4
  "description": "",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",