@konstructio/ui 0.1.2-alpha.103 → 0.1.2-alpha.105
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/README.md +15 -21
- package/dist/{AdditionalOptions-Cj29eeMF.js → AdditionalOptions-D0BAS2HG.js} +1 -1
- package/dist/{AlertDialogTrigger-CgcsW_ta.js → AlertDialogTrigger-BGo_acd5.js} +3 -3
- package/dist/{Checkbox-DzAx7n67.js → Checkbox-B_ngk9Dj.js} +56 -56
- package/dist/{Combination-cjXRJS03.js → Combination-CnMM05mt.js} +51 -45
- package/dist/{CommandInput-BnvRMfLI.js → CommandInput-BLq69pOT.js} +1 -1
- package/dist/Counter-BV680M5r.js +195 -0
- package/dist/DropdownButton-DfNojmCW.js +493 -0
- package/dist/{FlagSelectorList-BoYG-_It.js → FlagSelectorList-CkTR3j6O.js} +222 -218
- package/dist/{HamburgerTrigger-1vOTrm8-.js → HamburgerTrigger-DRylBL2d.js} +1 -1
- package/dist/{ImageUpload-DZTm4SBB.js → ImageUpload-DiwymQcU.js} +1 -1
- package/dist/{Input-CW0VwW2T.js → Input-Cf44DzfE.js} +18 -18
- package/dist/{Loading-fD0Xiyeq.js → Loading-DUh9PMJN.js} +3 -1
- package/dist/Modal-Dyn088X7.js +81 -0
- package/dist/Sidebar.css +1 -1
- package/dist/{Spinner-Lw9mZYhg.js → Spinner-CUwE2bLm.js} +1 -1
- package/dist/{Switch-WBRr8uOJ.js → Switch-aPhL5rNG.js} +4 -4
- package/dist/{Toast-ByH-l4XK.js → Toast-3NEz7LLa.js} +149 -148
- package/dist/Wrapper-CVJSuYWx.js +114 -0
- package/dist/{Wrapper-XeeD3av7.js → Wrapper-DP6Sxngx.js} +185 -180
- package/dist/Wrapper-R8fik3ah.js +182 -0
- package/dist/components/Alert/Alert.js +21 -21
- package/dist/components/AlertDialog/AlertDialog.js +1 -1
- package/dist/components/AlertDialog/components/AlertDialogTrigger.js +1 -1
- package/dist/components/AlertDialog/components/index.js +1 -1
- package/dist/components/AlertDialog/hooks/useAlertDialog.js +14 -10
- package/dist/components/Autocomplete/components/List/List.js +22 -26
- package/dist/components/Autocomplete/components/List/List.variants.js +7 -19
- package/dist/components/Autocomplete/hooks/useAutocomplete.js +39 -38
- package/dist/components/Autocomplete/hooks/useNavigationList.js +2 -1
- package/dist/components/Badge/Badge.js +37 -36
- package/dist/components/Button/Button.js +1 -1
- package/dist/components/Checkbox/Checkbox.js +1 -1
- package/dist/components/Command/Command.js +2 -2
- package/dist/components/Command/components/Command.js +6 -6
- package/dist/components/Command/components/CommandEmpty.js +1 -1
- package/dist/components/Command/components/CommandGroup.js +1 -1
- package/dist/components/Command/components/CommandInput.js +1 -1
- package/dist/components/Command/components/CommandItem.js +1 -1
- package/dist/components/Command/components/CommandList.js +2 -2
- package/dist/components/Command/components/CommandSeparator.js +1 -1
- package/dist/components/Command/components/DialogContent.js +2 -2
- package/dist/components/Command/components/DialogOverlay.js +1 -1
- package/dist/components/Command/components/index.js +1 -1
- package/dist/components/Command/contexts/Command.provider.js +16 -12
- package/dist/components/Counter/Counter.js +1 -1
- package/dist/components/DateRangePicker/components/CalendarPanel/components/CalendarMonth/CalendarMonth.js +1 -1
- package/dist/components/DateRangePicker/components/CalendarPanel/components/IndependentModeCalendar/IndependentModeCalendar.js +57 -58
- package/dist/components/DateRangePicker/components/CalendarPanel/components/TogetherModeCalendar/TogetherModeCalendar.js +42 -43
- package/dist/components/DateRangePicker/components/CalendarPanel/constants/dayPickerClassNames.js +1 -1
- package/dist/components/DateRangePicker/components/CalendarPanel/constants/index.js +1 -1
- package/dist/components/DateRangePicker/components/CalendarPanel/hooks/index.js +1 -1
- package/dist/components/DateRangePicker/components/CalendarPanel/hooks/useIndependentCarousel.js +42 -50
- package/dist/components/DateRangePicker/components/CalendarPanel/hooks/useTogetherCarousel.js +61 -79
- package/dist/components/DateRangePicker/components/CalendarPanel/utils/index.js +1 -1
- package/dist/components/DateRangePicker/components/DateTimeInputs/components/EndInputFields/EndInputFields.js +1 -1
- package/dist/components/DateRangePicker/components/DateTimeInputs/components/StartInputFields/StartInputFields.js +1 -1
- package/dist/components/DateRangePicker/components/DateTimeInputs/hooks/useDateTimeInputs.js +89 -122
- package/dist/components/Datepicker/DatePicker.js +13 -13
- package/dist/components/Drawer/Drawer.js +54 -49
- package/dist/components/Drawer/hooks/useDrawer.js +39 -44
- package/dist/components/DropdownButton/DropdownButton.js +1 -1
- package/dist/components/Filter/Filter.js +23 -22
- package/dist/components/Filter/components/BadgeDropdown/BadgeMultiSelect.hook.js +42 -56
- package/dist/components/Filter/components/BadgeDropdown/BadgeMultiSelect.js +1 -1
- package/dist/components/Filter/components/DateFilterDropdown/DateFilterDropdown.hook.js +30 -43
- package/dist/components/Filter/components/DateRangeFilterDropdown/DateRangeFilterDropdown.hook.js +36 -49
- package/dist/components/Filter/components/FilterDropdown/FilterDropdown.js +1 -1
- package/dist/components/Filter/components/ResetButton/ResetButton.js +21 -18
- package/dist/components/Filter/components/TextMultiSelect/TextMultiSelect.js +1 -1
- package/dist/components/Filter/components/TimeFilterDropdown/TimeFilterDropdown.hook.js +31 -45
- package/dist/components/Filter/contexts/filter.provider.js +15 -10
- package/dist/components/Filter/events/index.js +26 -5
- package/dist/components/Filter/hooks/index.js +4 -0
- package/dist/components/Filter/hooks/useFilterDropdownSync.js +26 -0
- package/dist/components/ImageUpload/ImageUpload.js +1 -1
- package/dist/components/Input/Input.js +1 -1
- package/dist/components/Loading/Loading.js +1 -1
- package/dist/components/Modal/Modal.js +1 -1
- package/dist/components/Modal/components/Body/Body.js +1 -1
- package/dist/components/Modal/components/Footer/Footer.js +1 -1
- package/dist/components/Modal/components/Header/Header.js +1 -1
- package/dist/components/Modal/components/Wrapper/Wrapper.js +1 -1
- package/dist/components/Modal/components/index.js +1 -1
- package/dist/components/Modal/contexts/Modal.provider.js +26 -19
- package/dist/components/MultiSelectDropdown/MultiSelectDropdown.js +1 -1
- package/dist/components/MultiSelectDropdown/components/List/List.js +1 -1
- package/dist/components/MultiSelectDropdown/components/Wrapper/Wrapper.js +1 -1
- package/dist/components/MultiSelectDropdown/components/index.js +1 -1
- package/dist/components/MultiSelectDropdown/hooks/useMultiSelectDropdown.js +14 -13
- package/dist/components/PhoneNumberInput/PhoneNumberInput.js +1 -1
- package/dist/components/PhoneNumberInput/components/FlagContent/FlagContent.js +6 -4
- package/dist/components/PhoneNumberInput/components/FlagSelectorList/FlagSelectorList.js +1 -1
- package/dist/components/PhoneNumberInput/components/FlagSelectorWrapper/FlagSelectorWrapper.js +16 -16
- package/dist/components/PhoneNumberInput/components/TruncateText/TruncateText.js +1 -1
- package/dist/components/PhoneNumberInput/components/Wrapper.js +1 -1
- package/dist/components/PhoneNumberInput/components/index.js +2 -2
- package/dist/components/PieChart/PieChart.js +33 -32
- package/dist/components/ProgressBar/ProgressBar.js +26 -20
- package/dist/components/Radio/Radio.js +28 -30
- package/dist/components/RadioCardGroup/RadioCardGroup.js +18 -18
- package/dist/components/RadioGroup/RadioGroup.js +24 -24
- package/dist/components/Range/Range.js +15 -13
- package/dist/components/Select/Select.js +2 -2
- package/dist/components/Select/components/AdditionalOptions/AdditionalOptions.js +1 -1
- package/dist/components/Select/components/List/List.js +2 -2
- package/dist/components/Select/components/ListItem/ListItem.js +30 -30
- package/dist/components/Select/components/Wrapper.js +1 -1
- package/dist/components/Select/components/index.js +2 -2
- package/dist/components/Select/hooks/useSelect.js +28 -39
- package/dist/components/Sidebar/Sidebar.js +21 -18
- package/dist/components/Sidebar/components/CollapseTrigger/CollapseTrigger.js +30 -0
- package/dist/components/Sidebar/components/CollapseTrigger/CollapseTrigger.variants.js +20 -0
- package/dist/components/Sidebar/components/HamburgerTrigger/HamburgerTrigger.js +1 -1
- package/dist/components/Sidebar/components/Logo/Logo.js +14 -10
- package/dist/components/Sidebar/components/Logo/Logo.variants.js +14 -4
- package/dist/components/Sidebar/components/NavigationOption/NavigationOption.js +41 -37
- package/dist/components/Sidebar/components/NavigationOption/NavigationOption.variants.js +4 -5
- package/dist/components/Sidebar/components/Wrapper/Wrapper.js +75 -68
- package/dist/components/Sidebar/components/index.js +17 -15
- package/dist/components/Sidebar/contexts/SidebarContext.js +8 -5
- package/dist/components/Slider/Slider.js +17 -15
- package/dist/components/Spinner/Spinner.js +1 -1
- package/dist/components/Stepper/Stepper.variants.js +6 -6
- package/dist/components/Stepper/hooks/useStepItemLogic.js +12 -17
- package/dist/components/Switch/Switch.js +1 -1
- package/dist/components/Table/components/Filter.js +1 -1
- package/dist/components/Tabs/Tabs.js +1 -1
- package/dist/components/Tabs/Tabs.variants.js +1 -1
- package/dist/components/Tabs/components/Content.js +1 -1
- package/dist/components/Tabs/components/List.js +1 -1
- package/dist/components/Tabs/components/Trigger.js +1 -1
- package/dist/components/Tag/Tag.js +1 -1
- package/dist/components/Tag/Tag.variants.js +17 -17
- package/dist/components/TagSelect/TagSelect.js +1 -1
- package/dist/components/TagSelect/components/Wrapper/Wrapper.js +1 -1
- package/dist/components/TagSelect/components/index.js +1 -1
- package/dist/components/TagSelect/hooks/useTagSelect.js +12 -11
- package/dist/components/TimePicker/components/HoursList/HoursList.js +34 -38
- package/dist/components/TimePicker/components/MeridianList/MeridianList.js +25 -29
- package/dist/components/TimePicker/components/MinutesList/MinutesList.js +33 -33
- package/dist/components/TimePicker/components/Wrapper/Wrapper.js +91 -99
- package/dist/components/TimePicker/components/WrapperList/WrapperList.js +29 -30
- package/dist/components/TimePicker/contexts/time-picker.provider.js +10 -10
- package/dist/components/Toast/Toast.js +1 -1
- package/dist/components/Toast/Toast.variants.js +1 -1
- package/dist/components/Tooltip/Tooltip.js +1 -1
- package/dist/components/VirtualizedTable/VirtualizedTable.js +32 -29
- package/dist/components/VirtualizedTable/components/Actions/Actions.js +0 -2
- package/dist/components/VirtualizedTable/components/Body/Body.js +5 -5
- package/dist/components/VirtualizedTable/components/DropdownPaginate/DropdownPaginate.js +1 -1
- package/dist/components/VirtualizedTable/components/Filter/Filter.js +55 -53
- package/dist/components/VirtualizedTable/components/FormPaginate/FormPaginate.js +1 -1
- package/dist/components/VirtualizedTable/components/Header/Header.js +1 -1
- package/dist/components/VirtualizedTable/contexts/index.js +1 -1
- package/dist/components/VirtualizedTable/contexts/table.provider.js +1 -1
- package/dist/components/VirtualizedTable/events/filters/filters.js +7 -0
- package/dist/components/VirtualizedTable/events/index.js +10 -25
- package/dist/components/VirtualizedTable/events/refresh/refresh.js +7 -0
- package/dist/components/VirtualizedTable/events/row/row.js +22 -0
- package/dist/components/VirtualizedTable/utils/get-table-id.js +4 -0
- package/dist/components/VirtualizedTable/utils/index.js +4 -2
- package/dist/components/index.js +95 -89
- package/dist/{components-BIHlj4yH.js → components-Cf345jTv.js} +45 -41
- package/dist/constants-CxJJRVK3.js +31 -0
- package/dist/{dist-DISvWx7U.js → dist-BUocnzkM.js} +1 -1
- package/dist/{dist-Dse3gSmZ.js → dist-BZNE2Tnx.js} +4 -4
- package/dist/{dist-2bGlmy8N2.js → dist-BaPW7qXd2.js} +27 -26
- package/dist/dist-BdobXn93.js +192 -0
- package/dist/dist-BlPTJNIm.js +118 -0
- package/dist/{dist-BiJrNvNo.js → dist-C3YVLapk.js} +29 -28
- package/dist/dist-C4j75TwZ.js +20 -0
- package/dist/dist-CCdbu9GU.js +46 -0
- package/dist/dist-CzKqHuqJ2.js +427 -0
- package/dist/dist-D-yS0HN8.js +228 -0
- package/dist/dist-D5XYRjmR.js +15 -0
- package/dist/dist-DDck_2lb.js +451 -0
- package/dist/{dist-C2aTw0m62.js → dist-DFCz63oC2.js} +5 -5
- package/dist/dist-DGOjiAnB2.js +14 -0
- package/dist/dist-DKryKPmP.js +193 -0
- package/dist/{dist-CTvBzxW8.js → dist-DX0sBG3Q.js} +1 -1
- package/dist/dist-DYIabsrY.js +17 -0
- package/dist/dist-pWlMx4Fi2.js +36 -0
- package/dist/{dist-CVDFmWf2.js → dist-tGUUcv8n.js} +17 -16
- package/dist/dist-xCbHbMLA.js +116 -0
- package/dist/{es2015-BWf6xQHm.js → es2015-CoHq2g4y.js} +95 -86
- package/dist/es2015-DigR3dar.js +795 -0
- package/dist/events.types-BG1Uh8i6.js +6 -0
- package/dist/hooks/index.js +6 -4
- package/dist/hooks/useClickOutside.js +14 -0
- package/dist/index.js +146 -138
- package/dist/lib/components/Autocomplete/components/List/List.variants.d.ts +0 -1
- package/dist/lib/components/DropdownButton/DropdownButton.d.ts +5 -6
- package/dist/lib/components/DropdownButton/DropdownButton.types.d.ts +2 -0
- package/dist/lib/components/Filter/Filter.types.d.ts +2 -0
- package/dist/lib/components/Filter/contexts/filter.context.d.ts +1 -0
- package/dist/lib/components/Filter/events/index.d.ts +10 -2
- package/dist/lib/components/Filter/hooks/index.d.ts +1 -0
- package/dist/lib/components/Filter/hooks/useFilterDropdownSync.d.ts +2 -0
- package/dist/lib/components/Filter/hooks/useFilterDropdownSync.types.d.ts +5 -0
- package/dist/lib/components/PieChart/PieChart.types.d.ts +4 -4
- package/dist/lib/components/ProgressBar/ProgressBar.types.d.ts +2 -0
- package/dist/lib/components/Select/hooks/useSelect.d.ts +2 -3
- package/dist/lib/components/Sidebar/Sidebar.d.ts +2 -2
- package/dist/lib/components/Sidebar/Sidebar.types.d.ts +6 -5
- package/dist/lib/components/Sidebar/components/CollapseTrigger/CollapseTrigger.d.ts +4 -0
- package/dist/lib/components/Sidebar/components/CollapseTrigger/CollapseTrigger.types.d.ts +4 -0
- package/dist/lib/components/Sidebar/components/CollapseTrigger/CollapseTrigger.variants.d.ts +1 -0
- package/dist/lib/components/Sidebar/components/Logo/Logo.types.d.ts +8 -0
- package/dist/lib/components/Sidebar/components/Logo/Logo.variants.d.ts +3 -1
- package/dist/lib/components/Sidebar/components/index.d.ts +2 -0
- package/dist/lib/components/Sidebar/contexts/SidebarContext.d.ts +12 -0
- package/dist/lib/components/VirtualizedTable/VirtualizedTable.d.ts +1 -0
- package/dist/lib/components/VirtualizedTable/events/events.types.d.ts +11 -0
- package/dist/lib/components/VirtualizedTable/events/filters/filters.d.ts +1 -0
- package/dist/lib/components/VirtualizedTable/events/index.d.ts +4 -14
- package/dist/lib/components/VirtualizedTable/events/refresh/refresh.d.ts +2 -0
- package/dist/lib/components/VirtualizedTable/events/refresh/refresh.types.d.ts +3 -0
- package/dist/lib/components/VirtualizedTable/events/row/row.d.ts +3 -0
- package/dist/lib/components/VirtualizedTable/utils/get-table-id.d.ts +1 -0
- package/dist/lib/components/VirtualizedTable/utils/index.d.ts +1 -0
- package/dist/lib/components/index.d.ts +2 -2
- package/dist/lib/hooks/index.d.ts +1 -0
- package/dist/lib/hooks/useClickOutside.d.ts +2 -0
- package/dist/package.json +24 -24
- package/dist/styles.css +1 -1
- package/dist/{table.provider-2sAkE7z_.js → table.provider-B0BafHuU.js} +395 -381
- package/dist/ui/civo-theme.css +4 -0
- package/dist/ui/kubefirst-theme.css +4 -0
- package/package.json +24 -24
- package/dist/Counter-CY0xGnVM.js +0 -208
- package/dist/DropdownButton-DnlwdPmb.js +0 -92
- package/dist/Modal-Bfzggwlr.js +0 -76
- package/dist/Wrapper-ClJ_Mham.js +0 -110
- package/dist/Wrapper-DNEn4fef.js +0 -161
- package/dist/constants-DXrF9vV4.js +0 -31
- package/dist/dist-B-Aoze_D.js +0 -10
- package/dist/dist-BuFiu480.js +0 -13
- package/dist/dist-C2s4VX-42.js +0 -31
- package/dist/dist-CT6d9xe7.js +0 -441
- package/dist/dist-CVy-ulDZ.js +0 -42
- package/dist/dist-D4FePjTS.js +0 -194
- package/dist/dist-Db6UeFo4.js +0 -291
- package/dist/dist-DqKFpce5.js +0 -98
- package/dist/dist-j7FOUrFU.js +0 -206
- package/dist/dist-l-aDnQZC.js +0 -62
- package/dist/dist-ppXKUlVt.js +0 -10
- /package/dist/{x-a_LpoXzG.js → x-a_LpoXzG2.js} +0 -0
|
@@ -1,31 +1,32 @@
|
|
|
1
|
-
import { n as
|
|
2
|
-
import { t as
|
|
3
|
-
import { t as
|
|
1
|
+
import { n as zt } from "./dist-DX0sBG3Q.js";
|
|
2
|
+
import { t as J } from "./utils-Cx-WzRZF.js";
|
|
3
|
+
import { t as Tt } from "./chevron-right-CDwgDdp-.js";
|
|
4
4
|
import "./components/VirtualizedTable/constants/pagination.js";
|
|
5
|
-
import { TableContext as
|
|
6
|
-
import {
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
|
|
5
|
+
import { TableContext as Bt } from "./components/VirtualizedTable/contexts/table.context.js";
|
|
6
|
+
import { getTableId as Je } from "./components/VirtualizedTable/utils/get-table-id.js";
|
|
7
|
+
import { t as fe } from "./events.types-BG1Uh8i6.js";
|
|
8
|
+
import * as Le from "react";
|
|
9
|
+
import { useCallback as z, useEffect as k, useMemo as U, useRef as b, useState as I } from "react";
|
|
10
|
+
import { jsx as ce } from "react/jsx-runtime";
|
|
11
|
+
import { useQuery as qt } from "@tanstack/react-query";
|
|
12
|
+
function T(e, o) {
|
|
12
13
|
return typeof e == "function" ? e(o) : e;
|
|
13
14
|
}
|
|
14
15
|
function x(e, o) {
|
|
15
16
|
return (t) => {
|
|
16
17
|
o.setState((n) => ({
|
|
17
18
|
...n,
|
|
18
|
-
[e]:
|
|
19
|
+
[e]: T(t, n[e])
|
|
19
20
|
}));
|
|
20
21
|
};
|
|
21
22
|
}
|
|
22
|
-
function
|
|
23
|
+
function Ce(e) {
|
|
23
24
|
return e instanceof Function;
|
|
24
25
|
}
|
|
25
|
-
function
|
|
26
|
+
function Nt(e) {
|
|
26
27
|
return Array.isArray(e) && e.every((o) => typeof o == "number");
|
|
27
28
|
}
|
|
28
|
-
function
|
|
29
|
+
function jt(e, o) {
|
|
29
30
|
const t = [], n = (r) => {
|
|
30
31
|
r.forEach((i) => {
|
|
31
32
|
t.push(i);
|
|
@@ -67,7 +68,7 @@ function C(e, o, t, n) {
|
|
|
67
68
|
onChange: n
|
|
68
69
|
};
|
|
69
70
|
}
|
|
70
|
-
function
|
|
71
|
+
function kt(e, o, t, n) {
|
|
71
72
|
const r = () => {
|
|
72
73
|
var l;
|
|
73
74
|
return (l = i.getValue()) != null ? l : e.options.renderFallbackValue;
|
|
@@ -95,7 +96,7 @@ function zt(e, o, t, n) {
|
|
|
95
96
|
l.createCell == null || l.createCell(i, t, o, e);
|
|
96
97
|
}, {}), i;
|
|
97
98
|
}
|
|
98
|
-
function
|
|
99
|
+
function Ut(e, o, t, n) {
|
|
99
100
|
var r, i;
|
|
100
101
|
const l = {
|
|
101
102
|
...e._getDefaultColumnDef(),
|
|
@@ -131,7 +132,7 @@ function Tt(e, o, t, n) {
|
|
|
131
132
|
return d;
|
|
132
133
|
}
|
|
133
134
|
var M = "debugHeaders";
|
|
134
|
-
function
|
|
135
|
+
function be(e, o, t) {
|
|
135
136
|
var n;
|
|
136
137
|
let r = {
|
|
137
138
|
id: (n = t.id) != null ? n : o.id,
|
|
@@ -160,7 +161,7 @@ function Xe(e, o, t) {
|
|
|
160
161
|
i.createHeader == null || i.createHeader(r, e);
|
|
161
162
|
}), r;
|
|
162
163
|
}
|
|
163
|
-
var
|
|
164
|
+
var Kt = { createTable: (e) => {
|
|
164
165
|
e.getHeaderGroups = m(() => [
|
|
165
166
|
e.getAllColumns(),
|
|
166
167
|
e.getVisibleLeafColumns(),
|
|
@@ -169,7 +170,7 @@ var Bt = { createTable: (e) => {
|
|
|
169
170
|
], (o, t, n, r) => {
|
|
170
171
|
var i, l;
|
|
171
172
|
const s = (i = n?.map((d) => t.find((g) => g.id === d)).filter(Boolean)) != null ? i : [], u = (l = r?.map((d) => t.find((g) => g.id === d)).filter(Boolean)) != null ? l : [], a = t.filter((d) => !(n != null && n.includes(d.id)) && !(r != null && r.includes(d.id)));
|
|
172
|
-
return
|
|
173
|
+
return pe(o, [
|
|
173
174
|
...s,
|
|
174
175
|
...a,
|
|
175
176
|
...u
|
|
@@ -179,20 +180,20 @@ var Bt = { createTable: (e) => {
|
|
|
179
180
|
e.getVisibleLeafColumns(),
|
|
180
181
|
e.getState().columnPinning.left,
|
|
181
182
|
e.getState().columnPinning.right
|
|
182
|
-
], (o, t, n, r) => (t = t.filter((i) => !(n != null && n.includes(i.id)) && !(r != null && r.includes(i.id))),
|
|
183
|
+
], (o, t, n, r) => (t = t.filter((i) => !(n != null && n.includes(i.id)) && !(r != null && r.includes(i.id))), pe(o, t, e, "center")), C(e.options, M, "getCenterHeaderGroups")), e.getLeftHeaderGroups = m(() => [
|
|
183
184
|
e.getAllColumns(),
|
|
184
185
|
e.getVisibleLeafColumns(),
|
|
185
186
|
e.getState().columnPinning.left
|
|
186
187
|
], (o, t, n) => {
|
|
187
188
|
var r;
|
|
188
|
-
return
|
|
189
|
+
return pe(o, (r = n?.map((i) => t.find((l) => l.id === i)).filter(Boolean)) != null ? r : [], e, "left");
|
|
189
190
|
}, C(e.options, M, "getLeftHeaderGroups")), e.getRightHeaderGroups = m(() => [
|
|
190
191
|
e.getAllColumns(),
|
|
191
192
|
e.getVisibleLeafColumns(),
|
|
192
193
|
e.getState().columnPinning.right
|
|
193
194
|
], (o, t, n) => {
|
|
194
195
|
var r;
|
|
195
|
-
return
|
|
196
|
+
return pe(o, (r = n?.map((i) => t.find((l) => l.id === i)).filter(Boolean)) != null ? r : [], e, "right");
|
|
196
197
|
}, C(e.options, M, "getRightHeaderGroups")), e.getFooterGroups = m(() => [e.getHeaderGroups()], (o) => [...o].reverse(), C(e.options, M, "getFooterGroups")), e.getLeftFooterGroups = m(() => [e.getLeftHeaderGroups()], (o) => [...o].reverse(), C(e.options, M, "getLeftFooterGroups")), e.getCenterFooterGroups = m(() => [e.getCenterHeaderGroups()], (o) => [...o].reverse(), C(e.options, M, "getCenterFooterGroups")), e.getRightFooterGroups = m(() => [e.getRightHeaderGroups()], (o) => [...o].reverse(), C(e.options, M, "getRightFooterGroups")), e.getFlatHeaders = m(() => [e.getHeaderGroups()], (o) => o.map((t) => t.headers).flat(), C(e.options, M, "getFlatHeaders")), e.getLeftFlatHeaders = m(() => [e.getLeftHeaderGroups()], (o) => o.map((t) => t.headers).flat(), C(e.options, M, "getLeftFlatHeaders")), e.getCenterFlatHeaders = m(() => [e.getCenterHeaderGroups()], (o) => o.map((t) => t.headers).flat(), C(e.options, M, "getCenterFlatHeaders")), e.getRightFlatHeaders = m(() => [e.getRightHeaderGroups()], (o) => o.map((t) => t.headers).flat(), C(e.options, M, "getRightFlatHeaders")), e.getCenterLeafHeaders = m(() => [e.getCenterFlatHeaders()], (o) => o.filter((t) => {
|
|
197
198
|
var n;
|
|
198
199
|
return !((n = t.subHeaders) != null && n.length);
|
|
@@ -215,7 +216,7 @@ var Bt = { createTable: (e) => {
|
|
|
215
216
|
].map((d) => d.getLeafHeaders()).flat();
|
|
216
217
|
}, C(e.options, M, "getLeafHeaders"));
|
|
217
218
|
} };
|
|
218
|
-
function
|
|
219
|
+
function pe(e, o, t, n) {
|
|
219
220
|
var r, i;
|
|
220
221
|
let l = 0;
|
|
221
222
|
const s = function(g, f) {
|
|
@@ -233,36 +234,36 @@ function de(e, o, t, n) {
|
|
|
233
234
|
headers: []
|
|
234
235
|
}, p = [];
|
|
235
236
|
g.forEach((v) => {
|
|
236
|
-
const $ = [...p].reverse()[0],
|
|
237
|
-
let
|
|
238
|
-
if (
|
|
237
|
+
const $ = [...p].reverse()[0], h = v.column.depth === c.depth;
|
|
238
|
+
let w, _ = !1;
|
|
239
|
+
if (h && v.column.parent ? w = v.column.parent : (w = v.column, _ = !0), $ && $?.column === w) $.subHeaders.push(v);
|
|
239
240
|
else {
|
|
240
|
-
const
|
|
241
|
+
const L = be(t, w, {
|
|
241
242
|
id: [
|
|
242
243
|
n,
|
|
243
244
|
f,
|
|
244
|
-
|
|
245
|
+
w.id,
|
|
245
246
|
v?.id
|
|
246
247
|
].filter(Boolean).join("_"),
|
|
247
248
|
isPlaceholder: _,
|
|
248
|
-
placeholderId: _ ? `${p.filter((P) => P.column ===
|
|
249
|
+
placeholderId: _ ? `${p.filter((P) => P.column === w).length}` : void 0,
|
|
249
250
|
depth: f,
|
|
250
251
|
index: p.length
|
|
251
252
|
});
|
|
252
|
-
|
|
253
|
+
L.subHeaders.push(v), p.push(L);
|
|
253
254
|
}
|
|
254
255
|
c.headers.push(v), v.headerGroup = c;
|
|
255
256
|
}), u.push(c), f > 0 && a(p, f - 1);
|
|
256
257
|
};
|
|
257
|
-
a(o.map((g, f) =>
|
|
258
|
+
a(o.map((g, f) => be(t, g, {
|
|
258
259
|
depth: l,
|
|
259
260
|
index: f
|
|
260
261
|
})), l - 1), u.reverse();
|
|
261
262
|
const d = (g) => g.filter((f) => f.column.getIsVisible()).map((f) => {
|
|
262
263
|
let c = 0, p = 0, v = [0];
|
|
263
|
-
f.subHeaders && f.subHeaders.length ? (v = [], d(f.subHeaders).forEach((
|
|
264
|
-
let { colSpan:
|
|
265
|
-
c +=
|
|
264
|
+
f.subHeaders && f.subHeaders.length ? (v = [], d(f.subHeaders).forEach((h) => {
|
|
265
|
+
let { colSpan: w, rowSpan: _ } = h;
|
|
266
|
+
c += w, v.push(_);
|
|
266
267
|
})) : c = 1;
|
|
267
268
|
const $ = Math.min(...v);
|
|
268
269
|
return p = p + $, f.colSpan = c, f.rowSpan = p, {
|
|
@@ -272,7 +273,7 @@ function de(e, o, t, n) {
|
|
|
272
273
|
});
|
|
273
274
|
return d((r = (i = u[0]) == null ? void 0 : i.headers) != null ? r : []), u;
|
|
274
275
|
}
|
|
275
|
-
var
|
|
276
|
+
var Xt = (e, o, t, n, r, i, l) => {
|
|
276
277
|
let s = {
|
|
277
278
|
id: o,
|
|
278
279
|
index: n,
|
|
@@ -298,7 +299,7 @@ var qt = (e, o, t, n, r, i, l) => {
|
|
|
298
299
|
return (a = s.getValue(u)) != null ? a : e.options.renderFallbackValue;
|
|
299
300
|
},
|
|
300
301
|
subRows: i ?? [],
|
|
301
|
-
getLeafRows: () =>
|
|
302
|
+
getLeafRows: () => jt(s.subRows, (u) => u.subRows),
|
|
302
303
|
getParentRow: () => s.parentId ? e.getRow(s.parentId, !0) : void 0,
|
|
303
304
|
getParentRows: () => {
|
|
304
305
|
let u = [], a = s;
|
|
@@ -309,7 +310,7 @@ var qt = (e, o, t, n, r, i, l) => {
|
|
|
309
310
|
}
|
|
310
311
|
return u.reverse();
|
|
311
312
|
},
|
|
312
|
-
getAllCells: m(() => [e.getAllLeafColumns()], (u) => u.map((a) =>
|
|
313
|
+
getAllCells: m(() => [e.getAllLeafColumns()], (u) => u.map((a) => kt(e, s, a, a.id)), C(e.options, "debugRows", "getAllCells")),
|
|
313
314
|
_getAllCellsByColumnId: m(() => [s.getAllCells()], (u) => u.reduce((a, d) => (a[d.column.id] = d, a), {}), C(e.options, "debugRows", "getAllCellsByColumnId"))
|
|
314
315
|
};
|
|
315
316
|
for (let u = 0; u < e._features.length; u++) {
|
|
@@ -317,52 +318,52 @@ var qt = (e, o, t, n, r, i, l) => {
|
|
|
317
318
|
a == null || a.createRow == null || a.createRow(s, e);
|
|
318
319
|
}
|
|
319
320
|
return s;
|
|
320
|
-
},
|
|
321
|
+
}, Wt = { createColumn: (e, o) => {
|
|
321
322
|
e._getFacetedRowModel = o.options.getFacetedRowModel && o.options.getFacetedRowModel(o, e.id), e.getFacetedRowModel = () => e._getFacetedRowModel ? e._getFacetedRowModel() : o.getPreFilteredRowModel(), e._getFacetedUniqueValues = o.options.getFacetedUniqueValues && o.options.getFacetedUniqueValues(o, e.id), e.getFacetedUniqueValues = () => e._getFacetedUniqueValues ? e._getFacetedUniqueValues() : /* @__PURE__ */ new Map(), e._getFacetedMinMaxValues = o.options.getFacetedMinMaxValues && o.options.getFacetedMinMaxValues(o, e.id), e.getFacetedMinMaxValues = () => {
|
|
322
323
|
if (e._getFacetedMinMaxValues)
|
|
323
324
|
return e._getFacetedMinMaxValues();
|
|
324
325
|
};
|
|
325
|
-
} },
|
|
326
|
+
} }, nt = (e, o, t) => {
|
|
326
327
|
var n, r;
|
|
327
328
|
const i = t == null || (n = t.toString()) == null ? void 0 : n.toLowerCase();
|
|
328
329
|
return !!(!((r = e.getValue(o)) == null || (r = r.toString()) == null || (r = r.toLowerCase()) == null) && r.includes(i));
|
|
329
330
|
};
|
|
330
|
-
|
|
331
|
-
var
|
|
331
|
+
nt.autoRemove = (e) => A(e);
|
|
332
|
+
var ot = (e, o, t) => {
|
|
332
333
|
var n;
|
|
333
334
|
return !!(!((n = e.getValue(o)) == null || (n = n.toString()) == null) && n.includes(t));
|
|
334
335
|
};
|
|
335
|
-
|
|
336
|
-
var
|
|
336
|
+
ot.autoRemove = (e) => A(e);
|
|
337
|
+
var rt = (e, o, t) => {
|
|
337
338
|
var n;
|
|
338
339
|
return ((n = e.getValue(o)) == null || (n = n.toString()) == null ? void 0 : n.toLowerCase()) === t?.toLowerCase();
|
|
339
340
|
};
|
|
340
|
-
|
|
341
|
-
var
|
|
341
|
+
rt.autoRemove = (e) => A(e);
|
|
342
|
+
var it = (e, o, t) => {
|
|
342
343
|
var n;
|
|
343
344
|
return (n = e.getValue(o)) == null ? void 0 : n.includes(t);
|
|
344
345
|
};
|
|
345
|
-
|
|
346
|
-
var
|
|
346
|
+
it.autoRemove = (e) => A(e);
|
|
347
|
+
var lt = (e, o, t) => !t.some((n) => {
|
|
347
348
|
var r;
|
|
348
349
|
return !((r = e.getValue(o)) != null && r.includes(n));
|
|
349
350
|
});
|
|
350
|
-
|
|
351
|
-
var
|
|
351
|
+
lt.autoRemove = (e) => A(e) || !(e != null && e.length);
|
|
352
|
+
var st = (e, o, t) => t.some((n) => {
|
|
352
353
|
var r;
|
|
353
354
|
return (r = e.getValue(o)) == null ? void 0 : r.includes(n);
|
|
354
355
|
});
|
|
355
|
-
|
|
356
|
-
var
|
|
357
|
-
|
|
358
|
-
var
|
|
359
|
-
|
|
360
|
-
var
|
|
356
|
+
st.autoRemove = (e) => A(e) || !(e != null && e.length);
|
|
357
|
+
var ut = (e, o, t) => e.getValue(o) === t;
|
|
358
|
+
ut.autoRemove = (e) => A(e);
|
|
359
|
+
var at = (e, o, t) => e.getValue(o) == t;
|
|
360
|
+
at.autoRemove = (e) => A(e);
|
|
361
|
+
var Te = (e, o, t) => {
|
|
361
362
|
let [n, r] = t;
|
|
362
363
|
const i = e.getValue(o);
|
|
363
364
|
return i >= n && i <= r;
|
|
364
365
|
};
|
|
365
|
-
|
|
366
|
+
Te.resolveFilterValue = (e) => {
|
|
366
367
|
let [o, t] = e, n = typeof o != "number" ? parseFloat(o) : o, r = typeof t != "number" ? parseFloat(t) : t, i = o === null || Number.isNaN(n) ? -1 / 0 : n, l = t === null || Number.isNaN(r) ? 1 / 0 : r;
|
|
367
368
|
if (i > l) {
|
|
368
369
|
const s = i;
|
|
@@ -370,22 +371,22 @@ Ge.resolveFilterValue = (e) => {
|
|
|
370
371
|
}
|
|
371
372
|
return [i, l];
|
|
372
373
|
};
|
|
373
|
-
|
|
374
|
+
Te.autoRemove = (e) => A(e) || A(e[0]) && A(e[1]);
|
|
374
375
|
var H = {
|
|
375
|
-
includesString:
|
|
376
|
-
includesStringSensitive:
|
|
377
|
-
equalsString:
|
|
378
|
-
arrIncludes:
|
|
379
|
-
arrIncludesAll:
|
|
380
|
-
arrIncludesSome:
|
|
381
|
-
equals:
|
|
382
|
-
weakEquals:
|
|
383
|
-
inNumberRange:
|
|
376
|
+
includesString: nt,
|
|
377
|
+
includesStringSensitive: ot,
|
|
378
|
+
equalsString: rt,
|
|
379
|
+
arrIncludes: it,
|
|
380
|
+
arrIncludesAll: lt,
|
|
381
|
+
arrIncludesSome: st,
|
|
382
|
+
equals: ut,
|
|
383
|
+
weakEquals: at,
|
|
384
|
+
inNumberRange: Te
|
|
384
385
|
};
|
|
385
|
-
function
|
|
386
|
+
function A(e) {
|
|
386
387
|
return e == null || e === "";
|
|
387
388
|
}
|
|
388
|
-
var
|
|
389
|
+
var Qt = {
|
|
389
390
|
getDefaultColumnDef: () => ({ filterFn: "auto" }),
|
|
390
391
|
getInitialState: (e) => ({
|
|
391
392
|
columnFilters: [],
|
|
@@ -402,7 +403,7 @@ var jt = {
|
|
|
402
403
|
return typeof n == "string" ? H.includesString : typeof n == "number" ? H.inNumberRange : typeof n == "boolean" || n !== null && typeof n == "object" ? H.equals : Array.isArray(n) ? H.arrIncludes : H.weakEquals;
|
|
403
404
|
}, e.getFilterFn = () => {
|
|
404
405
|
var t, n;
|
|
405
|
-
return
|
|
406
|
+
return Ce(e.columnDef.filterFn) ? e.columnDef.filterFn : e.columnDef.filterFn === "auto" ? e.getAutoFilterFn() : (t = (n = o.options.filterFns) == null ? void 0 : n[e.columnDef.filterFn]) != null ? t : H[e.columnDef.filterFn];
|
|
406
407
|
}, e.getCanFilter = () => {
|
|
407
408
|
var t, n, r;
|
|
408
409
|
return ((t = e.columnDef.enableColumnFilter) != null ? t : !0) && ((n = o.options.enableColumnFilters) != null ? n : !0) && ((r = o.options.enableFilters) != null ? r : !0) && !!e.accessorFn;
|
|
@@ -414,8 +415,8 @@ var jt = {
|
|
|
414
415
|
return (t = (n = o.getState().columnFilters) == null ? void 0 : n.findIndex((r) => r.id === e.id)) != null ? t : -1;
|
|
415
416
|
}, e.setFilterValue = (t) => {
|
|
416
417
|
o.setColumnFilters((n) => {
|
|
417
|
-
const r = e.getFilterFn(), i = n?.find((d) => d.id === e.id), l =
|
|
418
|
-
if (
|
|
418
|
+
const r = e.getFilterFn(), i = n?.find((d) => d.id === e.id), l = T(t, i ? i.value : void 0);
|
|
419
|
+
if (et(r, l, e)) {
|
|
419
420
|
var s;
|
|
420
421
|
return (s = n?.filter((d) => d.id !== e.id)) != null ? s : [];
|
|
421
422
|
}
|
|
@@ -438,9 +439,9 @@ var jt = {
|
|
|
438
439
|
e.setColumnFilters = (o) => {
|
|
439
440
|
const t = e.getAllLeafColumns(), n = (r) => {
|
|
440
441
|
var i;
|
|
441
|
-
return (i =
|
|
442
|
+
return (i = T(o, r)) == null ? void 0 : i.filter((l) => {
|
|
442
443
|
const s = t.find((u) => u.id === l.id);
|
|
443
|
-
return !(s &&
|
|
444
|
+
return !(s && et(s.getFilterFn(), l.value, s));
|
|
444
445
|
});
|
|
445
446
|
};
|
|
446
447
|
e.options.onColumnFiltersChange == null || e.options.onColumnFiltersChange(n);
|
|
@@ -450,54 +451,54 @@ var jt = {
|
|
|
450
451
|
}, e.getPreFilteredRowModel = () => e.getCoreRowModel(), e.getFilteredRowModel = () => (!e._getFilteredRowModel && e.options.getFilteredRowModel && (e._getFilteredRowModel = e.options.getFilteredRowModel(e)), e.options.manualFiltering || !e._getFilteredRowModel ? e.getPreFilteredRowModel() : e._getFilteredRowModel());
|
|
451
452
|
}
|
|
452
453
|
};
|
|
453
|
-
function
|
|
454
|
+
function et(e, o, t) {
|
|
454
455
|
return (e && e.autoRemove ? e.autoRemove(o, t) : !1) || typeof o > "u" || typeof o == "string" && !o;
|
|
455
456
|
}
|
|
456
|
-
var
|
|
457
|
+
var Yt = (e, o, t) => t.reduce((n, r) => {
|
|
457
458
|
const i = r.getValue(e);
|
|
458
459
|
return n + (typeof i == "number" ? i : 0);
|
|
459
|
-
}, 0),
|
|
460
|
+
}, 0), Zt = (e, o, t) => {
|
|
460
461
|
let n;
|
|
461
462
|
return t.forEach((r) => {
|
|
462
463
|
const i = r.getValue(e);
|
|
463
464
|
i != null && (n > i || n === void 0 && i >= i) && (n = i);
|
|
464
465
|
}), n;
|
|
465
|
-
},
|
|
466
|
+
}, Jt = (e, o, t) => {
|
|
466
467
|
let n;
|
|
467
468
|
return t.forEach((r) => {
|
|
468
469
|
const i = r.getValue(e);
|
|
469
470
|
i != null && (n < i || n === void 0 && i >= i) && (n = i);
|
|
470
471
|
}), n;
|
|
471
|
-
},
|
|
472
|
+
}, bt = (e, o, t) => {
|
|
472
473
|
let n, r;
|
|
473
474
|
return t.forEach((i) => {
|
|
474
475
|
const l = i.getValue(e);
|
|
475
476
|
l != null && (n === void 0 ? l >= l && (n = r = l) : (n > l && (n = l), r < l && (r = l)));
|
|
476
477
|
}), [n, r];
|
|
477
|
-
},
|
|
478
|
+
}, en = (e, o) => {
|
|
478
479
|
let t = 0, n = 0;
|
|
479
480
|
if (o.forEach((r) => {
|
|
480
481
|
let i = r.getValue(e);
|
|
481
482
|
i != null && (i = +i) >= i && (++t, n += i);
|
|
482
483
|
}), t) return n / t;
|
|
483
|
-
},
|
|
484
|
+
}, tn = (e, o) => {
|
|
484
485
|
if (!o.length) return;
|
|
485
486
|
const t = o.map((i) => i.getValue(e));
|
|
486
|
-
if (!
|
|
487
|
+
if (!Nt(t)) return;
|
|
487
488
|
if (t.length === 1) return t[0];
|
|
488
489
|
const n = Math.floor(t.length / 2), r = t.sort((i, l) => i - l);
|
|
489
490
|
return t.length % 2 !== 0 ? r[n] : (r[n - 1] + r[n]) / 2;
|
|
490
|
-
},
|
|
491
|
-
sum:
|
|
492
|
-
min:
|
|
493
|
-
max:
|
|
494
|
-
extent:
|
|
495
|
-
mean:
|
|
496
|
-
median:
|
|
497
|
-
unique:
|
|
498
|
-
uniqueCount:
|
|
499
|
-
count:
|
|
500
|
-
},
|
|
491
|
+
}, nn = (e, o) => Array.from(new Set(o.map((t) => t.getValue(e))).values()), on = (e, o) => new Set(o.map((t) => t.getValue(e))).size, rn = (e, o) => o.length, Pe = {
|
|
492
|
+
sum: Yt,
|
|
493
|
+
min: Zt,
|
|
494
|
+
max: Jt,
|
|
495
|
+
extent: bt,
|
|
496
|
+
mean: en,
|
|
497
|
+
median: tn,
|
|
498
|
+
unique: nn,
|
|
499
|
+
uniqueCount: on,
|
|
500
|
+
count: rn
|
|
501
|
+
}, ln = {
|
|
501
502
|
getDefaultColumnDef: () => ({
|
|
502
503
|
aggregatedCell: (e) => {
|
|
503
504
|
var o, t;
|
|
@@ -532,12 +533,12 @@ var kt = (e, o, t) => t.reduce((n, r) => {
|
|
|
532
533
|
};
|
|
533
534
|
}, e.getAutoAggregationFn = () => {
|
|
534
535
|
const t = o.getCoreRowModel().flatRows[0], n = t?.getValue(e.id);
|
|
535
|
-
if (typeof n == "number") return
|
|
536
|
-
if (Object.prototype.toString.call(n) === "[object Date]") return
|
|
536
|
+
if (typeof n == "number") return Pe.sum;
|
|
537
|
+
if (Object.prototype.toString.call(n) === "[object Date]") return Pe.extent;
|
|
537
538
|
}, e.getAggregationFn = () => {
|
|
538
539
|
var t, n;
|
|
539
540
|
if (!e) throw new Error();
|
|
540
|
-
return
|
|
541
|
+
return Ce(e.columnDef.aggregationFn) ? e.columnDef.aggregationFn : e.columnDef.aggregationFn === "auto" ? e.getAutoAggregationFn() : (t = (n = o.options.aggregationFns) == null ? void 0 : n[e.columnDef.aggregationFn]) != null ? t : Pe[e.columnDef.aggregationFn];
|
|
541
542
|
};
|
|
542
543
|
},
|
|
543
544
|
createTable: (e) => {
|
|
@@ -560,24 +561,24 @@ var kt = (e, o, t) => t.reduce((n, r) => {
|
|
|
560
561
|
};
|
|
561
562
|
}
|
|
562
563
|
};
|
|
563
|
-
function
|
|
564
|
+
function sn(e, o, t) {
|
|
564
565
|
if (!(o != null && o.length) || !t) return e;
|
|
565
566
|
const n = e.filter((r) => !o.includes(r.id));
|
|
566
567
|
return t === "remove" ? n : [...o.map((r) => e.find((i) => i.id === r)).filter(Boolean), ...n];
|
|
567
568
|
}
|
|
568
|
-
var
|
|
569
|
+
var un = {
|
|
569
570
|
getInitialState: (e) => ({
|
|
570
571
|
columnOrder: [],
|
|
571
572
|
...e
|
|
572
573
|
}),
|
|
573
574
|
getDefaultOptions: (e) => ({ onColumnOrderChange: x("columnOrder", e) }),
|
|
574
575
|
createColumn: (e, o) => {
|
|
575
|
-
e.getIndex = m((t) => [
|
|
576
|
+
e.getIndex = m((t) => [te(o, t)], (t) => t.findIndex((n) => n.id === e.id), C(o.options, "debugColumns", "getIndex")), e.getIsFirstColumn = (t) => {
|
|
576
577
|
var n;
|
|
577
|
-
return ((n =
|
|
578
|
+
return ((n = te(o, t)[0]) == null ? void 0 : n.id) === e.id;
|
|
578
579
|
}, e.getIsLastColumn = (t) => {
|
|
579
580
|
var n;
|
|
580
|
-
const r =
|
|
581
|
+
const r = te(o, t);
|
|
581
582
|
return ((n = r[r.length - 1]) == null ? void 0 : n.id) === e.id;
|
|
582
583
|
};
|
|
583
584
|
},
|
|
@@ -600,15 +601,15 @@ var tn = {
|
|
|
600
601
|
}
|
|
601
602
|
i = [...i, ...s];
|
|
602
603
|
}
|
|
603
|
-
return
|
|
604
|
+
return sn(i, t, n);
|
|
604
605
|
}, C(e.options, "debugTable", "_getOrderColumnsFn"));
|
|
605
606
|
}
|
|
606
|
-
},
|
|
607
|
+
}, Ie = () => ({
|
|
607
608
|
left: [],
|
|
608
609
|
right: []
|
|
609
|
-
}),
|
|
610
|
+
}), an = {
|
|
610
611
|
getInitialState: (e) => ({
|
|
611
|
-
columnPinning:
|
|
612
|
+
columnPinning: Ie(),
|
|
612
613
|
...e
|
|
613
614
|
}),
|
|
614
615
|
getDefaultOptions: (e) => ({ onColumnPinningChange: x("columnPinning", e) }),
|
|
@@ -667,7 +668,7 @@ var tn = {
|
|
|
667
668
|
createTable: (e) => {
|
|
668
669
|
e.setColumnPinning = (o) => e.options.onColumnPinningChange == null ? void 0 : e.options.onColumnPinningChange(o), e.resetColumnPinning = (o) => {
|
|
669
670
|
var t, n;
|
|
670
|
-
return e.setColumnPinning(o ?
|
|
671
|
+
return e.setColumnPinning(o ? Ie() : (t = (n = e.initialState) == null ? void 0 : n.columnPinning) != null ? t : Ie());
|
|
671
672
|
}, e.getIsSomeColumnsPinned = (o) => {
|
|
672
673
|
var t;
|
|
673
674
|
const n = e.getState().columnPinning;
|
|
@@ -686,25 +687,25 @@ var tn = {
|
|
|
686
687
|
}, C(e.options, "debugColumns", "getCenterLeafColumns"));
|
|
687
688
|
}
|
|
688
689
|
};
|
|
689
|
-
function
|
|
690
|
+
function gn(e) {
|
|
690
691
|
return e || (typeof document < "u" ? document : null);
|
|
691
692
|
}
|
|
692
|
-
var
|
|
693
|
+
var Se = {
|
|
693
694
|
size: 150,
|
|
694
695
|
minSize: 20,
|
|
695
696
|
maxSize: Number.MAX_SAFE_INTEGER
|
|
696
|
-
},
|
|
697
|
+
}, Ve = () => ({
|
|
697
698
|
startOffset: null,
|
|
698
699
|
startSize: null,
|
|
699
700
|
deltaOffset: null,
|
|
700
701
|
deltaPercentage: null,
|
|
701
702
|
isResizingColumn: !1,
|
|
702
703
|
columnSizingStart: []
|
|
703
|
-
}),
|
|
704
|
-
getDefaultColumnDef: () =>
|
|
704
|
+
}), dn = {
|
|
705
|
+
getDefaultColumnDef: () => Se,
|
|
705
706
|
getInitialState: (e) => ({
|
|
706
707
|
columnSizing: {},
|
|
707
|
-
columnSizingInfo:
|
|
708
|
+
columnSizingInfo: Ve(),
|
|
708
709
|
...e
|
|
709
710
|
}),
|
|
710
711
|
getDefaultOptions: (e) => ({
|
|
@@ -717,14 +718,14 @@ var fe = {
|
|
|
717
718
|
e.getSize = () => {
|
|
718
719
|
var t, n, r;
|
|
719
720
|
const i = o.getState().columnSizing[e.id];
|
|
720
|
-
return Math.min(Math.max((t = e.columnDef.minSize) != null ? t :
|
|
721
|
+
return Math.min(Math.max((t = e.columnDef.minSize) != null ? t : Se.minSize, (n = i ?? e.columnDef.size) != null ? n : Se.size), (r = e.columnDef.maxSize) != null ? r : Se.maxSize);
|
|
721
722
|
}, e.getStart = m((t) => [
|
|
722
723
|
t,
|
|
723
|
-
|
|
724
|
+
te(o, t),
|
|
724
725
|
o.getState().columnSizing
|
|
725
726
|
], (t, n) => n.slice(0, e.getIndex(t)).reduce((r, i) => r + i.getSize(), 0), C(o.options, "debugColumns", "getStart")), e.getAfter = m((t) => [
|
|
726
727
|
t,
|
|
727
|
-
|
|
728
|
+
te(o, t),
|
|
728
729
|
o.getState().columnSizing
|
|
729
730
|
], (t, n) => n.slice(e.getIndex(t) + 1).reduce((r, i) => r + i.getSize(), 0), C(o.options, "debugColumns", "getAfter")), e.resetSize = () => {
|
|
730
731
|
o.setColumnSizing((t) => {
|
|
@@ -756,27 +757,27 @@ var fe = {
|
|
|
756
757
|
}, e.getResizeHandler = (t) => {
|
|
757
758
|
const n = o.getColumn(e.column.id), r = n?.getCanResize();
|
|
758
759
|
return (i) => {
|
|
759
|
-
if (!n || !r || (i.persist == null || i.persist(),
|
|
760
|
+
if (!n || !r || (i.persist == null || i.persist(), xe(i) && i.touches && i.touches.length > 1))
|
|
760
761
|
return;
|
|
761
|
-
const l = e.getSize(), s = e ? e.getLeafHeaders().map((
|
|
762
|
-
typeof
|
|
763
|
-
var
|
|
764
|
-
const V = o.options.columnResizeDirection === "rtl" ? -1 : 1,
|
|
765
|
-
return _.columnSizingStart.forEach((
|
|
766
|
-
let [
|
|
767
|
-
a[
|
|
762
|
+
const l = e.getSize(), s = e ? e.getLeafHeaders().map((h) => [h.column.id, h.column.getSize()]) : [[n.id, n.getSize()]], u = xe(i) ? Math.round(i.touches[0].clientX) : i.clientX, a = {}, d = (h, w) => {
|
|
763
|
+
typeof w == "number" && (o.setColumnSizingInfo((_) => {
|
|
764
|
+
var L, P;
|
|
765
|
+
const V = o.options.columnResizeDirection === "rtl" ? -1 : 1, K = (w - ((L = _?.startOffset) != null ? L : 0)) * V, X = Math.max(K / ((P = _?.startSize) != null ? P : 0), -0.999999);
|
|
766
|
+
return _.columnSizingStart.forEach((ve) => {
|
|
767
|
+
let [Re, j] = ve;
|
|
768
|
+
a[Re] = Math.round(Math.max(j + j * X, 0) * 100) / 100;
|
|
768
769
|
}), {
|
|
769
770
|
..._,
|
|
770
|
-
deltaOffset:
|
|
771
|
-
deltaPercentage:
|
|
771
|
+
deltaOffset: K,
|
|
772
|
+
deltaPercentage: X
|
|
772
773
|
};
|
|
773
|
-
}), (o.options.columnResizeMode === "onChange" ||
|
|
774
|
+
}), (o.options.columnResizeMode === "onChange" || h === "end") && o.setColumnSizing((_) => ({
|
|
774
775
|
..._,
|
|
775
776
|
...a
|
|
776
777
|
})));
|
|
777
|
-
}, g = (
|
|
778
|
-
d("end",
|
|
779
|
-
...
|
|
778
|
+
}, g = (h) => d("move", h), f = (h) => {
|
|
779
|
+
d("end", h), o.setColumnSizingInfo((w) => ({
|
|
780
|
+
...w,
|
|
780
781
|
isResizingColumn: !1,
|
|
781
782
|
startOffset: null,
|
|
782
783
|
startSize: null,
|
|
@@ -784,20 +785,20 @@ var fe = {
|
|
|
784
785
|
deltaPercentage: null,
|
|
785
786
|
columnSizingStart: []
|
|
786
787
|
}));
|
|
787
|
-
}, c =
|
|
788
|
-
moveHandler: (
|
|
789
|
-
upHandler: (
|
|
790
|
-
c?.removeEventListener("mousemove", p.moveHandler), c?.removeEventListener("mouseup", p.upHandler), f(
|
|
788
|
+
}, c = gn(t), p = {
|
|
789
|
+
moveHandler: (h) => g(h.clientX),
|
|
790
|
+
upHandler: (h) => {
|
|
791
|
+
c?.removeEventListener("mousemove", p.moveHandler), c?.removeEventListener("mouseup", p.upHandler), f(h.clientX);
|
|
791
792
|
}
|
|
792
793
|
}, v = {
|
|
793
|
-
moveHandler: (
|
|
794
|
-
upHandler: (
|
|
795
|
-
var
|
|
796
|
-
c?.removeEventListener("touchmove", v.moveHandler), c?.removeEventListener("touchend", v.upHandler),
|
|
794
|
+
moveHandler: (h) => (h.cancelable && (h.preventDefault(), h.stopPropagation()), g(h.touches[0].clientX), !1),
|
|
795
|
+
upHandler: (h) => {
|
|
796
|
+
var w;
|
|
797
|
+
c?.removeEventListener("touchmove", v.moveHandler), c?.removeEventListener("touchend", v.upHandler), h.cancelable && (h.preventDefault(), h.stopPropagation()), f((w = h.touches[0]) == null ? void 0 : w.clientX);
|
|
797
798
|
}
|
|
798
|
-
}, $ =
|
|
799
|
-
|
|
800
|
-
...
|
|
799
|
+
}, $ = fn() ? { passive: !1 } : !1;
|
|
800
|
+
xe(i) ? (c?.addEventListener("touchmove", v.moveHandler, $), c?.addEventListener("touchend", v.upHandler, $)) : (c?.addEventListener("mousemove", p.moveHandler, $), c?.addEventListener("mouseup", p.upHandler, $)), o.setColumnSizingInfo((h) => ({
|
|
801
|
+
...h,
|
|
801
802
|
startOffset: u,
|
|
802
803
|
startSize: l,
|
|
803
804
|
deltaOffset: 0,
|
|
@@ -814,7 +815,7 @@ var fe = {
|
|
|
814
815
|
e.setColumnSizing(o ? {} : (t = e.initialState.columnSizing) != null ? t : {});
|
|
815
816
|
}, e.resetHeaderSizeInfo = (o) => {
|
|
816
817
|
var t;
|
|
817
|
-
e.setColumnSizingInfo(o ?
|
|
818
|
+
e.setColumnSizingInfo(o ? Ve() : (t = e.initialState.columnSizingInfo) != null ? t : Ve());
|
|
818
819
|
}, e.getTotalSize = () => {
|
|
819
820
|
var o, t;
|
|
820
821
|
return (o = (t = e.getHeaderGroups()[0]) == null ? void 0 : t.headers.reduce((n, r) => n + r.getSize(), 0)) != null ? o : 0;
|
|
@@ -829,9 +830,9 @@ var fe = {
|
|
|
829
830
|
return (o = (t = e.getRightHeaderGroups()[0]) == null ? void 0 : t.headers.reduce((n, r) => n + r.getSize(), 0)) != null ? o : 0;
|
|
830
831
|
};
|
|
831
832
|
}
|
|
832
|
-
},
|
|
833
|
-
function
|
|
834
|
-
if (typeof
|
|
833
|
+
}, me = null;
|
|
834
|
+
function fn() {
|
|
835
|
+
if (typeof me == "boolean") return me;
|
|
835
836
|
let e = !1;
|
|
836
837
|
try {
|
|
837
838
|
const o = { get passive() {
|
|
@@ -842,12 +843,12 @@ function ln() {
|
|
|
842
843
|
} catch {
|
|
843
844
|
e = !1;
|
|
844
845
|
}
|
|
845
|
-
return
|
|
846
|
+
return me = e, me;
|
|
846
847
|
}
|
|
847
|
-
function
|
|
848
|
+
function xe(e) {
|
|
848
849
|
return e.type === "touchstart";
|
|
849
850
|
}
|
|
850
|
-
var
|
|
851
|
+
var cn = {
|
|
851
852
|
getInitialState: (e) => ({
|
|
852
853
|
columnVisibility: {},
|
|
853
854
|
...e
|
|
@@ -898,15 +899,15 @@ var sn = {
|
|
|
898
899
|
};
|
|
899
900
|
}
|
|
900
901
|
};
|
|
901
|
-
function
|
|
902
|
+
function te(e, o) {
|
|
902
903
|
return o ? o === "center" ? e.getCenterVisibleLeafColumns() : o === "left" ? e.getLeftVisibleLeafColumns() : e.getRightVisibleLeafColumns() : e.getVisibleLeafColumns();
|
|
903
904
|
}
|
|
904
|
-
var
|
|
905
|
+
var pn = { createTable: (e) => {
|
|
905
906
|
e._getGlobalFacetedRowModel = e.options.getFacetedRowModel && e.options.getFacetedRowModel(e, "__global__"), e.getGlobalFacetedRowModel = () => e.options.manualFiltering || !e._getGlobalFacetedRowModel ? e.getPreFilteredRowModel() : e._getGlobalFacetedRowModel(), e._getGlobalFacetedUniqueValues = e.options.getFacetedUniqueValues && e.options.getFacetedUniqueValues(e, "__global__"), e.getGlobalFacetedUniqueValues = () => e._getGlobalFacetedUniqueValues ? e._getGlobalFacetedUniqueValues() : /* @__PURE__ */ new Map(), e._getGlobalFacetedMinMaxValues = e.options.getFacetedMinMaxValues && e.options.getFacetedMinMaxValues(e, "__global__"), e.getGlobalFacetedMinMaxValues = () => {
|
|
906
907
|
if (e._getGlobalFacetedMinMaxValues)
|
|
907
908
|
return e._getGlobalFacetedMinMaxValues();
|
|
908
909
|
};
|
|
909
|
-
} },
|
|
910
|
+
} }, Sn = {
|
|
910
911
|
getInitialState: (e) => ({
|
|
911
912
|
globalFilter: void 0,
|
|
912
913
|
...e
|
|
@@ -930,14 +931,14 @@ var un = { createTable: (e) => {
|
|
|
930
931
|
e.getGlobalAutoFilterFn = () => H.includesString, e.getGlobalFilterFn = () => {
|
|
931
932
|
var o, t;
|
|
932
933
|
const { globalFilterFn: n } = e.options;
|
|
933
|
-
return
|
|
934
|
+
return Ce(n) ? n : n === "auto" ? e.getGlobalAutoFilterFn() : (o = (t = e.options.filterFns) == null ? void 0 : t[n]) != null ? o : H[n];
|
|
934
935
|
}, e.setGlobalFilter = (o) => {
|
|
935
936
|
e.options.onGlobalFilterChange == null || e.options.onGlobalFilterChange(o);
|
|
936
937
|
}, e.resetGlobalFilter = (o) => {
|
|
937
938
|
e.setGlobalFilter(o ? void 0 : e.initialState.globalFilter);
|
|
938
939
|
};
|
|
939
940
|
}
|
|
940
|
-
},
|
|
941
|
+
}, mn = {
|
|
941
942
|
getInitialState: (e) => ({
|
|
942
943
|
expanded: {},
|
|
943
944
|
...e
|
|
@@ -1020,14 +1021,14 @@ var un = { createTable: (e) => {
|
|
|
1020
1021
|
};
|
|
1021
1022
|
};
|
|
1022
1023
|
}
|
|
1023
|
-
},
|
|
1024
|
-
pageIndex:
|
|
1025
|
-
pageSize:
|
|
1026
|
-
}),
|
|
1024
|
+
}, De = 0, He = 10, ye = () => ({
|
|
1025
|
+
pageIndex: De,
|
|
1026
|
+
pageSize: He
|
|
1027
|
+
}), Cn = {
|
|
1027
1028
|
getInitialState: (e) => ({
|
|
1028
1029
|
...e,
|
|
1029
1030
|
pagination: {
|
|
1030
|
-
...
|
|
1031
|
+
...ye(),
|
|
1031
1032
|
...e?.pagination
|
|
1032
1033
|
}
|
|
1033
1034
|
}),
|
|
@@ -1049,14 +1050,14 @@ var un = { createTable: (e) => {
|
|
|
1049
1050
|
});
|
|
1050
1051
|
}
|
|
1051
1052
|
}, e.setPagination = (n) => {
|
|
1052
|
-
const r = (i) =>
|
|
1053
|
+
const r = (i) => T(n, i);
|
|
1053
1054
|
return e.options.onPaginationChange == null ? void 0 : e.options.onPaginationChange(r);
|
|
1054
1055
|
}, e.resetPagination = (n) => {
|
|
1055
1056
|
var r;
|
|
1056
|
-
e.setPagination(n ?
|
|
1057
|
+
e.setPagination(n ? ye() : (r = e.initialState.pagination) != null ? r : ye());
|
|
1057
1058
|
}, e.setPageIndex = (n) => {
|
|
1058
1059
|
e.setPagination((r) => {
|
|
1059
|
-
let i =
|
|
1060
|
+
let i = T(n, r.pageIndex);
|
|
1060
1061
|
const l = typeof e.options.pageCount > "u" || e.options.pageCount === -1 ? Number.MAX_SAFE_INTEGER : e.options.pageCount - 1;
|
|
1061
1062
|
return i = Math.max(0, Math.min(i, l)), {
|
|
1062
1063
|
...r,
|
|
@@ -1065,13 +1066,13 @@ var un = { createTable: (e) => {
|
|
|
1065
1066
|
});
|
|
1066
1067
|
}, e.resetPageIndex = (n) => {
|
|
1067
1068
|
var r, i;
|
|
1068
|
-
e.setPageIndex(n ?
|
|
1069
|
+
e.setPageIndex(n ? De : (r = (i = e.initialState) == null || (i = i.pagination) == null ? void 0 : i.pageIndex) != null ? r : De);
|
|
1069
1070
|
}, e.resetPageSize = (n) => {
|
|
1070
1071
|
var r, i;
|
|
1071
|
-
e.setPageSize(n ?
|
|
1072
|
+
e.setPageSize(n ? He : (r = (i = e.initialState) == null || (i = i.pagination) == null ? void 0 : i.pageSize) != null ? r : He);
|
|
1072
1073
|
}, e.setPageSize = (n) => {
|
|
1073
1074
|
e.setPagination((r) => {
|
|
1074
|
-
const i = Math.max(1,
|
|
1075
|
+
const i = Math.max(1, T(n, r.pageSize)), l = r.pageSize * r.pageIndex, s = Math.floor(l / i);
|
|
1075
1076
|
return {
|
|
1076
1077
|
...r,
|
|
1077
1078
|
pageIndex: s,
|
|
@@ -1080,7 +1081,7 @@ var un = { createTable: (e) => {
|
|
|
1080
1081
|
});
|
|
1081
1082
|
}, e.setPageCount = (n) => e.setPagination((r) => {
|
|
1082
1083
|
var i;
|
|
1083
|
-
let l =
|
|
1084
|
+
let l = T(n, (i = e.options.pageCount) != null ? i : -1);
|
|
1084
1085
|
return typeof l == "number" && (l = Math.max(-1, l)), {
|
|
1085
1086
|
...r,
|
|
1086
1087
|
pageCount: l
|
|
@@ -1099,12 +1100,12 @@ var un = { createTable: (e) => {
|
|
|
1099
1100
|
return (n = e.options.rowCount) != null ? n : e.getPrePaginationRowModel().rows.length;
|
|
1100
1101
|
};
|
|
1101
1102
|
}
|
|
1102
|
-
},
|
|
1103
|
+
}, Ee = () => ({
|
|
1103
1104
|
top: [],
|
|
1104
1105
|
bottom: []
|
|
1105
|
-
}),
|
|
1106
|
+
}), vn = {
|
|
1106
1107
|
getInitialState: (e) => ({
|
|
1107
|
-
rowPinning:
|
|
1108
|
+
rowPinning: Ee(),
|
|
1108
1109
|
...e
|
|
1109
1110
|
}),
|
|
1110
1111
|
getDefaultOptions: (e) => ({ onRowPinningChange: x("rowPinning", e) }),
|
|
@@ -1163,7 +1164,7 @@ var un = { createTable: (e) => {
|
|
|
1163
1164
|
createTable: (e) => {
|
|
1164
1165
|
e.setRowPinning = (o) => e.options.onRowPinningChange == null ? void 0 : e.options.onRowPinningChange(o), e.resetRowPinning = (o) => {
|
|
1165
1166
|
var t, n;
|
|
1166
|
-
return e.setRowPinning(o ?
|
|
1167
|
+
return e.setRowPinning(o ? Ee() : (t = (n = e.initialState) == null ? void 0 : n.rowPinning) != null ? t : Ee());
|
|
1167
1168
|
}, e.getIsSomeRowsPinned = (o) => {
|
|
1168
1169
|
var t;
|
|
1169
1170
|
const n = e.getState().rowPinning;
|
|
@@ -1190,7 +1191,7 @@ var un = { createTable: (e) => {
|
|
|
1190
1191
|
return o.filter((i) => !r.has(i.id));
|
|
1191
1192
|
}, C(e.options, "debugRows", "getCenterRows"));
|
|
1192
1193
|
}
|
|
1193
|
-
},
|
|
1194
|
+
}, Rn = {
|
|
1194
1195
|
getInitialState: (e) => ({
|
|
1195
1196
|
rowSelection: {},
|
|
1196
1197
|
...e
|
|
@@ -1218,17 +1219,17 @@ var un = { createTable: (e) => {
|
|
|
1218
1219
|
}, e.toggleAllPageRowsSelected = (o) => e.setRowSelection((t) => {
|
|
1219
1220
|
const n = typeof o < "u" ? o : !e.getIsAllPageRowsSelected(), r = { ...t };
|
|
1220
1221
|
return e.getRowModel().rows.forEach((i) => {
|
|
1221
|
-
|
|
1222
|
+
Ge(r, i.id, n, !0, e);
|
|
1222
1223
|
}), r;
|
|
1223
|
-
}), e.getPreSelectedRowModel = () => e.getCoreRowModel(), e.getSelectedRowModel = m(() => [e.getState().rowSelection, e.getCoreRowModel()], (o, t) => Object.keys(o).length ?
|
|
1224
|
+
}), e.getPreSelectedRowModel = () => e.getCoreRowModel(), e.getSelectedRowModel = m(() => [e.getState().rowSelection, e.getCoreRowModel()], (o, t) => Object.keys(o).length ? Ae(e, t) : {
|
|
1224
1225
|
rows: [],
|
|
1225
1226
|
flatRows: [],
|
|
1226
1227
|
rowsById: {}
|
|
1227
|
-
}, C(e.options, "debugTable", "getSelectedRowModel")), e.getFilteredSelectedRowModel = m(() => [e.getState().rowSelection, e.getFilteredRowModel()], (o, t) => Object.keys(o).length ?
|
|
1228
|
+
}, C(e.options, "debugTable", "getSelectedRowModel")), e.getFilteredSelectedRowModel = m(() => [e.getState().rowSelection, e.getFilteredRowModel()], (o, t) => Object.keys(o).length ? Ae(e, t) : {
|
|
1228
1229
|
rows: [],
|
|
1229
1230
|
flatRows: [],
|
|
1230
1231
|
rowsById: {}
|
|
1231
|
-
}, C(e.options, "debugTable", "getFilteredSelectedRowModel")), e.getGroupedSelectedRowModel = m(() => [e.getState().rowSelection, e.getSortedRowModel()], (o, t) => Object.keys(o).length ?
|
|
1232
|
+
}, C(e.options, "debugTable", "getFilteredSelectedRowModel")), e.getGroupedSelectedRowModel = m(() => [e.getState().rowSelection, e.getSortedRowModel()], (o, t) => Object.keys(o).length ? Ae(e, t) : {
|
|
1232
1233
|
rows: [],
|
|
1233
1234
|
flatRows: [],
|
|
1234
1235
|
rowsById: {}
|
|
@@ -1260,17 +1261,17 @@ var un = { createTable: (e) => {
|
|
|
1260
1261
|
var l;
|
|
1261
1262
|
if (t = typeof t < "u" ? t : !r, e.getCanSelect() && r === t) return i;
|
|
1262
1263
|
const s = { ...i };
|
|
1263
|
-
return
|
|
1264
|
+
return Ge(s, e.id, t, (l = n?.selectChildren) != null ? l : !0, o), s;
|
|
1264
1265
|
});
|
|
1265
1266
|
}, e.getIsSelected = () => {
|
|
1266
1267
|
const { rowSelection: t } = o.getState();
|
|
1267
|
-
return
|
|
1268
|
+
return Be(e, t);
|
|
1268
1269
|
}, e.getIsSomeSelected = () => {
|
|
1269
1270
|
const { rowSelection: t } = o.getState();
|
|
1270
|
-
return
|
|
1271
|
+
return Oe(e, t) === "some";
|
|
1271
1272
|
}, e.getIsAllSubRowsSelected = () => {
|
|
1272
1273
|
const { rowSelection: t } = o.getState();
|
|
1273
|
-
return
|
|
1274
|
+
return Oe(e, t) === "all";
|
|
1274
1275
|
}, e.getCanSelect = () => {
|
|
1275
1276
|
var t;
|
|
1276
1277
|
return typeof o.options.enableRowSelection == "function" ? o.options.enableRowSelection(e) : (t = o.options.enableRowSelection) != null ? t : !0;
|
|
@@ -1288,16 +1289,16 @@ var un = { createTable: (e) => {
|
|
|
1288
1289
|
};
|
|
1289
1290
|
};
|
|
1290
1291
|
}
|
|
1291
|
-
},
|
|
1292
|
+
}, Ge = (e, o, t, n, r) => {
|
|
1292
1293
|
var i;
|
|
1293
1294
|
const l = r.getRow(o, !0);
|
|
1294
|
-
t ? (l.getCanMultiSelect() || Object.keys(e).forEach((s) => delete e[s]), l.getCanSelect() && (e[o] = !0)) : delete e[o], n && (i = l.subRows) != null && i.length && l.getCanSelectSubRows() && l.subRows.forEach((s) =>
|
|
1295
|
+
t ? (l.getCanMultiSelect() || Object.keys(e).forEach((s) => delete e[s]), l.getCanSelect() && (e[o] = !0)) : delete e[o], n && (i = l.subRows) != null && i.length && l.getCanSelectSubRows() && l.subRows.forEach((s) => Ge(e, s.id, t, n, r));
|
|
1295
1296
|
};
|
|
1296
|
-
function
|
|
1297
|
+
function Ae(e, o) {
|
|
1297
1298
|
const t = e.getState().rowSelection, n = [], r = {}, i = function(l, s) {
|
|
1298
1299
|
return l.map((u) => {
|
|
1299
1300
|
var a;
|
|
1300
|
-
const d =
|
|
1301
|
+
const d = Be(u, t);
|
|
1301
1302
|
if (d && (n.push(u), r[u.id] = u), (a = u.subRows) != null && a.length && (u = {
|
|
1302
1303
|
...u,
|
|
1303
1304
|
subRows: i(u.subRows)
|
|
@@ -1310,33 +1311,33 @@ function xe(e, o) {
|
|
|
1310
1311
|
rowsById: r
|
|
1311
1312
|
};
|
|
1312
1313
|
}
|
|
1313
|
-
function
|
|
1314
|
+
function Be(e, o) {
|
|
1314
1315
|
var t;
|
|
1315
1316
|
return (t = o[e.id]) != null ? t : !1;
|
|
1316
1317
|
}
|
|
1317
|
-
function
|
|
1318
|
+
function Oe(e, o, t) {
|
|
1318
1319
|
var n;
|
|
1319
1320
|
if (!((n = e.subRows) != null && n.length)) return !1;
|
|
1320
1321
|
let r = !0, i = !1;
|
|
1321
1322
|
return e.subRows.forEach((l) => {
|
|
1322
|
-
if (!(i && !r) && (l.getCanSelect() && (
|
|
1323
|
-
const s =
|
|
1323
|
+
if (!(i && !r) && (l.getCanSelect() && (Be(l, o) ? i = !0 : r = !1), l.subRows && l.subRows.length)) {
|
|
1324
|
+
const s = Oe(l, o);
|
|
1324
1325
|
s === "all" ? i = !0 : (s === "some" && (i = !0), r = !1);
|
|
1325
1326
|
}
|
|
1326
1327
|
}), r ? "all" : i ? "some" : !1;
|
|
1327
1328
|
}
|
|
1328
|
-
var
|
|
1329
|
+
var ze = /([0-9]+)/gm, hn = (e, o, t) => gt(B(e.getValue(t)).toLowerCase(), B(o.getValue(t)).toLowerCase()), wn = (e, o, t) => gt(B(e.getValue(t)), B(o.getValue(t))), _n = (e, o, t) => qe(B(e.getValue(t)).toLowerCase(), B(o.getValue(t)).toLowerCase()), Fn = (e, o, t) => qe(B(e.getValue(t)), B(o.getValue(t))), $n = (e, o, t) => {
|
|
1329
1330
|
const n = e.getValue(t), r = o.getValue(t);
|
|
1330
1331
|
return n > r ? 1 : n < r ? -1 : 0;
|
|
1331
|
-
},
|
|
1332
|
-
function
|
|
1332
|
+
}, Mn = (e, o, t) => qe(e.getValue(t), o.getValue(t));
|
|
1333
|
+
function qe(e, o) {
|
|
1333
1334
|
return e === o ? 0 : e > o ? 1 : -1;
|
|
1334
1335
|
}
|
|
1335
|
-
function
|
|
1336
|
+
function B(e) {
|
|
1336
1337
|
return typeof e == "number" ? isNaN(e) || e === 1 / 0 || e === -1 / 0 ? "" : String(e) : typeof e == "string" ? e : "";
|
|
1337
1338
|
}
|
|
1338
|
-
function
|
|
1339
|
-
const t = e.split(
|
|
1339
|
+
function gt(e, o) {
|
|
1340
|
+
const t = e.split(ze).filter(Boolean), n = o.split(ze).filter(Boolean);
|
|
1340
1341
|
for (; t.length && n.length; ) {
|
|
1341
1342
|
const r = t.shift(), i = n.shift(), l = parseInt(r, 10), s = parseInt(i, 10), u = [l, s].sort();
|
|
1342
1343
|
if (isNaN(u[0])) {
|
|
@@ -1350,14 +1351,14 @@ function rt(e, o) {
|
|
|
1350
1351
|
}
|
|
1351
1352
|
return t.length - n.length;
|
|
1352
1353
|
}
|
|
1353
|
-
var
|
|
1354
|
-
alphanumeric:
|
|
1355
|
-
alphanumericCaseSensitive:
|
|
1356
|
-
text:
|
|
1357
|
-
textCaseSensitive:
|
|
1358
|
-
datetime:
|
|
1359
|
-
basic:
|
|
1360
|
-
},
|
|
1354
|
+
var ee = {
|
|
1355
|
+
alphanumeric: hn,
|
|
1356
|
+
alphanumericCaseSensitive: wn,
|
|
1357
|
+
text: _n,
|
|
1358
|
+
textCaseSensitive: Fn,
|
|
1359
|
+
datetime: $n,
|
|
1360
|
+
basic: Mn
|
|
1361
|
+
}, Pn = {
|
|
1361
1362
|
getInitialState: (e) => ({
|
|
1362
1363
|
sorting: [],
|
|
1363
1364
|
...e
|
|
@@ -1376,18 +1377,18 @@ var J = {
|
|
|
1376
1377
|
let n = !1;
|
|
1377
1378
|
for (const r of t) {
|
|
1378
1379
|
const i = r?.getValue(e.id);
|
|
1379
|
-
if (Object.prototype.toString.call(i) === "[object Date]") return
|
|
1380
|
-
if (typeof i == "string" && (n = !0, i.split(
|
|
1381
|
-
return
|
|
1380
|
+
if (Object.prototype.toString.call(i) === "[object Date]") return ee.datetime;
|
|
1381
|
+
if (typeof i == "string" && (n = !0, i.split(ze).length > 1))
|
|
1382
|
+
return ee.alphanumeric;
|
|
1382
1383
|
}
|
|
1383
|
-
return n ?
|
|
1384
|
+
return n ? ee.text : ee.basic;
|
|
1384
1385
|
}, e.getAutoSortDir = () => {
|
|
1385
1386
|
const t = o.getFilteredRowModel().flatRows[0];
|
|
1386
1387
|
return typeof t?.getValue(e.id) == "string" ? "asc" : "desc";
|
|
1387
1388
|
}, e.getSortingFn = () => {
|
|
1388
1389
|
var t, n;
|
|
1389
1390
|
if (!e) throw new Error();
|
|
1390
|
-
return
|
|
1391
|
+
return Ce(e.columnDef.sortingFn) ? e.columnDef.sortingFn : e.columnDef.sortingFn === "auto" ? e.getAutoSortingFn() : (t = (n = o.options.sortingFns) == null ? void 0 : n[e.columnDef.sortingFn]) != null ? t : ee[e.columnDef.sortingFn];
|
|
1391
1392
|
}, e.toggleSorting = (t, n) => {
|
|
1392
1393
|
const r = e.getNextSortingOrder(), i = typeof t < "u" && t !== null;
|
|
1393
1394
|
o.setSorting((l) => {
|
|
@@ -1443,27 +1444,27 @@ var J = {
|
|
|
1443
1444
|
e.setSorting(o ? [] : (t = (n = e.initialState) == null ? void 0 : n.sorting) != null ? t : []);
|
|
1444
1445
|
}, e.getPreSortedRowModel = () => e.getGroupedRowModel(), e.getSortedRowModel = () => (!e._getSortedRowModel && e.options.getSortedRowModel && (e._getSortedRowModel = e.options.getSortedRowModel(e)), e.options.manualSorting || !e._getSortedRowModel ? e.getPreSortedRowModel() : e._getSortedRowModel());
|
|
1445
1446
|
}
|
|
1446
|
-
},
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
tn,
|
|
1450
|
-
nn,
|
|
1451
|
-
Nt,
|
|
1452
|
-
jt,
|
|
1447
|
+
}, In = [
|
|
1448
|
+
Kt,
|
|
1449
|
+
cn,
|
|
1453
1450
|
un,
|
|
1454
1451
|
an,
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1452
|
+
Wt,
|
|
1453
|
+
Qt,
|
|
1454
|
+
pn,
|
|
1455
|
+
Sn,
|
|
1456
|
+
Pn,
|
|
1457
|
+
ln,
|
|
1458
|
+
mn,
|
|
1459
|
+
Cn,
|
|
1460
|
+
vn,
|
|
1461
|
+
Rn,
|
|
1462
|
+
dn
|
|
1462
1463
|
];
|
|
1463
|
-
function
|
|
1464
|
+
function Vn(e) {
|
|
1464
1465
|
var o, t;
|
|
1465
1466
|
process.env.NODE_ENV !== "production" && (e.debugAll || e.debugTable) && console.info("Creating Table Instance...");
|
|
1466
|
-
const n = [...
|
|
1467
|
+
const n = [...In, ...(o = e._features) != null ? o : []];
|
|
1467
1468
|
let r = { _features: n };
|
|
1468
1469
|
const i = r._features.reduce((g, f) => Object.assign(g, f.getDefaultOptions == null ? void 0 : f.getDefaultOptions(r)), {}), l = (g) => r.options.mergeOptions ? r.options.mergeOptions(i, g) : {
|
|
1469
1470
|
...i,
|
|
@@ -1495,7 +1496,7 @@ function _n(e) {
|
|
|
1495
1496
|
r.setState(r.initialState);
|
|
1496
1497
|
},
|
|
1497
1498
|
setOptions: (g) => {
|
|
1498
|
-
const f =
|
|
1499
|
+
const f = T(g, r.options);
|
|
1499
1500
|
r.options = l(f);
|
|
1500
1501
|
},
|
|
1501
1502
|
getState: () => r.options.state,
|
|
@@ -1533,8 +1534,8 @@ function _n(e) {
|
|
|
1533
1534
|
getAllColumns: m(() => [r._getColumnDefs()], (g) => {
|
|
1534
1535
|
const f = function(c, p, v) {
|
|
1535
1536
|
return v === void 0 && (v = 0), c.map(($) => {
|
|
1536
|
-
const
|
|
1537
|
-
return
|
|
1537
|
+
const h = Ut(r, $, v, p), w = $;
|
|
1538
|
+
return h.columns = w.columns ? f(w.columns, h, v + 1) : [], h;
|
|
1538
1539
|
});
|
|
1539
1540
|
};
|
|
1540
1541
|
return f(g);
|
|
@@ -1554,7 +1555,7 @@ function _n(e) {
|
|
|
1554
1555
|
}
|
|
1555
1556
|
return r;
|
|
1556
1557
|
}
|
|
1557
|
-
function
|
|
1558
|
+
function xn() {
|
|
1558
1559
|
return (e) => m(() => [e.options.data], (o) => {
|
|
1559
1560
|
const t = {
|
|
1560
1561
|
rows: [],
|
|
@@ -1564,7 +1565,7 @@ function Fn() {
|
|
|
1564
1565
|
i === void 0 && (i = 0);
|
|
1565
1566
|
const s = [];
|
|
1566
1567
|
for (let a = 0; a < r.length; a++) {
|
|
1567
|
-
const d =
|
|
1568
|
+
const d = Xt(e, e._getRowId(r[a], a, l), r[a], a, i, void 0, l?.id);
|
|
1568
1569
|
if (t.flatRows.push(d), t.rowsById[d.id] = d, s.push(d), e.options.getSubRows) {
|
|
1569
1570
|
var u;
|
|
1570
1571
|
d.originalSubRows = e.options.getSubRows(r[a], a), (u = d.originalSubRows) != null && u.length && (d.subRows = n(d.originalSubRows, i + 1, d));
|
|
@@ -1575,7 +1576,7 @@ function Fn() {
|
|
|
1575
1576
|
return t.rows = n(o), t;
|
|
1576
1577
|
}, C(e.options, "debugTable", "getRowModel", () => e._autoResetPageIndex()));
|
|
1577
1578
|
}
|
|
1578
|
-
function
|
|
1579
|
+
function yn() {
|
|
1579
1580
|
return (e) => m(() => [e.getState().sorting, e.getPreSortedRowModel()], (o, t) => {
|
|
1580
1581
|
if (!t.rows.length || !(o != null && o.length)) return t;
|
|
1581
1582
|
const n = e.getState().sorting, r = [], i = n.filter((u) => {
|
|
@@ -1595,18 +1596,18 @@ function $n() {
|
|
|
1595
1596
|
return a.sort((d, g) => {
|
|
1596
1597
|
for (let c = 0; c < i.length; c += 1) {
|
|
1597
1598
|
var f;
|
|
1598
|
-
const p = i[c], v = l[p.id], $ = v.sortUndefined,
|
|
1599
|
-
let
|
|
1599
|
+
const p = i[c], v = l[p.id], $ = v.sortUndefined, h = (f = p?.desc) != null ? f : !1;
|
|
1600
|
+
let w = 0;
|
|
1600
1601
|
if ($) {
|
|
1601
|
-
const _ = d.getValue(p.id),
|
|
1602
|
+
const _ = d.getValue(p.id), L = g.getValue(p.id), P = _ === void 0, V = L === void 0;
|
|
1602
1603
|
if (P || V) {
|
|
1603
1604
|
if ($ === "first") return P ? -1 : 1;
|
|
1604
1605
|
if ($ === "last") return P ? 1 : -1;
|
|
1605
|
-
|
|
1606
|
+
w = P && V ? 0 : P ? $ : -$;
|
|
1606
1607
|
}
|
|
1607
1608
|
}
|
|
1608
|
-
if (
|
|
1609
|
-
return
|
|
1609
|
+
if (w === 0 && (w = v.sortingFn(d, g, p.id)), w !== 0)
|
|
1610
|
+
return h && (w *= -1), v.invertSorting && (w *= -1), w;
|
|
1610
1611
|
}
|
|
1611
1612
|
return d.index - g.index;
|
|
1612
1613
|
}), a.forEach((d) => {
|
|
@@ -1621,29 +1622,29 @@ function $n() {
|
|
|
1621
1622
|
};
|
|
1622
1623
|
}, C(e.options, "debugTable", "getSortedRowModel", () => e._autoResetPageIndex()));
|
|
1623
1624
|
}
|
|
1624
|
-
function
|
|
1625
|
-
return e ?
|
|
1625
|
+
function Wn(e, o) {
|
|
1626
|
+
return e ? En(e) ? /* @__PURE__ */ Le.createElement(e, o) : e : null;
|
|
1626
1627
|
}
|
|
1627
|
-
function
|
|
1628
|
-
return
|
|
1628
|
+
function En(e) {
|
|
1629
|
+
return An(e) || typeof e == "function" || Ln(e);
|
|
1629
1630
|
}
|
|
1630
|
-
function
|
|
1631
|
+
function An(e) {
|
|
1631
1632
|
return typeof e == "function" && (() => {
|
|
1632
1633
|
const o = Object.getPrototypeOf(e);
|
|
1633
1634
|
return o.prototype && o.prototype.isReactComponent;
|
|
1634
1635
|
})();
|
|
1635
1636
|
}
|
|
1636
|
-
function
|
|
1637
|
+
function Ln(e) {
|
|
1637
1638
|
return typeof e == "object" && typeof e.$$typeof == "symbol" && ["react.memo", "react.forward_ref"].includes(e.$$typeof.description);
|
|
1638
1639
|
}
|
|
1639
|
-
function
|
|
1640
|
+
function Dn(e) {
|
|
1640
1641
|
const o = {
|
|
1641
1642
|
state: {},
|
|
1642
1643
|
onStateChange: () => {
|
|
1643
1644
|
},
|
|
1644
1645
|
renderFallbackValue: null,
|
|
1645
1646
|
...e
|
|
1646
|
-
}, [t] =
|
|
1647
|
+
}, [t] = Le.useState(() => ({ current: Vn(o) })), [n, r] = Le.useState(() => t.current.initialState);
|
|
1647
1648
|
return t.current.setOptions((i) => ({
|
|
1648
1649
|
...i,
|
|
1649
1650
|
...e,
|
|
@@ -1656,186 +1657,199 @@ function In(e) {
|
|
|
1656
1657
|
}
|
|
1657
1658
|
})), t.current;
|
|
1658
1659
|
}
|
|
1659
|
-
var
|
|
1660
|
+
var tt = [
|
|
1660
1661
|
"data",
|
|
1661
1662
|
"error",
|
|
1662
1663
|
"isError",
|
|
1663
1664
|
"isLoading",
|
|
1664
1665
|
"isFetching",
|
|
1665
1666
|
"dataUpdatedAt"
|
|
1666
|
-
],
|
|
1667
|
+
], Hn = [], Gn = (e) => e === void 0 || e === "all" ? e : typeof e == "function" ? () => {
|
|
1667
1668
|
const o = e();
|
|
1668
|
-
return o === void 0 || o === "all" ? o : [.../* @__PURE__ */ new Set([...o, ...
|
|
1669
|
-
} : [.../* @__PURE__ */ new Set([...e, ...
|
|
1670
|
-
const [
|
|
1669
|
+
return o === void 0 || o === "all" ? o : [.../* @__PURE__ */ new Set([...o, ...tt])];
|
|
1670
|
+
} : [.../* @__PURE__ */ new Set([...e, ...tt])], Qn = ({ children: e, classNameExpandedCell: o, classNameExpandedContent: t, classNameExpandedRow: n, classNameExpandedHeader: r, classNameActiveExpandedRow: i, classNameHoverRow: l, columns: s = [], data: u = [], defaultExpanded: a, enableExpandedRow: d, enableHoverRow: g, expandedState: f, headerContent: c, id: p, isPaginationEnabled: v, queryOptions: $ = {}, totalItems: h, getRowId: w, fetchData: _, onExpandedChange: L, renderExpandedRow: P, keepExpandColumnVisible: V }) => {
|
|
1671
|
+
const [K, X] = I([]), [ve, Re] = I(!!_), [j, W] = I(0), [ne, dt] = I(), [oe, ft] = I(10), [ct, pt] = I(h), Ne = _ ? ct : h, St = Math.ceil(Ne / oe), [re, mt] = I({}), [ie, Ct] = I({}), [le, vt] = I({}), [se, Rt] = I({}), ht = () => {
|
|
1671
1672
|
const S = typeof p == "string" || typeof p == "number" ? [p] : [...p];
|
|
1672
|
-
return v && S.push(
|
|
1673
|
-
S.push(`${
|
|
1674
|
-
}), Object.entries(
|
|
1675
|
-
F && S.push(`${
|
|
1676
|
-
}), Object.entries(
|
|
1677
|
-
F && S.push(`${
|
|
1678
|
-
}), Object.entries(
|
|
1679
|
-
F && S.push(`${
|
|
1673
|
+
return v && S.push(j, oe), ne && S.push(ne), Object.entries(re).forEach(([R, F]) => {
|
|
1674
|
+
S.push(`${R}:${F.join(",")}`);
|
|
1675
|
+
}), Object.entries(ie).forEach(([R, F]) => {
|
|
1676
|
+
F && S.push(`${R}:${F}`);
|
|
1677
|
+
}), Object.entries(le).forEach(([R, F]) => {
|
|
1678
|
+
F && S.push(`${R}:${F.from ?? ""}-${F.to ?? ""}`);
|
|
1679
|
+
}), Object.entries(se).forEach(([R, F]) => {
|
|
1680
|
+
F && S.push(`${R}:${F}`);
|
|
1680
1681
|
}), S;
|
|
1681
|
-
}, { notifyOnChangeProps:
|
|
1682
|
+
}, { notifyOnChangeProps: wt, ...je } = $, ke = b({}), Ue = b(!1), G = qt({
|
|
1682
1683
|
refetchOnMount: !1,
|
|
1683
1684
|
refetchOnWindowFocus: !1,
|
|
1684
|
-
...
|
|
1685
|
-
notifyOnChangeProps:
|
|
1686
|
-
queryKey:
|
|
1685
|
+
...je,
|
|
1686
|
+
notifyOnChangeProps: Gn(wt),
|
|
1687
|
+
queryKey: ht(),
|
|
1687
1688
|
enabled: (S) => {
|
|
1688
1689
|
if (!_) return !1;
|
|
1689
|
-
const { enabled:
|
|
1690
|
-
return typeof
|
|
1690
|
+
const { enabled: R } = je;
|
|
1691
|
+
return typeof R == "function" ? !!R(S) : R ?? !0;
|
|
1691
1692
|
},
|
|
1692
1693
|
initialData: () => {
|
|
1693
|
-
if (!(
|
|
1694
|
-
return
|
|
1694
|
+
if (!(Ue.current || u.length === 0))
|
|
1695
|
+
return Ue.current = !0, u;
|
|
1695
1696
|
},
|
|
1696
1697
|
queryFn: async ({ signal: S }) => {
|
|
1697
|
-
const { data:
|
|
1698
|
-
page: Math.max(
|
|
1699
|
-
pageSize:
|
|
1700
|
-
termOfSearch:
|
|
1701
|
-
...Object.keys(ne).length > 0 ? ne : {},
|
|
1702
|
-
...Object.keys(oe).length > 0 ? oe : {},
|
|
1698
|
+
const { data: R, totalItemsCount: F } = await _({
|
|
1699
|
+
page: Math.max(j + 1, 1),
|
|
1700
|
+
pageSize: oe,
|
|
1701
|
+
termOfSearch: ne,
|
|
1703
1702
|
...Object.keys(re).length > 0 ? re : {},
|
|
1704
|
-
...Object.keys(ie).length > 0 ? ie : {}
|
|
1703
|
+
...Object.keys(ie).length > 0 ? ie : {},
|
|
1704
|
+
...Object.keys(le).length > 0 ? le : {},
|
|
1705
|
+
...Object.keys(se).length > 0 ? se : {}
|
|
1705
1706
|
}, S);
|
|
1706
|
-
return
|
|
1707
|
+
return ke.current = { totalItemsCount: F }, R;
|
|
1707
1708
|
}
|
|
1708
|
-
}),
|
|
1709
|
-
|
|
1710
|
-
|
|
1711
|
-
|
|
1712
|
-
|
|
1713
|
-
|
|
1714
|
-
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
|
|
1709
|
+
}), [_t, Ke] = I(!1), he = b(0), Xe = b(!0), We = b(G.refetch);
|
|
1710
|
+
We.current = G.refetch;
|
|
1711
|
+
const Q = _ ? G.data ?? Hn : u, Ft = _ ? G.isLoading : !1, $t = _ ? G.isFetching : !1, Mt = _ ? G.error : null, Qe = !!c;
|
|
1712
|
+
k(() => {
|
|
1713
|
+
if (!_ || G.dataUpdatedAt === 0) return;
|
|
1714
|
+
Re(!1);
|
|
1715
|
+
const { totalItemsCount: S } = ke.current;
|
|
1716
|
+
S && pt(S);
|
|
1717
|
+
}, [_, G.dataUpdatedAt]);
|
|
1718
|
+
const Pt = z((S) => {
|
|
1719
|
+
dt(S), W(0);
|
|
1720
|
+
}, []), It = z((S, R) => {
|
|
1718
1721
|
const F = S.toLowerCase().replace(/\s+/g, "_");
|
|
1719
|
-
|
|
1720
|
-
...
|
|
1721
|
-
[F]:
|
|
1722
|
+
mt((E) => ({
|
|
1723
|
+
...E,
|
|
1724
|
+
[F]: R
|
|
1722
1725
|
}));
|
|
1723
|
-
}, []),
|
|
1726
|
+
}, []), Vt = z((S, R) => {
|
|
1724
1727
|
const F = S.toLowerCase().replace(/\s+/g, "_");
|
|
1725
|
-
|
|
1726
|
-
...
|
|
1727
|
-
[F]:
|
|
1728
|
-
})),
|
|
1729
|
-
}, []),
|
|
1728
|
+
Ct((E) => ({
|
|
1729
|
+
...E,
|
|
1730
|
+
[F]: R?.toISOString()
|
|
1731
|
+
})), W(0);
|
|
1732
|
+
}, []), xt = z((S, R) => {
|
|
1730
1733
|
const F = S.toLowerCase().replace(/\s+/g, "_");
|
|
1731
|
-
|
|
1732
|
-
...
|
|
1733
|
-
[F]:
|
|
1734
|
-
from:
|
|
1735
|
-
to:
|
|
1734
|
+
vt((E) => ({
|
|
1735
|
+
...E,
|
|
1736
|
+
[F]: R ? {
|
|
1737
|
+
from: R.from?.toISOString(),
|
|
1738
|
+
to: R.to?.toISOString()
|
|
1736
1739
|
} : void 0
|
|
1737
|
-
})),
|
|
1738
|
-
}, []),
|
|
1740
|
+
})), W(0);
|
|
1741
|
+
}, []), yt = z((S, R) => {
|
|
1739
1742
|
const F = S.toLowerCase().replace(/\s+/g, "_");
|
|
1740
|
-
|
|
1741
|
-
...
|
|
1742
|
-
[F]:
|
|
1743
|
-
})),
|
|
1744
|
-
}, []),
|
|
1745
|
-
const
|
|
1746
|
-
|
|
1743
|
+
Rt((E) => ({
|
|
1744
|
+
...E,
|
|
1745
|
+
[F]: R?.toISOString()
|
|
1746
|
+
})), W(0);
|
|
1747
|
+
}, []), Et = z((S) => W(S), []), At = z((S) => ft(S), []), [Lt, Dt] = I(a ?? {}), we = f !== void 0, q = we ? f : Lt, Y = z((S) => {
|
|
1748
|
+
const R = typeof S == "function" ? S(q) : S;
|
|
1749
|
+
we || Dt(R), L?.(S);
|
|
1747
1750
|
}, [
|
|
1748
|
-
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
+
q,
|
|
1752
|
+
we,
|
|
1753
|
+
L
|
|
1751
1754
|
]);
|
|
1752
|
-
|
|
1755
|
+
k(() => {
|
|
1753
1756
|
if (!d) return;
|
|
1754
|
-
const S =
|
|
1755
|
-
const { detail:
|
|
1756
|
-
|
|
1757
|
+
const S = Je(p), R = new AbortController(), F = (Z) => {
|
|
1758
|
+
const { detail: O } = Z, { rowId: y } = O;
|
|
1759
|
+
O.tableId !== S || !y || Y((D) => typeof D == "boolean" ? { [y]: !0 } : {
|
|
1757
1760
|
...D,
|
|
1758
1761
|
[y]: !0
|
|
1759
1762
|
});
|
|
1760
|
-
},
|
|
1761
|
-
const { detail:
|
|
1762
|
-
|
|
1763
|
+
}, E = (Z) => {
|
|
1764
|
+
const { detail: O } = Z, { rowId: y } = O;
|
|
1765
|
+
O.tableId !== S || !y || Y((D) => {
|
|
1763
1766
|
if (typeof D == "boolean") return {};
|
|
1764
|
-
const
|
|
1765
|
-
return delete
|
|
1767
|
+
const de = { ...D };
|
|
1768
|
+
return delete de[y], de;
|
|
1766
1769
|
});
|
|
1767
|
-
},
|
|
1768
|
-
const { detail:
|
|
1769
|
-
|
|
1770
|
+
}, ge = (Z) => {
|
|
1771
|
+
const { detail: O } = Z, { rowId: y } = O;
|
|
1772
|
+
O.tableId !== S || !y || Y((D) => {
|
|
1770
1773
|
if (typeof D == "boolean") return { [y]: !D };
|
|
1771
|
-
const
|
|
1772
|
-
return
|
|
1774
|
+
const de = !!D[y], Me = { ...D };
|
|
1775
|
+
return de ? delete Me[y] : Me[y] = !0, Me;
|
|
1773
1776
|
});
|
|
1774
1777
|
};
|
|
1775
|
-
return document.addEventListener(
|
|
1778
|
+
return document.addEventListener(fe.EXPAND_ROW, F, { signal: R.signal }), document.addEventListener(fe.COLLAPSE_ROW, E, { signal: R.signal }), document.addEventListener(fe.TOGGLE_ROW, ge, { signal: R.signal }), () => R.abort();
|
|
1776
1779
|
}, [
|
|
1777
1780
|
d,
|
|
1778
1781
|
p,
|
|
1779
|
-
|
|
1780
|
-
])
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
if (
|
|
1784
|
-
|
|
1782
|
+
Y
|
|
1783
|
+
]), k(() => () => {
|
|
1784
|
+
Xe.current = !1;
|
|
1785
|
+
}, []), k(() => {
|
|
1786
|
+
if (!_) return;
|
|
1787
|
+
const S = Je(p), R = new AbortController(), F = (E) => {
|
|
1788
|
+
const { detail: ge } = E;
|
|
1789
|
+
ge.tableId !== void 0 && ge.tableId !== S || (he.current += 1, Ke(!0), We.current().finally(() => {
|
|
1790
|
+
he.current -= 1, he.current === 0 && Xe.current && Ke(!1);
|
|
1791
|
+
}));
|
|
1792
|
+
};
|
|
1793
|
+
return document.addEventListener(fe.REFRESH, F, { signal: R.signal }), () => R.abort();
|
|
1794
|
+
}, [_, p]);
|
|
1795
|
+
const _e = U(() => Q.some((S) => !!S.meta?.expandedRow), [Q]), ue = U(() => Q.map((S, R) => w ? w(S, R) : String(R)), [Q, w]), Ht = U(() => typeof q == "boolean" ? q : ue.some((S) => !!q[S]), [q, ue]), Gt = U(() => typeof V == "boolean" ? V : typeof V == "object" ? ue.some((S) => !!V[S]) : !1, [V, ue]), Fe = _e || P && (Ht || Gt), [N, Ye] = I(!!Fe);
|
|
1796
|
+
k(() => {
|
|
1797
|
+
if (Fe) {
|
|
1798
|
+
const S = requestAnimationFrame(() => Ye(!0));
|
|
1785
1799
|
return () => cancelAnimationFrame(S);
|
|
1786
|
-
} else
|
|
1787
|
-
}, [
|
|
1788
|
-
const [
|
|
1789
|
-
|
|
1790
|
-
if (
|
|
1800
|
+
} else Ye(!1);
|
|
1801
|
+
}, [Fe]);
|
|
1802
|
+
const [ae, Ze] = I(!N);
|
|
1803
|
+
k(() => {
|
|
1804
|
+
if (N) Ze(!1);
|
|
1791
1805
|
else {
|
|
1792
|
-
const S = setTimeout(() =>
|
|
1806
|
+
const S = setTimeout(() => Ze(!0), 300);
|
|
1793
1807
|
return () => clearTimeout(S);
|
|
1794
1808
|
}
|
|
1795
|
-
}, [
|
|
1796
|
-
const
|
|
1809
|
+
}, [N]);
|
|
1810
|
+
const $e = U(() => !d || !_e && !P ? null : {
|
|
1797
1811
|
id: "__expand",
|
|
1798
|
-
header: () => /* @__PURE__ */
|
|
1812
|
+
header: () => /* @__PURE__ */ ce(zt, { children: "Expand Column" }),
|
|
1799
1813
|
cell: ({ row: S }) => {
|
|
1800
|
-
const { meta:
|
|
1801
|
-
return !
|
|
1814
|
+
const { meta: R } = S.original, F = typeof V == "object" && !!V[S.id];
|
|
1815
|
+
return !R?.expandedRow && !S.getIsExpanded() && !F ? null : /* @__PURE__ */ ce("button", {
|
|
1802
1816
|
type: "button",
|
|
1803
1817
|
className: "hover:cursor-pointer",
|
|
1804
1818
|
onClick: () => S.toggleExpanded(),
|
|
1805
1819
|
"aria-label": S.getIsExpanded() ? "Collapse row" : "Expand row",
|
|
1806
|
-
children: /* @__PURE__ */
|
|
1820
|
+
children: /* @__PURE__ */ ce(Tt, { className: J("size-4 transition-transform text-slate-400 dark:text-metal-400", { "-rotate-90": S.getIsExpanded() }) })
|
|
1807
1821
|
});
|
|
1808
1822
|
},
|
|
1809
1823
|
enableSorting: !1,
|
|
1810
1824
|
meta: {
|
|
1811
|
-
headerClassName:
|
|
1812
|
-
className:
|
|
1825
|
+
headerClassName: J("transition-[width,max-width,padding] duration-300 ease-in-out overflow-hidden", N ? "w-10 max-w-10 px-2" : "w-0 max-w-0 !p-0", ae && J("!border-0 !rounded-none dark:[&+th]:border-l", !Qe && "[&+th]:rounded-tl-lg")),
|
|
1826
|
+
className: J("transition-[width,max-width,padding] duration-300 ease-in-out overflow-hidden", N ? J("w-10 max-w-10 px-1 text-center", r) : "w-0 max-w-0 !p-0", ae && "!border-0 dark:[&+td]:border-l")
|
|
1813
1827
|
}
|
|
1814
1828
|
}, [
|
|
1815
1829
|
d,
|
|
1816
|
-
|
|
1817
|
-
|
|
1830
|
+
_e,
|
|
1831
|
+
Qe,
|
|
1818
1832
|
P,
|
|
1819
|
-
|
|
1820
|
-
|
|
1833
|
+
N,
|
|
1834
|
+
ae,
|
|
1821
1835
|
V
|
|
1822
|
-
]),
|
|
1823
|
-
data:
|
|
1824
|
-
columns:
|
|
1825
|
-
...
|
|
1836
|
+
]), Ot = Dn({
|
|
1837
|
+
data: Q,
|
|
1838
|
+
columns: U(() => $e ? [$e, ...s] : s, [s, $e]),
|
|
1839
|
+
...w ? { getRowId: w } : {},
|
|
1826
1840
|
state: {
|
|
1827
|
-
sorting:
|
|
1828
|
-
...d ? { expanded:
|
|
1841
|
+
sorting: K,
|
|
1842
|
+
...d ? { expanded: q } : {}
|
|
1829
1843
|
},
|
|
1830
|
-
onSortingChange:
|
|
1844
|
+
onSortingChange: X,
|
|
1831
1845
|
...d ? {
|
|
1832
|
-
onExpandedChange:
|
|
1846
|
+
onExpandedChange: Y,
|
|
1833
1847
|
manualExpanding: !0
|
|
1834
1848
|
} : {},
|
|
1835
|
-
getCoreRowModel:
|
|
1836
|
-
getSortedRowModel:
|
|
1849
|
+
getCoreRowModel: xn(),
|
|
1850
|
+
getSortedRowModel: yn()
|
|
1837
1851
|
});
|
|
1838
|
-
return /* @__PURE__ */
|
|
1852
|
+
return /* @__PURE__ */ ce(Bt.Provider, {
|
|
1839
1853
|
value: {
|
|
1840
1854
|
classNameActiveExpandedRow: i,
|
|
1841
1855
|
classNameExpandedCell: o,
|
|
@@ -1844,38 +1858,38 @@ var Qe = [
|
|
|
1844
1858
|
classNameHoverRow: l,
|
|
1845
1859
|
enableExpandedRow: d,
|
|
1846
1860
|
enableHoverRow: g,
|
|
1847
|
-
isBorderOnAdjacentCell:
|
|
1848
|
-
isExpandColumnVisible:
|
|
1849
|
-
isFirstLoad:
|
|
1850
|
-
multiselectSelected:
|
|
1851
|
-
dateFilters:
|
|
1852
|
-
dateRangeFilters:
|
|
1853
|
-
timeFilters:
|
|
1854
|
-
page:
|
|
1855
|
-
pageSize:
|
|
1856
|
-
sortedData:
|
|
1857
|
-
table:
|
|
1858
|
-
tableFetching:
|
|
1859
|
-
tableLoading:
|
|
1860
|
-
tableError:
|
|
1861
|
+
isBorderOnAdjacentCell: ae,
|
|
1862
|
+
isExpandColumnVisible: N,
|
|
1863
|
+
isFirstLoad: ve,
|
|
1864
|
+
multiselectSelected: re,
|
|
1865
|
+
dateFilters: ie,
|
|
1866
|
+
dateRangeFilters: le,
|
|
1867
|
+
timeFilters: se,
|
|
1868
|
+
page: j,
|
|
1869
|
+
pageSize: oe,
|
|
1870
|
+
sortedData: K,
|
|
1871
|
+
table: Ot,
|
|
1872
|
+
tableFetching: $t,
|
|
1873
|
+
tableLoading: Ft || _t,
|
|
1874
|
+
tableError: Mt,
|
|
1861
1875
|
headerContent: c,
|
|
1862
|
-
termOfSearch:
|
|
1863
|
-
totalItems:
|
|
1864
|
-
totalPages:
|
|
1865
|
-
handlePage:
|
|
1866
|
-
onChangeTermOfSearch:
|
|
1867
|
-
onPageSize:
|
|
1868
|
-
onSelectMultiselect:
|
|
1869
|
-
onSelectDateFilter:
|
|
1870
|
-
onSelectDateRangeFilter:
|
|
1871
|
-
onSelectTimeFilter:
|
|
1872
|
-
onSorting:
|
|
1876
|
+
termOfSearch: ne,
|
|
1877
|
+
totalItems: Ne,
|
|
1878
|
+
totalPages: St,
|
|
1879
|
+
handlePage: Et,
|
|
1880
|
+
onChangeTermOfSearch: Pt,
|
|
1881
|
+
onPageSize: At,
|
|
1882
|
+
onSelectMultiselect: It,
|
|
1883
|
+
onSelectDateFilter: Vt,
|
|
1884
|
+
onSelectDateRangeFilter: xt,
|
|
1885
|
+
onSelectTimeFilter: yt,
|
|
1886
|
+
onSorting: X,
|
|
1873
1887
|
renderExpandedRow: P
|
|
1874
1888
|
},
|
|
1875
1889
|
children: e
|
|
1876
1890
|
});
|
|
1877
1891
|
};
|
|
1878
1892
|
export {
|
|
1879
|
-
|
|
1880
|
-
|
|
1893
|
+
Wn as n,
|
|
1894
|
+
Qn as t
|
|
1881
1895
|
};
|