@dcs-tech/ui 0.10.0 → 0.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +362 -0
- package/README.md +3 -2
- package/THIRD_PARTY_NOTICES.md +23 -0
- package/dist/ChartImageMenu-sB2QNQzd.js +9673 -0
- package/dist/ChartView-BstZkP1g.js +1942 -0
- package/dist/{SummaryChart-i6fOdrDM.js → SummaryChart-B5ibDNOZ.js} +11 -10
- package/dist/{SummaryImage-CCt5ozD9.js → SummaryImage-CRP7X2Nl.js} +2 -2
- package/dist/SummarySeeAll-CtYRGV4G.js +101 -0
- package/dist/assets/fileTask.worker-D97s2vRV.js +1 -0
- package/dist/{columnValue-74XDBcVF.js → columnValue-BOn9NC8X.js} +86 -79
- package/dist/exportContext-CMzuzRjc.js +274 -0
- package/dist/{exportEngine-BmDly7iw.js → exportEngine-CYDN8Ty-.js} +167 -137
- package/dist/file-worker.js +1 -1
- package/dist/{fileActions-CFNO14Aj.js → fileActions-DkPEWE-t.js} +1 -1
- package/dist/{geometry-DG134nYI.js → geometry-CFS5If1N.js} +769 -466
- package/dist/index.js +21095 -12669
- package/dist/{labels-BPItSeRU.js → labels-mukFhYkc.js} +124 -1
- package/dist/{runFileTask-BIZTFnZP.js → runFileTask-DI_39TjR.js} +17 -0
- package/dist/scrollArea-B52kugL1.js +291 -0
- package/dist/style.css +1 -1
- package/dist/{summaryChartData-BiQYJbYZ.js → summaryChartData-D15kw64n.js} +6 -5
- package/dist/types/components/Charts/BarList.d.ts +4 -3
- package/dist/types/components/Charts/CalendarHeatmap.d.ts +4 -2
- package/dist/types/components/Charts/Chart.d.ts +3 -2
- package/dist/types/components/Charts/ChartView.d.ts +3 -2
- package/dist/types/components/Charts/ColumnChart.d.ts +4 -3
- package/dist/types/components/Charts/Donut.d.ts +3 -2
- package/dist/types/components/Charts/Funnel.d.ts +3 -2
- package/dist/types/components/Charts/Gauge.d.ts +3 -2
- package/dist/types/components/Charts/LineChart.d.ts +4 -3
- package/dist/types/components/Charts/NumberTrend.d.ts +4 -3
- package/dist/types/components/Charts/Progress.d.ts +3 -2
- package/dist/types/components/Charts/StackedBar.d.ts +3 -2
- package/dist/types/components/Charts/Treemap.d.ts +3 -2
- package/dist/types/components/Charts/chartData.d.ts +6 -0
- package/dist/types/components/Charts/chartImage.d.ts +2 -0
- package/dist/types/components/Charts/geometry.d.ts +3 -0
- package/dist/types/components/Charts/index.d.ts +2 -0
- package/dist/types/components/Charts/palette.d.ts +1 -0
- package/dist/types/components/Charts/parts.d.ts +14 -0
- package/dist/types/components/Charts/useChartMotion.d.ts +8 -0
- package/dist/types/components/DataTable/DataTable.d.ts +3 -1
- package/dist/types/components/DataTable/DisplayPopover.d.ts +1 -0
- package/dist/types/components/DataTable/HeaderMenu.d.ts +1 -0
- package/dist/types/components/DataTable/TableColumnModal.d.ts +4 -1
- package/dist/types/components/DataTable/TableToolbar.d.ts +20 -1
- package/dist/types/components/DataTable/TableView.d.ts +18 -2
- package/dist/types/components/DataTable/cards/CardView.d.ts +25 -5
- package/dist/types/components/DataTable/cards/rowParts.d.ts +1 -0
- package/dist/types/components/DataTable/cellSelection/CellRangeBar.d.ts +16 -0
- package/dist/types/components/DataTable/cellSelection/cellRangeStore.d.ts +18 -0
- package/dist/types/components/DataTable/cellSelection/paintRanges.d.ts +2 -0
- package/dist/types/components/DataTable/cellSelection/useCellSelection.d.ts +63 -0
- package/dist/types/components/DataTable/data/listDelta.d.ts +27 -0
- package/dist/types/components/DataTable/data/rowLineage.d.ts +3 -0
- package/dist/types/components/DataTable/data/rowModels.d.ts +9 -0
- package/dist/types/components/DataTable/data/rowTransaction.d.ts +9 -0
- package/dist/types/components/DataTable/data/useServerData.d.ts +3 -1
- package/dist/types/components/DataTable/export/exportCells.d.ts +5 -2
- package/dist/types/components/DataTable/export/exportEngine.d.ts +7 -2
- package/dist/types/components/DataTable/export/useTableExport.d.ts +17 -1
- package/dist/types/components/DataTable/filters/filterRowModel.d.ts +1 -0
- package/dist/types/components/DataTable/grouping/groupModel.d.ts +11 -0
- package/dist/types/components/DataTable/index.d.ts +1 -1
- package/dist/types/components/DataTable/keyboard/ShortcutsDialog.d.ts +4 -1
- package/dist/types/components/DataTable/keyboard/useGridKeyboard.d.ts +8 -0
- package/dist/types/components/DataTable/labels.d.ts +128 -0
- package/dist/types/components/DataTable/layout/LayoutSwitcher.d.ts +10 -2
- package/dist/types/components/DataTable/layout/useFitWidths.d.ts +7 -0
- package/dist/types/components/DataTable/menu/RowMenu.d.ts +1 -0
- package/dist/types/components/DataTable/menu/buildRowMenu.d.ts +6 -3
- package/dist/types/components/DataTable/motion/RowChangeNotice.d.ts +19 -0
- package/dist/types/components/DataTable/motion/rowChanges.d.ts +25 -0
- package/dist/types/components/DataTable/motion/useNoticeInsets.d.ts +2 -0
- package/dist/types/components/DataTable/motion/useRowChangeNotices.d.ts +35 -0
- package/dist/types/components/DataTable/motion/useRowMotion.d.ts +29 -3
- package/dist/types/components/DataTable/persistence/reconcile.d.ts +4 -0
- package/dist/types/components/DataTable/persistence/useColumnPersistence.d.ts +5 -1
- package/dist/types/components/DataTable/pivot/PivotPanel.d.ts +11 -0
- package/dist/types/components/DataTable/pivot/PivotView.d.ts +22 -0
- package/dist/types/components/DataTable/pivot/pivotModel.d.ts +54 -0
- package/dist/types/components/DataTable/pivot/usePivot.d.ts +44 -0
- package/dist/types/components/DataTable/rows/PressRow.d.ts +1 -0
- package/dist/types/components/DataTable/rows/RowLead.d.ts +23 -0
- package/dist/types/components/DataTable/rows/rowPress.d.ts +2 -0
- package/dist/types/components/DataTable/rows/usePinnedRows.d.ts +34 -0
- package/dist/types/components/DataTable/rows/useRowDrag.d.ts +44 -0
- package/dist/types/components/DataTable/split/SplitView.d.ts +4 -2
- package/dist/types/components/DataTable/summary/SummaryChart.d.ts +2 -1
- package/dist/types/components/DataTable/summary/TableSummary.d.ts +2 -1
- package/dist/types/components/DataTable/summary/summaryModel.d.ts +28 -6
- package/dist/types/components/DataTable/summary/useTableSummary.d.ts +3 -0
- package/dist/types/components/DataTable/toolbar/ToolbarMore.d.ts +14 -0
- package/dist/types/components/DataTable/toolbar/useToolbarFit.d.ts +10 -0
- package/dist/types/components/DataTable/tree/TreeChips.d.ts +5 -0
- package/dist/types/components/DataTable/tree/treeExport.d.ts +54 -0
- package/dist/types/components/DataTable/tree/treeMove.d.ts +1 -0
- package/dist/types/components/DataTable/tree/useTreeChildren.d.ts +15 -0
- package/dist/types/components/DataTable/tree/useTreeData.d.ts +60 -0
- package/dist/types/components/DataTable/types.d.ts +272 -4
- package/dist/types/components/DataTable/useDataChangeTracker.d.ts +11 -4
- package/dist/types/components/DataTable/useTable.d.ts +13 -1
- package/dist/types/components/DataTable/virtual/useVirtualLines.d.ts +1 -0
- package/dist/types/components/EventCalendar/EventCalendar.d.ts +46 -0
- package/dist/types/components/EventCalendar/eventParts.d.ts +10 -0
- package/dist/types/components/EventCalendar/index.d.ts +3 -0
- package/dist/types/components/EventCalendar/useCalendarEdit.d.ts +40 -0
- package/dist/types/components/Icon/Icon.d.ts +36 -0
- package/dist/types/components/Icon/Icon.storyData.d.ts +6 -0
- package/dist/types/components/Icon/IconContext.d.ts +7 -0
- package/dist/types/components/Icon/icons.d.ts +223 -0
- package/dist/types/components/Icon/index.d.ts +7 -0
- package/dist/types/components/Icon/useIconDone.d.ts +5 -0
- package/dist/types/components/Popover/Popover.d.ts +1 -0
- package/dist/types/components/Popover/floatingPosition.d.ts +22 -2
- package/dist/types/components/ReorderList/ReorderList.d.ts +2 -1
- package/dist/types/components/Scroll/ui.d.ts +1 -0
- package/dist/types/components/SlidingHighlight/index.d.ts +2 -0
- package/dist/types/components/SlidingHighlight/useSlidingHighlight.d.ts +20 -0
- package/dist/types/components/Suggest/SuggestionList.d.ts +1 -0
- package/dist/types/components/UIProvider/UILabelsContext.d.ts +34 -0
- package/dist/types/components/UIProvider/UIProvider.d.ts +2 -0
- package/dist/types/core/hooks/index.d.ts +1 -1
- package/dist/types/core/hooks/usePresence.d.ts +1 -0
- package/dist/types/core/icons/actions.icons.d.ts +37 -0
- package/dist/types/core/icons/commerce.icons.d.ts +16 -0
- package/dist/types/core/icons/communication.icons.d.ts +10 -0
- package/dist/types/core/icons/delivery.icons.d.ts +13 -0
- package/dist/types/core/icons/devices.icons.d.ts +16 -0
- package/dist/types/core/icons/files.icons.d.ts +13 -0
- package/dist/types/core/icons/general.icons.d.ts +24 -0
- package/dist/types/core/icons/index.d.ts +14 -0
- package/dist/types/core/icons/media.icons.d.ts +11 -0
- package/dist/types/core/icons/navigation.icons.d.ts +25 -0
- package/dist/types/core/icons/people.icons.d.ts +13 -0
- package/dist/types/core/icons/registry.d.ts +2 -0
- package/dist/types/core/icons/state.icons.d.ts +14 -0
- package/dist/types/core/icons/status.icons.d.ts +10 -0
- package/dist/types/core/icons/table.icons.d.ts +22 -0
- package/dist/types/core/icons/text.icons.d.ts +13 -0
- package/dist/types/core/logic/cellRange.logic.d.ts +66 -0
- package/dist/types/core/logic/cellTouch.logic.d.ts +16 -0
- package/dist/types/core/logic/columnGroups.logic.d.ts +31 -0
- package/dist/types/core/logic/dropdownSide.logic.d.ts +19 -0
- package/dist/types/core/logic/eventCalendar.logic.d.ts +225 -0
- package/dist/types/core/logic/fitColumns.logic.d.ts +7 -0
- package/dist/types/core/logic/icon.logic.d.ts +24 -0
- package/dist/types/core/logic/index.d.ts +16 -0
- package/dist/types/core/logic/pivot.logic.d.ts +100 -0
- package/dist/types/core/logic/rowActions.logic.d.ts +7 -0
- package/dist/types/core/logic/rowDrag.logic.d.ts +36 -0
- package/dist/types/core/logic/rowPinning.logic.d.ts +12 -0
- package/dist/types/core/logic/slidingHighlight.logic.d.ts +20 -0
- package/dist/types/core/logic/toolbarOverflow.logic.d.ts +21 -0
- package/dist/types/core/logic/treeData.logic.d.ts +44 -0
- package/dist/types/core/logic/treeDrag.logic.d.ts +63 -0
- package/dist/types/core/logic/tween.logic.d.ts +33 -0
- package/dist/types/core/logic/visualViewport.logic.d.ts +13 -0
- package/dist/types/core/types/eventCalendar.types.d.ts +18 -0
- package/dist/types/core/types/fileEngine.types.d.ts +6 -0
- package/dist/types/core/types/icon.types.d.ts +109 -0
- package/dist/types/core/types/index.d.ts +2 -0
- package/dist/types/index.d.ts +7 -0
- package/package.json +4 -4
- package/dist/ChartImageMenu-3OfqNFyt.js +0 -1510
- package/dist/ChartView-n4G5_2ro.js +0 -1707
- package/dist/SummarySeeAll-BY8knsRe.js +0 -101
- package/dist/assets/fileTask.worker--Q3rI3Bn.js +0 -1
- package/dist/exportContext-C52ZuHd8.js +0 -166
- package/dist/scrollArea-D84Cwm4o.js +0 -310
|
@@ -1,29 +1,30 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { t as e } from "./ChartView-
|
|
3
|
-
import { n as t } from "./summaryChartData-
|
|
2
|
+
import { t as e } from "./ChartView-BstZkP1g.js";
|
|
3
|
+
import { n as t } from "./summaryChartData-D15kw64n.js";
|
|
4
4
|
import { jsx as n } from "react/jsx-runtime";
|
|
5
5
|
// src/components/DataTable/summary/SummaryChart.tsx
|
|
6
6
|
var r = {
|
|
7
7
|
treemap: 112,
|
|
8
8
|
other: 72
|
|
9
9
|
}, i = 96;
|
|
10
|
-
function a({ item: a, onSelect: o, format: s, locale: c, labels: l, onLegendCut: u }) {
|
|
11
|
-
let
|
|
12
|
-
...
|
|
13
|
-
data:
|
|
14
|
-
} :
|
|
10
|
+
function a({ item: a, onSelect: o, format: s, locale: c, labels: l, onLegendCut: u, animate: d }) {
|
|
11
|
+
let f = t(a, l), p = f.kind === "bars" ? {
|
|
12
|
+
...f,
|
|
13
|
+
data: f.data.slice(0, 6)
|
|
14
|
+
} : f;
|
|
15
15
|
return /* @__PURE__ */ n(e, {
|
|
16
|
-
chart:
|
|
16
|
+
chart: p,
|
|
17
17
|
ariaLabel: a.card.title,
|
|
18
18
|
compact: !0,
|
|
19
|
-
height:
|
|
19
|
+
height: f.kind === "treemap" ? r.treemap : r.other,
|
|
20
20
|
size: i,
|
|
21
21
|
onSelect: o,
|
|
22
22
|
selected: "selected" in a ? a.selected : null,
|
|
23
23
|
format: s,
|
|
24
24
|
locale: c,
|
|
25
25
|
labels: l,
|
|
26
|
-
onLegendCut: u
|
|
26
|
+
onLegendCut: u,
|
|
27
|
+
animate: d
|
|
27
28
|
});
|
|
28
29
|
}
|
|
29
30
|
export { a as default };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { t as e } from "./ChartImageMenu-
|
|
3
|
-
import { n as t } from "./summaryChartData-
|
|
2
|
+
import { t as e } from "./ChartImageMenu-sB2QNQzd.js";
|
|
3
|
+
import { n as t } from "./summaryChartData-D15kw64n.js";
|
|
4
4
|
import { jsx as n } from "react/jsx-runtime";
|
|
5
5
|
// src/components/DataTable/summary/SummaryImage.tsx
|
|
6
6
|
function r({ item: r, report: i, context: a, branding: o, format: s, locale: c, labels: l }) {
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { t as e } from "./ChartImageMenu-sB2QNQzd.js";
|
|
3
|
+
import { t } from "./ChartView-BstZkP1g.js";
|
|
4
|
+
import { G as n, Q as r, jt as i, tn as a, ut as o } from "./geometry-CFS5If1N.js";
|
|
5
|
+
import { n as s, o as c, s as l } from "./scrollArea-B52kugL1.js";
|
|
6
|
+
import { r as u, t as d } from "./summaryChartData-D15kw64n.js";
|
|
7
|
+
import { Fragment as f, jsx as p, jsxs as m } from "react/jsx-runtime";
|
|
8
|
+
// src/components/DataTable/summary/SummarySeeAll.tsx
|
|
9
|
+
function h({ item: h, all: g, onClose: _, onSelect: v, image: y, labels: b }) {
|
|
10
|
+
let { labels: x, format: S } = c(), C = x.summaryAllOf(h.card.title, S.number(h.values)), w = a(h, S.number), T = i(h.card), E = g === "failed" ? [] : g, D = E.reduce((e, t) => e + Math.max(0, t.count), 0), O = d(h, E), k = n(O, u(h), b), A = (e) => {
|
|
11
|
+
if (T === "bars") return o(1);
|
|
12
|
+
let t = O.type === "values" ? O.values[e] : void 0;
|
|
13
|
+
return o(t?.slot ?? e + 1);
|
|
14
|
+
}, j = (e) => {
|
|
15
|
+
e !== "\0others" && v?.(e, E.find((t) => t.key === e)?.value ?? null);
|
|
16
|
+
};
|
|
17
|
+
return /* @__PURE__ */ p(l, {
|
|
18
|
+
open: !0,
|
|
19
|
+
onClose: _,
|
|
20
|
+
size: "lg",
|
|
21
|
+
"aria-label": C,
|
|
22
|
+
title: /* @__PURE__ */ m("span", {
|
|
23
|
+
className: "dt-summary-all-head",
|
|
24
|
+
children: [/* @__PURE__ */ p("span", {
|
|
25
|
+
className: "dt-summary-all-title",
|
|
26
|
+
children: C
|
|
27
|
+
}), y && g !== "failed" && /* @__PURE__ */ p(e, {
|
|
28
|
+
report: y.report,
|
|
29
|
+
title: C,
|
|
30
|
+
context: y.context,
|
|
31
|
+
branding: y.branding,
|
|
32
|
+
chart: k,
|
|
33
|
+
format: w,
|
|
34
|
+
locale: S.locale,
|
|
35
|
+
labels: b
|
|
36
|
+
})]
|
|
37
|
+
}),
|
|
38
|
+
subtitle: y?.context,
|
|
39
|
+
className: "dt-summary-all",
|
|
40
|
+
children: g === "failed" ? /* @__PURE__ */ p("div", {
|
|
41
|
+
className: "dt-summary-status dt-summary-status--failed",
|
|
42
|
+
role: "alert",
|
|
43
|
+
children: x.summaryFailed
|
|
44
|
+
}) : /* @__PURE__ */ m("div", {
|
|
45
|
+
className: `dt-summary-all-body ${s}`,
|
|
46
|
+
children: [/* @__PURE__ */ p("div", {
|
|
47
|
+
className: `dt-summary-all-chart dt-summary-all-chart--${T}`,
|
|
48
|
+
children: /* @__PURE__ */ p(t, {
|
|
49
|
+
chart: k,
|
|
50
|
+
ariaLabel: C,
|
|
51
|
+
height: T === "treemap" ? 260 : void 0,
|
|
52
|
+
size: 220,
|
|
53
|
+
legend: !1,
|
|
54
|
+
onSelect: v ? j : void 0,
|
|
55
|
+
selected: h.selected,
|
|
56
|
+
format: w,
|
|
57
|
+
locale: S.locale,
|
|
58
|
+
labels: b
|
|
59
|
+
})
|
|
60
|
+
}), /* @__PURE__ */ p("ul", {
|
|
61
|
+
className: "dt-summary-all-list chart-root",
|
|
62
|
+
"aria-label": x.summaryLegend,
|
|
63
|
+
children: E.map((e, t) => {
|
|
64
|
+
let n = /* @__PURE__ */ m(f, { children: [
|
|
65
|
+
/* @__PURE__ */ p("span", {
|
|
66
|
+
className: "chart-swatch",
|
|
67
|
+
style: { background: A(t) },
|
|
68
|
+
"aria-hidden": !0
|
|
69
|
+
}),
|
|
70
|
+
/* @__PURE__ */ p("span", {
|
|
71
|
+
className: "dt-summary-all-name",
|
|
72
|
+
children: e.label
|
|
73
|
+
}),
|
|
74
|
+
/* @__PURE__ */ p("span", {
|
|
75
|
+
className: "dt-summary-all-count",
|
|
76
|
+
children: w(e.count)
|
|
77
|
+
}),
|
|
78
|
+
/* @__PURE__ */ p("span", {
|
|
79
|
+
className: "dt-summary-all-share",
|
|
80
|
+
children: r(D ? Math.max(0, e.count) / D * 100 : 0)
|
|
81
|
+
})
|
|
82
|
+
] });
|
|
83
|
+
return /* @__PURE__ */ p("li", {
|
|
84
|
+
className: `dt-summary-all-row${h.selected === e.key ? " dt-summary-all-row--on" : ""}`,
|
|
85
|
+
children: v && !e.others ? /* @__PURE__ */ p("button", {
|
|
86
|
+
type: "button",
|
|
87
|
+
className: "dt-summary-all-pick",
|
|
88
|
+
"aria-pressed": h.selected === e.key,
|
|
89
|
+
onClick: () => j(e.key),
|
|
90
|
+
children: n
|
|
91
|
+
}) : /* @__PURE__ */ p("span", {
|
|
92
|
+
className: "dt-summary-all-pick",
|
|
93
|
+
children: n
|
|
94
|
+
})
|
|
95
|
+
}, e.key);
|
|
96
|
+
})
|
|
97
|
+
})]
|
|
98
|
+
})
|
|
99
|
+
});
|
|
100
|
+
}
|
|
101
|
+
export { h as default };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const e=()=>new DOMException(`Aborted`,`AbortError`);async function t(t,n){if(n.signal?.aborted)throw e();switch(t.kind){case`xlsx`:return d(t.workbook,n);case`pdf`:return h(t,n);default:throw Error(`Unknown file task: ${t.kind}`)}}const n=globalThis;async function r(){let e=await import(`exceljs`),t=[e.default?.default,e.default,e,n.ExcelJS].find(e=>e&&typeof e.Workbook==`function`);if(!t)throw Error(`ExcelJS did not load`);return t}let i=null;function a(){return i||=o().catch(e=>{throw i=null,e}),i}async function o(){let e=await import(`pdfmake/build/pdfmake.js`),t=[e.default?.default,e.default,e,n.pdfMake].find(e=>e&&typeof e.createPdf==`function`);if(!t)throw Error(`pdfmake did not load`);let r,i=`pdfMake`in n,a=i?n.pdfMake:n.pdfMake={},o=a?.addVirtualFileSystem;a&&(a.addVirtualFileSystem=e=>{r=e,o?.call(a,e)});let s;try{s=await import(`pdfmake/build/vfs_fonts.js`)}finally{i?a&&(o?a.addVirtualFileSystem=o:delete a.addVirtualFileSystem):delete n.pdfMake}return{pdfMake:t,vfs:[s?.default,s,s?.pdfMake?.vfs,s?.default?.pdfMake?.vfs,r,t.vfs,n.pdfMake?.vfs].find(e=>e&&e[`Roboto-Regular.ttf`])}}const s=e=>ArrayBuffer.isView(e)?e.buffer.slice(e.byteOffset,e.byteOffset+e.byteLength):e,c=e=>`FF`+e.replace(`#`,``).toUpperCase();function l(e,t){if(t&&((t.bold!==void 0||t.italic!==void 0||t.size||t.color)&&(e.font={...e.font??{},...t.bold===void 0?{}:{bold:t.bold},...t.italic===void 0?{}:{italic:t.italic},...t.size?{size:t.size}:{},...t.color?{color:{argb:c(t.color)}}:{}}),t.fill&&(e.fill={type:`pattern`,pattern:`solid`,fgColor:{argb:c(t.fill)}}),t.align&&(e.alignment={horizontal:t.align,vertical:`middle`}),t.numFmt&&(typeof e.value==`number`||e.value instanceof Date)&&(e.numFmt=t.numFmt),t.borderTop||t.borderBottom)){let n=e=>({style:e.style,...e.color?{color:{argb:c(e.color)}}:{}});e.border={...t.borderTop?{top:n(t.borderTop)}:{},...t.borderBottom?{bottom:n(t.borderBottom)}:{}}}}function u(e,t,n){let r=e.addRow(t.values);t.style?.bold&&(r.font={bold:!0}),t.merge&&n>1&&e.mergeCells(r.number,1,r.number,n);let i=t.merge?1:Math.max(t.values.length,0);for(let e=0;e<i;e++){let n=r.getCell(e+1);l(n,t.style),l(n,t.cells?.[e])}}async function d(t,n){let i=new(await(r())).Workbook,a=Math.max(1,t.sheets.reduce((e,t)=>e+t.rows.length,0)),o=Math.max(1,Math.floor(a/50)),d=0;for(let r of t.sheets){let t=i.addWorksheet(r.name),s=r.columns.length;t.columns=r.columns.map((e,t)=>({key:String(t),width:e.width}));for(let e of r.before??[])u(t,e,s);for(let e of r.headerGroups??[]){let n=Array(s).fill(``);for(let t of e)t.start>=0&&t.start<s&&(n[t.start]=t.label);let i=t.addRow(n);i.font={bold:r.headerStyle?.bold??!0};for(let e=1;e<=s;e++){let t=i.getCell(e);l(t,r.headerStyle),t.alignment={horizontal:`center`,vertical:`middle`}}for(let n of e){let e=Math.min(s,n.start+n.span);e-n.start>1&&t.mergeCells(i.number,n.start+1,i.number,e)}}let f=t.addRow(r.columns.map(e=>e.header));f.font={bold:r.headerStyle?.bold??!0},f.eachCell((e,t)=>{let n=r.columns[t-1]?.align;n&&(e.alignment={horizontal:n,vertical:`middle`}),l(e,r.headerStyle)});let p=f.number;r.freeze?t.views=[{state:`frozen`,ySplit:r.freeze.rows??0,xSplit:r.freeze.cols??0}]:r.freezeHeader!==!1&&(t.views=[{state:`frozen`,ySplit:p}]),r.rows.forEach((i,s)=>{let u=t.addRow(i),f=r.cellStyles?.[s],p=r.stripe&&s%2==1;if(r.columns.forEach((e,t)=>{let n=u.getCell(t+1);e.numFmt&&(typeof n.value==`number`||n.value instanceof Date)&&(n.numFmt=e.numFmt),e.align&&(n.alignment={horizontal:e.align,vertical:`middle`}),p&&(n.fill={type:`pattern`,pattern:`solid`,fgColor:{argb:c(r.stripe)}}),l(n,e.style),l(n,f?.[t])}),++d%o===0){if(n.signal?.aborted)throw e();n.progress(d/a*.9)}}),r.autoFilter&&r.rows.length>0&&(t.autoFilter={from:{row:p,column:1},to:{row:p,column:s}});for(let e of r.after??[])u(t,e,s)}let f=await i.xlsx.writeBuffer();return n.progress(1),s(f)}const f={Roboto:{normal:`Roboto-Regular.ttf`,bold:`Roboto-Medium.ttf`,italics:`Roboto-Italic.ttf`,bolditalics:`Roboto-MediumItalic.ttf`}};function p(e){let t=e.hLineWidth??1,n=e.edgeLineWidth??t;return{hLineWidth:(e,r)=>e===0||e===(r.table.headerRows??0)||e===r.table.body.length?n:t,vLineWidth:()=>e.vLineWidth??1,...e.hLineColor?{hLineColor:()=>e.hLineColor}:{},...e.vLineColor?{vLineColor:()=>e.vLineColor}:{},...e.paddingX===void 0?{}:{paddingLeft:()=>e.paddingX,paddingRight:()=>e.paddingX},...e.paddingY===void 0?{}:{paddingTop:()=>e.paddingY,paddingBottom:()=>e.paddingY}}}function m(e){return(t,n)=>({text:e.text.replace(/\{page\}/g,String(t)).replace(/\{pages\}/g,String(n)),...e.font?{font:e.font}:{},alignment:e.alignment??`center`,fontSize:e.fontSize??8,...e.color?{color:e.color}:{},...e.margin?{margin:e.margin}:{}})}async function h(t,n){let r=n.pdfFonts?{fonts:{...n.pdfFonts.fonts,...t.fonts?.fonts},vfs:n.pdfFonts.vfs||t.fonts?.vfs?{...n.pdfFonts.vfs,...t.fonts?.vfs}:void 0}:t.fonts,i=t.footer?{...t.document,footer:m(t.footer)}:t.document,o=t.tableLayouts?Object.fromEntries(Object.entries(t.tableLayouts).map(([e,t])=>[e,p(t)])):void 0,{pdfMake:s,vfs:c}=await a();if(n.progress(.1),n.signal?.aborted)throw e();let l={...f,...r?.fonts??{}},u=r?.vfs?{...c??{},...r.vfs}:c,d=await new Promise((e,t)=>{try{let n=s.createPdf(i,o,l,u).getStream(),r=[];n.on(`data`,e=>r.push(e)),n.on(`error`,t),n.on(`end`,()=>{let t=new Uint8Array(r.reduce((e,t)=>e+t.byteLength,0)),n=0;for(let e of r)t.set(e,n),n+=e.byteLength;e(t.buffer)}),n.end()}catch(e){t(e)}});return n.progress(1),d}let g;const _=self;_.onmessage=async e=>{if(e.data.type===`init`){g=e.data.pdfFonts;return}let{id:n,task:r}=e.data;try{let e=await t(r,{progress:e=>_.postMessage({type:`progress`,id:n,fraction:e}),pdfFonts:g});_.postMessage({type:`done`,id:n,buffer:e},[e])}catch(e){_.postMessage({type:`error`,id:n,message:e instanceof Error?e.message:String(e)})}};
|
|
@@ -154,7 +154,7 @@ function T(e, t = {}) {
|
|
|
154
154
|
};
|
|
155
155
|
return r(m) ? i(m) : null;
|
|
156
156
|
}
|
|
157
|
-
function
|
|
157
|
+
function ee(e, t = {}) {
|
|
158
158
|
let n = String(e ?? "").trim(), r = n.indexOf("+");
|
|
159
159
|
if (r <= 0 || r >= n.length - 1) return null;
|
|
160
160
|
let i = T(n.slice(0, r), t);
|
|
@@ -168,20 +168,20 @@ function E(e, t = {}) {
|
|
|
168
168
|
to: c(a, i) < 0 ? d(a, 1) : a
|
|
169
169
|
} : null;
|
|
170
170
|
}
|
|
171
|
-
function
|
|
171
|
+
function E(e, n = "dd-mm-yyyy") {
|
|
172
172
|
let r = a(e);
|
|
173
173
|
if (!r) return "";
|
|
174
174
|
let i = t(r.d), o = t(r.m), s = String(r.y).padStart(4, "0");
|
|
175
175
|
return n === "yyyy-mm-dd" ? `${s}-${o}-${i}` : n === "dd/mm/yyyy" ? `${i}/${o}/${s}` : `${i}-${o}-${s}`;
|
|
176
176
|
}
|
|
177
|
-
var
|
|
178
|
-
function
|
|
177
|
+
var te = (e = "dd-mm-yyyy", t = !1) => t ? `${e} hh:mm` : e;
|
|
178
|
+
function ne(e, t = "dd-mm-yyyy", n = !1) {
|
|
179
179
|
let { day: r, time: i } = y(e);
|
|
180
180
|
if (!r) return "";
|
|
181
|
-
let a =
|
|
181
|
+
let a = E(r, t);
|
|
182
182
|
return n && i ? `${a} ${i}` : a;
|
|
183
183
|
}
|
|
184
|
-
function
|
|
184
|
+
function re(e, t = {}) {
|
|
185
185
|
let n = String(e ?? "").trim(), r = "";
|
|
186
186
|
if (t.withTime) {
|
|
187
187
|
let e = /[\s,]*(\d{1,2}:\d{2})$/.exec(n);
|
|
@@ -196,7 +196,7 @@ function ne(e, t = {}) {
|
|
|
196
196
|
time: r
|
|
197
197
|
} : null;
|
|
198
198
|
}
|
|
199
|
-
function
|
|
199
|
+
function ie(e) {
|
|
200
200
|
let t = a(e.month) ?? a(o()), r = i({
|
|
201
201
|
...t,
|
|
202
202
|
d: 1
|
|
@@ -230,7 +230,7 @@ function re(e) {
|
|
|
230
230
|
canPageNext: h(l(p(r), 1), e.min, e.max)
|
|
231
231
|
};
|
|
232
232
|
}
|
|
233
|
-
var
|
|
233
|
+
var ae = [
|
|
234
234
|
"highlightLeft",
|
|
235
235
|
"highlightRight",
|
|
236
236
|
"highlightPrev",
|
|
@@ -240,15 +240,15 @@ var ie = [
|
|
|
240
240
|
"highlightPrevPage",
|
|
241
241
|
"highlightNextPage"
|
|
242
242
|
];
|
|
243
|
-
function
|
|
243
|
+
function oe(e, t, n = {}) {
|
|
244
244
|
let r = s(e) || o();
|
|
245
245
|
return g(t === "highlightLeft" ? l(r, -1) : t === "highlightRight" ? l(r, 1) : t === "highlightPrev" ? l(r, -7) : t === "highlightNext" ? l(r, 7) : t === "highlightFirst" ? f(r) : t === "highlightLast" ? p(r) : t === "highlightPrevPage" ? u(r, -1) : u(r, 1), n.min, n.max);
|
|
246
246
|
}
|
|
247
|
-
function
|
|
247
|
+
function se(e, t = {}) {
|
|
248
248
|
let { day: n } = y(e);
|
|
249
249
|
return n || g(s(t.today ?? o()) || o(), t.min, t.max);
|
|
250
250
|
}
|
|
251
|
-
function
|
|
251
|
+
function D(e, t = 4) {
|
|
252
252
|
let n = a(e) ?? a(o()), r = Math.min(12, Math.max(1, Math.trunc(t) || 1)), s = i({
|
|
253
253
|
y: n.m >= r ? n.y : n.y - 1,
|
|
254
254
|
m: r,
|
|
@@ -259,19 +259,19 @@ function k(e, t = 4) {
|
|
|
259
259
|
to: l(d(s, 1), -1)
|
|
260
260
|
};
|
|
261
261
|
}
|
|
262
|
-
function
|
|
262
|
+
function O(e, t = 0) {
|
|
263
263
|
let n = s(e) || o(), r = (Math.trunc(t) % 7 + 7) % 7;
|
|
264
264
|
return l(n, -(((m(n) - r) % 7 + 7) % 7));
|
|
265
265
|
}
|
|
266
|
-
function
|
|
267
|
-
let n =
|
|
266
|
+
function k(e, t = 4) {
|
|
267
|
+
let n = D(e, t), r = a(e).y * 12 + a(e).m - (a(n.from).y * 12 + a(n.from).m), i = u(n.from, Math.floor(r / 3) * 3);
|
|
268
268
|
return {
|
|
269
269
|
from: i,
|
|
270
270
|
to: p(u(i, 2))
|
|
271
271
|
};
|
|
272
272
|
}
|
|
273
|
-
function
|
|
274
|
-
let t = s(e.today ?? o()) || o(), n = e.fyStartMonth ?? 4, r = e.weekStart ?? 0, i =
|
|
273
|
+
function A(e = {}) {
|
|
274
|
+
let t = s(e.today ?? o()) || o(), n = e.fyStartMonth ?? 4, r = e.weekStart ?? 0, i = D(t, n), a = D(l(i.from, -1), n), c = O(t, r), d = l(c, -7), m = u(t, -1), h = k(t, n), g = k(l(h.from, -1), n), _ = [
|
|
275
275
|
{
|
|
276
276
|
key: "today",
|
|
277
277
|
label: "Today",
|
|
@@ -451,83 +451,89 @@ function N(e, t, n, a, o) {
|
|
|
451
451
|
let c = Number(a), l = Number(o);
|
|
452
452
|
return c > 23 || l > 59 ? null : c === 0 && l === 0 ? s : `${s}T${j(c)}:${j(l)}`;
|
|
453
453
|
}
|
|
454
|
-
var P = "(?:[T ](\\d{1,2}):(\\d{2})(?::\\d{2}(?:\\.\\d+)?)?)?", fe = RegExp(`^(\\d{4})-(\\d{2})-(\\d{2})${P}$`), F = /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}(?::\d{2}(?:\.\d+)?)?(?:Z|[+-]\d{2}:?\d{2})$/i, pe = RegExp(`^(\\d{1,2})[-/.](\\d{1,2})[-/.](\\d{4})${P}$`),
|
|
454
|
+
var P = "(?:[T ](\\d{1,2}):(\\d{2})(?::\\d{2}(?:\\.\\d+)?)?)?", fe = RegExp(`^(\\d{4})-(\\d{2})-(\\d{2})${P}$`), F = /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}(?::\d{2}(?:\.\d+)?)?(?:Z|[+-]\d{2}:?\d{2})$/i, pe = RegExp(`^(\\d{1,2})[-/.](\\d{1,2})[-/.](\\d{4})${P}$`), me = RegExp(`^(\\d{4})[-/.](\\d{1,2})[-/.](\\d{1,2})${P}$`), I = /* @__PURE__ */ new Map(), he = 2e4;
|
|
455
455
|
function L(e, t) {
|
|
456
456
|
if (e == null || e === "") return null;
|
|
457
457
|
if (e instanceof Date) return M(e);
|
|
458
458
|
if (typeof e == "number") return Number.isFinite(e) ? M(new Date(e)) : null;
|
|
459
459
|
if (typeof e != "string") return null;
|
|
460
|
+
let n = t ? `${t}\u0000${e}` : e, r = I.get(n);
|
|
461
|
+
if (r !== void 0) return r;
|
|
462
|
+
let i = R(e, t);
|
|
463
|
+
return I.size >= he && I.clear(), I.set(n, i), i;
|
|
464
|
+
}
|
|
465
|
+
function R(e, t) {
|
|
460
466
|
let n = e.trim();
|
|
461
467
|
if (!n) return null;
|
|
462
468
|
let r = fe.exec(n);
|
|
463
|
-
return r && !F.test(n) ? N(Number(r[1]), Number(r[2]), Number(r[3]), r[4], r[5]) : F.test(n) ? M(new Date(n)) : t === "dd-mm-yyyy" || t === "dd/mm/yyyy" ? (r = pe.exec(n), r ? N(Number(r[3]), Number(r[2]), Number(r[1]), r[4], r[5]) : null) : t === "yyyy-mm-dd" ? (r =
|
|
469
|
+
return r && !F.test(n) ? N(Number(r[1]), Number(r[2]), Number(r[3]), r[4], r[5]) : F.test(n) ? M(new Date(n)) : t === "dd-mm-yyyy" || t === "dd/mm/yyyy" ? (r = pe.exec(n), r ? N(Number(r[3]), Number(r[2]), Number(r[1]), r[4], r[5]) : null) : t === "yyyy-mm-dd" ? (r = me.exec(n), r ? N(Number(r[1]), Number(r[2]), Number(r[3]), r[4], r[5]) : null) : /[a-z]/i.test(n) ? M(new Date(n)) : null;
|
|
464
470
|
}
|
|
465
|
-
var
|
|
466
|
-
function
|
|
471
|
+
var ge = (e) => e ? e.slice(0, 10) : null, _e = (e, t) => e < t ? -1 : +(e > t);
|
|
472
|
+
function z(e, t = "dd-mm-yyyy") {
|
|
467
473
|
if (!e) return "";
|
|
468
|
-
let n =
|
|
474
|
+
let n = E(e.slice(0, 10), t);
|
|
469
475
|
return e.length > 10 ? `${n} ${e.slice(11, 16)}` : n;
|
|
470
476
|
}
|
|
471
|
-
function
|
|
477
|
+
function ve(e, t, n, r) {
|
|
472
478
|
let i = e == null, a = t == null;
|
|
473
479
|
return i && a ? 0 : i ? n ? -1 : 1 : a ? n ? 1 : -1 : r(e, t);
|
|
474
480
|
}
|
|
475
|
-
var
|
|
481
|
+
var B = [
|
|
476
482
|
25,
|
|
477
483
|
50,
|
|
478
484
|
100,
|
|
479
485
|
500,
|
|
480
486
|
-1
|
|
481
|
-
],
|
|
487
|
+
], ye = [
|
|
482
488
|
25,
|
|
483
489
|
50,
|
|
484
490
|
100
|
|
485
|
-
],
|
|
491
|
+
], V = { pageSize: 25 }, H = {
|
|
486
492
|
multiSort: !1,
|
|
487
493
|
defaultSort: []
|
|
488
|
-
},
|
|
494
|
+
}, U = { advanced: !0 }, be = [
|
|
489
495
|
"xlsx",
|
|
490
496
|
"pdf",
|
|
491
497
|
"csv",
|
|
492
498
|
"html",
|
|
493
499
|
"json"
|
|
494
|
-
],
|
|
495
|
-
function
|
|
500
|
+
], W = { mode: "multiple" };
|
|
501
|
+
function xe() {
|
|
496
502
|
return {
|
|
497
|
-
id:
|
|
503
|
+
id: G(),
|
|
498
504
|
logic: "AND",
|
|
499
505
|
conditions: []
|
|
500
506
|
};
|
|
501
507
|
}
|
|
502
|
-
function
|
|
503
|
-
return e.pagination === !1 ? !1 : e.pagination === !0 || e.pagination === void 0 ?
|
|
504
|
-
...
|
|
508
|
+
function Se(e) {
|
|
509
|
+
return e.pagination === !1 ? !1 : e.pagination === !0 || e.pagination === void 0 ? V : {
|
|
510
|
+
...V,
|
|
505
511
|
...e.pagination
|
|
506
512
|
};
|
|
507
513
|
}
|
|
508
|
-
function
|
|
514
|
+
function Ce(e, t) {
|
|
509
515
|
let n = (t ?? []).filter((e) => e > 0);
|
|
510
516
|
return n.length === 0 ? e > 0 ? e : 25 : n.includes(e) ? e : n[0];
|
|
511
517
|
}
|
|
512
|
-
function
|
|
518
|
+
function we(e, t, n = B) {
|
|
513
519
|
return e || [...[...new Set([...n, ...t.map((e) => e ?? 0)].filter((e) => e > 0))].sort((e, t) => e - t), ...n.includes(-1) ? [-1] : []];
|
|
514
520
|
}
|
|
515
|
-
function
|
|
521
|
+
function Te(e) {
|
|
516
522
|
return JSON.stringify(e ?? {}, (e, t) => t && typeof t == "object" && !Array.isArray(t) ? Object.fromEntries(Object.entries(t).sort(([e], [t]) => e < t ? -1 : +(e > t))) : t);
|
|
517
523
|
}
|
|
518
|
-
function
|
|
519
|
-
return e.sorting === !1 ? !1 : e.sorting === !0 || e.sorting === void 0 ?
|
|
520
|
-
...
|
|
524
|
+
function Ee(e) {
|
|
525
|
+
return e.sorting === !1 ? !1 : e.sorting === !0 || e.sorting === void 0 ? H : {
|
|
526
|
+
...H,
|
|
521
527
|
...e.sorting
|
|
522
528
|
};
|
|
523
529
|
}
|
|
524
|
-
function
|
|
525
|
-
return e.filtering === !1 ? !1 : e.filtering === !0 || e.filtering === void 0 ?
|
|
526
|
-
...
|
|
530
|
+
function De(e) {
|
|
531
|
+
return e.filtering === !1 ? !1 : e.filtering === !0 || e.filtering === void 0 ? U : {
|
|
532
|
+
...U,
|
|
527
533
|
...e.filtering
|
|
528
534
|
};
|
|
529
535
|
}
|
|
530
|
-
function
|
|
536
|
+
function Oe(e) {
|
|
531
537
|
if (!e.export) return !1;
|
|
532
538
|
let t = { ...e.export };
|
|
533
539
|
return t.quick && (t.quick.enabled === void 0 && (t.quick = {
|
|
@@ -535,49 +541,49 @@ function we(e) {
|
|
|
535
541
|
enabled: !0
|
|
536
542
|
}), t.quick.formats || (t.quick = {
|
|
537
543
|
...t.quick,
|
|
538
|
-
formats:
|
|
544
|
+
formats: be
|
|
539
545
|
}), t.quick.fileNameAs || (t.quick = {
|
|
540
546
|
...t.quick,
|
|
541
547
|
fileNameAs: "title-date-generated"
|
|
542
548
|
})), t;
|
|
543
549
|
}
|
|
544
|
-
function
|
|
550
|
+
function ke(e) {
|
|
545
551
|
let t = e.selection === void 0 ? "onDemand" : e.selection;
|
|
546
552
|
return t ? t === !0 || t === "onDemand" ? {
|
|
547
|
-
...
|
|
553
|
+
...W,
|
|
548
554
|
show: "onDemand"
|
|
549
555
|
} : t === "always" ? {
|
|
550
|
-
...
|
|
556
|
+
...W,
|
|
551
557
|
show: "always"
|
|
552
558
|
} : {
|
|
553
|
-
...
|
|
559
|
+
...W,
|
|
554
560
|
...t,
|
|
555
561
|
show: t.show ?? "onDemand"
|
|
556
562
|
} : !1;
|
|
557
563
|
}
|
|
558
|
-
function
|
|
564
|
+
function G() {
|
|
559
565
|
return Math.random().toString(36).substring(2, 10);
|
|
560
566
|
}
|
|
561
|
-
function
|
|
562
|
-
return t.split(".").reduce((e, t) => e?.[t], e);
|
|
567
|
+
function K(e, t) {
|
|
568
|
+
return t.includes(".") ? t.split(".").reduce((e, t) => e?.[t], e) : e?.[t];
|
|
563
569
|
}
|
|
564
570
|
// src/components/DataTable/columnValue.ts
|
|
565
|
-
var
|
|
566
|
-
function
|
|
567
|
-
return e.value ? e.value(t) :
|
|
571
|
+
var Ae = "dd-mm-yyyy";
|
|
572
|
+
function q(e, t) {
|
|
573
|
+
return e.value ? e.value(t) : K(t, e.key);
|
|
568
574
|
}
|
|
569
|
-
function
|
|
575
|
+
function J(e, t, n) {
|
|
570
576
|
return L(typeof e.parse == "function" ? e.parse(t, n) : t, typeof e.parse == "string" ? e.parse : void 0);
|
|
571
577
|
}
|
|
572
|
-
var
|
|
573
|
-
function
|
|
574
|
-
return e.filterAccessor ? L(e.filterAccessor(t), typeof e.parse == "string" ? e.parse : void 0) :
|
|
578
|
+
var je = (e, t) => J(e, q(e, t), t);
|
|
579
|
+
function Me(e, t, n) {
|
|
580
|
+
return e.filterAccessor ? L(e.filterAccessor(t), typeof e.parse == "string" ? e.parse : void 0) : J(e, t, n);
|
|
575
581
|
}
|
|
576
|
-
function
|
|
577
|
-
let r =
|
|
578
|
-
return r ?
|
|
582
|
+
function Y(e, t, n) {
|
|
583
|
+
let r = J(e, t, n);
|
|
584
|
+
return r ? z(r, e.dateFormat ?? "dd-mm-yyyy") : t == null ? "" : String(t);
|
|
579
585
|
}
|
|
580
|
-
function
|
|
586
|
+
function Ne(e, t, n) {
|
|
581
587
|
switch (t) {
|
|
582
588
|
case "integer": return n.number(e, 0);
|
|
583
589
|
case "amount": return n.number(e, 2);
|
|
@@ -586,52 +592,53 @@ function Oe(e, t, n) {
|
|
|
586
592
|
default: return String(e);
|
|
587
593
|
}
|
|
588
594
|
}
|
|
589
|
-
function
|
|
595
|
+
function X(e, t, n, r) {
|
|
590
596
|
if (e.format) {
|
|
591
597
|
let n = e.format(t, r);
|
|
592
598
|
return n == null ? "" : String(n);
|
|
593
599
|
}
|
|
594
|
-
if (e.type === "date" || t instanceof Date) return
|
|
600
|
+
if (e.type === "date" || t instanceof Date) return Y(e, t, r);
|
|
595
601
|
if (t == null) return "";
|
|
596
|
-
if (Array.isArray(t)) return t.map((t) =>
|
|
602
|
+
if (Array.isArray(t)) return t.map((t) => X({
|
|
597
603
|
...e,
|
|
598
604
|
format: void 0
|
|
599
605
|
}, t, n, r)).filter(Boolean).join(", ");
|
|
600
606
|
if (typeof t == "boolean") return t ? n.yes : n.no;
|
|
601
607
|
let i = e.filterOptions?.find((e) => String(e.value) === String(t));
|
|
602
|
-
return i ? i.label : typeof t == "number" && e.numberFormat && n.fmt && Number.isFinite(t) ?
|
|
608
|
+
return i ? i.label : typeof t == "number" && e.numberFormat && n.fmt && Number.isFinite(t) ? Ne(t, e.numberFormat, n.fmt) : typeof t == "object" ? "" : String(t);
|
|
603
609
|
}
|
|
604
|
-
var
|
|
605
|
-
function
|
|
606
|
-
let r =
|
|
610
|
+
var Pe = (e, t, n) => X(e, q(e, t), n, t);
|
|
611
|
+
function Fe(e, t, n) {
|
|
612
|
+
let r = q(e, t);
|
|
607
613
|
if (e.searchText) return e.searchText(r, t) ?? "";
|
|
608
|
-
let i =
|
|
614
|
+
let i = X(e, r, n, t), a = r == null || typeof r == "object" ? "" : String(r);
|
|
609
615
|
return a && a !== i ? `${i} ${a}` : i;
|
|
610
616
|
}
|
|
611
|
-
var
|
|
612
|
-
function
|
|
617
|
+
var Z = (e) => e == null || e === "" || typeof e == "number" && Number.isNaN(e);
|
|
618
|
+
function Ie(e, t, n, r) {
|
|
613
619
|
if (e.sortValue) {
|
|
614
620
|
let r = e.sortValue(t, n);
|
|
615
|
-
return
|
|
621
|
+
return Z(r) ? null : r;
|
|
616
622
|
}
|
|
617
|
-
if (e.type === "date") return
|
|
618
|
-
if (
|
|
623
|
+
if (e.type === "date") return J(e, t, n);
|
|
624
|
+
if (Z(t)) return null;
|
|
619
625
|
if (e.type === "number") {
|
|
620
626
|
let e = typeof t == "number" ? t : Number(t);
|
|
621
627
|
return Number.isFinite(e) ? e : null;
|
|
622
628
|
}
|
|
623
629
|
if (typeof t == "boolean") return +!!t;
|
|
624
|
-
let i =
|
|
630
|
+
let i = X({
|
|
625
631
|
...e,
|
|
626
632
|
format: void 0,
|
|
627
633
|
numberFormat: void 0
|
|
628
634
|
}, t, r, n);
|
|
629
635
|
return i === "" ? null : i;
|
|
630
636
|
}
|
|
631
|
-
|
|
632
|
-
|
|
637
|
+
var Q;
|
|
638
|
+
function $(e, t) {
|
|
639
|
+
return typeof e == "number" && typeof t == "number" ? e - t : (Q ??= new Intl.Collator(void 0, {
|
|
633
640
|
numeric: !0,
|
|
634
641
|
sensitivity: "base"
|
|
635
|
-
});
|
|
642
|
+
}), Q.compare(String(e), String(t)));
|
|
636
643
|
}
|
|
637
|
-
export {
|
|
644
|
+
export { O as $, ae as A, E as B, ke as C, z as D, _e as E, c as F, se as G, b as H, te as I, a as J, ee as K, x as L, ie as M, A as N, ge as O, de as P, f as Q, ue as R, Se as S, ve as T, ce as U, h as V, oe as W, u as X, l as Y, y as Z, K as _, q as a, Oe as b, Me as c, X as d, i as et, B as f, G as g, Ce as h, Pe as i, _ as it, e as j, L as k, Fe as l, xe as m, je as n, le as nt, $ as o, ye as p, re as q, J as r, m as rt, Y as s, Ae as t, o as tt, Ie as u, we as v, Ee as w, De as x, Te as y, ne as z };
|