@lucian-seo/lucian-ui 0.1.2 → 0.1.4

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 (37) hide show
  1. package/dist/lib/Input-DzJm1Kv4.js +93 -0
  2. package/dist/lib/Input-DzJm1Kv4.js.map +1 -0
  3. package/dist/lib/{Switch-CMllJkGp.js → Switch-DyKAqvde.js} +173 -150
  4. package/dist/lib/Switch-DyKAqvde.js.map +1 -0
  5. package/dist/lib/{TagInput-BxbmmLeL.js → TagInput-CeA0n7ax.js} +2 -2
  6. package/dist/lib/{TagInput-BxbmmLeL.js.map → TagInput-CeA0n7ax.js.map} +1 -1
  7. package/dist/lib/{ToggleButton-DVmHmemS.js → ToggleButton-r73bokux.js} +4 -4
  8. package/dist/lib/ToggleButton-r73bokux.js.map +1 -0
  9. package/dist/lib/{Toolbar-C0Dn66Ry.js → Toolbar-DpCq_HXG.js} +440 -318
  10. package/dist/lib/Toolbar-DpCq_HXG.js.map +1 -0
  11. package/dist/lib/{Tooltip-BJSUlXS2.js → Tooltip-BW1-aVDg.js} +2 -2
  12. package/dist/lib/{Tooltip-BJSUlXS2.js.map → Tooltip-BW1-aVDg.js.map} +1 -1
  13. package/dist/lib/{VoiceControlBar-CpEz6uxS.js → VoiceControlBar-CZL-k7ym.js} +755 -720
  14. package/dist/lib/VoiceControlBar-CZL-k7ym.js.map +1 -0
  15. package/dist/lib/{Waveform-C6OQRKbh.js → Waveform-EahaE6uD.js} +2 -2
  16. package/dist/lib/{Waveform-C6OQRKbh.js.map → Waveform-EahaE6uD.js.map} +1 -1
  17. package/dist/lib/components/common/index.js +4 -4
  18. package/dist/lib/components/composed/Combobox/Combobox.d.ts +10 -8
  19. package/dist/lib/components/composed/DatePicker/dates.d.ts +2 -0
  20. package/dist/lib/components/composed/Pagination/Pagination.d.ts +3 -1
  21. package/dist/lib/components/composed/Tabs/Tabs.d.ts +3 -2
  22. package/dist/lib/components/composed/Tabs/index.d.ts +1 -1
  23. package/dist/lib/components/composed/index.js +1 -1
  24. package/dist/lib/components/derived/index.js +2 -2
  25. package/dist/lib/components/extended/DataGrid/DataGrid.d.ts +11 -1
  26. package/dist/lib/components/extended/DataGrid/index.d.ts +1 -1
  27. package/dist/lib/components/extended/index.js +1 -1
  28. package/dist/lib/index.js +8 -8
  29. package/dist/lib/styles.css +1 -1
  30. package/dist/lib/tokens.css +32 -0
  31. package/package.json +1 -1
  32. package/dist/lib/Input-Bv7L1_wj.js +0 -90
  33. package/dist/lib/Input-Bv7L1_wj.js.map +0 -1
  34. package/dist/lib/Switch-CMllJkGp.js.map +0 -1
  35. package/dist/lib/ToggleButton-DVmHmemS.js.map +0 -1
  36. package/dist/lib/Toolbar-C0Dn66Ry.js.map +0 -1
  37. package/dist/lib/VoiceControlBar-CpEz6uxS.js.map +0 -1
@@ -1,11 +1,11 @@
1
1
  import { a as e, n as t, o as n, s as r, t as i } from "./VisuallyHidden-DcE0EFpo.js";
2
- import { r as a } from "./Tooltip-BJSUlXS2.js";
2
+ import { r as a } from "./Tooltip-BW1-aVDg.js";
3
3
  import { Fragment as o, jsx as s, jsxs as c } from "react/jsx-runtime";
4
- import { Fragment as l, forwardRef as u, useEffect as d, useId as f, useRef as p, useState as m } from "react";
5
- import { ArrowUpRight as h, Check as g, ChevronDown as _, Paperclip as v, X as y } from "lucide-react";
6
- import * as b from "@radix-ui/react-popover";
4
+ import { Fragment as l, forwardRef as u, useEffect as d, useId as f, useLayoutEffect as p, useRef as m, useState as h } from "react";
5
+ import { ArrowUpRight as g, Check as _, ChevronDown as v, Paperclip as y, X as b } from "lucide-react";
6
+ import * as x from "@radix-ui/react-popover";
7
7
  //#region src/components/common/AspectRatio/AspectRatio.tsx
8
- function x({ children: e, ratio: t = "video", className: n, ...r }) {
8
+ function S({ children: e, ratio: t = "video", className: n, ...r }) {
9
9
  return /* @__PURE__ */ s("div", {
10
10
  "data-ratio": t,
11
11
  ...r,
@@ -15,7 +15,7 @@ function x({ children: e, ratio: t = "video", className: n, ...r }) {
15
15
  }
16
16
  //#endregion
17
17
  //#region src/components/common/Blockquote/Blockquote.tsx
18
- function S({ children: e, cite: t, sourceUrl: n, icon: i, className: a, ...l }) {
18
+ function C({ children: e, cite: t, sourceUrl: n, icon: i, className: a, ...l }) {
19
19
  let u = /* @__PURE__ */ c(o, { children: [i ? /* @__PURE__ */ s("span", {
20
20
  className: "blockquote__icon",
21
21
  "aria-hidden": "true",
@@ -49,24 +49,24 @@ function S({ children: e, cite: t, sourceUrl: n, icon: i, className: a, ...l })
49
49
  }
50
50
  //#endregion
51
51
  //#region src/components/common/CalibratedPulse/CalibratedPulse.tsx
52
- var C = 6, w = 2400, T = 220, E = 3, D = (e) => `${(e / 1e3).toFixed(2)}초에 한 건`;
53
- function O({ label: e, events: t, remaining: n, size: r = "md", className: i, ...a }) {
54
- let o = t?.length ?? 0, l = t?.[o - 1], u = t?.slice(Math.max(0, o - C)) ?? [], f;
52
+ var w = 6, T = 2400, E = 220, D = 3, O = (e) => `${(e / 1e3).toFixed(2)}초에 한 건`;
53
+ function k({ label: e, events: t, remaining: n, size: r = "md", className: i, ...a }) {
54
+ let o = t?.length ?? 0, l = t?.[o - 1], u = t?.slice(Math.max(0, o - w)) ?? [], f;
55
55
  if (u.length >= 2) {
56
56
  let e = (u[u.length - 1] - u[0]) / (u.length - 1);
57
57
  e > 0 && (f = e);
58
58
  }
59
- let [p, h] = m(!1);
59
+ let [p, m] = h(!1);
60
60
  d(() => {
61
- if (h(!1), f === void 0) return;
62
- let e = window.setTimeout(() => h(!0), Math.min(w, Math.max(T, f)) * E);
61
+ if (m(!1), f === void 0) return;
62
+ let e = window.setTimeout(() => m(!0), Math.min(T, Math.max(E, f)) * D);
63
63
  return () => window.clearTimeout(e);
64
64
  }, [
65
65
  o,
66
66
  l,
67
67
  f
68
68
  ]);
69
- let g = f !== void 0 && !p, _ = g ? Math.min(w, Math.max(T, f)) : w, v = p ? "들어오던 것이 멈췄습니다" : f === void 0 ? o === 0 ? "아직 들어온 것이 없습니다" : "속도는 두 건부터 나옵니다" : void 0;
69
+ let g = f !== void 0 && !p, _ = g ? Math.min(T, Math.max(E, f)) : T, v = p ? "들어오던 것이 멈췄습니다" : f === void 0 ? o === 0 ? "아직 들어온 것이 없습니다" : "속도는 두 건부터 나옵니다" : void 0;
70
70
  return /* @__PURE__ */ c("div", {
71
71
  ...a,
72
72
  className: `calibrated-pulse ${i ?? ""}`.trim(),
@@ -106,7 +106,7 @@ function O({ label: e, events: t, remaining: n, size: r = "md", className: i, ..
106
106
  children: [
107
107
  g ? /* @__PURE__ */ s("span", {
108
108
  "data-part": "period",
109
- children: D(f)
109
+ children: O(f)
110
110
  }) : null,
111
111
  g && n !== void 0 ? /* @__PURE__ */ s("span", {
112
112
  "aria-hidden": "true",
@@ -123,7 +123,7 @@ function O({ label: e, events: t, remaining: n, size: r = "md", className: i, ..
123
123
  }
124
124
  //#endregion
125
125
  //#region src/components/common/Center/Center.tsx
126
- function k({ children: e, as: t = "div", inline: n, className: r, ...i }) {
126
+ function A({ children: e, as: t = "div", inline: n, className: r, ...i }) {
127
127
  return /* @__PURE__ */ s(t, {
128
128
  "data-inline": n ? "" : void 0,
129
129
  ...i,
@@ -133,8 +133,8 @@ function k({ children: e, as: t = "div", inline: n, className: r, ...i }) {
133
133
  }
134
134
  //#endregion
135
135
  //#region src/components/common/Code/Code.tsx
136
- function A({ children: e, block: t = !1, as: n, className: r, ...i }) {
137
- let a = n ?? (t ? "pre" : "code"), o = p(null), [c, l] = m(!1);
136
+ function j({ children: e, block: t = !1, as: n, className: r, ...i }) {
137
+ let a = n ?? (t ? "pre" : "code"), o = m(null), [c, l] = h(!1);
138
138
  return d(() => {
139
139
  let e = o.current;
140
140
  if (!t || !e) return;
@@ -167,7 +167,7 @@ function A({ children: e, block: t = !1, as: n, className: r, ...i }) {
167
167
  }
168
168
  //#endregion
169
169
  //#region src/components/common/Collapse/Collapse.tsx
170
- function j({ children: e, open: t, axis: n = "block", id: r, className: i, ...a }) {
170
+ function M({ children: e, open: t, axis: n = "block", id: r, className: i, ...a }) {
171
171
  return /* @__PURE__ */ s("div", {
172
172
  id: r,
173
173
  "data-axis": n,
@@ -182,7 +182,7 @@ function j({ children: e, open: t, axis: n = "block", id: r, className: i, ...a
182
182
  }
183
183
  //#endregion
184
184
  //#region src/components/common/Container/Container.tsx
185
- function M({ children: e, as: t = "div", width: n = "xl", className: r, ...i }) {
185
+ function N({ children: e, as: t = "div", width: n = "xl", className: r, ...i }) {
186
186
  return /* @__PURE__ */ s(t, {
187
187
  "data-width": n,
188
188
  ...i,
@@ -192,7 +192,7 @@ function M({ children: e, as: t = "div", width: n = "xl", className: r, ...i })
192
192
  }
193
193
  //#endregion
194
194
  //#region src/components/common/Divider/Divider.tsx
195
- function N(e) {
195
+ function P(e) {
196
196
  let { orientation: t = "horizontal", tone: n = "default", spacing: r = "md", children: i, className: a, ...o } = e, c = i != null && i !== !1;
197
197
  return /* @__PURE__ */ s("div", {
198
198
  ...o,
@@ -211,42 +211,42 @@ function N(e) {
211
211
  }
212
212
  //#endregion
213
213
  //#region src/components/common/FileInput/FileInput.tsx
214
- function P(e, t) {
214
+ function F(e, t) {
215
215
  let n = (e ?? "").split(",").map((e) => e.trim().toLowerCase()).filter(Boolean);
216
216
  if (n.length === 0) return !0;
217
217
  let r = t.name.toLowerCase(), i = t.type.toLowerCase();
218
218
  return n.some((e) => e.startsWith(".") ? r.endsWith(e) : e.endsWith("/*") ? i.startsWith(e.slice(0, -1)) : i === e);
219
219
  }
220
- var F = [
220
+ var I = [
221
221
  "B",
222
222
  "KB",
223
223
  "MB",
224
224
  "GB"
225
225
  ];
226
- function I(e) {
226
+ function L(e) {
227
227
  let t = e, n = 0;
228
- for (; t >= 1024 && n < F.length - 1;) t /= 1024, n += 1;
229
- return `${n === 0 ? t : Number(t.toFixed(1))}${F[n]}`;
228
+ for (; t >= 1024 && n < I.length - 1;) t /= 1024, n += 1;
229
+ return `${n === 0 ? t : Number(t.toFixed(1))}${I[n]}`;
230
230
  }
231
- function L({ value: e, onValueChange: n, label: i, accept: a, multiple: o, maxSize: l, size: u = "md", disabled: h, invalid: g, id: _, name: b, placeholder: x = "선택된 파일 없음", "aria-describedby": S, "aria-labelledby": C, required: w, className: T, ...E }) {
232
- let D = f(), O = _ ?? `${D}-input`, k = p(null), [A, j] = m([]);
233
- d(() => {
231
+ function R({ value: e, onValueChange: n, label: i, accept: a, multiple: o, maxSize: l, size: u = "md", disabled: d, invalid: g, id: _, name: v, placeholder: x = "선택된 파일 없음", "aria-describedby": S, "aria-labelledby": C, required: w, className: T, ...E }) {
232
+ let D = f(), O = _ ?? `${D}-input`, k = m(null), [A, j] = h([]);
233
+ p(() => {
234
234
  let t = k.current;
235
235
  if (!t || typeof DataTransfer > "u") return;
236
236
  let n = new DataTransfer();
237
237
  for (let t of e) n.items.add(t);
238
238
  t.files = n.files;
239
- }, [e]);
239
+ });
240
240
  let M = (e) => {
241
- let t = Array.from(e.target.files ?? []), r = [], i = t.filter((e) => P(a, e) ? l !== void 0 && e.size > l ? (r.push(`${e.name} — ${I(l)}를 넘습니다. 이 파일은 ${I(e.size)}입니다`), !1) : !0 : (r.push(`${e.name} — 받지 않는 형식입니다. ${a}만 받습니다`), !1));
241
+ let t = Array.from(e.target.files ?? []), r = [], i = t.filter((e) => F(a, e) ? l !== void 0 && e.size > l ? (r.push(`${e.name} — ${L(l)}를 넘습니다. 이 파일은 ${L(e.size)}입니다`), !1) : !0 : (r.push(`${e.name} — 받지 않는 형식입니다. ${a}만 받습니다`), !1));
242
242
  j(r), n(o ? i : i.slice(0, 1));
243
243
  }, N = (t) => {
244
244
  n(e.filter((e, n) => n !== t)), j([]), k.current?.focus();
245
- }, F = e.length === 0 ? x : e.length === 1 ? e[0].name : `${e.length}개 선택됨`;
245
+ }, P = e.length === 0 ? x : e.length === 1 ? e[0].name : `${e.length}개 선택됨`;
246
246
  return /* @__PURE__ */ c("div", {
247
247
  "data-size": u,
248
248
  "data-invalid": g ? "" : void 0,
249
- "data-disabled": h ? "" : void 0,
249
+ "data-disabled": d ? "" : void 0,
250
250
  "data-empty": e.length === 0 ? "" : void 0,
251
251
  ...E,
252
252
  className: `file-input ${T ?? ""}`.trim(),
@@ -259,12 +259,12 @@ function L({ value: e, onValueChange: n, label: i, accept: a, multiple: o, maxSi
259
259
  /* @__PURE__ */ s("input", {
260
260
  ref: k,
261
261
  id: O,
262
- name: b,
262
+ name: v,
263
263
  type: "file",
264
264
  className: "file-input__native",
265
265
  accept: a,
266
266
  multiple: o,
267
- disabled: h,
267
+ disabled: d,
268
268
  required: w,
269
269
  "aria-invalid": g || void 0,
270
270
  "aria-label": C ? void 0 : i,
@@ -278,7 +278,7 @@ function L({ value: e, onValueChange: n, label: i, accept: a, multiple: o, maxSi
278
278
  "aria-hidden": "true",
279
279
  "data-part": "button",
280
280
  children: [/* @__PURE__ */ s(r, {
281
- icon: v,
281
+ icon: y,
282
282
  size: "sm"
283
283
  }), "파일 선택"]
284
284
  }),
@@ -286,7 +286,7 @@ function L({ value: e, onValueChange: n, label: i, accept: a, multiple: o, maxSi
286
286
  className: "file-input__summary",
287
287
  "aria-hidden": "true",
288
288
  "data-part": "summary",
289
- children: F
289
+ children: P
290
290
  })
291
291
  ]
292
292
  }),
@@ -309,10 +309,10 @@ function L({ value: e, onValueChange: n, label: i, accept: a, multiple: o, maxSi
309
309
  }),
310
310
  /* @__PURE__ */ s("span", {
311
311
  className: "file-input__size",
312
- children: I(e.size)
312
+ children: L(e.size)
313
313
  }),
314
- h ? null : /* @__PURE__ */ s(t, {
315
- icon: y,
314
+ d ? null : /* @__PURE__ */ s(t, {
315
+ icon: b,
316
316
  label: `${e.name} 지우기`,
317
317
  size: "sm",
318
318
  variant: "ghost",
@@ -328,7 +328,7 @@ function L({ value: e, onValueChange: n, label: i, accept: a, multiple: o, maxSi
328
328
  }
329
329
  //#endregion
330
330
  //#region src/components/common/Flex/Flex.tsx
331
- function R({ children: e, direction: t = "row", gap: n = 4, align: r = "stretch", justify: i = "start", wrap: a = !1, as: o = "div", className: c, ...l }) {
331
+ function z({ children: e, direction: t = "row", gap: n = 4, align: r = "stretch", justify: i = "start", wrap: a = !1, as: o = "div", className: c, ...l }) {
332
332
  return /* @__PURE__ */ s(o, {
333
333
  "data-direction": t,
334
334
  "data-gap": n,
@@ -342,7 +342,7 @@ function R({ children: e, direction: t = "row", gap: n = 4, align: r = "stretch"
342
342
  }
343
343
  //#endregion
344
344
  //#region src/components/common/Glass/rim.ts
345
- function z(e, t) {
345
+ function B(e, t) {
346
346
  d(() => {
347
347
  let n = e.current;
348
348
  if (!n || !t || typeof matchMedia > "u" || !matchMedia("(hover: hover) and (pointer: fine)").matches || matchMedia("(prefers-reduced-motion: reduce)").matches) return;
@@ -362,9 +362,9 @@ function z(e, t) {
362
362
  }
363
363
  //#endregion
364
364
  //#region src/components/common/Glass/Glass.tsx
365
- var B = u(function({ children: t, radius: r = "lg", rim: i, className: a, ...o }, c) {
366
- let l = p(null), u = n(l), d = e(l, c);
367
- return z(l, !!i), /* @__PURE__ */ s("div", {
365
+ var V = u(function({ children: t, radius: r = "lg", rim: i, className: a, ...o }, c) {
366
+ let l = m(null), u = n(l), d = e(l, c);
367
+ return B(l, !!i), /* @__PURE__ */ s("div", {
368
368
  ref: d,
369
369
  "data-radius": r,
370
370
  "data-rim": i ? "" : void 0,
@@ -376,7 +376,7 @@ var B = u(function({ children: t, radius: r = "lg", rim: i, className: a, ...o }
376
376
  });
377
377
  //#endregion
378
378
  //#region src/components/common/Grid/Grid.tsx
379
- function V({ children: e, as: t = "div", columns: n = 12, className: r, ...i }) {
379
+ function H({ children: e, as: t = "div", columns: n = 12, className: r, ...i }) {
380
380
  return /* @__PURE__ */ s(t, {
381
381
  "data-columns": n,
382
382
  ...i,
@@ -386,7 +386,7 @@ function V({ children: e, as: t = "div", columns: n = 12, className: r, ...i })
386
386
  }
387
387
  //#endregion
388
388
  //#region src/components/common/Grid/GridItem.tsx
389
- function H({ children: e, as: t = "div", span: n, spanMd: r, spanLg: i, className: a, ...o }) {
389
+ function U({ children: e, as: t = "div", span: n, spanMd: r, spanLg: i, className: a, ...o }) {
390
390
  return /* @__PURE__ */ s(t, {
391
391
  "data-span": n,
392
392
  "data-span-md": r,
@@ -398,7 +398,7 @@ function H({ children: e, as: t = "div", span: n, spanMd: r, spanLg: i, classNam
398
398
  }
399
399
  //#endregion
400
400
  //#region src/components/common/Group/Group.tsx
401
- function U({ children: e, gap: t = 3, align: n = "center", justify: r = "start", wrap: i = !0, grow: a, as: o = "div", className: c, ...l }) {
401
+ function W({ children: e, gap: t = 3, align: n = "center", justify: r = "start", wrap: i = !0, grow: a, as: o = "div", className: c, ...l }) {
402
402
  return /* @__PURE__ */ s(o, {
403
403
  "data-gap": t,
404
404
  "data-align": n,
@@ -412,7 +412,7 @@ function U({ children: e, gap: t = 3, align: n = "center", justify: r = "start",
412
412
  }
413
413
  //#endregion
414
414
  //#region src/components/common/Mark/Mark.tsx
415
- function W({ children: e, tone: t = "warning", as: n = "mark", className: r, ...i }) {
415
+ function G({ children: e, tone: t = "warning", as: n = "mark", className: r, ...i }) {
416
416
  return /* @__PURE__ */ s(n, {
417
417
  "data-tone": t,
418
418
  ...i,
@@ -422,9 +422,9 @@ function W({ children: e, tone: t = "warning", as: n = "mark", className: r, ...
422
422
  }
423
423
  //#endregion
424
424
  //#region src/components/common/Highlight/Highlight.tsx
425
- var G = (e) => e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
426
- function K(e, t) {
427
- let n = (Array.isArray(t) ? t : [t]).filter((e) => e.trim().length > 0).sort((e, t) => t.length - e.length).map(G);
425
+ var K = (e) => e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
426
+ function q(e, t) {
427
+ let n = (Array.isArray(t) ? t : [t]).filter((e) => e.trim().length > 0).sort((e, t) => t.length - e.length).map(K);
428
428
  if (n.length === 0) return [{
429
429
  text: e,
430
430
  matched: !1
@@ -435,12 +435,12 @@ function K(e, t) {
435
435
  matched: t % 2 == 1
436
436
  })).filter((e) => e.text.length > 0);
437
437
  }
438
- function q({ children: e, query: t, tone: n = "warning", className: r, ...i }) {
439
- let a = K(e, t);
438
+ function J({ children: e, query: t, tone: n = "warning", className: r, ...i }) {
439
+ let a = q(e, t);
440
440
  return /* @__PURE__ */ s("span", {
441
441
  ...i,
442
442
  className: `highlight ${r ?? ""}`.trim(),
443
- children: a.map((e, t) => e.matched ? /* @__PURE__ */ s(W, {
443
+ children: a.map((e, t) => e.matched ? /* @__PURE__ */ s(G, {
444
444
  tone: n,
445
445
  children: e.text
446
446
  }, t) : /* @__PURE__ */ s(l, { children: e.text }, t))
@@ -448,7 +448,7 @@ function q({ children: e, query: t, tone: n = "warning", className: r, ...i }) {
448
448
  }
449
449
  //#endregion
450
450
  //#region src/components/common/Indicator/Indicator.tsx
451
- function J({ children: e, label: t, count: n, max: r = 99, position: a = "top-end", target: l = "square", tone: u = "accent", dot: d, hidden: f, className: p, ...m }) {
451
+ function Y({ children: e, label: t, count: n, max: r = 99, position: a = "top-end", target: l = "square", tone: u = "accent", dot: d, hidden: f, className: p, ...m }) {
452
452
  let h = d || n === void 0 ? "dot" : "count", g = n === void 0 ? null : n > r ? `${r}+` : String(n);
453
453
  return /* @__PURE__ */ c("span", {
454
454
  "data-position": a,
@@ -467,7 +467,7 @@ function J({ children: e, label: t, count: n, max: r = 99, position: a = "top-en
467
467
  }
468
468
  //#endregion
469
469
  //#region src/components/common/Kbd/Kbd.tsx
470
- function Y({ children: e, size: t = "md", as: n = "kbd", className: r, ...i }) {
470
+ function X({ children: e, size: t = "md", as: n = "kbd", className: r, ...i }) {
471
471
  return /* @__PURE__ */ s(n, {
472
472
  "data-size": t,
473
473
  ...i,
@@ -477,7 +477,7 @@ function Y({ children: e, size: t = "md", as: n = "kbd", className: r, ...i }) {
477
477
  }
478
478
  //#endregion
479
479
  //#region src/components/common/Link/Link.tsx
480
- function X({ children: e, href: t, tone: n = "accent", underline: a = "always", external: l, className: u, ...d }) {
480
+ function Z({ children: e, href: t, tone: n = "accent", underline: a = "always", external: l, className: u, ...d }) {
481
481
  return /* @__PURE__ */ c("a", {
482
482
  ...d,
483
483
  className: `link ${u ?? ""}`.trim(),
@@ -488,7 +488,7 @@ function X({ children: e, href: t, tone: n = "accent", underline: a = "always",
488
488
  target: l ? "_blank" : void 0,
489
489
  rel: l ? "noreferrer" : void 0,
490
490
  children: [e, l ? /* @__PURE__ */ c(o, { children: [/* @__PURE__ */ s(r, {
491
- icon: h,
491
+ icon: g,
492
492
  size: "xs",
493
493
  className: "link__mark"
494
494
  }), /* @__PURE__ */ s(i, { children: "(새 창)" })] }) : null]
@@ -496,135 +496,157 @@ function X({ children: e, href: t, tone: n = "accent", underline: a = "always",
496
496
  }
497
497
  //#endregion
498
498
  //#region src/components/common/MultiSelect/MultiSelect.tsx
499
- var Z = (e, t) => e.label.toLowerCase().includes(t.toLowerCase()) || (e.description ?? "").toLowerCase().includes(t.toLowerCase());
500
- function ee({ options: e, value: t, onValueChange: n, label: o, placeholder: l, max: u, searchable: d = !0, size: h = "md", disabled: v, invalid: x, id: S, name: C, emptyMessage: w = "맞는 것이 없습니다", "aria-describedby": T, "aria-labelledby": E, required: D, className: O, ...k }) {
501
- let A = f(), j = S ?? `${A}-input`, M = `${A}-list`, N = p(null), [P, F] = m(!1), [I, L] = m(""), R = new Set(t), z = u !== void 0 && t.length >= u, B = e.filter((e) => P && I ? Z(e, I) : !0), V = (e) => !!e.disabled || z && !R.has(e.value), H = (e) => `${A}-option-${e.value}`, U = a({
502
- rows: B,
503
- locked: V,
504
- id: H
505
- }), { active: W, setActive: G } = U, K = t.map((t) => e.find((e) => e.value === t) ?? {
499
+ var ee = (e, t) => e.label.toLowerCase().includes(t.toLowerCase()) || (e.description ?? "").toLowerCase().includes(t.toLowerCase());
500
+ function te({ options: e, value: t, onValueChange: n, label: o, placeholder: l, max: u, searchable: p = !0, size: g = "md", disabled: y, invalid: S, id: C, name: w, emptyMessage: T = "맞는 것이 없습니다", "aria-describedby": E, "aria-labelledby": D, required: O, className: k, ...A }) {
501
+ let j = f(), M = C ?? `${j}-input`, N = `${j}-list`, P = m(null), [F, I] = h(!1), [L, R] = h("");
502
+ d(() => {
503
+ P.current?.setCustomValidity(O && t.length === 0 ? `${o} 항목을 선택하세요` : "");
504
+ }, [
505
+ O,
506
+ t.length,
507
+ o
508
+ ]);
509
+ let z = new Set(t), B = u !== void 0 && t.length >= u, V = e.filter((e) => F && L ? ee(e, L) : !0), H = (e) => !!e.disabled || B && !z.has(e.value), U = (e) => `${j}-option-${e.value}`, W = a({
510
+ rows: V,
511
+ locked: H,
512
+ id: U
513
+ }), { active: G, setActive: K } = W, q = t.map((t) => e.find((e) => e.value === t) ?? {
506
514
  value: t,
507
515
  label: t
508
- }), q = (e) => {
509
- if (R.has(e.value)) n(t.filter((t) => t !== e.value));
516
+ }), J = (e) => {
517
+ if (z.has(e.value)) n(t.filter((t) => t !== e.value));
510
518
  else {
511
- if (V(e)) return;
519
+ if (H(e)) return;
512
520
  n([...t, e.value]);
513
521
  }
514
- L(""), N.current?.focus();
515
- }, J = (e) => {
516
- n(t.filter((t) => t !== e)), N.current?.focus();
522
+ R(""), P.current?.focus();
517
523
  }, Y = (e) => {
518
- if (!v && !(e.nativeEvent.isComposing || e.nativeEvent.keyCode === 229)) {
519
- if (e.key === "Backspace" && I === "" && t.length > 0) {
524
+ n(t.filter((t) => t !== e)), P.current?.focus();
525
+ }, X = (e) => {
526
+ if (!y && !(e.nativeEvent.isComposing || e.nativeEvent.keyCode === 229)) {
527
+ if (e.key === "Backspace" && L === "" && t.length > 0) {
520
528
  e.preventDefault(), n(t.slice(0, -1));
521
529
  return;
522
530
  }
523
531
  if (e.key === "ArrowDown" || e.key === "ArrowUp") {
524
- if (e.preventDefault(), !P) {
525
- G(0), F(!0);
532
+ if (e.preventDefault(), !F) {
533
+ K(0), I(!0);
526
534
  return;
527
535
  }
528
- U.move(e.key === "ArrowDown" ? 1 : -1);
536
+ W.move(e.key === "ArrowDown" ? 1 : -1);
529
537
  return;
530
538
  }
531
- if (P) {
539
+ if (F) {
532
540
  if (e.key === "Enter") {
533
- let t = U.activeRow;
534
- t && (e.preventDefault(), q(t));
541
+ let t = W.activeRow;
542
+ t && (e.preventDefault(), J(t));
535
543
  return;
536
544
  }
537
- (e.key === "Home" || e.key === "End") && (e.preventDefault(), e.key === "Home" ? U.first() : U.last());
545
+ (e.key === "Home" || e.key === "End") && (e.preventDefault(), e.key === "Home" ? W.first() : W.last());
538
546
  }
539
547
  }
540
548
  };
541
- return /* @__PURE__ */ s(b.Root, {
542
- open: P && !v,
543
- onOpenChange: F,
549
+ return /* @__PURE__ */ s(x.Root, {
550
+ open: F && !y,
551
+ onOpenChange: I,
544
552
  children: /* @__PURE__ */ c("div", {
545
- "data-size": h,
546
- "data-invalid": x ? "" : void 0,
547
- "data-disabled": v ? "" : void 0,
548
- "data-full": z ? "" : void 0,
549
- ...k,
550
- className: `multi-select ${O ?? ""}`.trim(),
553
+ "data-size": g,
554
+ "data-invalid": S ? "" : void 0,
555
+ "data-disabled": y ? "" : void 0,
556
+ "data-full": B ? "" : void 0,
557
+ ...A,
558
+ className: `multi-select ${k ?? ""}`.trim(),
551
559
  children: [
552
- C ? t.map((e) => /* @__PURE__ */ s("input", {
560
+ w ? t.map((e) => /* @__PURE__ */ s("input", {
553
561
  type: "hidden",
554
- name: C,
555
- value: e
562
+ name: w,
563
+ value: e,
564
+ disabled: y
556
565
  }, e)) : null,
557
- /* @__PURE__ */ s(b.Anchor, {
566
+ O && !p ? /* @__PURE__ */ s(i, { children: /* @__PURE__ */ s("input", {
567
+ type: "text",
568
+ value: t.length > 0 ? "selected" : "",
569
+ required: !0,
570
+ disabled: y,
571
+ onChange: () => void 0,
572
+ tabIndex: -1,
573
+ "aria-hidden": "true",
574
+ onInvalid: (e) => {
575
+ e.preventDefault(), P.current?.focus();
576
+ }
577
+ }) }) : null,
578
+ /* @__PURE__ */ s(x.Anchor, {
558
579
  asChild: !0,
559
580
  children: /* @__PURE__ */ c("div", {
560
581
  className: "multi-select__field",
561
582
  onMouseDown: (e) => {
562
- e.target !== e.currentTarget || v || (e.preventDefault(), N.current?.focus(), F(!0));
583
+ e.target !== e.currentTarget || y || (e.preventDefault(), P.current?.focus(), I(!0));
563
584
  },
564
585
  "data-part": "field",
565
586
  children: [
566
- K.map((e) => /* @__PURE__ */ c("span", {
587
+ q.map((e) => /* @__PURE__ */ c("span", {
567
588
  className: "multi-select__chip",
568
589
  "data-part": `chip-${e.value}`,
569
590
  children: [/* @__PURE__ */ s("span", {
570
591
  className: "multi-select__chip-text",
571
592
  children: e.label
572
- }), v ? null : /* @__PURE__ */ s("button", {
593
+ }), y ? null : /* @__PURE__ */ s("button", {
573
594
  type: "button",
574
595
  className: "multi-select__chip-remove",
575
596
  "aria-label": `${e.label} 제거`,
576
597
  onMouseDown: (e) => e.preventDefault(),
577
- onClick: () => J(e.value),
598
+ onClick: () => Y(e.value),
578
599
  "data-part": `remove-${e.value}`,
579
600
  children: /* @__PURE__ */ s(r, {
580
- icon: y,
601
+ icon: b,
581
602
  size: "xs"
582
603
  })
583
604
  })]
584
605
  }, e.value)),
585
606
  /* @__PURE__ */ s("input", {
586
- ref: N,
587
- id: j,
607
+ ref: P,
608
+ id: M,
588
609
  className: "multi-select__input",
589
610
  type: "text",
590
611
  role: "combobox",
591
- "aria-expanded": P,
592
- "aria-controls": M,
612
+ "aria-expanded": F,
613
+ "aria-controls": N,
593
614
  "aria-autocomplete": "list",
594
- "aria-activedescendant": P ? U.activeId : void 0,
595
- "aria-label": E ? void 0 : o,
596
- "aria-labelledby": E,
597
- "aria-describedby": T,
598
- required: D,
599
- "aria-invalid": x || void 0,
615
+ "aria-activedescendant": F ? W.activeId : void 0,
616
+ "aria-label": D ? void 0 : o,
617
+ "aria-labelledby": D,
618
+ "aria-describedby": E,
619
+ required: O && t.length === 0,
620
+ "aria-required": O || void 0,
621
+ "aria-invalid": S || void 0,
600
622
  autoComplete: "off",
601
- readOnly: !d,
602
- value: I,
623
+ readOnly: !p,
624
+ value: L,
603
625
  placeholder: t.length === 0 ? l : void 0,
604
- disabled: v,
626
+ disabled: y,
605
627
  onChange: (e) => {
606
- d && (L(e.target.value), G(0), F(!0));
628
+ p && (R(e.target.value), K(0), I(!0));
607
629
  },
608
- onKeyDown: Y,
609
- onClick: () => F(!0),
630
+ onKeyDown: X,
631
+ onClick: () => I(!0),
610
632
  onFocus: (e) => {
611
- L(""), e.target.select();
633
+ R(""), e.target.select();
612
634
  },
613
- onBlur: () => F(!1),
635
+ onBlur: () => I(!1),
614
636
  "data-part": "input"
615
637
  }),
616
638
  /* @__PURE__ */ s("button", {
617
639
  type: "button",
618
640
  className: "multi-select__toggle",
619
641
  tabIndex: -1,
620
- "aria-label": P ? `${o} 목록 닫기` : `${o} 목록 열기`,
621
- disabled: v,
642
+ "aria-label": F ? `${o} 목록 닫기` : `${o} 목록 열기`,
643
+ disabled: y,
622
644
  onPointerDown: (e) => {
623
- e.preventDefault(), F((e) => !e), N.current?.focus();
645
+ e.preventDefault(), I((e) => !e), P.current?.focus();
624
646
  },
625
647
  "data-part": "toggle",
626
648
  children: /* @__PURE__ */ s(r, {
627
- icon: _,
649
+ icon: v,
628
650
  size: "sm"
629
651
  })
630
652
  })
@@ -635,9 +657,9 @@ function ee({ options: e, value: t, onValueChange: n, label: o, placeholder: l,
635
657
  role: "status",
636
658
  "aria-live": "polite",
637
659
  "data-part": "count",
638
- children: P ? z ? `최대 ${u}개까지 고를 수 있습니다` : B.length > 0 ? `${B.length}개 결과` : w : ""
660
+ children: F ? B ? `최대 ${u}개까지 고를 수 있습니다` : V.length > 0 ? `${V.length}개 결과` : T : ""
639
661
  }) }),
640
- /* @__PURE__ */ s(b.Portal, { children: /* @__PURE__ */ s(b.Content, {
662
+ /* @__PURE__ */ s(x.Portal, { children: /* @__PURE__ */ s(x.Content, {
641
663
  className: "multi-select__panel",
642
664
  side: "bottom",
643
665
  align: "start",
@@ -647,29 +669,29 @@ function ee({ options: e, value: t, onValueChange: n, label: o, placeholder: l,
647
669
  onCloseAutoFocus: (e) => e.preventDefault(),
648
670
  children: /* @__PURE__ */ c("ul", {
649
671
  className: "multi-select__list",
650
- id: M,
672
+ id: N,
651
673
  role: "listbox",
652
674
  "aria-label": o,
653
675
  "aria-multiselectable": "true",
654
- children: [B.map((e, t) => /* @__PURE__ */ c("li", {
655
- id: H(e),
676
+ children: [V.map((e, t) => /* @__PURE__ */ c("li", {
677
+ id: U(e),
656
678
  className: "multi-select__option",
657
679
  role: "option",
658
- "aria-selected": R.has(e.value),
659
- "aria-disabled": V(e) || void 0,
660
- "data-active": t === W ? "" : void 0,
680
+ "aria-selected": z.has(e.value),
681
+ "aria-disabled": H(e) || void 0,
682
+ "data-active": t === G ? "" : void 0,
661
683
  "data-part": `option-${e.value}`,
662
684
  onMouseDown: (t) => {
663
- t.preventDefault(), q(e);
685
+ t.preventDefault(), J(e);
664
686
  },
665
687
  onMouseEnter: () => {
666
- V(e) || G(t);
688
+ H(e) || K(t);
667
689
  },
668
690
  children: [/* @__PURE__ */ s("span", {
669
691
  className: "multi-select__mark",
670
692
  "aria-hidden": "true",
671
- children: R.has(e.value) ? /* @__PURE__ */ s(r, {
672
- icon: g,
693
+ children: z.has(e.value) ? /* @__PURE__ */ s(r, {
694
+ icon: _,
673
695
  size: "xs"
674
696
  }) : null
675
697
  }), /* @__PURE__ */ c("span", {
@@ -682,11 +704,11 @@ function ee({ options: e, value: t, onValueChange: n, label: o, placeholder: l,
682
704
  children: e.description
683
705
  }) : null]
684
706
  })]
685
- }, e.value)), B.length === 0 ? /* @__PURE__ */ s("li", {
707
+ }, e.value)), V.length === 0 ? /* @__PURE__ */ s("li", {
686
708
  className: "multi-select__empty",
687
709
  role: "presentation",
688
710
  "data-part": "empty",
689
- children: w
711
+ children: T
690
712
  }) : null]
691
713
  })
692
714
  }) })
@@ -699,8 +721,8 @@ function ee({ options: e, value: t, onValueChange: n, label: o, placeholder: l,
699
721
  function Q(e, t) {
700
722
  return t === "number" ? e.replace(/[^0-9]/g, "") : e.replace(/\s/g, "");
701
723
  }
702
- function te({ value: e, onValueChange: t, length: n = 6, label: r, type: i = "number", mask: a, size: o = "md", disabled: l, invalid: u, name: f, autoFocus: m, onComplete: h, id: g, className: _, required: v, "aria-labelledby": y, "aria-describedby": b, ...x }) {
703
- let S = p([]), C = p(e.length >= n);
724
+ function ne({ value: e, onValueChange: t, length: n = 6, label: r, type: i = "number", mask: a, size: o = "md", disabled: l, invalid: u, name: f, autoFocus: p, onComplete: h, id: g, className: _, required: v, "aria-labelledby": y, "aria-describedby": b, ...x }) {
725
+ let S = m([]), C = m(e.length >= n);
704
726
  d(() => {
705
727
  let t = e.length >= n;
706
728
  t && !C.current && h?.(e.slice(0, n)), C.current = t;
@@ -784,7 +806,7 @@ function te({ value: e, onValueChange: t, length: n = 6, label: r, type: i = "nu
784
806
  "aria-invalid": u || void 0,
785
807
  "aria-label": `${r} ${n + 1}번째 자리`,
786
808
  "aria-describedby": b,
787
- autoFocus: m && n === 0,
809
+ autoFocus: p && n === 0,
788
810
  onChange: E(n),
789
811
  onKeyDown: O(n),
790
812
  onPaste: k(n),
@@ -793,13 +815,14 @@ function te({ value: e, onValueChange: t, length: n = 6, label: r, type: i = "nu
793
815
  }), f ? /* @__PURE__ */ s("input", {
794
816
  type: "hidden",
795
817
  name: f,
796
- value: e
818
+ value: e,
819
+ disabled: l
797
820
  }) : null]
798
821
  });
799
822
  }
800
823
  //#endregion
801
824
  //#region src/components/common/RingProgress/RingProgress.tsx
802
- function ne({ value: e, max: t = 100, size: n = "md", tone: r = "accent", label: i, children: a, className: o, ...l }) {
825
+ function re({ value: e, max: t = 100, size: n = "md", tone: r = "accent", label: i, children: a, className: o, ...l }) {
803
826
  let u = Math.min(Math.max(e, 0), t), d = t === 0 ? 0 : u / t * 100;
804
827
  return /* @__PURE__ */ c("div", {
805
828
  ...l,
@@ -823,8 +846,8 @@ function ne({ value: e, max: t = 100, size: n = "md", tone: r = "accent", label:
823
846
  }
824
847
  //#endregion
825
848
  //#region src/components/common/ScrollArea/ScrollArea.tsx
826
- function re({ children: e, axis: t = "block", maxHeight: n = "md", label: r, className: i, ...a }) {
827
- let o = p(null), [c, l] = m(!1);
849
+ function ie({ children: e, axis: t = "block", maxHeight: n = "md", label: r, className: i, ...a }) {
850
+ let o = m(null), [c, l] = h(!1);
828
851
  d(() => {
829
852
  let e = o.current;
830
853
  if (!e) return;
@@ -862,7 +885,7 @@ function re({ children: e, axis: t = "block", maxHeight: n = "md", label: r, cla
862
885
  }
863
886
  //#endregion
864
887
  //#region src/components/common/SimpleGrid/SimpleGrid.tsx
865
- function ie({ children: e, as: t = "div", columns: n, min: r, gap: i = 4, className: a, ...o }) {
888
+ function ae({ children: e, as: t = "div", columns: n, min: r, gap: i = 4, className: a, ...o }) {
866
889
  return /* @__PURE__ */ s(t, {
867
890
  "data-columns": n,
868
891
  "data-min": r,
@@ -877,7 +900,7 @@ function ie({ children: e, as: t = "div", columns: n, min: r, gap: i = 4, classN
877
900
  function $(e, t, n) {
878
901
  return n === t ? 0 : Math.min(1, Math.max(0, (e - t) / (n - t)));
879
902
  }
880
- function ae(e, t, n, r) {
903
+ function oe(e, t, n, r) {
881
904
  if (n <= t) return t;
882
905
  let i = Math.min(n, Math.max(t, e)), a = Number.isFinite(r) && r > 0 ? r : 1, o = (i - t) / a, s = (n - t) / a;
883
906
  if (!Number.isFinite(o) || !Number.isFinite(s)) return i;
@@ -887,8 +910,8 @@ function ae(e, t, n, r) {
887
910
  }, d = Math.max(u(t), u(a));
888
911
  return d > 100 ? l : Number(l.toFixed(d));
889
912
  }
890
- function oe({ value: e, onValueChange: t, min: n = 0, max: r = 100, step: i = 1, label: a, size: o = "md", disabled: l, invalid: u, name: d, marks: f, formatValue: p, id: m, className: h, required: g, "aria-labelledby": _, "aria-describedby": v, ...y }) {
891
- let b = ae(e, n, r, i), x = p ? p(b) : String(b), S = $(b, n, r);
913
+ function se({ value: e, onValueChange: t, min: n = 0, max: r = 100, step: i = 1, label: a, size: o = "md", disabled: l, invalid: u, name: d, marks: f, formatValue: p, id: m, className: h, required: g, "aria-labelledby": _, "aria-describedby": v, ...y }) {
914
+ let b = oe(e, n, r, i), x = p ? p(b) : String(b), S = $(b, n, r);
892
915
  return /* @__PURE__ */ c("span", {
893
916
  "data-size": o,
894
917
  "data-disabled": l ? "" : void 0,
@@ -955,7 +978,7 @@ function oe({ value: e, onValueChange: t, min: n = 0, max: r = 100, step: i = 1,
955
978
  }
956
979
  //#endregion
957
980
  //#region src/components/common/Space/Space.tsx
958
- function se({ size: e = 4, axis: t = "block", as: n = "div", className: r, ...i }) {
981
+ function ce({ size: e = 4, axis: t = "block", as: n = "div", className: r, ...i }) {
959
982
  return /* @__PURE__ */ s(n, {
960
983
  "data-size": e,
961
984
  "data-axis": t,
@@ -966,7 +989,7 @@ function se({ size: e = 4, axis: t = "block", as: n = "div", className: r, ...i
966
989
  }
967
990
  //#endregion
968
991
  //#region src/components/common/Stack/Stack.tsx
969
- function ce({ children: e, gap: t = 4, align: n = "stretch", justify: r = "start", as: i = "div", className: a, ...o }) {
992
+ function le({ children: e, gap: t = 4, align: n = "stretch", justify: r = "start", as: i = "div", className: a, ...o }) {
970
993
  return /* @__PURE__ */ s(i, {
971
994
  "data-gap": t,
972
995
  "data-align": n,
@@ -978,7 +1001,7 @@ function ce({ children: e, gap: t = 4, align: n = "stretch", justify: r = "start
978
1001
  }
979
1002
  //#endregion
980
1003
  //#region src/components/common/Switch/Switch.tsx
981
- function le({ children: e, size: t = "md", disabled: n, className: r, ...i }) {
1004
+ function ue({ children: e, size: t = "md", disabled: n, className: r, ...i }) {
982
1005
  return /* @__PURE__ */ c("label", {
983
1006
  className: `switch ${r ?? ""}`.trim(),
984
1007
  "data-size": t,
@@ -1004,6 +1027,6 @@ function le({ children: e, size: t = "md", disabled: n, className: r, ...i }) {
1004
1027
  });
1005
1028
  }
1006
1029
  //#endregion
1007
- export { x as A, N as C, k as D, A as E, O, I as S, j as T, H as _, ie as a, R as b, te as c, Y as d, J as f, U as g, W as h, oe as i, S as k, ee as l, K as m, ce as n, re as o, q as p, se as r, ne as s, le as t, X as u, V as v, M as w, L as x, B as y };
1030
+ export { S as A, P as C, A as D, j as E, k as O, L as S, M as T, U as _, ae as a, z as b, ne as c, X as d, Y as f, W as g, G as h, se as i, C as k, te as l, q as m, le as n, ie as o, J as p, ce as r, re as s, ue as t, Z as u, H as v, N as w, R as x, V as y };
1008
1031
 
1009
- //# sourceMappingURL=Switch-CMllJkGp.js.map
1032
+ //# sourceMappingURL=Switch-DyKAqvde.js.map