@iamfiro/design 0.1.0 → 0.3.0

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 (160) hide show
  1. package/AGENTS.md +1 -0
  2. package/agents/INDEX.md +1 -0
  3. package/agents/brand-icon/AGENTS.md +2 -2
  4. package/agents/social-login-button/AGENTS.md +156 -0
  5. package/lib/components/Accordion/Accordion2.js +135 -0
  6. package/lib/components/ActionBar/ActionBar2.js +65 -0
  7. package/lib/components/Alert/Alert2.js +131 -0
  8. package/lib/components/AppShell/AppShell2.js +94 -0
  9. package/lib/components/AreaChart/AreaChart.js +59 -0
  10. package/lib/components/BarChart/BarChart2.js +243 -0
  11. package/lib/components/BarList/BarList2.js +172 -0
  12. package/lib/components/Breadcrumb/Breadcrumb2.js +87 -0
  13. package/lib/components/Calendar/Calendar2.js +309 -0
  14. package/lib/components/Calendar/DatePicker2.js +229 -0
  15. package/lib/components/Calendar/date.js +121 -0
  16. package/lib/components/Card/Card2.js +104 -0
  17. package/lib/components/CardFrame/CardFrame2.js +72 -0
  18. package/lib/components/Chart/ChartParts.js +150 -0
  19. package/lib/components/Chart/chart2.js +96 -0
  20. package/lib/components/Chart/useChartInteraction.js +94 -0
  21. package/lib/components/ChatBubble/ChatBubble2.js +174 -0
  22. package/lib/components/ChatBubble/formatChatTime.js +53 -0
  23. package/lib/components/ChatComposer/ChatComposer2.js +153 -0
  24. package/lib/components/CodeBlock/CodeBlock2.js +93 -0
  25. package/lib/components/CodeBlock/highlight.js +114 -0
  26. package/lib/components/ColorPicker/ColorPicker2.js +610 -0
  27. package/lib/components/ColorPicker/color.js +180 -0
  28. package/lib/components/ColorPicker/presets.js +75 -0
  29. package/lib/components/Combobox/Combobox2.js +229 -0
  30. package/lib/components/CommandMenu/CommandMenu.js +267 -0
  31. package/lib/components/Comment/Comment2.js +134 -0
  32. package/lib/components/ContextMenu/ContextMenu2.js +168 -0
  33. package/lib/components/DataGrid/DataGrid2.js +1996 -0
  34. package/lib/components/DataGrid/GridPopover.js +154 -0
  35. package/lib/components/DataGrid/anchor.js +50 -0
  36. package/lib/components/DataGrid/model.js +558 -0
  37. package/lib/components/DataGrid/panels.js +703 -0
  38. package/lib/components/DataGrid/typeMeta.js +76 -0
  39. package/lib/components/DataGrid/types.js +54 -0
  40. package/lib/components/DescriptionList/DescriptionList2.js +180 -0
  41. package/lib/components/Dialog/AlertDialog.js +118 -0
  42. package/lib/components/Dialog/Dialog2.js +109 -0
  43. package/lib/components/Dialog/modal.js +92 -0
  44. package/lib/components/Drawer/Drawer2.js +244 -0
  45. package/lib/components/DropdownMenu/DropdownMenu2.js +394 -0
  46. package/lib/components/DropdownMenu/menuCore.js +63 -0
  47. package/lib/components/Dropzone/Dropzone2.js +144 -0
  48. package/lib/components/EmptyState/EmptyState2.js +72 -0
  49. package/lib/components/FileChip/FileChip2.js +118 -0
  50. package/lib/components/FileUpload/FileUpload.js +258 -0
  51. package/lib/components/FilterChips/FilterChips2.js +101 -0
  52. package/lib/components/FunnelChart/FunnelChart2.js +283 -0
  53. package/lib/components/FunnelChart/funnel.js +69 -0
  54. package/lib/components/Highlight/Highlight2.js +100 -0
  55. package/lib/components/HoverCard/HoverCard.js +134 -0
  56. package/lib/components/InlineDiff/InlineDiff2.js +215 -0
  57. package/lib/components/InlineDiff/diff.js +126 -0
  58. package/lib/components/InlineDiff/useDiffReview.js +109 -0
  59. package/lib/components/Kanban/Kanban2.js +691 -0
  60. package/lib/components/Kanban/KanbanCard.js +159 -0
  61. package/lib/components/Kanban/move.js +69 -0
  62. package/lib/components/LineChart/LineChart2.js +342 -0
  63. package/lib/components/List/List2.js +133 -0
  64. package/lib/components/Listbox/Listbox2.js +163 -0
  65. package/lib/components/Marker/Marker2.js +82 -0
  66. package/lib/components/Menubar/Menubar2.js +223 -0
  67. package/lib/components/MultiSelect/MultiSelect2.js +204 -0
  68. package/lib/components/NavigationMenu/NavigationMenu2.js +481 -0
  69. package/lib/components/NoticeStack/NoticeStack2.js +178 -0
  70. package/lib/components/NumberStepper/NumberStepper2.js +129 -0
  71. package/lib/components/OtpInput/OtpInput2.js +122 -0
  72. package/lib/components/Pagination/Pagination2.js +210 -0
  73. package/lib/components/Pagination/paginationRange.js +53 -0
  74. package/lib/components/PhoneInput/PhoneInput.js +175 -0
  75. package/lib/components/PieChart/PieChart2.js +246 -0
  76. package/lib/components/PieChart/arc.js +66 -0
  77. package/lib/components/PieChart/useArcTween.js +94 -0
  78. package/lib/components/Popover/Popover2.js +112 -0
  79. package/lib/components/ProgressTracker/ProgressTracker2.js +226 -0
  80. package/lib/components/Rating/Rating2.js +186 -0
  81. package/lib/components/Resizable/Resizable2.js +236 -0
  82. package/lib/components/Resizable/layout.js +115 -0
  83. package/lib/components/ScaledPreview/ScaledPreview2.js +100 -0
  84. package/lib/components/ScatterChart/ScatterChart2.js +356 -0
  85. package/lib/components/ScatterChart/scatter.js +83 -0
  86. package/lib/components/ScrollArea/ScrollArea2.js +218 -0
  87. package/lib/components/Select/Select2.js +153 -0
  88. package/lib/components/Sidebar/Sidebar2.js +127 -0
  89. package/lib/components/Skeleton/Skeleton2.js +91 -0
  90. package/lib/components/Slider/Slider2.js +142 -0
  91. package/lib/components/SocialLoginButton/SocialLoginButton.js +85 -0
  92. package/lib/components/SparkChart/SparkChart2.js +217 -0
  93. package/lib/components/SparkChart/spark.js +76 -0
  94. package/lib/components/Sparkbar/Sparkbar2.js +111 -0
  95. package/lib/components/SplitView/SplitView2.js +95 -0
  96. package/lib/components/Stat/Stat2.js +164 -0
  97. package/lib/components/StepList/StepList2.js +131 -0
  98. package/lib/components/Table/Table2.js +104 -0
  99. package/lib/components/Tabs/Tabs2.js +131 -0
  100. package/lib/components/TagInput/TagInput2.js +360 -0
  101. package/lib/components/TimePicker/TimePicker2.js +388 -0
  102. package/lib/components/TimePicker/time.js +83 -0
  103. package/lib/components/Timeline/Timeline2.js +369 -0
  104. package/lib/components/Timeline/scale.js +83 -0
  105. package/lib/components/Toast/Toaster.js +212 -0
  106. package/lib/components/Toast/store.js +129 -0
  107. package/lib/components/ToggleGroup/ToggleGroup2.js +125 -0
  108. package/lib/components/Toolbar/Toolbar2.js +281 -0
  109. package/lib/components/Tracker/Tracker2.js +172 -0
  110. package/lib/components/TreeDiagram/TreeDiagram2.js +223 -0
  111. package/lib/components/TreeView/TreeView2.js +284 -0
  112. package/lib/hooks/timing.js +55 -0
  113. package/lib/hooks/useControllableState.js +49 -0
  114. package/lib/hooks/useCountdown.js +80 -0
  115. package/lib/hooks/useDigitInput.js +105 -0
  116. package/lib/hooks/useDismiss.js +71 -0
  117. package/lib/hooks/useElapsed.js +83 -0
  118. package/lib/hooks/useFloating.js +70 -0
  119. package/lib/hooks/useFocusTrap.js +61 -0
  120. package/lib/hooks/usePresence.js +60 -0
  121. package/lib/hooks/usePressToOpen.js +69 -0
  122. package/lib/hooks/useScrollLock.js +70 -0
  123. package/lib/hooks/useSelection.js +68 -0
  124. package/lib/index.js +175 -17911
  125. package/lib/primitives/AspectRatio2.js +80 -0
  126. package/lib/primitives/BrandIcon.js +245 -0
  127. package/lib/primitives/ColorDot2.js +70 -0
  128. package/lib/primitives/CopyButton2.js +85 -0
  129. package/lib/primitives/CountBadge2.js +78 -0
  130. package/lib/primitives/Countdown2.js +65 -0
  131. package/lib/primitives/Delta2.js +67 -0
  132. package/lib/primitives/Elapsed.js +62 -0
  133. package/lib/primitives/FileIcon2.js +125 -0
  134. package/lib/primitives/Flag2.js +263 -0
  135. package/lib/primitives/IconStack2.js +85 -0
  136. package/lib/primitives/IconTile2.js +68 -0
  137. package/lib/primitives/Kbd2.js +88 -0
  138. package/lib/primitives/Layout2.js +118 -0
  139. package/lib/primitives/Link2.js +53 -0
  140. package/lib/primitives/MaskedText2.js +120 -0
  141. package/lib/primitives/Progress2.js +137 -0
  142. package/lib/primitives/RelativeTime.js +84 -0
  143. package/lib/primitives/SearchInput2.js +84 -0
  144. package/lib/primitives/SelectorButton2.js +97 -0
  145. package/lib/primitives/Spinner2.js +98 -0
  146. package/lib/primitives/StatusIcon2.js +126 -0
  147. package/lib/primitives/Swatch2.js +79 -0
  148. package/lib/primitives/Tooltip2.js +132 -0
  149. package/lib/primitives/Typography2.js +97 -0
  150. package/lib/primitives/formatCountdown.js +51 -0
  151. package/lib/primitives/formatElapsed.js +66 -0
  152. package/lib/primitives/formatRelativeTime.js +64 -0
  153. package/lib/primitives/hotkey.js +94 -0
  154. package/lib/primitives/index.js +352 -0
  155. package/lib/primitives/maskValue.js +65 -0
  156. package/lib/style.css +1 -1
  157. package/lib/types/components/SocialLoginButton/SocialLoginButton.d.ts +10 -0
  158. package/lib/types/components/index.d.ts +2 -0
  159. package/lib/types/primitives/BrandIcon.d.ts +1 -1
  160. package/package.json +2 -1
@@ -0,0 +1,172 @@
1
+ "use client";
2
+ const e = m;
3
+ (function(e, t) {
4
+ let n = m, r = e();
5
+ for (;;) try {
6
+ if (-parseInt(n(277)) / 1 * (-parseInt(n(257)) / 2) + -parseInt(n(272)) / 3 + parseInt(n(256)) / 4 * (-parseInt(n(238)) / 5) + -parseInt(n(296)) / 6 + parseInt(n(292)) / 7 * (-parseInt(n(260)) / 8) + -parseInt(n(243)) / 9 * (-parseInt(n(254)) / 10) + -parseInt(n(264)) / 11 * (-parseInt(n(240)) / 12) == t) break;
7
+ r.push(r.shift());
8
+ } catch {
9
+ r.push(r.shift());
10
+ }
11
+ })(t, 578204);
12
+ function t() {
13
+ let e = /* @__PURE__ */ "CMvTB3zLrxzLBNrmAxn0zw5LCG.og91tevjBa.mJq0Aw5IANzV.ywrKrxzLBNrmAxn0zw5LCG.BM93.mtK1mZCZnLf3uLHfta.C2nYB2XS.C3bHBG.DMfYkc0TBJuP.mtfNCNrwsfO.CMvZAxPL.Aw5UzxjxAwr0Aa.6RIW66gDioYxHUYDJa.D2LKDgG.ChGP.DMfYkc0TC3vJy2vZCYK.BwfW.mZe2ndy1nu9JwwvOEa.y2XPzw50wa.C3vJy2vZCW.CxvLCNLtzwXLy3rVCKfSBa.B2zMC2v0sgvPz2H0.mZaWovHVtw15tq.Dg9VBhrPCa.Dg9Uzq.yM90Dg9T.C2v0vgLTzw91Da.DMfYka.Dg9VBhrPCfnRAxa.zhmTy2HHCNrFx3nY.B2zMC2v0v2LKDgG.7isX64QLioYGGo2vMa.C3rHDhvZ.7iob7yoCioQ4SoUHNq.zhmTy2HHCNq.zhmTC3rHDhvZlxrYywnRzxjFx2jSB2nR.BwLU.mJHqr0TLBK4.zMXVB3i.y3vYCMvUDa.zhmTC3rHDhvZlxrYywnRzxi.mJC0nZG2ofnjv2nQDW.lwXPDMu.DMfYkc0TzgfUz2vYkq.zgL2.ChGSia.DhjHBNnSyxrLka.BgvMDa.y29SB3i.y3vYCMvUDfrHCMDLDa.lMrZlxn0yxr1CY10CMfJA2vYx19IBg9JAW.B3bLBG.otiWotm1z1LhvMPX.BgvUz3rO.mZyZnZi1nJrtCNLdsxG.DMfSDwu.Bwf4.ntiYC0PQzvfx.CMvM.DMfYkc0TD2fYBMLUzYK.zhmTy2HHCNrFx3bSB3q.zMLSBa.y2XLyxjuAw1LB3v0.Dg9W.Cg9SAxrL.y2XVC2vK.yM9KEq.BgfZDa.nJu4mg9usKnWyq".split(".");
14
+ return t = function() {
15
+ return e;
16
+ }, t();
17
+ }
18
+ import { TIMING as n } from "../../hooks/timing.js";
19
+ import { cx as r } from "../../primitives/index.js";
20
+ /* empty css */
21
+ import { ChartTooltip as i } from "../Chart/ChartParts.js";
22
+ import { useChartInteraction as a } from "../Chart/useChartInteraction.js";
23
+ /* empty css */
24
+ import { useEffect as o, useId as s, useLayoutEffect as c, useRef as l, useState as u } from "react";
25
+ import { Fragment as d, jsx as f, jsxs as p } from "react/jsx-runtime";
26
+ function m(e, n) {
27
+ e -= 238;
28
+ let r = t(), i = r[e];
29
+ m.uAtgho === void 0 && (m.ESWNTd = function(e) {
30
+ let t = "", n = "";
31
+ for (let n = 0, r, i, a = 0; i = e.charAt(a++); ~i && (r = n % 4 ? r * 64 + i : i, n++ % 4) && (t += String.fromCharCode(255 & r >> (-2 * n & 6)))) i = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=".indexOf(i);
32
+ for (let e = 0, r = t.length; e < r; e++) n += "%" + ("00" + t.charCodeAt(e).toString(16)).slice(-2);
33
+ return decodeURIComponent(n);
34
+ }, m.BziNEc = {}, m.uAtgho = !0);
35
+ let a = r[0];
36
+ m.RbmxEo !== a && (m.BziNEc = {}, m.RbmxEo = a);
37
+ let o = m.BziNEc[e];
38
+ return o === void 0 ? (i = m.ESWNTd(i), m.BziNEc[e] = i) : i = o, i;
39
+ }
40
+ import { createPortal as h } from "react-dom";
41
+ var g = {
42
+ success: e(270),
43
+ warning: e(245),
44
+ danger: e(298),
45
+ neutral: "var(--n8)",
46
+ accent: "var(--accent)",
47
+ empty: e(263)
48
+ }, _ = {
49
+ success: "정상",
50
+ warning: e(286),
51
+ danger: "장애",
52
+ neutral: "배포",
53
+ accent: "점검",
54
+ empty: e(267)
55
+ }, v = {
56
+ sm: 24,
57
+ md: 32,
58
+ lg: 40
59
+ }, y = 8, b = 8, x = (t) => {
60
+ let n = e;
61
+ return t?.[n(303)] ? t[n(303)].startsWith("--") ? n(282) + t[n(303)] + ")" : t[n(303)] : g[t?.[n(279)] ?? n(274)];
62
+ };
63
+ function S({ data: t, size: g = "md", height: S, layout: C = e(247), tooltip: w = !0, activeIndex: T, defaultActiveIndex: E, onActiveIndexChange: D, "aria-label": O = e(288), className: k, style: A }) {
64
+ let j = e, M = t[j(239)], { open: N, shown: P, settled: F, hover: I, leave: L, plotProps: R } = a({
65
+ count: M,
66
+ activeIndex: T,
67
+ defaultActiveIndex: E,
68
+ onActiveIndexChange: D,
69
+ initialKeyboardIndex: j(253)
70
+ }), z = s(), B = l(null), [V, H] = u(null), U = l(void 0), W = l(null), G = l(0), K = l(!1);
71
+ o(() => {
72
+ let e = j;
73
+ N ? K.current = !0 : K[e(294)] && (K[e(294)] = !1, G[e(294)] = Date[e(259)]());
74
+ }, [N]), o(() => () => window[j(248)](U[j(294)]), []);
75
+ let q = (e) => {
76
+ let t = j, n = e[t(304)].getBoundingClientRect();
77
+ return Math[t(291)](M - 1, Math[t(242)](0, Math[t(293)]((e[t(273)] - n[t(302)]) / n[t(268)] * M)));
78
+ }, J = (e) => {
79
+ let t = j;
80
+ if (!M) return;
81
+ let r = q(e);
82
+ e.pointerType !== "mouse" || N || Date[t(259)]() - G[t(294)] < n[t(283)] ? (window[t(248)](U[t(294)]), U.current = void 0, I(r)) : (W[t(294)] !== r || U.current === void 0) && (W[t(294)] = r, window.clearTimeout(U.current), U.current = window[t(281)](() => {
83
+ let e = t;
84
+ U[e(294)] = void 0, W[e(294)] !== null && I(W[e(294)]);
85
+ }, n.tooltipDelay));
86
+ }, Y = () => {
87
+ let e = j;
88
+ window[e(248)](U[e(294)]), U[e(294)] = void 0, W[e(294)] = null, L();
89
+ };
90
+ c(() => {
91
+ let e = j;
92
+ if (!N || P === null || !w) return;
93
+ let t = () => {
94
+ let e = m, t = R[e(244)][e(294)]?.[e(275)](e(305))[P], n = B.current;
95
+ if (!t || !n) return;
96
+ let r = t.getBoundingClientRect(), i = n[e(285)], a = n[e(276)], o = Math.max(b, Math.min(r[e(302)] + r[e(268)] / 2 - i / 2, window[e(266)] - i - b)), s = r[e(249)] - y - a, c = s >= b ? s : r[e(280)] + y;
97
+ H((e) => e && e.x === o && e.y === c ? e : {
98
+ x: o,
99
+ y: c
100
+ });
101
+ };
102
+ return t(), window[e(258)](e(265), t), window[e(258)](e(261), t, !0), () => {
103
+ let n = e;
104
+ window.removeEventListener("resize", t), window[n(255)](n(261), t, !0);
105
+ };
106
+ }, [
107
+ N,
108
+ P,
109
+ w,
110
+ R[j(244)]
111
+ ]);
112
+ let X = P === null ? void 0 : t[P], Z = X ? X[j(287)] ?? _[X[j(279)] ?? "success"] : null, Q = S ?? v[g];
113
+ return p("div", {
114
+ ...R,
115
+ className: r(j(289), j(246), j(295), k),
116
+ "data-size": g,
117
+ "data-layout": C,
118
+ style: {
119
+ "--_h": Q + "px",
120
+ ...A
121
+ },
122
+ "aria-roledescription": j(288),
123
+ "aria-label": O,
124
+ "aria-describedby": z + j(297),
125
+ onPointerMove: J,
126
+ onPointerDown: J,
127
+ onPointerLeave: Y,
128
+ children: [
129
+ t[j(271)]((e, t) => f("span", {
130
+ className: j(290),
131
+ "data-tone": e.color ? void 0 : e[j(279)] ?? j(274),
132
+ "data-active": N && P === t || void 0,
133
+ "data-first": t === 0 || void 0,
134
+ "data-last": t === M - 1 || void 0,
135
+ style: {
136
+ "--_i": t,
137
+ ...e[j(303)] && { "--_c": x(e) }
138
+ },
139
+ "aria-hidden": !0
140
+ }, e.key)),
141
+ w && h(f(j(299), {
142
+ ref: B,
143
+ className: "ds-status-tracker__tip",
144
+ "data-state": j(N && V ? 306 : 251),
145
+ "data-settled": F && V !== null || void 0,
146
+ style: { transform: j(301) + (V?.x ?? 0) + j(300) + (V?.y ?? 0) + j(269) },
147
+ "aria-hidden": !0,
148
+ children: f(i, {
149
+ title: X?.[j(278)],
150
+ rows: X ? [{
151
+ key: "status",
152
+ label: Z,
153
+ color: x(X),
154
+ value: X[j(241)] ?? ""
155
+ }] : []
156
+ })
157
+ }), document[j(252)]),
158
+ f(j(262), {
159
+ id: z + j(297),
160
+ className: j(284),
161
+ "aria-live": j(250),
162
+ children: N && X ? p(d, { children: [
163
+ X[j(278)],
164
+ X[j(278)] != null && ": ",
165
+ Z,
166
+ X[j(241)] != null && p(d, { children: [" ", X.value] })
167
+ ] }) : null
168
+ })
169
+ ]
170
+ });
171
+ }
172
+ export { S as Tracker };
@@ -0,0 +1,223 @@
1
+ "use client";
2
+ const e = h;
3
+ (function(e, t) {
4
+ let n = h, r = e();
5
+ for (;;) try {
6
+ if (-parseInt(n(230)) / 1 * (parseInt(n(267)) / 2) + -parseInt(n(263)) / 3 + -parseInt(n(287)) / 4 * (parseInt(n(266)) / 5) + -parseInt(n(242)) / 6 * (parseInt(n(264)) / 7) + parseInt(n(281)) / 8 + parseInt(n(272)) / 9 + parseInt(n(234)) / 10 == t) break;
7
+ r.push(r.shift());
8
+ } catch {
9
+ r.push(r.shift());
10
+ }
11
+ })(f, 748028);
12
+ import { useControllableState as t } from "../../hooks/useControllableState.js";
13
+ import { cx as n } from "../../primitives/index.js";
14
+ /* empty css */
15
+ import { useCallback as r, useId as i, useLayoutEffect as a, useRef as o, useState as s } from "react";
16
+ import { ChevronDown as c } from "lucide-react";
17
+ import { jsx as l, jsxs as u } from "react/jsx-runtime";
18
+ var d = (t) => t === 0 ? "0px" : e(218) + t + ")";
19
+ function f() {
20
+ let e = /* @__PURE__ */ "zMLYC3rfBgvTzw50q2HPBgq.mZqWotK1sufzq1Dh.odq3txfPsgjR.zhmTDhjLzs1KAwfNCMfTx19Jyw52yxm.nZe2nZm1ufnkv0XY.nZHJELbOuvq.C2v0qxr0CMLIDxrL.B2jZzxj2zq.ywjZ.zhmTDhjLzs1KAwfNCMfTx19MB3jLC3q.mJGYotKWnNHuu0DMzG.zhmTDhjLzs1KAwfNCMfTx19Oyw5KBgu.z3jPzc10zw1WBgf0zs1YB3DZ.AgvPz2H0.z2v0qM91BMrPBMDdBgLLBNrszwn0.BgvUz3rO.BwLU.y2HPBgrYzw4.BgfZDevSzw1LBNrdAgLSza.nZaWmdu0neHStw9iAW.z3jVDxa.DgfYz2v0.C2LNBG.yxbWzw5K.zhmTDhjLzs1KAwfNCMfTx19UB2rL.mJHrCgjPrgq.zgL2.y2XHC3m.DMfYkc0TCW.y3vYCMvUDa.yNv0Dg9U.BwfW.y2HPBgrmyxLVDxq.B2zMC2v0v2LKDgG.zM9YrwfJAa.zhmTDhjLzs1KAwfNCMfTx19SAw5R.zgvSzxrL.y2LYy2XL.zhmTDhjLzs1KAwfNCMfTx190B2DNBgu.mY41.mJu3mtnQrgXMB1i.yM90Dg9T.AgfZ.y3jLyxrLrwXLBwvUDe5t.mJq5oty1ndbywMfUCfu.Dg9W.zhmTDhjLzs1KAwfNCMfTigrZlxnJCM9SBa.zgf0ys12AxnPyMXL.AM9PBG.CM93.Bwf4.C2v0.nda3mJjTvefVzeu.zhmTDhjLzs1KAwfNCMfTx19MB2XK.7y687lMy6RIW.D2LKDgG.y3vYCMvUDfrHCMDLDa.C3zN.Aw5Kzw50zwq.BgvMDa.z2v0.Cgf0Aa.ywrK.zhmTDhjLzs1KAwfNCMfTx190B2DNBguTy291BNq.zhmTDhjLzs1KAwfNCMfTx19SAw5LCW.7zwy7jYeia.AgfUzgXL.CxvLCNLtzwXLy3rVCKfSBa.zMLSDgvY.Dg9Nz2XLqxr0CMLIDxrL.CM91BMq.zhmTDhjLzs1KAwfNCMfTx19JAgLSzhjLBI0T".split(".");
21
+ return f = function() {
22
+ return e;
23
+ }, f();
24
+ }
25
+ function p({ count: t, collapsed: r, onToggle: i, "aria-controls": a, "aria-label": o, className: s }) {
26
+ let d = e;
27
+ return u(d(220), {
28
+ type: d(220),
29
+ className: n(d(228), s),
30
+ "aria-expanded": !r,
31
+ "aria-controls": a,
32
+ "aria-label": o ?? d(255) + t + "개 " + (r ? d(244) : "접기"),
33
+ "data-collapsed": r || void 0,
34
+ onClick: (e) => {
35
+ e.stopPropagation(), i();
36
+ },
37
+ children: [l("span", {
38
+ className: d(253),
39
+ children: t
40
+ }), l(c, { "aria-hidden": !0 })]
41
+ });
42
+ }
43
+ function m({ id: t, open: n, children: r }) {
44
+ let i = e, [a, o] = s(n), [c, u] = s(n);
45
+ return c !== n && (u(n), o(!1)), l(i(288), {
46
+ id: t,
47
+ className: i(243),
48
+ "data-open": n || void 0,
49
+ "data-settled": n && a || void 0,
50
+ inert: !n || void 0,
51
+ onTransitionEnd: (e) => {
52
+ let t = i;
53
+ e[t(283)] === e[t(246)] && n && e.propertyName === t(274) && o(!0);
54
+ },
55
+ children: l("div", {
56
+ className: "ds-tree-diagram__fold-inner",
57
+ children: r
58
+ })
59
+ });
60
+ }
61
+ function h(e, t) {
62
+ e -= 218;
63
+ let n = f(), r = n[e];
64
+ h.kJglNB === void 0 && (h.ilJIth = function(e) {
65
+ let t = "", n = "";
66
+ for (let n = 0, r, i, a = 0; i = e.charAt(a++); ~i && (r = n % 4 ? r * 64 + i : i, n++ % 4) && (t += String.fromCharCode(255 & r >> (-2 * n & 6)))) i = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=".indexOf(i);
67
+ for (let e = 0, r = t.length; e < r; e++) n += "%" + ("00" + t.charCodeAt(e).toString(16)).slice(-2);
68
+ return decodeURIComponent(n);
69
+ }, h.CEtcrX = {}, h.kJglNB = !0);
70
+ let i = n[0];
71
+ h.toxxBN !== i && (h.CEtcrX = {}, h.toxxBN = i);
72
+ let a = h.CEtcrX[e];
73
+ return a === void 0 ? (r = h.ilJIth(r), h.CEtcrX[e] = r) : r = a, r;
74
+ }
75
+ var g = 8, _ = (t) => Math[e(260)](t * 10) / 10;
76
+ function v(t, n) {
77
+ let r = e, i = t.cx, a = t[r(231)], o = a + (Math[r(278)](...n[r(221)]((e) => e.top)) - a) / 2;
78
+ return n[r(221)]((e) => {
79
+ let t = r, n = e.cx - i;
80
+ if (Math[t(270)](n) < 1) return "M" + _(i) + " " + _(a) + "V" + _(e.top);
81
+ let s = Math[t(284)](n), c = Math[t(240)](0, Math[t(278)](g, Math.abs(n) / 2, o - a, e.top - o));
82
+ return "M" + _(i) + " " + _(a) + "V" + _(o - c) + "Q" + _(i) + " " + _(o) + " " + _(i + s * c) + " " + _(o) + "H" + _(e.cx - s * c) + "Q" + _(e.cx) + " " + _(o) + " " + _(e.cx) + " " + _(o + c) + "V" + _(e[t(235)]);
83
+ }).join("");
84
+ }
85
+ function y(t, n) {
86
+ let r = e, i = t[r(249)] + (Math.min(...n[r(221)]((e) => e[r(249)])) - t[r(249)]) / 2, a = t.bottom;
87
+ return {
88
+ sx: i,
89
+ d: n.map((e) => {
90
+ let t = r, n = Math.max(0, Math[t(278)](g, e.cy - a, e[t(249)] - i));
91
+ return "M" + _(i) + " " + _(a) + "V" + _(e.cy - n) + "Q" + _(i) + " " + _(e.cy) + " " + _(i + n) + " " + _(e.cy) + "H" + _(e[t(249)]);
92
+ })[r(238)]("")
93
+ };
94
+ }
95
+ var b = "http://www.w3.org/2000/svg";
96
+ function x({ items: s, renderNode: c, collapsed: f, defaultCollapsed: h, onCollapsedChange: g, indentFrom: x, gap: S = 4, levelGap: C = 8, indent: w = 8, nodeWidth: T, className: E, style: D, "aria-label": O }) {
97
+ let k = e, [A, j] = t(f, h ?? [], g), M = i(), N = o(null), P = o(null), F = o(null), I = o(/* @__PURE__ */ new Map()), L = o(/* @__PURE__ */ new Map()), R = new Set(A), z = (e, t) => {
98
+ t !== R.has(e) && j(t ? [...A, e] : A.filter((t) => t !== e));
99
+ }, B = (e, t, n) => e[k(222)] ?? (n === k(248) || x !== void 0 && t >= x ? k(248) : k(239)), V = o({
100
+ items: s,
101
+ collapsed: A,
102
+ layoutOf: B
103
+ });
104
+ a(() => {
105
+ let e = k;
106
+ V[e(219)] = {
107
+ items: s,
108
+ collapsed: A,
109
+ layoutOf: B
110
+ };
111
+ });
112
+ let H = r(() => {
113
+ let e = k, t = P.current, n = F[e(219)], r = n?.[e(262)], i = n?.[e(280)];
114
+ if (!t || !r || !i) return;
115
+ let a = t[e(276)](), o = t[e(223)] > 0 && a[e(245)] > 0 ? a.width / t[e(223)] : 1, s = Math[e(270)](o - 1) < .01 ? 1 : o, c = (t) => {
116
+ let n = e, r = I[n(219)][n(250)](t);
117
+ if (!r) return null;
118
+ let i = r[n(276)](), o = (i[n(249)] - a[n(249)]) / s, c = (i[n(235)] - a[n(235)]) / s, l = i[n(245)] / s, u = i[n(275)] / s;
119
+ return {
120
+ left: o,
121
+ top: c,
122
+ right: o + l,
123
+ bottom: c + u,
124
+ cx: o + l / 2,
125
+ cy: c + u / 2
126
+ };
127
+ }, { items: l, collapsed: u, layoutOf: d } = V[e(219)], f = new Set(u), p = /* @__PURE__ */ new Set(), m = (t, n, a, o) => {
128
+ let s = e;
129
+ for (let e of t) {
130
+ if (!e[s(279)]?.[s(277)]) continue;
131
+ let t = d(e, n, a), l = o && !f.has(e.id), u = c(e.id), h = e[s(279)][s(221)]((e) => c(e.id))[s(258)]((e) => !!e);
132
+ if (u && h[s(277)]) {
133
+ p[s(252)](e.id);
134
+ let n = L[s(219)][s(250)](e.id);
135
+ if (!n) {
136
+ let t = document.createElementNS(b, "g"), a = document[s(233)](b, s(251)), o = document[s(233)](b, s(227));
137
+ t.setAttribute(s(289), s(225)), o[s(268)](s(289), s(273)), o[s(268)]("r", s(229)), t[s(285)](a), r[s(285)](t), i[s(285)](o), n = {
138
+ g: t,
139
+ path: a,
140
+ handle: o
141
+ }, L[s(219)][s(241)](e.id, n);
142
+ }
143
+ let a = u.cx;
144
+ if (t === s(239)) n[s(251)][s(268)]("d", v(u, h));
145
+ else {
146
+ let { sx: e, d: t } = y(u, h);
147
+ n[s(251)].setAttribute("d", t), a = e;
148
+ }
149
+ n[s(256)][s(268)]("cx", String(_(a))), n[s(256)].setAttribute("cy", String(_(u[s(231)]))), n.g[s(259)]("data-open", l), n.handle.toggleAttribute(s(237), o);
150
+ }
151
+ m(e.children, n + 1, t, l);
152
+ }
153
+ };
154
+ m(l, 0, e(239), !0);
155
+ for (let [t, n] of L.current) p.has(t) || (n.g.remove(), n[e(256)].remove(), L[e(219)][e(226)](t));
156
+ }, []);
157
+ a(H), a(() => {
158
+ let e = k, t = P[e(219)], n = N.current;
159
+ if (!t || !n) return;
160
+ let r = new ResizeObserver(() => H());
161
+ return r.observe(n), r[e(269)](t), t[e(257)](".ds-tree-diagram__node, .ds-tree-diagram__fold")[e(224)]((t) => r[e(269)](t)), () => r.disconnect();
162
+ });
163
+ let U = (e, t, r) => {
164
+ let i = k, a = e[i(279)]?.length ?? 0, o = R[i(232)](e.id), s = B(e, t, r), d = M + "-" + e.id, f = {
165
+ depth: t,
166
+ childCount: a,
167
+ collapsed: o,
168
+ setCollapsed: (t) => z(e.id, t),
169
+ childLayout: s,
170
+ toggle: a ? l(p, {
171
+ count: a,
172
+ collapsed: o,
173
+ "aria-controls": d,
174
+ onToggle: () => z(e.id, !o)
175
+ }) : null
176
+ };
177
+ return u("li", {
178
+ className: n("ds-tree-diagram__subtree", "ds-tree-diagram__subtree--" + r),
179
+ children: [l(i(288), {
180
+ ref: (t) => {
181
+ let n = i;
182
+ t ? I.current[n(241)](e.id, t) : I[n(219)][n(226)](e.id);
183
+ },
184
+ className: i(286),
185
+ style: T === void 0 ? void 0 : { width: T },
186
+ children: c(e, f)
187
+ }), a > 0 && e[i(279)] && l(m, {
188
+ id: d,
189
+ open: !o,
190
+ children: l("ul", {
191
+ className: n("ds-tree-diagram__children", i(261) + s),
192
+ children: e[i(279)][i(221)]((e) => U(e, t + 1, s))
193
+ })
194
+ })]
195
+ }, e.id);
196
+ };
197
+ return l(k(288), {
198
+ ref: N,
199
+ role: k(282),
200
+ "aria-label": O,
201
+ className: n(k(236), E),
202
+ style: {
203
+ "--_gap": d(S),
204
+ "--_level-gap": d(C),
205
+ "--_indent": d(w),
206
+ ...D
207
+ },
208
+ children: u(k(288), {
209
+ ref: P,
210
+ className: k(265),
211
+ children: [l("ul", {
212
+ className: k(271),
213
+ children: s.map((e) => U(e, 0, k(239)))
214
+ }), u(k(247), {
215
+ ref: F,
216
+ className: k(254),
217
+ "aria-hidden": !0,
218
+ children: [l("g", {}), l("g", {})]
219
+ })]
220
+ })
221
+ });
222
+ }
223
+ export { x as TreeDiagram, p as TreeDiagramToggle };
@@ -0,0 +1,284 @@
1
+ "use client";
2
+ const e = r;
3
+ (function(e, t) {
4
+ let n = r, i = e();
5
+ for (;;) try {
6
+ if (parseInt(n(245)) / 1 * (parseInt(n(241)) / 2) + -parseInt(n(232)) / 3 * (parseInt(n(237)) / 4) + -parseInt(n(197)) / 5 * (parseInt(n(181)) / 6) + -parseInt(n(211)) / 7 + parseInt(n(190)) / 8 * (-parseInt(n(189)) / 9) + -parseInt(n(183)) / 10 + parseInt(n(236)) / 11 * (parseInt(n(242)) / 12) == t) break;
7
+ i.push(i.shift());
8
+ } catch {
9
+ i.push(i.shift());
10
+ }
11
+ })(t, 895198);
12
+ function t() {
13
+ let e = /* @__PURE__ */ "otyZnuT4zuvJwa.Bwv0yuTLEq.rw5K.zhmTDhjLzs12Awv3x19SzwfKAw5N.Dg9mB3DLCKnHC2u.zhmTDhjLzs12Awv3x19KzxnJ.BMf0AxzLrxzLBNq.DgLTzxi.y3rYBeTLEq.C2v0.zgvMyxvSDa.ChvZAa.Dgv4Da.zxzLCNK.mJeWrePvqNjL.z2v0qxr0CMLIDxrL.mtaYmZm2mtbnwe1RENy.BgfIzwW.DhLWzwfOzwfK.zxHWyw5Kzwq.AgfZq2HPBgrYzw4.zhmTDhjLzs12Awv3.oda2ndLRsgn0vfq.mta0ofnds1DkAW.zhmTDhjLzs12Awv3x19MB2XKlwLUBMvY.rw50zxi.CM9Szq.AM9PBG.y3vYCMvUDa.zgL2.mtC0nZK1seX1rwrz.zhmTDhjLzs12Awv3x19SywjLBa.BgvHzgLUzW.zM9YrwfJAa.DhjHAwXPBMC.qxjYB3Dmzwz0.C3rVCfbYB3bHz2f0Aw9U.zgLZywjSzwq.DhjLzwL0zw0.CgfYzw50swq.C2v0vgLTzw91Da.AgfZ.zhmTDhjLzs12Awv3x190zxH0.zM9JDxm.mti1mtCYnJDpsxn5vMG.zgvZy3jPChrPB24.ChjVChm.BNvTyMvY.zhmTDhjLzs12Awv3x190CMfPBgLUzW.sg9Tzq.zgvSzxrL.ChjLDMvUDerLzMf1Bhq.AxndB21WB3nPBMC.qxjYB3DvCa.mhb4.C3bHBG.A2v5.y3vYCMvUDfrHCMDLDa.DgfYz2v0.C2LUz2XL.DhjLzq.DMfYkc0TCW.C3rYAw5N.z2v0.zMLUzeLUzgv4.ndC2nZC1zwnIrg51.y2HPBgrYzw4.zMLSDgvY.zhmTDhjLzs12Awv3x19YB3C.mtKWnJnLuLDHtMC.mJrpD2LnvNi.BM9Kzq.DhLWzq.BwfW.mKPhEvPcwG.ndG4mdrfu3H3thy.BgvUz3rO.y2XLyxjuAw1LB3v0".split(".");
14
+ return t = function() {
15
+ return e;
16
+ }, t();
17
+ }
18
+ import { TIMING as n } from "../../hooks/timing.js";
19
+ function r(e, n) {
20
+ e -= 176;
21
+ let i = t(), a = i[e];
22
+ r.luYwdw === void 0 && (r.JsVqMQ = function(e) {
23
+ let t = "", n = "";
24
+ for (let n = 0, r, i, a = 0; i = e.charAt(a++); ~i && (r = n % 4 ? r * 64 + i : i, n++ % 4) && (t += String.fromCharCode(255 & r >> (-2 * n & 6)))) i = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+/=".indexOf(i);
25
+ for (let e = 0, r = t.length; e < r; e++) n += "%" + ("00" + t.charCodeAt(e).toString(16)).slice(-2);
26
+ return decodeURIComponent(n);
27
+ }, r.glVlnE = {}, r.luYwdw = !0);
28
+ let o = i[0];
29
+ r.SsZMCG !== o && (r.glVlnE = {}, r.SsZMCG = o);
30
+ let s = r.glVlnE[e];
31
+ return s === void 0 ? (a = r.JsVqMQ(a), r.glVlnE[e] = a) : a = s, a;
32
+ }
33
+ import { useControllableState as i } from "../../hooks/useControllableState.js";
34
+ import { cx as a } from "../../primitives/index.js";
35
+ /* empty css */
36
+ import { Children as o, Fragment as s, isValidElement as c, useCallback as l, useEffect as u, useMemo as d, useRef as f, useState as p } from "react";
37
+ import { ChevronRight as m } from "lucide-react";
38
+ import { Fragment as ee, jsx as h, jsxs as g } from "react/jsx-runtime";
39
+ var _ = {
40
+ compact: 32,
41
+ default: 40,
42
+ comfortable: 48
43
+ };
44
+ function v(e, t) {
45
+ let n = t instanceof Set ? t : new Set(t), i = [], a = (e, t, o) => {
46
+ let s = r;
47
+ e[s(200)]((r, c) => {
48
+ let l = s, u = !!r[l(233)]?.[l(243)], d = u && n[l(208)](r.id);
49
+ i[l(178)]({
50
+ id: r.id,
51
+ node: r,
52
+ depth: t,
53
+ index: i[l(243)],
54
+ parentId: o,
55
+ hasChildren: u,
56
+ expanded: d,
57
+ posinset: c + 1,
58
+ setsize: e[l(243)]
59
+ }), d && r[l(233)] && a(r[l(233)], t + 1, r.id);
60
+ });
61
+ };
62
+ return a(e, 0, null), i;
63
+ }
64
+ function y(e) {
65
+ return null;
66
+ }
67
+ function b(e) {
68
+ let t = r, n = [];
69
+ return o[t(200)](e, (e) => {
70
+ let r = t;
71
+ if (!c(e)) return;
72
+ if (e[r(239)] === s) {
73
+ n[r(178)](...b(e.props[r(233)]));
74
+ return;
75
+ }
76
+ if (e.type !== y) return;
77
+ let { children: i, ...a } = e[r(213)], o = b(i);
78
+ n[r(178)]({
79
+ ...a,
80
+ children: o[r(243)] ? o : void 0
81
+ });
82
+ }), n;
83
+ }
84
+ var te = (t) => (t.textValue ?? (typeof t.label === e(229) || typeof t.label === e(214) ? String(t.label) : ""))[e(249)]();
85
+ function x({ items: t, children: o, expanded: s, defaultExpanded: c, onExpandedChange: y, selected: x, defaultSelected: ne, onSelectedChange: S, selectionMode: C = "single", expandOnClick: re, onAction: ie, density: w = e(177), rowHeight: ae, indent: T = 6, guides: oe, animated: se = !0, renderItem: E, onVisibleChange: D, className: O, style: k, "aria-label": A, "aria-labelledby": j }) {
86
+ let M = e, N = d(() => t ?? b(o), [t, o]), [P, F] = i(s, c ?? [], y), [I, ce] = i(x, ne ?? null, S), [L, R] = p(null), z = f(/* @__PURE__ */ new Map()), B = f({
87
+ text: "",
88
+ timer: 0
89
+ }), V = d(() => new Set(P), [P]), H = d(() => v(N, V), [N, V]), U = d(() => {
90
+ let e = r, t = /* @__PURE__ */ new Map(), n = (r, i) => r[e(200)]((r) => {
91
+ let a = e;
92
+ t[a(176)](r.id, i), r[a(233)] && n(r[a(233)], r.id);
93
+ });
94
+ return n(N, null), t;
95
+ }, [N]), W = d(() => new Set(H[M(240)]((e) => e.id)), [H]), G = (e) => {
96
+ let t = M, n = e;
97
+ for (; n && !W[t(208)](n);) n = U.get(n) ?? null;
98
+ return n;
99
+ }, K = G(L) ?? G(I) ?? H[0]?.id ?? null, q = H[M(240)]((e) => "" + e.id + (e[M(186)] ? "+" : ""))[M(194)]("|"), J = f(null);
100
+ u(() => {
101
+ let e = M;
102
+ q !== J[e(195)] && (J[e(195)] = q, D?.(H));
103
+ }, [
104
+ q,
105
+ H,
106
+ D
107
+ ]), u(() => {
108
+ let e = M, t = B[e(195)];
109
+ return () => window[e(244)](t[e(252)]);
110
+ }, []);
111
+ let Y = l((e) => {
112
+ let t = M;
113
+ R(e), z[t(195)][t(230)](e)?.[t(210)]();
114
+ }, []), X = (e, t) => {
115
+ let n = M, r = e ? U[n(230)](e) ?? null : null;
116
+ for (; r;) {
117
+ if (r === t) return !0;
118
+ r = U[n(230)](r) ?? null;
119
+ }
120
+ return !1;
121
+ }, Z = (e, t) => {
122
+ t !== V[M(208)](e) && (F(t ? [...P, e] : P.filter((t) => t !== e)), !t && X(L, e) && Y(e));
123
+ }, le = re ?? C === "none", Q = (e, t) => {
124
+ let n = M;
125
+ e[n(238)][n(204)] || (C === n(226) && ce(e.id), e.hasChildren && (le || C === "none" && !t) && Z(e.id, !e[n(186)]), ie?.(e[n(238)]));
126
+ }, ue = (e) => {
127
+ let t = M;
128
+ if (e[t(225)][t(182)](t(193)) !== "treeitem" || e[t(251)][t(219)]) return;
129
+ let r = H[t(231)]((e) => e.id === K);
130
+ if (r < 0) return;
131
+ let i = H[r], a = (e) => e && Y(e.id), o = !0;
132
+ switch (e[t(223)]) {
133
+ case "ArrowDown":
134
+ a(H[r + 1]);
135
+ break;
136
+ case t(220):
137
+ a(H[r - 1]);
138
+ break;
139
+ case t(216):
140
+ a(H[0]);
141
+ break;
142
+ case t(247):
143
+ a(H[H[t(243)] - 1]);
144
+ break;
145
+ case "ArrowRight":
146
+ i[t(187)] && !i[t(238)].disabled && (i.expanded ? a(H[r + 1]) : Z(i.id, !0));
147
+ break;
148
+ case t(202):
149
+ i[t(186)] ? Z(i.id, !1) : i.parentId && Y(i[t(206)]);
150
+ break;
151
+ case t(192):
152
+ case " ":
153
+ Q(i, !1);
154
+ break;
155
+ case "*": {
156
+ let e = H[t(234)]((e) => e[t(206)] === i[t(206)] && e[t(187)] && !e[t(238)].disabled && !e[t(186)]);
157
+ e.length && F([...P, ...e.map((e) => e.id)]);
158
+ break;
159
+ }
160
+ default: {
161
+ if (e[t(223)][t(243)] !== 1 || e[t(253)] || e[t(246)] || e.altKey) {
162
+ o = !1;
163
+ break;
164
+ }
165
+ let i = B[t(195)];
166
+ window[t(244)](i[t(252)]), i[t(179)] += e[t(223)].toLowerCase(), i[t(252)] = window[t(207)](() => {
167
+ i.text = "";
168
+ }, n[t(185)]);
169
+ let a = i.text.length > 1 && [...i.text][t(180)]((e) => e === i.text[0]) ? i[t(179)][0] : i[t(179)], s = a[t(243)] === 1 ? r + 1 : r;
170
+ for (let e = 0; e < H[t(243)]; e++) {
171
+ let n = H[(s + e) % H[t(243)]];
172
+ if (te(n.node).startsWith(a)) {
173
+ Y(n.id);
174
+ break;
175
+ }
176
+ }
177
+ }
178
+ }
179
+ o && e[t(218)]();
180
+ }, $ = (e, t) => e[M(240)]((n, r) => {
181
+ let i = M, a = !!n[i(233)]?.[i(243)], o = a && V.has(n.id), s = I === n.id, c = !!n[i(204)], l = {
182
+ depth: t,
183
+ expanded: o,
184
+ selected: s,
185
+ focused: L === n.id,
186
+ hasChildren: a,
187
+ disabled: c
188
+ }, u = {
189
+ id: n.id,
190
+ node: n,
191
+ depth: t,
192
+ index: -1,
193
+ parentId: U[i(230)](n.id) ?? null,
194
+ hasChildren: a,
195
+ expanded: o,
196
+ posinset: r + 1,
197
+ setsize: e[i(243)]
198
+ };
199
+ return g("li", {
200
+ ref: (e) => {
201
+ let t = i;
202
+ e ? z.current.set(n.id, e) : z.current[t(217)](n.id);
203
+ },
204
+ role: i(205),
205
+ className: "ds-tree-view__item",
206
+ "aria-level": t + 1,
207
+ "aria-posinset": r + 1,
208
+ "aria-setsize": e[i(243)],
209
+ "aria-expanded": a ? o : void 0,
210
+ "aria-selected": C === i(226) ? s : void 0,
211
+ "aria-disabled": c || void 0,
212
+ tabIndex: n.id === K ? 0 : -1,
213
+ "data-open": o || void 0,
214
+ onFocus: (e) => {
215
+ let t = i;
216
+ e.target === e[t(224)] && R(n.id);
217
+ },
218
+ children: [g(i(196), {
219
+ className: i(235),
220
+ style: { "--_depth": t },
221
+ "data-selected": s || void 0,
222
+ "data-disabled": c || void 0,
223
+ onClick: () => {
224
+ Y(n.id), Q(u, !0);
225
+ },
226
+ children: [
227
+ h(i(222), {
228
+ className: "ds-tree-view__toggle",
229
+ "aria-hidden": !0,
230
+ onClick: a && !c ? (e) => {
231
+ e[i(203)](), Y(n.id), Z(n.id, !o);
232
+ } : void 0,
233
+ children: a && h(m, {})
234
+ }),
235
+ n[i(199)] && h("span", {
236
+ className: i(248),
237
+ children: n[i(199)]
238
+ }),
239
+ h(i(222), {
240
+ className: i(209),
241
+ children: E ? E(n, l) : g(ee, { children: [h(i(222), {
242
+ className: i(198),
243
+ children: n[i(184)]
244
+ }), n[i(212)] && h(i(222), {
245
+ className: i(250),
246
+ children: n[i(212)]
247
+ })] })
248
+ }),
249
+ n[i(201)] && h("span", {
250
+ className: i(215),
251
+ children: n[i(201)]
252
+ })
253
+ ]
254
+ }), a && n[i(233)] && h("div", {
255
+ className: "ds-tree-view__fold",
256
+ inert: !o || void 0,
257
+ children: h("div", {
258
+ className: i(191),
259
+ children: h("ul", {
260
+ role: "group",
261
+ className: "ds-tree-view__group",
262
+ style: { "--_depth": t },
263
+ children: $(n.children, t + 1)
264
+ })
265
+ })
266
+ })]
267
+ }, n.id);
268
+ }), de = T === 0 ? M(221) : M(228) + T + ")";
269
+ return h("ul", {
270
+ role: M(227),
271
+ "aria-label": A,
272
+ "aria-labelledby": j,
273
+ className: a(M(188), "ds-tree-view--" + w, oe && "ds-tree-view--guides", !se && "ds-tree-view--static", O),
274
+ style: {
275
+ "--_row-h": (ae ?? _[w]) + "px",
276
+ "--_indent": de,
277
+ ...k
278
+ },
279
+ onKeyDown: ue,
280
+ children: $(N, 0)
281
+ });
282
+ }
283
+ x.Item = y;
284
+ export { _ as TREE_ROW_HEIGHT, y as TreeItem, x as TreeView, v as flattenTree };