@owp/core 2.5.21 → 2.5.23
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/dayjs.d.ts +4 -0
- package/dayjs.js +2 -0
- package/dist/_virtual/isBetween.js +8 -0
- package/dist/_virtual/isBetween.js.map +1 -0
- package/dist/_virtual/isBetween2.js +5 -0
- package/dist/_virtual/isBetween2.js.map +1 -0
- package/dist/components/OwpMrtTable/OwpMrtTable.js +21 -21
- package/dist/components/OwpMrtTable/OwpMrtTable.js.map +1 -1
- package/dist/components/OwpPageContent/OwpPageContent.js +20 -19
- package/dist/components/OwpPageContent/OwpPageContent.js.map +1 -1
- package/dist/components/OwpPicker/OwpDatePicker.js +31 -32
- package/dist/components/OwpPicker/OwpDatePicker.js.map +1 -1
- package/dist/components/OwpPicker/OwpDateRangePicker.js +21 -21
- package/dist/components/OwpPicker/OwpDateRangePicker.js.map +1 -1
- package/dist/components/OwpPicker/OwpTimePicker.js +29 -30
- package/dist/components/OwpPicker/OwpTimePicker.js.map +1 -1
- package/dist/components/OwpPicker/OwpWeekDatePicker.js +28 -29
- package/dist/components/OwpPicker/OwpWeekDatePicker.js.map +1 -1
- package/dist/components/OwpPicker/OwpYearRangePicker.js +1 -1
- package/dist/components/OwpPicker/OwpYearRangePicker.js.map +1 -1
- package/dist/components/OwpPicker/internal/DatePickerInput.js +5 -5
- package/dist/components/OwpPicker/internal/DatePickerInput.js.map +1 -1
- package/dist/components/OwpSection/OwpSection.js +118 -111
- package/dist/components/OwpSection/OwpSection.js.map +1 -1
- package/dist/components/OwpTable/OwpDataTable.js +13 -12
- package/dist/components/OwpTable/OwpDataTable.js.map +1 -1
- package/dist/components/OwpTable/OwpFieldTable.js +82 -99
- package/dist/components/OwpTable/OwpFieldTable.js.map +1 -1
- package/dist/components/OwpTable/OwpTable.js +56 -55
- package/dist/components/OwpTable/OwpTable.js.map +1 -1
- package/dist/components/OwpTable/internal/OwpTableBase.js +84 -58
- package/dist/components/OwpTable/internal/OwpTableBase.js.map +1 -1
- package/dist/components/OwpTable/internal/defaultTableStyle.js +6 -7
- package/dist/components/OwpTable/internal/defaultTableStyle.js.map +1 -1
- package/dist/components/OwpTable/utils/tableSx.js +16 -6
- package/dist/components/OwpTable/utils/tableSx.js.map +1 -1
- package/dist/components/OwpTreeGrid/OwpTreeGrid.js +104 -103
- package/dist/components/OwpTreeGrid/OwpTreeGrid.js.map +1 -1
- package/dist/components/OwpTreeGrid/internal/hooks/useOwpTreeGridDatePickerEditor.js +21 -22
- package/dist/components/OwpTreeGrid/internal/hooks/useOwpTreeGridDatePickerEditor.js.map +1 -1
- package/dist/components/OwpTreeGrid/internal/treeGridTheme.js +253 -252
- package/dist/components/OwpTreeGrid/internal/treeGridTheme.js.map +1 -1
- package/dist/constants/table.js +5 -0
- package/dist/constants/table.js.map +1 -0
- package/dist/constants.js +25 -23
- package/dist/constants.js.map +1 -1
- package/dist/dayjs.js +18 -0
- package/dist/dayjs.js.map +1 -0
- package/dist/features/themePreview/components/ThemePreviewCanvas.js +22 -22
- package/dist/features/themePreview/components/ThemePreviewCanvas.js.map +1 -1
- package/dist/features/themePreview/hooks/useThemePreview.js +16 -16
- package/dist/features/themePreview/hooks/useThemePreview.js.map +1 -1
- package/dist/hooks/{useInitCommonCodes.js → internal/useInitCommonCodes.js} +6 -6
- package/dist/hooks/internal/useInitCommonCodes.js.map +1 -0
- package/dist/hooks/internal/useMinimumVisibleState.js +31 -0
- package/dist/hooks/internal/useMinimumVisibleState.js.map +1 -0
- package/dist/hooks/useInitApp.js +17 -14
- package/dist/hooks/useInitApp.js.map +1 -1
- package/dist/hooks.js +49 -51
- package/dist/hooks.js.map +1 -1
- package/dist/node_modules/.pnpm/dayjs@1.11.18/node_modules/dayjs/plugin/isBetween.js +23 -0
- package/dist/node_modules/.pnpm/dayjs@1.11.18/node_modules/dayjs/plugin/isBetween.js.map +1 -0
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE93/constants.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/EAN_UPC/constants.js +1 -1
- package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/ITF/constants.js +1 -1
- package/dist/types/components/OwpPicker/OwpTimePicker.d.ts +1 -1
- package/dist/types/components/OwpSection/OwpSection.d.ts +9 -3
- package/dist/types/components/OwpTable/internal/defaultTableStyle.d.ts +0 -1
- package/dist/types/components/OwpTable/utils/tableSx.d.ts +15 -0
- package/dist/types/constants/index.d.ts +1 -0
- package/dist/types/constants/table.d.ts +1 -0
- package/dist/types/dayjs.d.ts +18 -0
- package/dist/types/hooks/index.d.ts +0 -1
- package/dist/types/hooks/internal/useMinimumVisibleState.d.ts +7 -0
- package/dist/types/utils/dayjsBrowser.d.ts +1 -7
- package/dist/types/utils/formatDateToYmd.d.ts +1 -1
- package/dist/utils/formatDateToYmd.js +3 -3
- package/dist/utils/formatDateToYmd.js.map +1 -1
- package/dist/utils/treeGridExportExcelUtil.js +1 -1
- package/dist/utils/treeGridExportExcelUtil.js.map +1 -1
- package/dist/utils/zipUtil.js +3 -3
- package/dist/utils/zipUtil.js.map +1 -1
- package/package.json +3 -1
- package/dist/hooks/useInitCommonCodes.js.map +0 -1
- package/dist/utils/dayjsBrowser.js +0 -16
- package/dist/utils/dayjsBrowser.js.map +0 -1
- /package/dist/types/hooks/{useInitCommonCodes.d.ts → internal/useInitCommonCodes.d.ts} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tableSx.js","sources":["../../../../src/components/OwpTable/utils/tableSx.ts"],"sourcesContent":["import type { SxProps, Theme } from '@mui/material';\nimport { isArray } from 'es-toolkit/compat';\n\n/**\n * sx 조건부 배열 병합\n * @param styles sx 목록\n */\nexport const mergeSx = (...styles: Array<SxProps<Theme> | undefined | false>): SxProps<Theme> =>\n styles.reduce<Array<Exclude<SxProps<Theme>, readonly unknown[]>>>((acc, style) => {\n if (!style) {\n return acc;\n }\n\n return [...acc, ...(isArray(style) ? style : [style])];\n }, []) as SxProps<Theme>;\n\n/**\n * table radius CSS 값 변환\n * @param value radius 값\n */\nexport const toTableRadiusCssValue = (value: number | string) => {\n return typeof value === 'number' ? `${value}px` : value;\n};\n"],"names":["mergeSx","__name","styles","acc","style","isArray","toTableRadiusCssValue","value"],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"tableSx.js","sources":["../../../../src/components/OwpTable/utils/tableSx.ts"],"sourcesContent":["import type { SxProps, Theme } from '@mui/material';\nimport { isArray } from 'es-toolkit/compat';\n\nconst TABLE_HELPER_TEXT_RESERVED_SPACE = 'calc(0.75rem * 1.66 + 3px)';\n\n/**\n * sx 조건부 배열 병합\n * @param styles sx 목록\n */\nexport const mergeSx = (...styles: Array<SxProps<Theme> | undefined | false>): SxProps<Theme> =>\n styles.reduce<Array<Exclude<SxProps<Theme>, readonly unknown[]>>>((acc, style) => {\n if (!style) {\n return acc;\n }\n\n return [...acc, ...(isArray(style) ? style : [style])];\n }, []) as SxProps<Theme>;\n\n/**\n * table radius CSS 값 변환\n * @param value radius 값\n */\nexport const toTableRadiusCssValue = (value: number | string) => {\n return typeof value === 'number' ? `${value}px` : value;\n};\n\n/**\n * table row helper text 높이 보정 sx\n * @param contentClassName 셀 콘텐츠 className\n */\nexport const getTableHelperTextRowSx = (contentClassName: string) =>\n ({\n [`&:has(.MuiFormHelperText-root) .${contentClassName}::after`]: {\n content: '\"\"',\n display: 'block',\n height: TABLE_HELPER_TEXT_RESERVED_SPACE,\n },\n [`&:has(.MuiFormHelperText-root) .${contentClassName}:has(.MuiFormHelperText-root)::after`]: {\n display: 'none',\n },\n }) as const;\n"],"names":["TABLE_HELPER_TEXT_RESERVED_SPACE","mergeSx","__name","styles","acc","style","isArray","toTableRadiusCssValue","value","getTableHelperTextRowSx","contentClassName"],"mappings":";;;AAGA,MAAMA,IAAmC,8BAM5BC,IAAU,gBAAAC,EAAA,IAAIC,MACzBA,EAAO,OAA2D,CAACC,GAAKC,MACjEA,IAIE,CAAC,GAAGD,GAAK,GAAIE,EAAQD,CAAK,IAAIA,IAAQ,CAACA,CAAK,CAAE,IAH5CD,GAIR,CAAA,CAAE,GAPgB,YAaVG,IAAwB,gBAAAL,EAAA,CAACM,MAC7B,OAAOA,KAAU,WAAW,GAAGA,CAAK,OAAOA,GADf,0BAQxBC,IAA0B,gBAAAP,EAAA,CAACQ,OACrC;AAAA,EACC,CAAC,mCAAmCA,CAAgB,SAAS,GAAG;AAAA,IAC9D,SAAS;AAAA,IACT,SAAS;AAAA,IACT,QAAQV;AAAA,EAAA;AAAA,EAEV,CAAC,mCAAmCU,CAAgB,sCAAsC,GAAG;AAAA,IAC3F,SAAS;AAAA,EAAA;AAEb,IAVqC;"}
|
|
@@ -2,34 +2,35 @@ var cr = Object.defineProperty;
|
|
|
2
2
|
var i = (e, r) => cr(e, "name", { value: r, configurable: !0 });
|
|
3
3
|
import { jsxs as ur, 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
4
|
import { resolveOwpGridTheme as fr } from "../../constants/gridTheme.js";
|
|
5
|
+
import { DEFAULT_TABLE_RADIUS as mr } from "../../constants/table.js";
|
|
5
6
|
import { resolveTreeGridColorNumber as M, TREEGRID_INPUT_CELL_COLOR as He, TREEGRID_CELL_HIGHLIGHT_COLOR as Me } from "../../constants/treeGrid.js";
|
|
6
|
-
import { useGetCurrentSettings as
|
|
7
|
-
import { useOwpTranslation as
|
|
8
|
-
import { useGetCurrentLanguage as
|
|
9
|
-
import { useConfirm as
|
|
7
|
+
import { useGetCurrentSettings as pr } from "../../hooks/useOwpSettings.js";
|
|
8
|
+
import { useOwpTranslation as Rr } from "../../hooks/useOwpTranslation.js";
|
|
9
|
+
import { useGetCurrentLanguage as Tr } from "../../hooks/useCurrentLanguage.js";
|
|
10
|
+
import { useConfirm as gr } from "../../hooks/useConfirm.js";
|
|
10
11
|
import { TREE_GRID_BODY_ROWS_CHANGED_EVENT as xe } from "../../utils/treeGridBodyRowsEvent.js";
|
|
11
|
-
import { getTreeGridCellComparableValue as
|
|
12
|
+
import { getTreeGridCellComparableValue as We, clearTreeGridCellHighlightById as Cr, isTreeGridRowAddedById as w, removeTreeGridAddedRowHighlightColumn as Gr, highlightTreeGridCellById as yr, appendTreeGridAddedRowHighlightColumn as Er, getTreeGridAddedRowBaselineValue as hr } from "../../utils/treeGridUtil.js";
|
|
12
13
|
import { getTreeGridPerfTimestamp as ee, countTreeGridPerf as Ne, logTreeGridPerf as we, measureTreeGridPerf as Fe } from "./internal/utils/perf.js";
|
|
13
|
-
import { useRef as n, useState as re, useMemo as
|
|
14
|
-
import
|
|
14
|
+
import { useRef as n, useState as re, useMemo as Br, useEffect as x, useLayoutEffect as vr } from "react";
|
|
15
|
+
import Dr from "@mui/material/GlobalStyles";
|
|
15
16
|
import { useOwpTreeGridDatePickerEditor as br } from "./internal/hooks/useOwpTreeGridDatePickerEditor.js";
|
|
16
|
-
import { useOwpTreeGridOverlayFrame as
|
|
17
|
-
import { hasTreeGridExplicitEnterMode as je, bindTreeGridEvents as
|
|
17
|
+
import { useOwpTreeGridOverlayFrame as Ir } from "./internal/hooks/useOwpTreeGridOverlayFrame.js";
|
|
18
|
+
import { hasTreeGridExplicitEnterMode as je, bindTreeGridEvents as _r, getTreeGridBodyDataCount as te, buildTreeGridInitializationOptions as kr, hasTreeGridDisplayDataRows as Ue, replaceTreeGridBodyData as Lr, TREE_GRID_BINDING_LOADING_MIN_VISIBLE_MS as Ar } from "./internal/treeGridRuntime.js";
|
|
18
19
|
import { applyTreeGridLayoutToGrid as Or } from "./internal/treeGridLayout.js";
|
|
19
|
-
import { OwpTreeGridLoadingOverlay as
|
|
20
|
-
import { OwpTreeGridNoDataOverlay as
|
|
21
|
-
import { createTreeGridThemeContainerStyle as Vr, TREE_GRID_THEME_WRAPPER_CLASS as
|
|
20
|
+
import { OwpTreeGridLoadingOverlay as Pr } from "./internal/OwpTreeGridLoadingOverlay.js";
|
|
21
|
+
import { OwpTreeGridNoDataOverlay as Sr } from "./internal/OwpTreeGridNoDataOverlay.js";
|
|
22
|
+
import { createTreeGridThemeContainerStyle as Vr, TREE_GRID_THEME_WRAPPER_CLASS as Hr, TREE_GRID_THEME_TABLE_RADIUS_CLASS as Mr, treeGridThemeStyles as xr } from "./internal/treeGridTheme.js";
|
|
22
23
|
import { isEmpty as N } from "../../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/predicate/isEmpty.js";
|
|
23
|
-
import { delay as
|
|
24
|
-
import { isEqual as
|
|
25
|
-
import { omit as
|
|
26
|
-
const
|
|
24
|
+
import { delay as Nr } from "../../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/function/delay.js";
|
|
25
|
+
import { isEqual as wr } from "../../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/predicate/isEqual.js";
|
|
26
|
+
import { omit as Fr } from "../../node_modules/.pnpm/es-toolkit@1.39.10/node_modules/es-toolkit/dist/compat/object/omit.js";
|
|
27
|
+
const jr = /* @__PURE__ */ i((e) => {
|
|
27
28
|
const r = e == null ? void 0 : e.Visible;
|
|
28
29
|
return !!e && r !== 0 && r !== !1 && r !== "0";
|
|
29
|
-
}, "isVisibleTreeGridRow"),
|
|
30
|
+
}, "isVisibleTreeGridRow"), Ur = /* @__PURE__ */ i((e) => {
|
|
30
31
|
const r = e == null ? void 0 : e.Added;
|
|
31
32
|
return !!e && r !== 0 && r !== !1 && r !== "0" && r !== void 0;
|
|
32
|
-
}, "isAddedTreeGridRow"),
|
|
33
|
+
}, "isAddedTreeGridRow"), qe = /* @__PURE__ */ i((e) => !e || e.Fixed === "Foot" || !jr(e) ? !1 : e.Kind === "Data" || Ur(e), "isDisplayTreeGridRow"), Wr = /* @__PURE__ */ i((e) => {
|
|
33
34
|
if (typeof e.GetFirst == "function" && typeof e.GetNext == "function") {
|
|
34
35
|
const r = [];
|
|
35
36
|
let t = e.GetFirst();
|
|
@@ -43,24 +44,24 @@ const Fr = /* @__PURE__ */ i((e) => {
|
|
|
43
44
|
return;
|
|
44
45
|
const t = Object.keys(e.Cols ?? {}).filter(Boolean);
|
|
45
46
|
Wr(e).forEach((o) => {
|
|
46
|
-
|
|
47
|
+
qe(o) && r.set(
|
|
47
48
|
o,
|
|
48
|
-
new Map(t.map((l) => [l,
|
|
49
|
+
new Map(t.map((l) => [l, We(e, o, l)]))
|
|
49
50
|
);
|
|
50
51
|
});
|
|
51
|
-
}, "captureTreeGridChangeBaselines"), Kr = /* @__PURE__ */ i((e) => e != null && e !== "" && e !== 0 && e !== !1 && e !== "0", "isTreeGridChangedFlag"),
|
|
52
|
+
}, "captureTreeGridChangeBaselines"), Kr = /* @__PURE__ */ i((e) => e != null && e !== "" && e !== 0 && e !== !1 && e !== "0", "isTreeGridChangedFlag"), $r = /* @__PURE__ */ i((e, r, t) => {
|
|
52
53
|
const o = r;
|
|
53
54
|
return Object.keys(e.Cols ?? {}).some((l) => l !== t && Kr(o[`${l}Changed`]));
|
|
54
|
-
}, "hasOtherTreeGridChangedCells"),
|
|
55
|
+
}, "hasOtherTreeGridChangedCells"), zr = /* @__PURE__ */ i((e, r, t) => {
|
|
55
56
|
const o = r;
|
|
56
|
-
o[`${t}Changed`] = 0, !w(r) &&
|
|
57
|
-
}, "clearTreeGridCellChangedState"),
|
|
57
|
+
o[`${t}Changed`] = 0, !w(r) && !$r(e, r, t) && (o.Changed = 0);
|
|
58
|
+
}, "clearTreeGridCellChangedState"), Yr = /* @__PURE__ */ i((e, r, t) => {
|
|
58
59
|
const o = e.get(r);
|
|
59
60
|
if (o != null && o.has(t))
|
|
60
61
|
return o.get(t);
|
|
61
62
|
if (w(r))
|
|
62
63
|
return hr(r, t) ?? "";
|
|
63
|
-
}, "resolveTreeGridCellBaselineValue"),
|
|
64
|
+
}, "resolveTreeGridCellBaselineValue"), Jr = /* @__PURE__ */ i(({
|
|
64
65
|
gridId: e,
|
|
65
66
|
grid: r,
|
|
66
67
|
row: t,
|
|
@@ -68,19 +69,19 @@ const Fr = /* @__PURE__ */ i((e) => {
|
|
|
68
69
|
backgroundColor: l,
|
|
69
70
|
baselineMap: F
|
|
70
71
|
}) => {
|
|
71
|
-
if (!
|
|
72
|
+
if (!qe(t))
|
|
72
73
|
return;
|
|
73
|
-
const C =
|
|
74
|
-
if (C !== void 0 &&
|
|
75
|
-
|
|
74
|
+
const C = Yr(F, t, o), b = We(r, t, o);
|
|
75
|
+
if (C !== void 0 && b === C) {
|
|
76
|
+
Cr(e, { row: t, col: o }), zr(r, t, o), w(t) && Gr(t, o);
|
|
76
77
|
return;
|
|
77
78
|
}
|
|
78
|
-
|
|
79
|
+
yr(e, {
|
|
79
80
|
row: t,
|
|
80
81
|
col: o,
|
|
81
82
|
backgroundColor: l
|
|
82
|
-
}), w(t) &&
|
|
83
|
-
}, "syncTreeGridChangedCellHighlightById"),
|
|
83
|
+
}), w(t) && Er(t, o);
|
|
84
|
+
}, "syncTreeGridChangedCellHighlightById"), Bt = /* @__PURE__ */ i(({
|
|
84
85
|
id: e = "treeGridWrapper",
|
|
85
86
|
containerStyle: r,
|
|
86
87
|
containerClassName: t,
|
|
@@ -88,13 +89,13 @@ const Fr = /* @__PURE__ */ i((e) => {
|
|
|
88
89
|
className: l,
|
|
89
90
|
style: F,
|
|
90
91
|
height: C = "100%",
|
|
91
|
-
width:
|
|
92
|
+
width: b = "100%",
|
|
92
93
|
canUseTableRadius: ne = !1,
|
|
93
|
-
tableBorderRadius:
|
|
94
|
+
tableBorderRadius: Ke = mr,
|
|
94
95
|
layoutUrl: $e,
|
|
95
96
|
layoutData: j,
|
|
96
97
|
dataUrl: ze,
|
|
97
|
-
layoutOverrides:
|
|
98
|
+
layoutOverrides: U,
|
|
98
99
|
data: c,
|
|
99
100
|
useDataUrl: oe,
|
|
100
101
|
onSelect: ie,
|
|
@@ -115,35 +116,35 @@ const Fr = /* @__PURE__ */ i((e) => {
|
|
|
115
116
|
loading: Qe,
|
|
116
117
|
showLoading: u = !0
|
|
117
118
|
}) => {
|
|
118
|
-
var
|
|
119
|
-
const { t: I } =
|
|
119
|
+
var Oe, Pe;
|
|
120
|
+
const { t: I } = Rr(), { confirmDelete: Xe } = gr(), W = pr(), q = (Pe = (Oe = W == null ? void 0 : W.theme) == null ? void 0 : Oe.main) == null ? void 0 : Pe.grid, d = n(null), Ce = n(null), Ge = n(null), K = n(null), $ = n(U), ye = n(c), Ee = n(je(j)), he = Je ? async () => await Xe({
|
|
120
121
|
title: I("Message.삭제된 항목을 완전히 삭제하시겠습니까?"),
|
|
121
122
|
description: I("Message.취소하면 삭제 상태가 해제됩니다."),
|
|
122
123
|
okText: I("Button.완전 삭제")
|
|
123
|
-
}) ? "remove" : "undelete" : void 0,
|
|
124
|
+
}) ? "remove" : "undelete" : void 0, _ = n({
|
|
124
125
|
onSelect: ie,
|
|
125
126
|
onRowClick: se,
|
|
126
127
|
onRowAdd: ae,
|
|
127
128
|
onRowDelete: de,
|
|
128
|
-
onBeforeRowUndelete:
|
|
129
|
+
onBeforeRowUndelete: he,
|
|
129
130
|
onRowUndelete: le,
|
|
130
131
|
onRowChange: ce,
|
|
131
132
|
onClickButton: ue,
|
|
132
133
|
onSave: fe,
|
|
133
134
|
onReady: me,
|
|
134
135
|
onAfterValueChanged: pe
|
|
135
|
-
}), G = n(void 0), z = n(!1),
|
|
136
|
-
() => fr(
|
|
137
|
-
[
|
|
138
|
-
),
|
|
136
|
+
}), G = n(void 0), z = n(!1), k = n(void 0), L = n(void 0), Ze = n(!1), y = n(0), g = n(null), E = n(void 0), h = n(void 0), Be = n(Re), Y = n(Te), ve = n(ge), [A, er] = re(!1), [rr, B] = re(!1), [tr, De] = re(!1), O = Tr(), f = Br(
|
|
137
|
+
() => fr(q),
|
|
138
|
+
[q]
|
|
139
|
+
), be = n(
|
|
139
140
|
M(f.editable.backgroundColor) ?? M(He)
|
|
140
141
|
), J = n(
|
|
141
142
|
f.changed.backgroundColor ?? Me
|
|
142
|
-
), P = n(/* @__PURE__ */ new WeakMap()), Ie = n(f.state.selectedCellBackgroundColor),
|
|
143
|
-
|
|
143
|
+
), P = n(/* @__PURE__ */ new WeakMap()), Ie = n(f.state.selectedCellBackgroundColor), _e = n(f.state.hoverCellBackgroundColor), ke = n(O.id), nr = u && c !== void 0 && A && L.current !== c, Q = u && Qe === !0 || u && (rr || nr), X = !Q && c !== void 0 && N(c) && !tr, Le = /* @__PURE__ */ i((s) => {
|
|
144
|
+
De(Ue(s));
|
|
144
145
|
}, "syncHasDisplayDataRows"), or = /* @__PURE__ */ i((s, a, p, T) => {
|
|
145
146
|
var m, v;
|
|
146
|
-
Y.current && a.Fixed !== "Foot" &&
|
|
147
|
+
Y.current && a.Fixed !== "Foot" && Jr({
|
|
147
148
|
gridId: e,
|
|
148
149
|
grid: s,
|
|
149
150
|
row: a,
|
|
@@ -151,10 +152,10 @@ const Fr = /* @__PURE__ */ i((e) => {
|
|
|
151
152
|
backgroundColor: J.current,
|
|
152
153
|
baselineMap: P.current
|
|
153
154
|
});
|
|
154
|
-
const R = ((m =
|
|
155
|
+
const R = ((m = _.current) == null ? void 0 : m.onAfterValueChanged) ?? ((v = _.current) == null ? void 0 : v.onRowChange);
|
|
155
156
|
R == null || R(s, a, p, T);
|
|
156
157
|
}, "handleDatePickerEditorValueChange");
|
|
157
|
-
$.current =
|
|
158
|
+
$.current = U, ye.current = c, Ee.current = je(j), Be.current = Re, Y.current = Te, ve.current = ge, be.current = M(f.editable.backgroundColor) ?? M(He), J.current = f.changed.backgroundColor ?? Me, Ie.current = f.state.selectedCellBackgroundColor, _e.current = f.state.hoverCellBackgroundColor;
|
|
158
159
|
const {
|
|
159
160
|
datePickerEditorElement: ir,
|
|
160
161
|
handleDatePickerEditorButtonClick: sr,
|
|
@@ -164,15 +165,15 @@ const Fr = /* @__PURE__ */ i((e) => {
|
|
|
164
165
|
} = br({
|
|
165
166
|
config: Ye,
|
|
166
167
|
treeGridInstanceRef: d,
|
|
167
|
-
isTreeGridReady:
|
|
168
|
+
isTreeGridReady: A,
|
|
168
169
|
onValueChange: or
|
|
169
170
|
});
|
|
170
|
-
|
|
171
|
+
_.current = {
|
|
171
172
|
onSelect: ie,
|
|
172
173
|
onRowClick: se,
|
|
173
174
|
onRowAdd: ae,
|
|
174
175
|
onRowDelete: de,
|
|
175
|
-
onBeforeRowUndelete:
|
|
176
|
+
onBeforeRowUndelete: he,
|
|
176
177
|
onRowUndelete: le,
|
|
177
178
|
onRowChange: ce,
|
|
178
179
|
onClickButton: ue,
|
|
@@ -184,45 +185,45 @@ const Fr = /* @__PURE__ */ i((e) => {
|
|
|
184
185
|
onInternalKeyDown: dr,
|
|
185
186
|
onInternalStartEdit: lr
|
|
186
187
|
};
|
|
187
|
-
const
|
|
188
|
+
const Ae = Ir({
|
|
188
189
|
visible: Q || X,
|
|
189
190
|
containerRef: Ce,
|
|
190
191
|
treeGridInstanceRef: d,
|
|
191
192
|
debugId: e
|
|
192
|
-
}),
|
|
193
|
-
h.current !== void 0 && (window.clearTimeout(h.current), h.current = void 0);
|
|
194
|
-
}, "clearBindingLoadingHideTimeout"), Z = /* @__PURE__ */ i(() => {
|
|
193
|
+
}), S = /* @__PURE__ */ i(() => {
|
|
195
194
|
E.current !== void 0 && (window.clearTimeout(E.current), E.current = void 0);
|
|
195
|
+
}, "clearBindingLoadingHideTimeout"), Z = /* @__PURE__ */ i(() => {
|
|
196
|
+
h.current !== void 0 && (window.clearTimeout(h.current), h.current = void 0);
|
|
196
197
|
}, "clearBodyReloadStartTimeout");
|
|
197
198
|
x(() => {
|
|
198
199
|
const s = /* @__PURE__ */ i((a) => {
|
|
199
200
|
var T;
|
|
200
|
-
((T = a.detail) == null ? void 0 : T.gridId) === e &&
|
|
201
|
+
((T = a.detail) == null ? void 0 : T.gridId) === e && De(Ue(d.current));
|
|
201
202
|
}, "handleBodyRowsChanged");
|
|
202
203
|
return window.addEventListener(xe, s), () => {
|
|
203
204
|
window.removeEventListener(xe, s);
|
|
204
205
|
};
|
|
205
206
|
}, [e]), x(() => {
|
|
206
|
-
u || (Z(),
|
|
207
|
+
u || (Z(), S(), g.current = null, B(!1));
|
|
207
208
|
}, [u]), x(() => {
|
|
208
209
|
var s;
|
|
209
|
-
if (
|
|
210
|
-
return
|
|
210
|
+
if (O.id !== ke.current && !N(d.current) && ((s = d.current) == null || s.Dispose(), d.current = null, ke.current = O.id), !!N(d.current))
|
|
211
|
+
return _r({
|
|
211
212
|
id: e,
|
|
212
|
-
latestEventHandlersRef:
|
|
213
|
-
layoutHasExplicitEnterModeRef:
|
|
213
|
+
latestEventHandlersRef: _,
|
|
214
|
+
layoutHasExplicitEnterModeRef: Ee,
|
|
214
215
|
highlightEditableCellsRef: Be,
|
|
215
216
|
highlightChangedCellsRef: Y,
|
|
216
217
|
syncDeletedRowCanEditRef: ve,
|
|
217
|
-
editableCellBackgroundColorValueRef:
|
|
218
|
+
editableCellBackgroundColorValueRef: be,
|
|
218
219
|
changedCellBackgroundColorRef: J,
|
|
219
220
|
selectedCellBackgroundColorRef: Ie,
|
|
220
|
-
hoverCellBackgroundColorRef:
|
|
221
|
+
hoverCellBackgroundColorRef: _e,
|
|
221
222
|
changedCellBaselineRef: P,
|
|
222
223
|
treeGridInstanceRef: d,
|
|
223
224
|
treeGridInitStartedAtRef: Ge,
|
|
224
225
|
latestLayoutOverridesRef: $,
|
|
225
|
-
appliedLayoutOverridesRef:
|
|
226
|
+
appliedLayoutOverridesRef: k,
|
|
226
227
|
appliedBodyDataPropRef: L,
|
|
227
228
|
hasAppliedInitialLayoutRef: Ze,
|
|
228
229
|
syncHasDisplayDataRows: Le,
|
|
@@ -238,103 +239,103 @@ const Fr = /* @__PURE__ */ i((e) => {
|
|
|
238
239
|
dataUrl: ze,
|
|
239
240
|
bodyData: c,
|
|
240
241
|
useDataUrl: oe,
|
|
241
|
-
width:
|
|
242
|
+
width: b,
|
|
242
243
|
height: C,
|
|
243
|
-
languageId:
|
|
244
|
+
languageId: O.id
|
|
244
245
|
}),
|
|
245
246
|
e,
|
|
246
247
|
e
|
|
247
248
|
), () => {
|
|
248
|
-
|
|
249
|
+
Nr(() => {
|
|
249
250
|
var a;
|
|
250
251
|
(a = d.current) == null || a.Dispose();
|
|
251
252
|
}, 200);
|
|
252
253
|
};
|
|
253
|
-
}, []),
|
|
254
|
+
}, []), vr(() => {
|
|
254
255
|
const s = d.current, a = $.current, p = ye.current;
|
|
255
|
-
if (N(s) || !
|
|
256
|
+
if (N(s) || !A)
|
|
256
257
|
return;
|
|
257
|
-
const T =
|
|
258
|
+
const T = k.current !== a && !wr(k.current, a), R = L.current !== p && (!z.current || G.current !== p);
|
|
258
259
|
if (!(!T && !R)) {
|
|
259
260
|
if (T) {
|
|
260
261
|
const m = ee();
|
|
261
|
-
Or(s, a, R),
|
|
262
|
+
Or(s, a, R), k.current = a, Fe(e, "apply layout", m, {
|
|
262
263
|
disableBodyReload: !!R
|
|
263
264
|
});
|
|
264
265
|
}
|
|
265
266
|
if (R) {
|
|
266
267
|
const m = y.current + 1, v = /* @__PURE__ */ i(() => {
|
|
267
|
-
const
|
|
268
|
-
|
|
269
|
-
bodyRowCount: te(
|
|
270
|
-
}),
|
|
268
|
+
const D = G.current;
|
|
269
|
+
h.current = void 0, K.current = ee(), Ne(e, "reload"), we(e, "ReloadBody start", {
|
|
270
|
+
bodyRowCount: te(D)
|
|
271
|
+
}), Lr(s, D, () => {
|
|
271
272
|
if (y.current !== m)
|
|
272
273
|
return;
|
|
273
|
-
L.current =
|
|
274
|
-
bodyRowCount: te(
|
|
275
|
-
}),
|
|
276
|
-
const
|
|
277
|
-
if (!u ||
|
|
274
|
+
L.current = D, P.current = /* @__PURE__ */ new WeakMap(), qr(s, P.current), Le(s), Fe(e, "ReloadBody end", K.current, {
|
|
275
|
+
bodyRowCount: te(D)
|
|
276
|
+
}), K.current = null, G.current === D && (G.current = void 0, z.current = !1);
|
|
277
|
+
const Se = g.current;
|
|
278
|
+
if (!u || Se === null) {
|
|
278
279
|
g.current = null, B(!1);
|
|
279
280
|
return;
|
|
280
281
|
}
|
|
281
|
-
const
|
|
282
|
+
const Ve = Math.max(
|
|
282
283
|
0,
|
|
283
|
-
|
|
284
|
+
Ar - (Date.now() - Se)
|
|
284
285
|
);
|
|
285
|
-
if (
|
|
286
|
+
if (S(), Ve === 0) {
|
|
286
287
|
g.current = null, B(!1);
|
|
287
288
|
return;
|
|
288
289
|
}
|
|
289
|
-
|
|
290
|
-
y.current === m && (
|
|
291
|
-
},
|
|
290
|
+
E.current = window.setTimeout(() => {
|
|
291
|
+
y.current === m && (E.current = void 0, g.current = null, B(!1));
|
|
292
|
+
}, Ve);
|
|
292
293
|
});
|
|
293
294
|
}, "runBodyReload");
|
|
294
|
-
y.current = m, G.current = p, z.current = !0, u && p !== void 0 ? (Z(),
|
|
295
|
+
y.current = m, G.current = p, z.current = !0, u && p !== void 0 ? (Z(), S(), g.current = Date.now(), B(!0), h.current = window.setTimeout(() => {
|
|
295
296
|
y.current === m && v();
|
|
296
297
|
}, 0)) : v();
|
|
297
298
|
}
|
|
298
299
|
}
|
|
299
|
-
}, [
|
|
300
|
-
Z(),
|
|
300
|
+
}, [A, U, c, u, e]), x(() => () => {
|
|
301
|
+
Z(), S();
|
|
301
302
|
}, []);
|
|
302
|
-
const
|
|
303
|
-
width:
|
|
303
|
+
const V = Vr({
|
|
304
|
+
width: b,
|
|
304
305
|
height: C,
|
|
305
306
|
treeGridTheme: f,
|
|
306
|
-
gridThemeConfig:
|
|
307
|
+
gridThemeConfig: q,
|
|
307
308
|
containerStyle: r,
|
|
308
|
-
tableBorderRadius: ne ?
|
|
309
|
+
tableBorderRadius: ne ? Ke : void 0
|
|
309
310
|
});
|
|
310
|
-
return o !== void 0 && (
|
|
311
|
+
return o !== void 0 && (V["--owp-tree-grid-toolbar-row-background-color"] = String(o)), (u || X) && (V.position = r != null && r.position && r.position !== "static" ? r.position : "relative", V.isolation = "isolate"), /* @__PURE__ */ ur(
|
|
311
312
|
"div",
|
|
312
313
|
{
|
|
313
314
|
ref: Ce,
|
|
314
315
|
className: [
|
|
315
|
-
|
|
316
|
-
ne &&
|
|
316
|
+
Hr,
|
|
317
|
+
ne && Mr,
|
|
317
318
|
t
|
|
318
319
|
].filter(Boolean).join(" "),
|
|
319
|
-
style:
|
|
320
|
+
style: V,
|
|
320
321
|
children: [
|
|
321
|
-
/* @__PURE__ */ H(
|
|
322
|
-
/* @__PURE__ */ H("div", { id: e, className: l, style:
|
|
322
|
+
/* @__PURE__ */ H(Dr, { styles: xr }),
|
|
323
|
+
/* @__PURE__ */ H("div", { id: e, className: l, style: Fr(F, ["height", "width"]) }),
|
|
323
324
|
/* @__PURE__ */ H(
|
|
324
|
-
|
|
325
|
+
Sr,
|
|
325
326
|
{
|
|
326
327
|
visible: X,
|
|
327
328
|
message: I("Message.조회된 결과가 없습니다."),
|
|
328
|
-
overlayFrame:
|
|
329
|
+
overlayFrame: Ae
|
|
329
330
|
}
|
|
330
331
|
),
|
|
331
|
-
/* @__PURE__ */ H(
|
|
332
|
+
/* @__PURE__ */ H(Pr, { visible: Q, overlayFrame: Ae }),
|
|
332
333
|
ir
|
|
333
334
|
]
|
|
334
335
|
}
|
|
335
336
|
);
|
|
336
337
|
}, "OwpTreeGrid");
|
|
337
338
|
export {
|
|
338
|
-
|
|
339
|
+
Bt as OwpTreeGrid
|
|
339
340
|
};
|
|
340
341
|
//# sourceMappingURL=OwpTreeGrid.js.map
|