@owp/core 2.2.4 → 2.2.6
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/dist/_virtual/index11.js +2 -2
- package/dist/_virtual/index12.js +2 -2
- package/dist/_virtual/index13.js +2 -2
- package/dist/_virtual/index14.js +2 -2
- package/dist/_virtual/index16.js +2 -5
- package/dist/_virtual/index16.js.map +1 -1
- package/dist/_virtual/index17.js +2 -2
- package/dist/_virtual/index6.js +5 -2
- package/dist/_virtual/index6.js.map +1 -1
- package/dist/_virtual/index7.js +2 -2
- package/dist/components/OwpCommonCode/OwpCommonCodeSelector.js +68 -149
- package/dist/components/OwpCommonCode/OwpCommonCodeSelector.js.map +1 -1
- package/dist/components/OwpDialog/OwpDialog.js +48 -46
- package/dist/components/OwpDialog/OwpDialog.js.map +1 -1
- package/dist/components/OwpErrorStatusPage/OwpErrorStatusPage.js +24 -24
- package/dist/components/OwpErrorStatusPage/OwpErrorStatusPage.js.map +1 -1
- package/dist/components/OwpMrtTable/OwpMrtTable.js +2 -2
- package/dist/components/OwpMrtTable/OwpMrtTable.js.map +1 -1
- package/dist/components/OwpMrtTable/{OwpMrtTableNoDataOverlay.js → internal/OwpMrtTableNoDataOverlay.js} +1 -1
- package/dist/components/OwpMrtTable/internal/OwpMrtTableNoDataOverlay.js.map +1 -0
- package/dist/components/OwpMrtTable/{OwpMrtTableTopToolbar.js → internal/OwpMrtTableTopToolbar.js} +3 -3
- package/dist/components/OwpMrtTable/internal/OwpMrtTableTopToolbar.js.map +1 -0
- package/dist/components/OwpOptionSelector/OwpOptionSelector.js +52 -38
- package/dist/components/OwpOptionSelector/OwpOptionSelector.js.map +1 -1
- package/dist/components/OwpPageCarded/OwpPageCarded.js +81 -77
- package/dist/components/OwpPageCarded/OwpPageCarded.js.map +1 -1
- package/dist/components/OwpPageCarded/{OwpPageCardedHeader.js → internal/OwpPageCardedHeader.js} +2 -2
- package/dist/components/OwpPageCarded/internal/OwpPageCardedHeader.js.map +1 -0
- package/dist/components/OwpPageCarded/{OwpPageCardedSidebar.js → internal/OwpPageCardedSidebar.js} +3 -3
- package/dist/components/OwpPageCarded/internal/OwpPageCardedSidebar.js.map +1 -0
- package/dist/components/OwpPageCarded/{OwpPageCardedSidebarContent.js → internal/OwpPageCardedSidebarContent.js} +2 -2
- package/dist/components/OwpPageCarded/internal/OwpPageCardedSidebarContent.js.map +1 -0
- package/dist/components/OwpPicker/OwpDatePicker.js +90 -83
- package/dist/components/OwpPicker/OwpDatePicker.js.map +1 -1
- package/dist/components/OwpPicker/OwpDateRangePicker.js +57 -50
- package/dist/components/OwpPicker/OwpDateRangePicker.js.map +1 -1
- package/dist/components/OwpPicker/OwpTimePicker.js +65 -61
- package/dist/components/OwpPicker/OwpTimePicker.js.map +1 -1
- package/dist/components/OwpPicker/OwpWeekDatePicker.js +58 -52
- package/dist/components/OwpPicker/OwpWeekDatePicker.js.map +1 -1
- package/dist/components/OwpPicker/OwpYearRangePicker.js +68 -62
- package/dist/components/OwpPicker/OwpYearRangePicker.js.map +1 -1
- package/dist/components/OwpPicker/{constants.js → constants/index.js} +1 -1
- package/dist/components/OwpPicker/constants/index.js.map +1 -0
- package/dist/components/OwpPicker/{AnimatedCalendarContainer.js → internal/AnimatedCalendarContainer.js} +2 -2
- package/dist/components/OwpPicker/internal/AnimatedCalendarContainer.js.map +1 -0
- package/dist/components/OwpPicker/{CalendarContainer.js → internal/CalendarContainer.js} +2 -2
- package/dist/components/OwpPicker/internal/CalendarContainer.js.map +1 -0
- package/dist/components/OwpPicker/{DatePickerInput.js → internal/DatePickerInput.js} +4 -4
- package/dist/components/OwpPicker/internal/DatePickerInput.js.map +1 -0
- package/dist/components/OwpQuerySelector/OwpQuerySelector.js +266 -0
- package/dist/components/OwpQuerySelector/OwpQuerySelector.js.map +1 -0
- package/dist/components/OwpSelectorBase/OwpSelectorAutocomplete.js +390 -0
- package/dist/components/OwpSelectorBase/OwpSelectorAutocomplete.js.map +1 -0
- package/dist/components/OwpSelectorBase/OwpSelectorBase.js +14 -0
- package/dist/components/OwpSelectorBase/OwpSelectorBase.js.map +1 -0
- package/dist/components/OwpSelectorBase/OwpSelectorSelect.js +152 -0
- package/dist/components/OwpSelectorBase/OwpSelectorSelect.js.map +1 -0
- package/dist/components/OwpSelectorBase/hooks/useOwpSelectorBase.js +120 -0
- package/dist/components/OwpSelectorBase/hooks/useOwpSelectorBase.js.map +1 -0
- package/dist/components/OwpSelectorBase/utils/querySelectorUtils.js +24 -0
- package/dist/components/OwpSelectorBase/utils/querySelectorUtils.js.map +1 -0
- package/dist/components/OwpStyleProvider/OwpStyleProvider.js +90 -42
- package/dist/components/OwpStyleProvider/OwpStyleProvider.js.map +1 -1
- package/dist/components/OwpSuspense/OwpSuspense.js.map +1 -1
- package/dist/components/OwpTable/OwpTable.js +50 -51
- package/dist/components/OwpTable/OwpTable.js.map +1 -1
- package/dist/components/OwpTreeGrid/OwpTreeGrid.js +163 -308
- package/dist/components/OwpTreeGrid/OwpTreeGrid.js.map +1 -1
- package/dist/components/OwpTreeGrid/hooks/useOwpTreeGridOverlayFrame.js +1 -1
- package/dist/components/OwpTreeGrid/hooks/useOwpTreeGridOverlayFrame.js.map +1 -1
- package/dist/components/OwpTreeGrid/{OwpTreeGridLoadingOverlay.js → internal/OwpTreeGridLoadingOverlay.js} +2 -2
- package/dist/components/OwpTreeGrid/internal/OwpTreeGridLoadingOverlay.js.map +1 -0
- package/dist/components/OwpTreeGrid/{OwpTreeGridNoDataOverlay.js → internal/OwpTreeGridNoDataOverlay.js} +2 -2
- package/dist/components/OwpTreeGrid/internal/OwpTreeGridNoDataOverlay.js.map +1 -0
- package/dist/components/OwpTreeGrid/{utils/index.js → internal/treeGridLayout.js} +1 -1
- package/dist/components/OwpTreeGrid/internal/treeGridLayout.js.map +1 -0
- package/dist/components/OwpTreeGrid/internal/treeGridRuntime.js +176 -0
- package/dist/components/OwpTreeGrid/internal/treeGridRuntime.js.map +1 -0
- package/dist/components/OwpTreeGrid/utils/perf.js.map +1 -0
- package/dist/components/OwpZoomImageSlider/OwpZoomImageSlider.js +1 -1
- package/dist/components/OwpZoomImageSlider/OwpZoomImageSlider.js.map +1 -1
- package/dist/components/OwpZoomImageSlider/{ZoomImage.js → internal/ZoomImage.js} +1 -1
- package/dist/components/OwpZoomImageSlider/internal/ZoomImage.js.map +1 -0
- package/dist/index.js +100 -104
- package/dist/index.js.map +1 -1
- package/dist/node_modules/.pnpm/@mui_icons-material@7.3.9_@mui_material@7.3.9_@emotion_react@11.14.0_@types_react@19.2._dc2be6bc014bebdac88a574e3e02c144/node_modules/@mui/icons-material/esm/ArrowDropDown.js +9 -0
- package/dist/node_modules/.pnpm/@mui_icons-material@7.3.9_@mui_material@7.3.9_@emotion_react@11.14.0_@types_react@19.2._dc2be6bc014bebdac88a574e3e02c144/node_modules/@mui/icons-material/esm/ArrowDropDown.js.map +1 -0
- package/dist/node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/predicate/isFunction.js +10 -0
- package/dist/node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/predicate/isFunction.js.map +1 -0
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE128/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE39/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE93/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/EAN_UPC/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/GenericBarcode/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/ITF/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/MSI/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/codabar/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/pharmacode/index.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/renderers/index.js +1 -1
- package/dist/node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/index.js +1 -1
- package/dist/node_modules/.pnpm/react-imask@7.6.1_react@19.2.4/node_modules/react-imask/esm/mixin.js +1 -1
- package/dist/node_modules/.pnpm/react-overlays@5.2.1_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/react-overlays/esm/Portal.js +1 -1
- package/dist/owp-app.css +1 -1
- package/dist/types/components/OwpCommonCode/OwpCommonCodeSelector.d.ts +16 -6
- package/dist/types/components/OwpOptionSelector/OwpOptionSelector.d.ts +9 -8
- package/dist/types/components/OwpPageCarded/OwpPageCarded.d.ts +12 -41
- package/dist/types/components/OwpPageSkeleton/index.d.ts +1 -0
- package/dist/types/components/OwpPicker/OwpWeekDatePicker.d.ts +0 -1
- package/dist/types/components/OwpPicker/OwpYearRangePicker.d.ts +0 -1
- package/dist/types/components/OwpQuerySelector/OwpQuerySelector.d.ts +6 -0
- package/dist/types/components/OwpQuerySelector/index.d.ts +2 -0
- package/dist/types/components/OwpQuerySelector/types/index.d.ts +1 -0
- package/dist/types/components/OwpQuerySelector/types/types.d.ts +44 -0
- package/dist/types/components/OwpSelectorBase/OwpSelectorAutocomplete.d.ts +11 -0
- package/dist/types/components/OwpSelectorBase/OwpSelectorBase.d.ts +6 -0
- package/dist/types/components/OwpSelectorBase/OwpSelectorSelect.d.ts +11 -0
- package/dist/types/components/OwpSelectorBase/hooks/useOwpSelectorBase.d.ts +6 -0
- package/dist/types/components/OwpSelectorBase/types/index.d.ts +1 -0
- package/dist/types/components/OwpSelectorBase/types/types.d.ts +59 -0
- package/dist/types/components/OwpSelectorBase/utils/index.d.ts +1 -0
- package/dist/types/components/OwpSelectorBase/utils/querySelectorUtils.d.ts +31 -0
- package/dist/types/components/OwpTreeGrid/OwpTreeGrid.d.ts +3 -1
- package/dist/types/components/OwpTreeGrid/{OwpTreeGridLoadingOverlay.d.ts → internal/OwpTreeGridLoadingOverlay.d.ts} +1 -1
- package/dist/types/components/OwpTreeGrid/{OwpTreeGridNoDataOverlay.d.ts → internal/OwpTreeGridNoDataOverlay.d.ts} +1 -1
- package/dist/types/components/OwpTreeGrid/{utils/index.d.ts → internal/treeGridLayout.d.ts} +0 -2
- package/dist/types/components/OwpTreeGrid/internal/treeGridRuntime.d.ts +75 -0
- package/dist/types/index.d.ts +2 -4
- package/dist/types/store/navigationSlice.d.ts +1 -0
- package/dist/types/types/OwpNavigationTypes.d.ts +14 -0
- package/dist/types/types/index.d.ts +1 -1
- package/dist/types/utils/index.d.ts +1 -0
- package/dist/types/utils/navigationUtils.d.ts +6 -2
- package/dist/types/utils/normalizeTimeToHourMinute.d.ts +11 -0
- package/dist/utils/navigationUtils.js.map +1 -1
- package/dist/utils/normalizeTimeToHourMinute.js +34 -0
- package/dist/utils/normalizeTimeToHourMinute.js.map +1 -0
- package/dist/utils/treeGridUtil.js +1 -1
- package/dist/utils/treeGridUtil.js.map +1 -1
- package/dist/utils.js +78 -75
- package/dist/utils.js.map +1 -1
- package/package.json +1 -1
- package/dist/components/OwpMrtTable/OwpMrtTableNoDataOverlay.js.map +0 -1
- package/dist/components/OwpMrtTable/OwpMrtTableTopToolbar.js.map +0 -1
- package/dist/components/OwpPageCarded/OwpPageCardedHeader.js.map +0 -1
- package/dist/components/OwpPageCarded/OwpPageCardedSidebar.js.map +0 -1
- package/dist/components/OwpPageCarded/OwpPageCardedSidebarContent.js.map +0 -1
- package/dist/components/OwpPicker/AnimatedCalendarContainer.js.map +0 -1
- package/dist/components/OwpPicker/CalendarContainer.js.map +0 -1
- package/dist/components/OwpPicker/DatePickerInput.js.map +0 -1
- package/dist/components/OwpPicker/constants.js.map +0 -1
- package/dist/components/OwpTreeGrid/OwpTreeGridLoadingOverlay.js.map +0 -1
- package/dist/components/OwpTreeGrid/OwpTreeGridNoDataOverlay.js.map +0 -1
- package/dist/components/OwpTreeGrid/perf.js.map +0 -1
- package/dist/components/OwpTreeGrid/utils/index.js.map +0 -1
- package/dist/components/OwpZoomImageSlider/ZoomImage.js.map +0 -1
- package/dist/node_modules/.pnpm/react-datepicker@8.7.0_react-dom@19.2.4_react@19.2.4__react@19.2.4/node_modules/react-datepicker/dist/react-datepicker.css +0 -1
- /package/dist/components/OwpTreeGrid/{perf.js → utils/perf.js} +0 -0
- /package/dist/types/components/OwpMrtTable/{OwpMrtTableNoDataOverlay.d.ts → internal/OwpMrtTableNoDataOverlay.d.ts} +0 -0
- /package/dist/types/components/OwpMrtTable/{OwpMrtTableTopToolbar.d.ts → internal/OwpMrtTableTopToolbar.d.ts} +0 -0
- /package/dist/types/components/OwpPageCarded/{OwpPageCardedHeader.d.ts → internal/OwpPageCardedHeader.d.ts} +0 -0
- /package/dist/types/components/OwpPageCarded/{OwpPageCardedSidebar.d.ts → internal/OwpPageCardedSidebar.d.ts} +0 -0
- /package/dist/types/components/OwpPageCarded/{OwpPageCardedSidebarContent.d.ts → internal/OwpPageCardedSidebarContent.d.ts} +0 -0
- /package/dist/types/components/OwpPicker/{constants.d.ts → constants/index.d.ts} +0 -0
- /package/dist/types/components/OwpPicker/{AnimatedCalendarContainer.d.ts → internal/AnimatedCalendarContainer.d.ts} +0 -0
- /package/dist/types/components/OwpPicker/{CalendarContainer.d.ts → internal/CalendarContainer.d.ts} +0 -0
- /package/dist/types/components/OwpPicker/{DatePickerInput.d.ts → internal/DatePickerInput.d.ts} +0 -0
- /package/dist/types/components/OwpTreeGrid/{perf.d.ts → utils/perf.d.ts} +0 -0
- /package/dist/types/components/OwpZoomImageSlider/{ZoomImage.d.ts → internal/ZoomImage.d.ts} +0 -0
|
@@ -1,345 +1,200 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
import { jsxs as
|
|
4
|
-
import { useOwpTranslation as
|
|
1
|
+
var Ae = Object.defineProperty;
|
|
2
|
+
var a = (r, u) => Ae(r, "name", { value: u, configurable: !0 });
|
|
3
|
+
import { jsxs as Ne, jsx as H } from "../../node_modules/.pnpm/@emotion_react@11.14.0_@types_react@19.2.14_react@19.2.4/node_modules/@emotion/react/jsx-runtime/dist/emotion-react-jsx-runtime.browser.esm.js";
|
|
4
|
+
import { useOwpTranslation as Pe } from "../../hooks/useOwpTranslation.js";
|
|
5
5
|
import { useGetCurrentLanguage as Ve } from "../../hooks/useCurrentLanguage.js";
|
|
6
|
-
import { TREE_GRID_BODY_ROWS_CHANGED_EVENT as
|
|
7
|
-
import { getTreeGridPerfTimestamp as
|
|
8
|
-
import { useRef as
|
|
9
|
-
import { useOwpTreeGridOverlayFrame as
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
useDataUrl:
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
const t = e == null ? void 0 : e.Visible;
|
|
46
|
-
return !!e && t !== 0 && t !== !1 && t !== "0";
|
|
47
|
-
}, "isVisibleTreeGridRow"), Ye = /* @__PURE__ */ i((e) => {
|
|
48
|
-
const t = e == null ? void 0 : e.Added;
|
|
49
|
-
return !!e && t !== 0 && t !== !1 && t !== "0" && t !== void 0;
|
|
50
|
-
}, "isAddedTreeGridRow"), ve = /* @__PURE__ */ i((e) => !e || e.Fixed === "Foot" || !Xe(e) ? !1 : e.Kind === "Data" || Ye(e), "isDisplayTreeGridRow"), be = /* @__PURE__ */ i((e) => {
|
|
51
|
-
if (!e)
|
|
52
|
-
return !1;
|
|
53
|
-
if (typeof e.GetFirst == "function" && typeof e.GetNext == "function") {
|
|
54
|
-
let t = e.GetFirst();
|
|
55
|
-
for (; t; ) {
|
|
56
|
-
if (ve(t))
|
|
57
|
-
return !0;
|
|
58
|
-
t = e.GetNext(t);
|
|
59
|
-
}
|
|
60
|
-
return !1;
|
|
61
|
-
}
|
|
62
|
-
return Object.values(e.Rows ?? {}).some((t) => ve(t));
|
|
63
|
-
}, "hasTreeGridDisplayDataRows"), Je = /* @__PURE__ */ i((e, t, a) => {
|
|
64
|
-
var R;
|
|
65
|
-
const G = (R = e.Data) == null ? void 0 : R.Data;
|
|
66
|
-
e.Data.Data = {
|
|
67
|
-
...G,
|
|
68
|
-
Data: { Body: [t || []] },
|
|
69
|
-
Url: ""
|
|
70
|
-
}, e.ReloadBody(a);
|
|
71
|
-
}, "replaceTreeGridBodyData"), Ze = /* @__PURE__ */ i(({
|
|
72
|
-
id: e,
|
|
73
|
-
latestEventHandlersRef: t,
|
|
74
|
-
treeGridInstanceRef: a,
|
|
75
|
-
treeGridInitStartedAtRef: G,
|
|
76
|
-
latestLayoutOverridesRef: R,
|
|
77
|
-
appliedLayoutOverridesRef: D,
|
|
78
|
-
appliedBodyDataPropRef: v,
|
|
79
|
-
hasAppliedInitialLayoutRef: b,
|
|
80
|
-
syncHasDisplayDataRows: w,
|
|
81
|
-
setIsTreeGridReady: S
|
|
82
|
-
}) => {
|
|
83
|
-
const r = t.current;
|
|
84
|
-
window.TGSetEvent("OnRowAdd", e, (o, c) => {
|
|
85
|
-
var n, u;
|
|
86
|
-
c.CanEdit = 1, c.CanDelete = 1, (u = (n = t.current) == null ? void 0 : n.onRowAdd) == null || u.call(n, o, c);
|
|
87
|
-
}), window.TGSetEvent("OnRowAdded", e, (o) => {
|
|
88
|
-
w(o);
|
|
89
|
-
}), typeof (r == null ? void 0 : r.onRowClick) == "function" && window.TGSetEvent(
|
|
90
|
-
"OnClick",
|
|
91
|
-
e,
|
|
92
|
-
M((o, c, n, u, s, l) => {
|
|
93
|
-
var p, C;
|
|
94
|
-
(C = (p = t.current) == null ? void 0 : p.onRowClick) == null || C.call(
|
|
95
|
-
p,
|
|
96
|
-
o,
|
|
97
|
-
c,
|
|
98
|
-
n,
|
|
99
|
-
u,
|
|
100
|
-
s,
|
|
101
|
-
l
|
|
102
|
-
);
|
|
103
|
-
}, 300)
|
|
104
|
-
), typeof (r == null ? void 0 : r.onClickButton) == "function" && window.TGSetEvent(
|
|
105
|
-
"OnClickButton",
|
|
106
|
-
e,
|
|
107
|
-
M((o, c, n, u) => {
|
|
108
|
-
var s, l;
|
|
109
|
-
(l = (s = t.current) == null ? void 0 : s.onClickButton) == null || l.call(
|
|
110
|
-
s,
|
|
111
|
-
o,
|
|
112
|
-
c,
|
|
113
|
-
n,
|
|
114
|
-
u
|
|
115
|
-
);
|
|
116
|
-
}, 300)
|
|
117
|
-
), typeof (r == null ? void 0 : r.onRowDelete) == "function" ? window.TGSetEvent("OnRowDelete", e, (o, c, n) => {
|
|
118
|
-
var u, s;
|
|
119
|
-
w(o), (s = (u = t.current) == null ? void 0 : u.onRowDelete) == null || s.call(
|
|
120
|
-
u,
|
|
121
|
-
o,
|
|
122
|
-
c,
|
|
123
|
-
n
|
|
124
|
-
);
|
|
125
|
-
}) : window.TGSetEvent("OnRowDelete", e, (o) => {
|
|
126
|
-
w(o);
|
|
127
|
-
}), typeof (r == null ? void 0 : r.onRowUndelete) == "function" ? window.TGSetEvent("OnRowUndelete", e, (o, c) => {
|
|
128
|
-
var n, u;
|
|
129
|
-
w(o), (u = (n = t.current) == null ? void 0 : n.onRowUndelete) == null || u.call(n, o, c);
|
|
130
|
-
}) : window.TGSetEvent("OnRowUndelete", e, (o) => {
|
|
131
|
-
w(o);
|
|
132
|
-
}), (typeof (r == null ? void 0 : r.onAfterValueChanged) == "function" || typeof (r == null ? void 0 : r.onRowChange) == "function") && window.TGSetEvent("OnAfterValueChanged", e, (o, c, n, u) => {
|
|
133
|
-
var l, p;
|
|
134
|
-
const s = ((l = t.current) == null ? void 0 : l.onAfterValueChanged) ?? ((p = t.current) == null ? void 0 : p.onRowChange);
|
|
135
|
-
s == null || s(o, c, n, u);
|
|
136
|
-
}), typeof (r == null ? void 0 : r.onSelect) == "function" && window.TGSetEvent(
|
|
137
|
-
"OnSelect",
|
|
138
|
-
e,
|
|
139
|
-
M((o) => {
|
|
140
|
-
var n, u;
|
|
141
|
-
const c = o.GetSelRows() ?? [];
|
|
142
|
-
(u = (n = t.current) == null ? void 0 : n.onSelect) == null || u.call(n, c);
|
|
143
|
-
}, 100)
|
|
144
|
-
), typeof (r == null ? void 0 : r.onSave) == "function" && window.TGSetEvent("OnSave", e, (o, c, n) => {
|
|
145
|
-
var u, s;
|
|
146
|
-
(s = (u = t.current) == null ? void 0 : u.onSave) == null || s.call(
|
|
147
|
-
u,
|
|
148
|
-
o,
|
|
149
|
-
c,
|
|
150
|
-
n
|
|
151
|
-
);
|
|
152
|
-
}), window.TGSetEvent(
|
|
153
|
-
"OnReady",
|
|
154
|
-
e,
|
|
155
|
-
M((o) => {
|
|
156
|
-
var c, n;
|
|
157
|
-
if (!b.current) {
|
|
158
|
-
const u = R.current;
|
|
159
|
-
b.current = !0, Be(o, u), a.current = o, D.current = u, v.current = De(o), w(o), S(!0), te(e, "TreeGrid init ready", G.current, {
|
|
160
|
-
bodyRowCount: j(
|
|
161
|
-
De(o)
|
|
162
|
-
)
|
|
163
|
-
}), G.current = null, (n = (c = t.current) == null ? void 0 : c.onReady) == null || n.call(c, o);
|
|
164
|
-
}
|
|
165
|
-
}, 100)
|
|
166
|
-
);
|
|
167
|
-
}, "bindTreeGridEvents"), Gt = /* @__PURE__ */ i(({
|
|
168
|
-
id: e = "treeGridWrapper",
|
|
169
|
-
containerStyle: t,
|
|
170
|
-
containerClassName: a,
|
|
171
|
-
className: G,
|
|
172
|
-
style: R,
|
|
173
|
-
height: D = "100%",
|
|
174
|
-
width: v = "100%",
|
|
175
|
-
layoutUrl: b,
|
|
176
|
-
dataUrl: w,
|
|
177
|
-
layoutOverrides: S,
|
|
178
|
-
data: r,
|
|
179
|
-
useDataUrl: o,
|
|
180
|
-
onSelect: c,
|
|
181
|
-
onRowClick: n,
|
|
182
|
-
onRowAdd: u,
|
|
183
|
-
onRowDelete: s,
|
|
184
|
-
onRowUndelete: l,
|
|
185
|
-
onRowChange: p,
|
|
186
|
-
onClickButton: C,
|
|
187
|
-
onSave: re,
|
|
188
|
-
onReady: oe,
|
|
189
|
-
onAfterValueChanged: ne,
|
|
190
|
-
loading: Se,
|
|
191
|
-
showLoading: T = !0
|
|
6
|
+
import { TREE_GRID_BODY_ROWS_CHANGED_EVENT as pe } from "../../utils/treeGridBodyRowsEvent.js";
|
|
7
|
+
import { getTreeGridPerfTimestamp as C, countTreeGridPerf as me, logTreeGridPerf as ye, measureTreeGridPerf as Re } from "./utils/perf.js";
|
|
8
|
+
import { useRef as e, useState as S, useEffect as I, useLayoutEffect as xe } from "react";
|
|
9
|
+
import { useOwpTreeGridOverlayFrame as He } from "./hooks/useOwpTreeGridOverlayFrame.js";
|
|
10
|
+
import { bindTreeGridEvents as Ce, getTreeGridBodyDataCount as M, buildTreeGridInitializationOptions as Se, hasTreeGridDisplayDataRows as ve, replaceTreeGridBodyData as Me, TREE_GRID_BINDING_LOADING_MIN_VISIBLE_MS as qe } from "./internal/treeGridRuntime.js";
|
|
11
|
+
import { applyTreeGridLayoutToGrid as je } from "./internal/treeGridLayout.js";
|
|
12
|
+
import { OwpTreeGridLoadingOverlay as Fe } from "./internal/OwpTreeGridLoadingOverlay.js";
|
|
13
|
+
import { OwpTreeGridNoDataOverlay as We } from "./internal/OwpTreeGridNoDataOverlay.js";
|
|
14
|
+
import { isEmpty as E } from "../../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/predicate/isEmpty.js";
|
|
15
|
+
import { delay as ze } from "../../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/function/delay.js";
|
|
16
|
+
import { isEqual as Ye } from "../../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/predicate/isEqual.js";
|
|
17
|
+
import { omit as he } from "../../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/object/omit.js";
|
|
18
|
+
const cr = /* @__PURE__ */ a(({
|
|
19
|
+
id: r = "treeGridWrapper",
|
|
20
|
+
containerStyle: u,
|
|
21
|
+
containerClassName: Te,
|
|
22
|
+
className: Ge,
|
|
23
|
+
style: De,
|
|
24
|
+
height: q = "100%",
|
|
25
|
+
width: j = "100%",
|
|
26
|
+
layoutUrl: be,
|
|
27
|
+
dataUrl: ge,
|
|
28
|
+
layoutOverrides: w,
|
|
29
|
+
data: n,
|
|
30
|
+
useDataUrl: F,
|
|
31
|
+
onSelect: W,
|
|
32
|
+
onRowClick: z,
|
|
33
|
+
onRowAdd: Y,
|
|
34
|
+
onRowDelete: h,
|
|
35
|
+
onRowUndelete: J,
|
|
36
|
+
onRowChange: K,
|
|
37
|
+
onClickButton: Q,
|
|
38
|
+
onSave: X,
|
|
39
|
+
onReady: Z,
|
|
40
|
+
onAfterValueChanged: $,
|
|
41
|
+
highlightEditableCells: U = !0,
|
|
42
|
+
highlightChangedCells: k = !0,
|
|
43
|
+
loading: Be,
|
|
44
|
+
showLoading: o = !0
|
|
192
45
|
}) => {
|
|
193
|
-
const { t:
|
|
194
|
-
onSelect:
|
|
195
|
-
onRowClick:
|
|
196
|
-
onRowAdd:
|
|
197
|
-
onRowDelete:
|
|
198
|
-
onRowUndelete:
|
|
199
|
-
onRowChange:
|
|
200
|
-
onClickButton:
|
|
201
|
-
onSave:
|
|
202
|
-
onReady:
|
|
203
|
-
onAfterValueChanged:
|
|
204
|
-
}),
|
|
205
|
-
|
|
46
|
+
const { t: Ie } = Pe(), i = e(null), ee = e(null), re = e(null), L = e(null), O = e(w), te = e(n), ne = e({
|
|
47
|
+
onSelect: W,
|
|
48
|
+
onRowClick: z,
|
|
49
|
+
onRowAdd: Y,
|
|
50
|
+
onRowDelete: h,
|
|
51
|
+
onRowUndelete: J,
|
|
52
|
+
onRowChange: K,
|
|
53
|
+
onClickButton: Q,
|
|
54
|
+
onSave: X,
|
|
55
|
+
onReady: Z,
|
|
56
|
+
onAfterValueChanged: $
|
|
57
|
+
}), l = e(void 0), _ = e(!1), G = e(void 0), D = e(void 0), Ee = e(!1), f = e(0), c = e(null), p = e(void 0), m = e(void 0), oe = e(U), ie = e(k), [A, we] = S(!1), [Le, y] = S(!1), [Oe, se] = S(!1), b = Ve(), ue = e(b.id), _e = o && n !== void 0 && A && D.current !== n, N = o && Be === !0 || o && (Le || _e), P = !N && n !== void 0 && E(n) && !Oe, ae = /* @__PURE__ */ a((t) => {
|
|
58
|
+
se(ve(t));
|
|
206
59
|
}, "syncHasDisplayDataRows");
|
|
207
|
-
|
|
208
|
-
onSelect:
|
|
209
|
-
onRowClick:
|
|
210
|
-
onRowAdd:
|
|
211
|
-
onRowDelete:
|
|
212
|
-
onRowUndelete:
|
|
213
|
-
onRowChange:
|
|
214
|
-
onClickButton:
|
|
215
|
-
onSave:
|
|
216
|
-
onReady:
|
|
217
|
-
onAfterValueChanged:
|
|
60
|
+
O.current = w, te.current = n, oe.current = U, ie.current = k, ne.current = {
|
|
61
|
+
onSelect: W,
|
|
62
|
+
onRowClick: z,
|
|
63
|
+
onRowAdd: Y,
|
|
64
|
+
onRowDelete: h,
|
|
65
|
+
onRowUndelete: J,
|
|
66
|
+
onRowChange: K,
|
|
67
|
+
onClickButton: Q,
|
|
68
|
+
onSave: X,
|
|
69
|
+
onReady: Z,
|
|
70
|
+
onAfterValueChanged: $
|
|
218
71
|
};
|
|
219
|
-
const
|
|
220
|
-
visible:
|
|
221
|
-
containerRef:
|
|
222
|
-
treeGridInstanceRef:
|
|
223
|
-
debugId:
|
|
224
|
-
}),
|
|
225
|
-
|
|
226
|
-
}, "clearBindingLoadingHideTimeout"),
|
|
227
|
-
|
|
72
|
+
const ce = He({
|
|
73
|
+
visible: N || P,
|
|
74
|
+
containerRef: ee,
|
|
75
|
+
treeGridInstanceRef: i,
|
|
76
|
+
debugId: r
|
|
77
|
+
}), g = /* @__PURE__ */ a(() => {
|
|
78
|
+
p.current !== void 0 && (window.clearTimeout(p.current), p.current = void 0);
|
|
79
|
+
}, "clearBindingLoadingHideTimeout"), V = /* @__PURE__ */ a(() => {
|
|
80
|
+
m.current !== void 0 && (window.clearTimeout(m.current), m.current = void 0);
|
|
228
81
|
}, "clearBodyReloadStartTimeout");
|
|
229
|
-
|
|
230
|
-
const
|
|
231
|
-
var
|
|
232
|
-
((
|
|
82
|
+
I(() => {
|
|
83
|
+
const t = /* @__PURE__ */ a((s) => {
|
|
84
|
+
var v;
|
|
85
|
+
((v = s.detail) == null ? void 0 : v.gridId) === r && se(ve(i.current));
|
|
233
86
|
}, "handleBodyRowsChanged");
|
|
234
|
-
return window.addEventListener(
|
|
235
|
-
window.removeEventListener(
|
|
87
|
+
return window.addEventListener(pe, t), () => {
|
|
88
|
+
window.removeEventListener(pe, t);
|
|
236
89
|
};
|
|
237
|
-
}, [
|
|
238
|
-
|
|
239
|
-
}, [
|
|
240
|
-
var
|
|
241
|
-
if (
|
|
242
|
-
return
|
|
243
|
-
id:
|
|
244
|
-
latestEventHandlersRef:
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
90
|
+
}, [r]), I(() => {
|
|
91
|
+
o || (V(), g(), c.current = null, y(!1));
|
|
92
|
+
}, [o]), I(() => {
|
|
93
|
+
var t;
|
|
94
|
+
if (b.id !== ue.current && !E(i.current) && ((t = i.current) == null || t.Dispose(), i.current = null, ue.current = b.id), !!E(i.current))
|
|
95
|
+
return Ce({
|
|
96
|
+
id: r,
|
|
97
|
+
latestEventHandlersRef: ne,
|
|
98
|
+
highlightEditableCellsRef: oe,
|
|
99
|
+
highlightChangedCellsRef: ie,
|
|
100
|
+
treeGridInstanceRef: i,
|
|
101
|
+
treeGridInitStartedAtRef: re,
|
|
102
|
+
latestLayoutOverridesRef: O,
|
|
103
|
+
appliedLayoutOverridesRef: G,
|
|
104
|
+
appliedBodyDataPropRef: D,
|
|
105
|
+
hasAppliedInitialLayoutRef: Ee,
|
|
251
106
|
syncHasDisplayDataRows: ae,
|
|
252
|
-
setIsTreeGridReady:
|
|
253
|
-
}),
|
|
254
|
-
useDataUrl: !!
|
|
255
|
-
bodyRowCount:
|
|
107
|
+
setIsTreeGridReady: we
|
|
108
|
+
}), re.current = C(), me(r, "init"), ye(r, "TreeGrid init start", {
|
|
109
|
+
useDataUrl: !!F,
|
|
110
|
+
bodyRowCount: M(n)
|
|
256
111
|
}), window.TreeGrid(
|
|
257
|
-
|
|
258
|
-
id:
|
|
259
|
-
layoutUrl:
|
|
260
|
-
dataUrl:
|
|
261
|
-
bodyData:
|
|
262
|
-
useDataUrl:
|
|
263
|
-
width:
|
|
264
|
-
height:
|
|
265
|
-
languageId:
|
|
112
|
+
Se({
|
|
113
|
+
id: r,
|
|
114
|
+
layoutUrl: be,
|
|
115
|
+
dataUrl: ge,
|
|
116
|
+
bodyData: n,
|
|
117
|
+
useDataUrl: F,
|
|
118
|
+
width: j,
|
|
119
|
+
height: q,
|
|
120
|
+
languageId: b.id
|
|
266
121
|
}),
|
|
267
|
-
|
|
268
|
-
|
|
122
|
+
r,
|
|
123
|
+
r
|
|
269
124
|
), () => {
|
|
270
|
-
|
|
271
|
-
var
|
|
272
|
-
(
|
|
125
|
+
ze(() => {
|
|
126
|
+
var s;
|
|
127
|
+
(s = i.current) == null || s.Dispose();
|
|
273
128
|
}, 200);
|
|
274
129
|
};
|
|
275
|
-
}, []),
|
|
276
|
-
const
|
|
277
|
-
if (
|
|
130
|
+
}, []), xe(() => {
|
|
131
|
+
const t = i.current, s = O.current, R = te.current;
|
|
132
|
+
if (E(t) || !A)
|
|
278
133
|
return;
|
|
279
|
-
const
|
|
280
|
-
if (!(!
|
|
281
|
-
if (
|
|
282
|
-
const
|
|
283
|
-
|
|
284
|
-
disableBodyReload: !!
|
|
134
|
+
const v = G.current !== s && !Ye(G.current, s), B = D.current !== R && (!_.current || l.current !== R);
|
|
135
|
+
if (!(!v && !B)) {
|
|
136
|
+
if (v) {
|
|
137
|
+
const d = C();
|
|
138
|
+
je(t, s, B), G.current = s, Re(r, "apply layout", d, {
|
|
139
|
+
disableBodyReload: !!B
|
|
285
140
|
});
|
|
286
141
|
}
|
|
287
|
-
if (
|
|
288
|
-
const
|
|
289
|
-
const
|
|
290
|
-
|
|
291
|
-
bodyRowCount:
|
|
292
|
-
}),
|
|
293
|
-
if (
|
|
142
|
+
if (B) {
|
|
143
|
+
const d = f.current + 1, de = /* @__PURE__ */ a(() => {
|
|
144
|
+
const T = l.current;
|
|
145
|
+
m.current = void 0, L.current = C(), me(r, "reload"), ye(r, "ReloadBody start", {
|
|
146
|
+
bodyRowCount: M(T)
|
|
147
|
+
}), Me(t, T, () => {
|
|
148
|
+
if (f.current !== d)
|
|
294
149
|
return;
|
|
295
|
-
|
|
296
|
-
bodyRowCount:
|
|
297
|
-
}),
|
|
298
|
-
const
|
|
299
|
-
if (!
|
|
300
|
-
|
|
150
|
+
D.current = T, ae(t), Re(r, "ReloadBody end", L.current, {
|
|
151
|
+
bodyRowCount: M(T)
|
|
152
|
+
}), L.current = null, l.current === T && (l.current = void 0, _.current = !1);
|
|
153
|
+
const le = c.current;
|
|
154
|
+
if (!o || le === null) {
|
|
155
|
+
c.current = null, y(!1);
|
|
301
156
|
return;
|
|
302
157
|
}
|
|
303
|
-
const
|
|
158
|
+
const fe = Math.max(
|
|
304
159
|
0,
|
|
305
|
-
qe - (Date.now() -
|
|
160
|
+
qe - (Date.now() - le)
|
|
306
161
|
);
|
|
307
|
-
if (
|
|
308
|
-
|
|
162
|
+
if (g(), fe === 0) {
|
|
163
|
+
c.current = null, y(!1);
|
|
309
164
|
return;
|
|
310
165
|
}
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
},
|
|
166
|
+
p.current = window.setTimeout(() => {
|
|
167
|
+
f.current === d && (p.current = void 0, c.current = null, y(!1));
|
|
168
|
+
}, fe);
|
|
314
169
|
});
|
|
315
170
|
}, "runBodyReload");
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
}, 0)) :
|
|
171
|
+
f.current = d, l.current = R, _.current = !0, o && R !== void 0 ? (V(), g(), c.current = Date.now(), y(!0), m.current = window.setTimeout(() => {
|
|
172
|
+
f.current === d && de();
|
|
173
|
+
}, 0)) : de();
|
|
319
174
|
}
|
|
320
175
|
}
|
|
321
|
-
}, [
|
|
322
|
-
|
|
176
|
+
}, [A, w, n, o, r]), I(() => () => {
|
|
177
|
+
V(), g();
|
|
323
178
|
}, []);
|
|
324
|
-
const
|
|
325
|
-
height:
|
|
326
|
-
width:
|
|
327
|
-
...
|
|
179
|
+
const x = {
|
|
180
|
+
height: q,
|
|
181
|
+
width: j,
|
|
182
|
+
...u
|
|
328
183
|
};
|
|
329
|
-
return (
|
|
330
|
-
/* @__PURE__ */
|
|
331
|
-
/* @__PURE__ */
|
|
332
|
-
|
|
184
|
+
return (o || P) && (x.position = u != null && u.position && u.position !== "static" ? u.position : "relative", x.isolation = "isolate"), /* @__PURE__ */ Ne("div", { ref: ee, className: Te, style: x, children: [
|
|
185
|
+
/* @__PURE__ */ H("div", { id: r, className: Ge, style: he(De, ["height", "width"]) }),
|
|
186
|
+
/* @__PURE__ */ H(
|
|
187
|
+
We,
|
|
333
188
|
{
|
|
334
|
-
visible:
|
|
335
|
-
message:
|
|
336
|
-
overlayFrame:
|
|
189
|
+
visible: P,
|
|
190
|
+
message: Ie("Message.조회된 결과가 없습니다."),
|
|
191
|
+
overlayFrame: ce
|
|
337
192
|
}
|
|
338
193
|
),
|
|
339
|
-
/* @__PURE__ */
|
|
194
|
+
/* @__PURE__ */ H(Fe, { visible: N, overlayFrame: ce })
|
|
340
195
|
] });
|
|
341
196
|
}, "OwpTreeGrid");
|
|
342
197
|
export {
|
|
343
|
-
|
|
198
|
+
cr as OwpTreeGrid
|
|
344
199
|
};
|
|
345
200
|
//# sourceMappingURL=OwpTreeGrid.js.map
|