@owp/core 2.5.10 → 2.5.12

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.
Files changed (71) hide show
  1. package/dist/_virtual/index11.js +2 -2
  2. package/dist/_virtual/index13.js +2 -2
  3. package/dist/_virtual/index14.js +2 -2
  4. package/dist/_virtual/index15.js +2 -2
  5. package/dist/components/OwpSearchFilter/OwpSearchFilter.js +42 -26
  6. package/dist/components/OwpSearchFilter/OwpSearchFilter.js.map +1 -1
  7. package/dist/components/OwpSelectorBase/OwpSelectorSelect.js +51 -51
  8. package/dist/components/OwpSelectorBase/OwpSelectorSelect.js.map +1 -1
  9. package/dist/components/OwpTable/OwpFieldTable.js +115 -90
  10. package/dist/components/OwpTable/OwpFieldTable.js.map +1 -1
  11. package/dist/components/OwpTable/OwpTable.js +161 -141
  12. package/dist/components/OwpTable/OwpTable.js.map +1 -1
  13. package/dist/components/OwpTable/internal/FieldTableValue.js +43 -0
  14. package/dist/components/OwpTable/internal/FieldTableValue.js.map +1 -0
  15. package/dist/components/OwpTable/internal/defaultTableStyle.js +13 -10
  16. package/dist/components/OwpTable/internal/defaultTableStyle.js.map +1 -1
  17. package/dist/components/OwpTreeGrid/OwpTreeGrid.js +176 -168
  18. package/dist/components/OwpTreeGrid/OwpTreeGrid.js.map +1 -1
  19. package/dist/components/OwpTreeGrid/internal/treeGridTheme.js +215 -147
  20. package/dist/components/OwpTreeGrid/internal/treeGridTheme.js.map +1 -1
  21. package/dist/configs/defaultConfig.js +110 -70
  22. package/dist/configs/defaultConfig.js.map +1 -1
  23. package/dist/constants/tableTheme.js +7 -6
  24. package/dist/constants/tableTheme.js.map +1 -1
  25. package/dist/features/themePreview/components/ThemePreviewCanvas.js +275 -273
  26. package/dist/features/themePreview/components/ThemePreviewCanvas.js.map +1 -1
  27. package/dist/features/themePreview/components/ThemePreviewCanvasSections.js +552 -316
  28. package/dist/features/themePreview/components/ThemePreviewCanvasSections.js.map +1 -1
  29. package/dist/features/themePreview/components/ThemePreviewColorField.js +227 -201
  30. package/dist/features/themePreview/components/ThemePreviewColorField.js.map +1 -1
  31. package/dist/features/themePreview/components/ThemePreviewControls.js +176 -160
  32. package/dist/features/themePreview/components/ThemePreviewControls.js.map +1 -1
  33. package/dist/features/themePreview/components/themePreviewCanvas.shared.js +38 -38
  34. package/dist/features/themePreview/components/themePreviewCanvas.shared.js.map +1 -1
  35. package/dist/features/themePreview/configs/settings.js +33 -20
  36. package/dist/features/themePreview/configs/settings.js.map +1 -1
  37. package/dist/features/themePreview/dialogs/ThemePreviewDialog.js +227 -220
  38. package/dist/features/themePreview/dialogs/ThemePreviewDialog.js.map +1 -1
  39. package/dist/features/themePreview/hooks/useThemePreview.js +213 -204
  40. package/dist/features/themePreview/hooks/useThemePreview.js.map +1 -1
  41. package/dist/features/themePreview/utils/themePreviewDefinitions.js +63 -30
  42. package/dist/features/themePreview/utils/themePreviewDefinitions.js.map +1 -1
  43. package/dist/layout/components/navbar/NavbarToggleButton.js +46 -42
  44. package/dist/layout/components/navbar/NavbarToggleButton.js.map +1 -1
  45. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE128/index.js +1 -1
  46. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE39/index.js +1 -1
  47. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/CODE93/index.js +1 -1
  48. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/EAN_UPC/index.js +1 -1
  49. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/GenericBarcode/index.js +1 -1
  50. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/ITF/index.js +1 -1
  51. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/MSI/index.js +1 -1
  52. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/codabar/index.js +1 -1
  53. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/barcodes/pharmacode/index.js +1 -1
  54. package/dist/node_modules/.pnpm/jsbarcode@3.12.1/node_modules/jsbarcode/bin/renderers/index.js +1 -1
  55. package/dist/owp-app.css +1 -1
  56. package/dist/types/components/OwpTable/OwpFieldTable.d.ts +7 -3
  57. package/dist/types/components/OwpTable/OwpTable.d.ts +3 -1
  58. package/dist/types/components/OwpTable/internal/FieldTableValue.d.ts +17 -0
  59. package/dist/types/components/OwpTable/internal/defaultTableStyle.d.ts +3 -0
  60. package/dist/types/components/OwpTreeGrid/OwpTreeGrid.d.ts +7 -1
  61. package/dist/types/components/OwpTreeGrid/internal/treeGridTheme.d.ts +4 -2
  62. package/dist/types/configs/defaultConfig.d.ts +42 -3
  63. package/dist/types/constants/tableTheme.d.ts +1 -0
  64. package/dist/types/features/themePreview/components/ThemePreviewCanvasSections.d.ts +8 -0
  65. package/dist/types/features/themePreview/components/themePreviewCanvas.shared.d.ts +3 -3
  66. package/dist/types/features/themePreview/configs/settings.d.ts +12 -0
  67. package/dist/types/index.d.ts +1 -0
  68. package/dist/types/types/OwpMuiThemeTypes.d.ts +9 -0
  69. package/dist/types/types/OwpTableThemeTypes.d.ts +1 -0
  70. package/dist/types/types/index.d.ts +1 -0
  71. package/package.json +1 -1
@@ -1,20 +1,20 @@
1
- var ie = Object.defineProperty;
2
- var s = (r, d) => ie(r, "name", { value: d, configurable: !0 });
3
- import { jsx as o, jsxs as u } 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 { MenuItem as W, ButtonBase as ae, Typography as x, Paper as A, TextField as Y, Divider as Z, Box as se, IconButton as de, FormControlLabel as ce, Checkbox as he } from "@mui/material";
5
- import ue from "../../../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/RestartAltOutlined.js";
6
- import { ThemeProvider as me, createTheme as fe } from "@mui/material/styles";
7
- import { useState as pe, useMemo as T } from "react";
8
- import { toolbarCuratedPresetKeys as be, designSystemPresetKeys as Ce } from "../configs/presets.js";
9
- import { ThemePreviewColorField as q } from "./ThemePreviewColorField.js";
10
- import { getThemePreviewPresetOptionsByMode as ve, THEME_PREVIEW_CUSTOM_PRESET_KEY as J, isThemePreviewCustomSection as ge, getThemePreviewPaletteValue as G } from "../utils/themePreviewSettings.js";
11
- import { themePreviewFieldGroupsBySection as xe, themePreviewSectionOptions as X } from "../utils/themePreviewDefinitions.js";
12
- import { deriveThemePreviewPaletteGroupValues as ye } from "../utils/color.js";
13
- function Pe(r) {
1
+ var ae = Object.defineProperty;
2
+ var s = (r, d) => ae(r, "name", { value: d, configurable: !0 });
3
+ import { jsx as o, jsxs 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 { MenuItem as W, ButtonBase as se, Typography as x, Paper as A, TextField as Z, Divider as q, Box as de, IconButton as ce, FormControlLabel as ue, Checkbox as he } from "@mui/material";
5
+ import me from "../../../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/RestartAltOutlined.js";
6
+ import { ThemeProvider as fe, createTheme as pe } from "@mui/material/styles";
7
+ import { useState as be, useRef as Ce, useMemo as B, useEffect as ge } from "react";
8
+ import { toolbarCuratedPresetKeys as ve, designSystemPresetKeys as xe } from "../configs/presets.js";
9
+ import { ThemePreviewColorField as J } from "./ThemePreviewColorField.js";
10
+ import { getThemePreviewPresetOptionsByMode as ye, THEME_PREVIEW_CUSTOM_PRESET_KEY as O, isThemePreviewCustomSection as ke, getThemePreviewPaletteValue as R } from "../utils/themePreviewSettings.js";
11
+ import { themePreviewFieldGroupsBySection as Pe, themePreviewSectionOptions as ee } from "../utils/themePreviewDefinitions.js";
12
+ import { deriveThemePreviewPaletteGroupValues as we } from "../utils/color.js";
13
+ function Te(r) {
14
14
  return r.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/^./, (d) => d.toUpperCase());
15
15
  }
16
- s(Pe, "getThemePreviewFieldClusterLabel");
17
- function ke(r) {
16
+ s(Te, "getThemePreviewFieldClusterLabel");
17
+ function Be(r) {
18
18
  const d = r.find((f) => f.path.endsWith(".main")), p = r.find((f) => f.path.endsWith(".light")), m = r.find((f) => f.path.endsWith(".dark")), c = r.find((f) => f.path.endsWith(".contrastText"));
19
19
  return !d || !p && !m && !c ? null : {
20
20
  mainPath: d.path,
@@ -23,18 +23,18 @@ function ke(r) {
23
23
  contrastTextPath: c == null ? void 0 : c.path
24
24
  };
25
25
  }
26
- s(ke, "getThemePreviewAutoDerivedFieldPaths");
27
- function we(r) {
26
+ s(Be, "getThemePreviewAutoDerivedFieldPaths");
27
+ function Me(r) {
28
28
  const d = r.reduce(
29
- (t, h) => {
30
- const i = h.path.split(".")[0] ?? "";
31
- return i && (t[i] || (t[i] = []), t[i].push(h)), t;
29
+ (t, u) => {
30
+ const i = u.path.split(".")[0] ?? "";
31
+ return i && (t[i] || (t[i] = []), t[i].push(u)), t;
32
32
  },
33
33
  {}
34
34
  ), p = Object.fromEntries(
35
- Object.entries(d).map(([t, h]) => [
35
+ Object.entries(d).map(([t, u]) => [
36
36
  t,
37
- h.length
37
+ u.length
38
38
  ])
39
39
  ), m = new Set(
40
40
  Object.entries(p).filter(([, t]) => t > 1).map(([t]) => t)
@@ -47,29 +47,29 @@ function we(r) {
47
47
  fields: [t]
48
48
  }));
49
49
  const F = /* @__PURE__ */ new Set();
50
- return r.reduce((t, h) => {
51
- const i = h.path.split(".")[0] ?? "";
50
+ return r.reduce((t, u) => {
51
+ const i = u.path.split(".")[0] ?? "";
52
52
  if (!m.has(i))
53
53
  return t.push({
54
- key: h.path,
55
- fields: [h]
54
+ key: u.path,
55
+ fields: [u]
56
56
  }), t;
57
57
  if (F.has(i))
58
58
  return t;
59
59
  F.add(i);
60
- const M = d[i] ?? [h];
60
+ const S = d[i] ?? [u];
61
61
  return t.push({
62
62
  key: i,
63
- label: Pe(i),
64
- fields: M,
65
- autoDerivedFieldPaths: ke(M) ?? void 0
63
+ label: Te(i),
64
+ fields: S,
65
+ autoDerivedFieldPaths: Be(S) ?? void 0
66
66
  }), t;
67
67
  }, []);
68
68
  }
69
- s(we, "getThemePreviewFieldClusters");
70
- const Te = Object.fromEntries(
71
- X.map((r) => [r.key, r])
72
- ), v = {
69
+ s(Me, "getThemePreviewFieldClusters");
70
+ const Fe = Object.fromEntries(
71
+ ee.map((r) => [r.key, r])
72
+ ), g = {
73
73
  active: {
74
74
  backgroundColor: "#1ea3e6",
75
75
  borderColor: "#1591cf",
@@ -82,14 +82,17 @@ const Te = Object.fromEntries(
82
82
  descriptionColor: "#6b7280",
83
83
  textColor: "#111827"
84
84
  }
85
- }, B = "#d8dee8", Be = "#d1d7e0", Fe = "#f8fafc", D = "#ffffff", y = "#111827", g = "#6b7280", O = "#ffffff", ee = "#cbd5e1", Me = "#94a3b8", z = "#1ea3e6", Q = "#111827", Se = "#f8fafc", Ne = "#f8fafc", Ie = fe({
85
+ }, M = "#d8dee8", Se = "#d1d7e0", Ee = "#f8fafc", D = "#ffffff", y = "#111827", v = "#6b7280", Q = "#ffffff", re = "#cbd5e1", Ne = "#94a3b8", z = "#1ea3e6", V = "#111827", Ie = "#f8fafc", We = "#f8fafc", ze = `특별한 경우가 아니면 연동 색상 편집은 권장하지 않습니다.
86
+
87
+ Primary Main 값을 선택하면 Light, Dark, Contrast 값이 자동으로 채워집니다.
88
+ 특수한 디자인 조정이 필요한 경우에만 직접 편집하세요.`, je = pe({
86
89
  palette: {
87
90
  mode: "light",
88
91
  background: {
89
92
  default: D,
90
93
  paper: D
91
94
  },
92
- divider: B,
95
+ divider: M,
93
96
  primary: {
94
97
  main: z
95
98
  },
@@ -98,7 +101,7 @@ const Te = Object.fromEntries(
98
101
  },
99
102
  text: {
100
103
  primary: y,
101
- secondary: g
104
+ secondary: v
102
105
  }
103
106
  },
104
107
  typography: {
@@ -111,16 +114,16 @@ const Te = Object.fromEntries(
111
114
  fontSize: "1.3rem"
112
115
  }
113
116
  }
114
- }), Ee = {
117
+ }), Ke = {
115
118
  color: y,
116
119
  "& .MuiFormHelperText-root": {
117
- color: g
120
+ color: v
118
121
  },
119
122
  "& .MuiInputAdornment-root": {
120
- color: g
123
+ color: v
121
124
  },
122
125
  "& .MuiInputLabel-root": {
123
- color: g
126
+ color: v
124
127
  },
125
128
  "& .MuiInputLabel-root.Mui-focused": {
126
129
  color: y
@@ -129,13 +132,13 @@ const Te = Object.fromEntries(
129
132
  color: y
130
133
  },
131
134
  "& .MuiOutlinedInput-root": {
132
- backgroundColor: O,
135
+ backgroundColor: Q,
133
136
  color: y,
134
137
  "& fieldset": {
135
- borderColor: ee
138
+ borderColor: re
136
139
  },
137
140
  "&:hover fieldset": {
138
- borderColor: Me
141
+ borderColor: Ne
139
142
  },
140
143
  "&.Mui-focused fieldset": {
141
144
  borderColor: z,
@@ -143,31 +146,31 @@ const Te = Object.fromEntries(
143
146
  }
144
147
  },
145
148
  "& .MuiSelect-icon": {
146
- color: g
149
+ color: v
147
150
  },
148
151
  "& .MuiButton-outlined": {
149
- backgroundColor: O,
150
- borderColor: Q,
152
+ backgroundColor: Q,
153
+ borderColor: V,
151
154
  color: y,
152
155
  "&:hover": {
153
- backgroundColor: Se,
154
- borderColor: Q
156
+ backgroundColor: Ie,
157
+ borderColor: V
155
158
  }
156
159
  },
157
160
  "& .MuiCheckbox-root": {
158
- color: g
161
+ color: v
159
162
  },
160
163
  "& .MuiCheckbox-root.Mui-checked": {
161
164
  color: z
162
165
  },
163
166
  "& .MuiDivider-root": {
164
- borderColor: B
167
+ borderColor: M
165
168
  }
166
- }, We = /* @__PURE__ */ new Set([
167
- ...be,
168
- ...Ce
169
- ]), V = /* @__PURE__ */ new Set(["tableFieldHeader", "tableFieldCell"]);
170
- function _e({
169
+ }, Le = /* @__PURE__ */ new Set([
170
+ ...ve,
171
+ ...xe
172
+ ]), X = /* @__PURE__ */ new Set(["tableFieldHeader", "tableFieldCell"]);
173
+ function Je({
171
174
  activeSection: r,
172
175
  presetOptions: d,
173
176
  selectedMode: p,
@@ -176,30 +179,30 @@ function _e({
176
179
  resetVersion: f,
177
180
  onSectionChange: F,
178
181
  onPaletteValueChange: t,
179
- onPaletteValuesChange: h,
182
+ onPaletteValuesChange: u,
180
183
  onPaletteValueReset: i,
181
- onPaletteValuesReset: M,
182
- onPresetKeyChange: re,
183
- onPresetModeChange: oe
184
+ onPaletteValuesReset: S,
185
+ onPresetKeyChange: oe,
186
+ onPresetModeChange: te
184
187
  }) {
185
- const [te, le] = pe({}), S = !ge(r), b = S ? r : null, N = T(
186
- () => S && b ? ve(d, b, p) : [],
187
- [S, d, b, p]
188
- ), R = T(
188
+ const [le, ne] = be({}), j = Ce(null), E = !ke(r), b = E ? r : null, N = B(
189
+ () => E && b ? ye(d, b, p) : [],
190
+ [E, d, b, p]
191
+ ), G = B(
189
192
  () => {
190
193
  var e;
191
194
  return (e = N.find(
192
- (l) => !We.has(l.key)
195
+ (l) => !Le.has(l.key)
193
196
  )) == null ? void 0 : e.key;
194
197
  },
195
198
  [N]
196
- ), H = xe[r], I = T(
199
+ ), H = Pe[r], I = B(
197
200
  () => H.map((e) => ({
198
201
  ...e,
199
- fieldClusters: we(e.fields)
202
+ fieldClusters: Me(e.fields)
200
203
  })),
201
204
  [H]
202
- ), L = T(() => {
205
+ ), U = B(() => {
203
206
  if (r !== "table")
204
207
  return [
205
208
  {
@@ -208,9 +211,9 @@ function _e({
208
211
  }
209
212
  ];
210
213
  const e = I.filter(
211
- (n) => V.has(n.key)
214
+ (n) => X.has(n.key)
212
215
  ), l = I.filter(
213
- (n) => !V.has(n.key)
216
+ (n) => !X.has(n.key)
214
217
  );
215
218
  return [
216
219
  {
@@ -224,18 +227,18 @@ function _e({
224
227
  fieldGroups: l
225
228
  }
226
229
  ].filter((n) => n.fieldGroups.length > 0);
227
- }, [r, I]), j = Te[r], ne = T(
230
+ }, [r, I]), K = Fe[r], ie = B(
228
231
  () => N.flatMap((e) => {
229
232
  const l = [];
230
- return e.key === R && l.push(
233
+ return e.key === G && l.push(
231
234
  /* @__PURE__ */ o(
232
- Z,
235
+ q,
233
236
  {
234
237
  component: "li",
235
238
  role: "presentation",
236
239
  textAlign: "center",
237
240
  sx: {
238
- color: g,
241
+ color: v,
239
242
  fontSize: "1.2rem",
240
243
  my: 0.5
241
244
  },
@@ -247,46 +250,50 @@ function _e({
247
250
  /* @__PURE__ */ o(W, { value: e.key, children: e.label }, e.key)
248
251
  ), l;
249
252
  }),
250
- [R, N]
251
- ), U = /* @__PURE__ */ s((e, l, n) => {
252
- const P = G(c, e, "common.white") || "#FFFFFF", k = G(c, e, "common.black") || "#111827", a = ye(n, {
253
- whiteTextColor: P,
254
- blackTextColor: k
253
+ [G, N]
254
+ );
255
+ ge(() => {
256
+ j.current && (j.current.scrollTop = 0);
257
+ }, [r]);
258
+ const _ = /* @__PURE__ */ s((e, l, n) => {
259
+ const k = R(c, e, "common.white") || "#FFFFFF", w = R(c, e, "common.black") || "#111827", a = we(n, {
260
+ whiteTextColor: k,
261
+ blackTextColor: w
255
262
  });
256
263
  return a ? [
257
264
  l.lightPath ? { path: l.lightPath, value: a.light } : null,
258
265
  l.darkPath ? { path: l.darkPath, value: a.dark } : null,
259
266
  l.contrastTextPath ? { path: l.contrastTextPath, value: a.contrastText } : null
260
- ].filter((K) => !!K) : [];
261
- }, "getAutoDerivedUpdates"), _ = /* @__PURE__ */ s((e) => {
267
+ ].filter((L) => !!L) : [];
268
+ }, "getAutoDerivedUpdates"), Y = /* @__PURE__ */ s((e) => {
262
269
  const l = e.fieldClusters.flatMap(
263
- (n) => n.fields.map((P) => P.path)
270
+ (n) => n.fields.map((k) => k.path)
264
271
  );
265
- return /* @__PURE__ */ u("div", { className: "flex flex-col gap-12", children: [
266
- e.label ? /* @__PURE__ */ u("div", { className: "flex items-center justify-between gap-8", children: [
272
+ return /* @__PURE__ */ h("div", { className: "flex flex-col gap-12", children: [
273
+ e.label ? /* @__PURE__ */ h("div", { className: "flex items-center justify-between gap-8", children: [
267
274
  /* @__PURE__ */ o(x, { variant: "subtitle1", fontWeight: 700, children: e.label }),
268
275
  /* @__PURE__ */ o(
269
- de,
276
+ ce,
270
277
  {
271
278
  size: "small",
272
279
  "aria-label": `${e.label} reset`,
273
280
  onClick: /* @__PURE__ */ s(() => {
274
- M(l);
281
+ S(l);
275
282
  }, "onClick"),
276
283
  sx: {
277
- border: `1px solid ${ee}`,
284
+ border: `1px solid ${re}`,
278
285
  borderRadius: 1,
279
- color: g,
286
+ color: v,
280
287
  p: 0.5
281
288
  },
282
- children: /* @__PURE__ */ o(ue, { sx: { fontSize: 18 } })
289
+ children: /* @__PURE__ */ o(me, { sx: { fontSize: 18 } })
283
290
  }
284
291
  )
285
292
  ] }) : null,
286
293
  /* @__PURE__ */ o("div", { className: "grid gap-12", children: e.fieldClusters.map((n) => {
287
294
  if (!n.label)
288
295
  return n.fields.map((C) => /* @__PURE__ */ o(
289
- q,
296
+ J,
290
297
  {
291
298
  definition: C,
292
299
  resetVersion: f,
@@ -297,72 +304,74 @@ function _e({
297
304
  },
298
305
  C.path
299
306
  ));
300
- const P = `${r}:${e.key}:${n.key}`, k = !!te[P], a = n.autoDerivedFieldPaths, K = !!(a && b);
301
- return /* @__PURE__ */ u(
307
+ const k = `${r}:${e.key}:${n.key}`, w = !!le[k], a = n.autoDerivedFieldPaths, L = !!(a && b);
308
+ return /* @__PURE__ */ h(
302
309
  A,
303
310
  {
304
311
  variant: "outlined",
305
312
  sx: {
306
- backgroundColor: Fe,
307
- borderColor: Be,
313
+ backgroundColor: Ee,
314
+ borderColor: Se,
308
315
  display: "flex",
309
316
  flexDirection: "column",
310
317
  gap: 1.5,
311
318
  p: 1.5
312
319
  },
313
320
  children: [
314
- /* @__PURE__ */ u("div", { className: "flex items-start justify-between gap-12", children: [
321
+ /* @__PURE__ */ h("div", { className: "flex items-start justify-between gap-12", children: [
315
322
  /* @__PURE__ */ o(x, { variant: "body2", fontWeight: 700, children: n.label }),
316
- K ? /* @__PURE__ */ o(
317
- ce,
323
+ L ? /* @__PURE__ */ o(
324
+ ue,
318
325
  {
319
326
  className: "m-0",
320
327
  control: /* @__PURE__ */ o(
321
328
  he,
322
329
  {
323
330
  size: "small",
324
- checked: k,
331
+ checked: w,
325
332
  onChange: /* @__PURE__ */ s((C) => {
326
- const E = C.target.checked;
327
- le((w) => ({
328
- ...w,
329
- [P]: E
330
- })), !E && (!b || !a || h(
331
- U(
333
+ const T = C.target.checked;
334
+ T && !window.confirm(
335
+ ze
336
+ ) || (ne((P) => ({
337
+ ...P,
338
+ [k]: T
339
+ })), !T && (!b || !a || u(
340
+ _(
332
341
  b,
333
342
  a,
334
- G(
343
+ R(
335
344
  c,
336
345
  r,
337
346
  a.mainPath
338
347
  )
339
348
  )
340
- ));
349
+ )));
341
350
  }, "onChange")
342
351
  }
343
352
  ),
344
- label: /* @__PURE__ */ o(x, { variant: "caption", color: "text.secondary", children: "Edit derived colors" })
353
+ label: /* @__PURE__ */ o(x, { variant: "caption", color: "text.secondary", children: "연동 색상 편집" })
345
354
  }
346
355
  ) : null
347
356
  ] }),
348
357
  /* @__PURE__ */ o("div", { className: "grid gap-12", children: n.fields.map((C) => {
349
- const E = a && b ? !k && C.path !== a.mainPath : !1;
358
+ const T = a && b ? !w && C.path !== a.mainPath : !1;
350
359
  return /* @__PURE__ */ o(
351
- q,
360
+ J,
352
361
  {
353
- disabled: E,
362
+ disabled: T,
354
363
  definition: C,
355
364
  resetVersion: f,
356
365
  sectionKey: r,
357
366
  settings: c,
358
- onChange: /* @__PURE__ */ s((w, $) => {
359
- if (!a || !b || k || w !== a.mainPath) {
360
- t(w, $);
367
+ onChange: /* @__PURE__ */ s((P, $) => {
368
+ if (!a || !b || w || P !== a.mainPath) {
369
+ t(P, $);
361
370
  return;
362
371
  }
363
- h([
364
- { path: w, value: $ },
365
- ...U(
372
+ u([
373
+ { path: P, value: $ },
374
+ ..._(
366
375
  b,
367
376
  a,
368
377
  $
@@ -381,29 +390,29 @@ function _e({
381
390
  }) })
382
391
  ] }, e.key);
383
392
  }, "renderFieldGroup");
384
- return /* @__PURE__ */ o(me, { theme: Ie, children: /* @__PURE__ */ u(se, { sx: Ee, className: "flex h-full min-h-0 flex-col gap-16", children: [
385
- /* @__PURE__ */ o("div", { className: "grid grid-cols-2 gap-12", children: X.map((e) => {
393
+ return /* @__PURE__ */ o(fe, { theme: je, children: /* @__PURE__ */ h(de, { sx: Ke, className: "flex h-full min-h-0 flex-col gap-16", children: [
394
+ /* @__PURE__ */ o("div", { className: "grid grid-cols-2 gap-12", children: ee.map((e) => {
386
395
  const l = e.key === r;
387
396
  return /* @__PURE__ */ o(
388
- ae,
397
+ se,
389
398
  {
390
399
  onClick: /* @__PURE__ */ s(() => F(e.key), "onClick"),
391
400
  className: "w-full rounded-lg text-left",
392
401
  sx: {
393
402
  alignItems: "flex-start",
394
- backgroundColor: l ? v.active.backgroundColor : v.inactive.backgroundColor,
395
- border: `1px solid ${l ? v.active.borderColor : v.inactive.borderColor}`,
396
- color: l ? v.active.textColor : v.inactive.textColor,
403
+ backgroundColor: l ? g.active.backgroundColor : g.inactive.backgroundColor,
404
+ border: `1px solid ${l ? g.active.borderColor : g.inactive.borderColor}`,
405
+ color: l ? g.active.textColor : g.inactive.textColor,
397
406
  p: 2
398
407
  },
399
- children: /* @__PURE__ */ u("div", { className: "flex w-full flex-col gap-4", children: [
408
+ children: /* @__PURE__ */ h("div", { className: "flex w-full flex-col gap-4", children: [
400
409
  /* @__PURE__ */ o(x, { variant: "subtitle1", fontWeight: 600, children: e.label }),
401
410
  e.description ? /* @__PURE__ */ o(
402
411
  x,
403
412
  {
404
413
  variant: "body2",
405
414
  sx: {
406
- color: l ? v.active.descriptionColor : v.inactive.descriptionColor
415
+ color: l ? g.active.descriptionColor : g.inactive.descriptionColor
407
416
  },
408
417
  children: e.description
409
418
  }
@@ -413,27 +422,27 @@ function _e({
413
422
  e.key
414
423
  );
415
424
  }) }),
416
- /* @__PURE__ */ u(
425
+ /* @__PURE__ */ h(
417
426
  A,
418
427
  {
419
428
  className: "flex min-h-0 flex-1 flex-col overflow-hidden rounded-lg",
420
429
  sx: {
421
430
  backgroundColor: D,
422
- border: `1px solid ${B}`,
431
+ border: `1px solid ${M}`,
423
432
  boxShadow: "none"
424
433
  },
425
434
  children: [
426
- /* @__PURE__ */ o("div", { className: "flex items-center justify-between px-20 py-16", children: /* @__PURE__ */ u("div", { className: "flex min-w-0 flex-1 flex-col gap-14", children: [
427
- /* @__PURE__ */ o(x, { variant: "h6", sx: { color: y }, children: j == null ? void 0 : j.label }),
428
- S ? /* @__PURE__ */ u("div", { className: "grid gap-12 md:grid-cols-2", children: [
429
- /* @__PURE__ */ u(
430
- Y,
435
+ /* @__PURE__ */ o("div", { className: "flex items-center justify-between px-20 py-16", children: /* @__PURE__ */ h("div", { className: "flex min-w-0 flex-1 flex-col gap-14", children: [
436
+ /* @__PURE__ */ o(x, { variant: "h6", sx: { color: y }, children: K == null ? void 0 : K.label }),
437
+ E ? /* @__PURE__ */ h("div", { className: "grid gap-12 md:grid-cols-2", children: [
438
+ /* @__PURE__ */ h(
439
+ Z,
431
440
  {
432
441
  select: !0,
433
442
  label: "Mode",
434
443
  value: p,
435
444
  onChange: /* @__PURE__ */ s((e) => {
436
- oe(e.target.value);
445
+ te(e.target.value);
437
446
  }, "onChange"),
438
447
  children: [
439
448
  /* @__PURE__ */ o(W, { value: "light", children: "light" }),
@@ -441,58 +450,65 @@ function _e({
441
450
  ]
442
451
  }
443
452
  ),
444
- /* @__PURE__ */ u(
445
- Y,
453
+ /* @__PURE__ */ h(
454
+ Z,
446
455
  {
447
456
  select: !0,
448
457
  label: "Preset",
449
458
  value: m,
450
459
  onChange: /* @__PURE__ */ s((e) => {
451
- re(e.target.value);
460
+ oe(e.target.value);
452
461
  }, "onChange"),
453
462
  children: [
454
- m === J ? /* @__PURE__ */ o(W, { value: J, children: "custom" }) : null,
455
- ne
463
+ m === O ? /* @__PURE__ */ o(W, { value: O, children: "custom" }) : null,
464
+ ie
456
465
  ]
457
466
  }
458
467
  )
459
468
  ] }) : null
460
469
  ] }) }),
461
470
  /* @__PURE__ */ o(
462
- Z,
471
+ q,
463
472
  {
464
473
  sx: {
465
- borderColor: B
474
+ borderColor: M
466
475
  }
467
476
  }
468
477
  ),
469
- /* @__PURE__ */ o("div", { className: "flex min-h-0 flex-1 flex-col gap-20 overflow-y-auto px-20 py-20", children: L.map((e) => r === "table" && L.length > 1 ? /* @__PURE__ */ u(
470
- A,
478
+ /* @__PURE__ */ o(
479
+ "div",
471
480
  {
472
- variant: "outlined",
473
- sx: {
474
- backgroundColor: Ne,
475
- borderColor: B,
476
- boxShadow: "none",
477
- display: "flex",
478
- flexDirection: "column",
479
- gap: 2,
480
- p: 2
481
- },
482
- children: [
483
- e.label ? /* @__PURE__ */ o(x, { variant: "subtitle1", fontWeight: 700, children: e.label }) : null,
484
- /* @__PURE__ */ o("div", { className: "grid gap-20", children: e.fieldGroups.map(_) })
485
- ]
486
- },
487
- e.key
488
- ) : e.fieldGroups.map(_)) })
481
+ ref: j,
482
+ className: "flex min-h-0 flex-1 flex-col gap-20 overflow-y-auto px-20 py-20",
483
+ children: U.map((e) => r === "table" && U.length > 1 ? /* @__PURE__ */ h(
484
+ A,
485
+ {
486
+ variant: "outlined",
487
+ sx: {
488
+ backgroundColor: We,
489
+ borderColor: M,
490
+ boxShadow: "none",
491
+ display: "flex",
492
+ flexDirection: "column",
493
+ gap: 2,
494
+ p: 2
495
+ },
496
+ children: [
497
+ e.label ? /* @__PURE__ */ o(x, { variant: "subtitle1", fontWeight: 700, children: e.label }) : null,
498
+ /* @__PURE__ */ o("div", { className: "grid gap-20", children: e.fieldGroups.map(Y) })
499
+ ]
500
+ },
501
+ e.key
502
+ ) : e.fieldGroups.map(Y))
503
+ }
504
+ )
489
505
  ]
490
506
  }
491
507
  )
492
508
  ] }) });
493
509
  }
494
- s(_e, "ThemePreviewControls");
510
+ s(Je, "ThemePreviewControls");
495
511
  export {
496
- _e as ThemePreviewControls
512
+ Je as ThemePreviewControls
497
513
  };
498
514
  //# sourceMappingURL=ThemePreviewControls.js.map