@xenide-io/the-old-ui-theme 0.2.6 → 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 (126) hide show
  1. package/README.md +1 -1
  2. package/dist/chunk-FDMD3IIN.mjs +3831 -0
  3. package/dist/index-D1RTT2Ap.d.mts +1044 -0
  4. package/dist/index-D1RTT2Ap.d.ts +1044 -0
  5. package/dist/index.d.mts +11 -758
  6. package/dist/index.d.ts +11 -758
  7. package/dist/index.js +1749 -768
  8. package/dist/index.mjs +312 -2846
  9. package/dist/tailwind-preset.js +7 -0
  10. package/dist/tailwind-preset.mjs +7 -0
  11. package/dist/ui.d.mts +4 -0
  12. package/dist/ui.d.ts +4 -0
  13. package/dist/ui.js +3864 -0
  14. package/dist/ui.mjs +169 -0
  15. package/package.json +28 -6
  16. package/src/app/globals.css +1005 -227
  17. package/src/components/charts/index.ts +8 -0
  18. package/src/components/charts/ph-insight-charts.tsx +162 -0
  19. package/src/components/dashboard/DashboardFiltersBar.tsx +19 -0
  20. package/src/components/dashboard/DashboardGrid.tsx +23 -0
  21. package/src/components/dashboard/DashboardInsightPlaceholder.tsx +37 -0
  22. package/src/components/dashboard/DashboardKpiCard.tsx +25 -0
  23. package/src/components/dashboard/DashboardToolbar.tsx +23 -0
  24. package/src/components/dashboard/DashboardWell.tsx +10 -0
  25. package/src/components/dashboard/InsightMiniCard.tsx +26 -0
  26. package/src/components/dashboard/InsightShell.tsx +37 -0
  27. package/src/components/dashboard/InsightShellHeader.tsx +22 -0
  28. package/src/components/dashboard/MiniTrendBars.tsx +51 -0
  29. package/src/components/dashboard/index.ts +31 -0
  30. package/src/components/dashboard/types.ts +9 -0
  31. package/src/components/icons/IconBase.tsx +47 -0
  32. package/src/components/icons/createIconBase.tsx +32 -0
  33. package/src/components/icons/icons.tsx +557 -0
  34. package/src/components/icons/index.ts +3 -0
  35. package/src/components/sections/AccordionShowcase.tsx +45 -0
  36. package/src/components/sections/AlertShowcase.tsx +40 -0
  37. package/src/components/sections/AvatarShowcase.tsx +80 -0
  38. package/src/components/sections/BadgeShowcase.tsx +65 -0
  39. package/src/components/sections/ButtonShowcase.tsx +308 -0
  40. package/src/components/sections/CalendarShowcase.tsx +35 -0
  41. package/src/components/sections/CardShowcase.tsx +159 -0
  42. package/src/components/sections/ChartShowcase.tsx +190 -0
  43. package/src/components/sections/CodeMockupShowcase.tsx +56 -0
  44. package/src/components/sections/ColorPalette.tsx +117 -0
  45. package/src/components/sections/CommandPaletteShowcase.tsx +48 -0
  46. package/src/components/sections/CountdownShowcase.tsx +43 -0
  47. package/src/components/sections/DashboardShowcase.tsx +191 -0
  48. package/src/components/sections/DiffShowcase.tsx +70 -0
  49. package/src/components/sections/DrawerShowcase.tsx +97 -0
  50. package/src/components/sections/DropdownShowcase.tsx +98 -0
  51. package/src/components/sections/EmptyStateShowcase.tsx +50 -0
  52. package/src/components/sections/FilterChipsShowcase.tsx +98 -0
  53. package/src/components/sections/FormShowcase.tsx +127 -0
  54. package/src/components/sections/HoverCardShowcase.tsx +50 -0
  55. package/src/components/sections/IconShowcase.tsx +127 -0
  56. package/src/components/sections/IndicatorShowcase.tsx +52 -0
  57. package/src/components/sections/KbdShowcase.tsx +57 -0
  58. package/src/components/sections/ModalShowcase.tsx +211 -0
  59. package/src/components/sections/NavigationShowcase.tsx +199 -0
  60. package/src/components/sections/ProductLayoutsShowcase.tsx +138 -0
  61. package/src/components/sections/ProgressShowcase.tsx +82 -0
  62. package/src/components/sections/SegmentedControlShowcase.tsx +49 -0
  63. package/src/components/sections/SetupThemeShowcase.tsx +262 -0
  64. package/src/components/sections/StackShowcase.tsx +33 -0
  65. package/src/components/sections/StatShowcase.tsx +129 -0
  66. package/src/components/sections/StepperShowcase.tsx +37 -0
  67. package/src/components/sections/SwapShowcase.tsx +99 -0
  68. package/src/components/sections/TabShowcase.tsx +84 -0
  69. package/src/components/sections/TableShowcase.tsx +140 -0
  70. package/src/components/sections/TimelineShowcase.tsx +83 -0
  71. package/src/components/sections/ToastShowcase.tsx +108 -0
  72. package/src/components/sections/TooltipShowcase.tsx +44 -0
  73. package/src/components/sections/UtilityShowcase.tsx +81 -0
  74. package/src/components/ui/Accordion.tsx +77 -0
  75. package/src/components/ui/Alert.tsx +77 -0
  76. package/src/components/ui/AuthLayout.tsx +58 -0
  77. package/src/components/ui/Avatar.tsx +97 -0
  78. package/src/components/ui/Badge.tsx +60 -0
  79. package/src/components/ui/Button.tsx +120 -0
  80. package/src/components/ui/ButtonChrome.tsx +20 -0
  81. package/src/components/ui/Calendar.tsx +115 -0
  82. package/src/components/ui/Card.tsx +70 -0
  83. package/src/components/ui/ChatBubble.tsx +71 -0
  84. package/src/components/ui/CodeBlock.tsx +48 -0
  85. package/src/components/ui/CollapsibleSection.tsx +49 -0
  86. package/src/components/ui/CommandPalette.tsx +137 -0
  87. package/src/components/ui/ComponentDocs.tsx +52 -0
  88. package/src/components/ui/Drawer.tsx +71 -0
  89. package/src/components/ui/DropdownMenu.tsx +262 -0
  90. package/src/components/ui/EmptyState.tsx +33 -0
  91. package/src/components/ui/FilterBar.tsx +165 -0
  92. package/src/components/ui/FilterChips.tsx +80 -0
  93. package/src/components/ui/FilterControls.tsx +30 -0
  94. package/src/components/ui/FormField.tsx +69 -0
  95. package/src/components/ui/HoverCard.tsx +36 -0
  96. package/src/components/ui/Indicator.tsx +61 -0
  97. package/src/components/ui/Input.tsx +385 -0
  98. package/src/components/ui/Kbd.tsx +113 -0
  99. package/src/components/ui/Loader.tsx +96 -0
  100. package/src/components/ui/Modal.tsx +105 -0
  101. package/src/components/ui/Navigation.tsx +94 -0
  102. package/src/components/ui/Panel.tsx +18 -0
  103. package/src/components/ui/Progress.tsx +59 -0
  104. package/src/components/ui/Rating.tsx +65 -0
  105. package/src/components/ui/SearchInput.tsx +106 -0
  106. package/src/components/ui/SegmentedControl.tsx +44 -0
  107. package/src/components/ui/SettingsLayout.tsx +94 -0
  108. package/src/components/ui/ShowcaseWrapper.tsx +124 -0
  109. package/src/components/ui/Stat.tsx +39 -0
  110. package/src/components/ui/Stepper.tsx +74 -0
  111. package/src/components/ui/Table.tsx +55 -0
  112. package/src/components/ui/Tabs.tsx +53 -0
  113. package/src/components/ui/Terminal.tsx +54 -0
  114. package/src/components/ui/ThemeDomSync.tsx +17 -0
  115. package/src/components/ui/ThemeManager.tsx +18 -0
  116. package/src/components/ui/ThemeSwitcher.tsx +46 -0
  117. package/src/components/ui/Timeline.tsx +60 -0
  118. package/src/components/ui/Toast.tsx +70 -0
  119. package/src/components/ui/Typography.tsx +129 -0
  120. package/src/components/ui/first-slice.test.tsx +98 -0
  121. package/src/components/ui/index.ts +151 -0
  122. package/src/components/ui/interaction-primitives.test.tsx +77 -0
  123. package/src/components/ui/kbd-icons.test.tsx +90 -0
  124. package/src/components/ui/product-patterns.test.tsx +77 -0
  125. package/src/styles/themes.css +528 -0
  126. package/tailwind-preset.ts +7 -0
@@ -0,0 +1,3831 @@
1
+ import {
2
+ __objRest,
3
+ __spreadProps,
4
+ __spreadValues
5
+ } from "./chunk-FWCSY2DS.mjs";
6
+
7
+ // src/components/ui/Button.tsx
8
+ import { forwardRef } from "react";
9
+
10
+ // src/components/ui/ButtonChrome.tsx
11
+ import { jsx, jsxs } from "react/jsx-runtime";
12
+ function ButtonChrome({ label, icon, sideIcon, split }) {
13
+ return /* @__PURE__ */ jsxs("span", { className: "ph-btn-chrome", children: [
14
+ icon != null ? /* @__PURE__ */ jsx("span", { className: "ph-btn-icon", children: icon }) : null,
15
+ label != null ? /* @__PURE__ */ jsx("span", { className: "ph-btn-label", children: label }) : null,
16
+ split ? /* @__PURE__ */ jsx("span", { className: "ph-btn-split-divider", "aria-hidden": true }) : null,
17
+ sideIcon != null ? /* @__PURE__ */ jsx("span", { className: "ph-btn-side-icon", children: sideIcon }) : null
18
+ ] });
19
+ }
20
+
21
+ // src/lib/cn.ts
22
+ function cn(...parts) {
23
+ return parts.filter(Boolean).join(" ");
24
+ }
25
+
26
+ // src/components/ui/Button.tsx
27
+ import { Fragment, jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
28
+ var variantClass = {
29
+ primary: "ph-btn-primary",
30
+ secondary: "ph-btn-secondary",
31
+ tertiary: "ph-btn-tertiary",
32
+ signal: "ph-btn-signal",
33
+ accent: "ph-btn-accent",
34
+ neutral: "ph-btn-neutral",
35
+ info: "ph-btn-info",
36
+ success: "ph-btn-success",
37
+ warning: "ph-btn-warning",
38
+ danger: "ph-btn-danger",
39
+ ghost: "ph-btn-ghost",
40
+ link: "ph-btn-link"
41
+ };
42
+ var sizeClass = {
43
+ xs: "ph-btn-xs",
44
+ sm: "ph-btn-sm",
45
+ md: "",
46
+ lg: "ph-btn-lg"
47
+ };
48
+ var shapeClass = {
49
+ default: "",
50
+ circle: "ph-btn-circle",
51
+ square: "ph-btn-square",
52
+ wide: "ph-btn-wide"
53
+ };
54
+ var Button = forwardRef(function Button2(_a, ref) {
55
+ var _b = _a, {
56
+ variant = "secondary",
57
+ size = "md",
58
+ shape = "default",
59
+ outline = false,
60
+ split = false,
61
+ icon,
62
+ sideIcon,
63
+ loading = false,
64
+ loadingLabel,
65
+ className,
66
+ children,
67
+ type = "button",
68
+ disabled
69
+ } = _b, props = __objRest(_b, [
70
+ "variant",
71
+ "size",
72
+ "shape",
73
+ "outline",
74
+ "split",
75
+ "icon",
76
+ "sideIcon",
77
+ "loading",
78
+ "loadingLabel",
79
+ "className",
80
+ "children",
81
+ "type",
82
+ "disabled"
83
+ ]);
84
+ const usesLemonChrome = !["tertiary", "ghost", "link"].includes(variant);
85
+ const label = loadingLabel != null ? loadingLabel : children;
86
+ const leadingIcon = loading ? /* @__PURE__ */ jsx2("span", { className: "ph-btn-spinner", "aria-hidden": true }) : icon;
87
+ const content = usesLemonChrome ? /* @__PURE__ */ jsx2(ButtonChrome, { label, icon: leadingIcon, sideIcon, split }) : /* @__PURE__ */ jsxs2(Fragment, { children: [
88
+ leadingIcon != null ? /* @__PURE__ */ jsx2("span", { className: "ph-btn-icon", children: leadingIcon }) : null,
89
+ label != null ? /* @__PURE__ */ jsx2("span", { className: "ph-btn-label", children: label }) : null,
90
+ split ? /* @__PURE__ */ jsx2("span", { className: "ph-btn-split-divider", "aria-hidden": true }) : null,
91
+ sideIcon != null ? /* @__PURE__ */ jsx2("span", { className: "ph-btn-side-icon", children: sideIcon }) : null
92
+ ] });
93
+ return /* @__PURE__ */ jsx2(
94
+ "button",
95
+ __spreadProps(__spreadValues({
96
+ ref,
97
+ type,
98
+ disabled: disabled || loading,
99
+ "aria-busy": loading || void 0,
100
+ className: cn(
101
+ "ph-btn",
102
+ usesLemonChrome && "ph-btn-raised",
103
+ outline && "ph-btn-outline",
104
+ variantClass[variant],
105
+ sizeClass[size],
106
+ shapeClass[shape],
107
+ split && "ph-btn-split",
108
+ className
109
+ )
110
+ }, props), {
111
+ children: content
112
+ })
113
+ );
114
+ });
115
+ Button.displayName = "Button";
116
+
117
+ // src/components/ui/Alert.tsx
118
+ import { forwardRef as forwardRef5 } from "react";
119
+
120
+ // src/components/icons/IconBase.tsx
121
+ import { forwardRef as forwardRef2 } from "react";
122
+ import { jsx as jsx3 } from "react/jsx-runtime";
123
+ var IconBase = forwardRef2(function IconBase2(_a, ref) {
124
+ var _b = _a, {
125
+ className,
126
+ size,
127
+ children,
128
+ viewBox = "0 0 24 24",
129
+ fill: fill2 = "none",
130
+ xmlns = "http://www.w3.org/2000/svg",
131
+ focusable = "false",
132
+ style,
133
+ role,
134
+ "aria-hidden": ariaHidden,
135
+ "aria-label": ariaLabel,
136
+ "aria-labelledby": ariaLabelledBy
137
+ } = _b, props = __objRest(_b, [
138
+ "className",
139
+ "size",
140
+ "children",
141
+ "viewBox",
142
+ "fill",
143
+ "xmlns",
144
+ "focusable",
145
+ "style",
146
+ "role",
147
+ "aria-hidden",
148
+ "aria-label",
149
+ "aria-labelledby"
150
+ ]);
151
+ const hasAccessibleName = Boolean(ariaLabel || ariaLabelledBy);
152
+ return /* @__PURE__ */ jsx3(
153
+ "svg",
154
+ __spreadProps(__spreadValues({
155
+ ref,
156
+ className: cn("ph-icon", className),
157
+ viewBox,
158
+ fill: fill2,
159
+ xmlns,
160
+ focusable,
161
+ role: role != null ? role : hasAccessibleName ? "img" : void 0,
162
+ "aria-hidden": ariaHidden != null ? ariaHidden : hasAccessibleName ? void 0 : true,
163
+ "aria-label": ariaLabel,
164
+ "aria-labelledby": ariaLabelledBy,
165
+ style: __spreadValues({ width: size, height: size }, style)
166
+ }, props), {
167
+ children
168
+ })
169
+ );
170
+ });
171
+ IconBase.displayName = "IconBase";
172
+
173
+ // src/components/icons/createIconBase.tsx
174
+ import { forwardRef as forwardRef3 } from "react";
175
+ import { jsx as jsx4 } from "react/jsx-runtime";
176
+ function createIconBase({ name = "IconGlyph", viewBox = "0 0 24 24", paths }) {
177
+ const IconGlyph = forwardRef3(function IconGlyph2(props, ref) {
178
+ return /* @__PURE__ */ jsx4(IconBase, __spreadProps(__spreadValues({ ref, viewBox }, props), { children: paths }));
179
+ });
180
+ IconGlyph.displayName = name;
181
+ return IconGlyph;
182
+ }
183
+ function createIconBasePath(d, viewBox = "0 0 24 24", name) {
184
+ return createIconBase({
185
+ name,
186
+ viewBox,
187
+ paths: /* @__PURE__ */ jsx4("path", { d, fill: "currentColor" })
188
+ });
189
+ }
190
+
191
+ // src/components/icons/icons.tsx
192
+ import { forwardRef as forwardRef4 } from "react";
193
+ import { Fragment as Fragment2, jsx as jsx5, jsxs as jsxs3 } from "react/jsx-runtime";
194
+ var fill = (d) => /* @__PURE__ */ jsx5("path", { d, fill: "currentColor" });
195
+ var IconAreaChart = createIconBase({
196
+ paths: fill("M3 20V7l4 3 5-7 5 4h4v13Zm5-3 4-5.5 7 5.45V9h-2.7l-3.9-3.125-4.95 6.95L5 11v3.6Z")
197
+ });
198
+ var IconCumulativeChart = createIconBase({
199
+ paths: fill(
200
+ "M20.8805 7.97408C15.0614 18.7809 6.51281 19.5979 2.71265 18.4578L3.28734 16.5422C6.15384 17.4021 13.7386 17.0191 19.1195 7.02588L20.8805 7.97408Z"
201
+ )
202
+ });
203
+ var IconTableChart = createIconBase({
204
+ paths: fill(
205
+ "M20 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h15c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 2v3H5V5h15zm-5 14h-5v-9h5v9zM5 10h3v9H5v-9zm12 9v-9h3v9h-3z"
206
+ )
207
+ });
208
+ var IconHandClick = createIconBase({
209
+ viewBox: "0 0 18 18",
210
+ paths: fill(
211
+ "M14.9942 7.90164C14.9942 7.82992 14.9583 7.46993 14.6342 7.10993C14.2925 6.71407 13.7524 6.49822 13.05 6.44407C12.9783 6.33579 12.8883 6.22822 12.7442 6.11993C12.3483 5.81407 11.7359 5.65164 10.9442 5.63407C10.8724 5.54407 10.7459 5.43578 10.6024 5.32822C10.2425 5.0765 9.79245 4.93236 9.23416 4.87822V3.41993C9.23416 3.27579 9.25244 2.66407 8.83831 2.23164C8.65831 2.03335 8.31659 1.79993 7.74002 1.79993C7.14587 1.79993 6.80416 2.03407 6.60587 2.23164C6.22759 2.64578 6.22759 3.18578 6.22759 3.31164V8.46C5.88587 8.1 5.50759 7.70414 5.29173 7.56C4.84173 7.21829 3.99587 7.39828 3.51002 7.75829C3.04173 8.1 2.88002 8.62243 3.06002 9.12658C3.38416 10.0266 4.19416 10.9266 4.39173 11.1424C4.57173 11.4841 5.38173 12.9782 6.10173 13.5182C6.48002 13.8065 6.76759 14.9941 6.84002 15.7499L6.87588 16.1457H13.6801V14.364C13.7701 14.1123 13.9859 13.5723 14.2201 13.3199C14.7783 12.7616 14.9583 11.3582 14.9583 10.9257V7.91986L14.9942 7.90164ZM14.1117 10.89C14.1117 11.4117 13.8959 12.4017 13.6259 12.6717C13.1576 13.14 12.87 14.04 12.8517 14.13L12.8335 14.1841V15.2283H7.68583C7.64997 15.03 7.61411 14.7783 7.54169 14.5083C7.32583 13.6441 7.03754 13.0866 6.65998 12.7983C6.13826 12.4024 5.39998 11.1241 5.16583 10.6566L5.09411 10.5484C5.09411 10.5301 4.2124 9.63008 3.90582 8.80251C3.86996 8.69423 3.86996 8.60422 3.99582 8.47836C4.22997 8.26251 4.67997 8.20836 4.78754 8.24422C5.05754 8.46008 5.88582 9.34251 6.35339 9.86422L7.12754 10.7284L7.12824 3.29418V3.25762C7.12824 3.1859 7.14652 2.95176 7.27238 2.82591C7.36238 2.71763 7.52409 2.66419 7.75824 2.66419C7.95652 2.66419 8.09995 2.71833 8.20824 2.80833C8.35238 2.97005 8.36996 3.25833 8.36996 3.36662V8.02826H9.25167V5.7599C10.0617 5.8499 10.2958 6.19161 10.3317 6.24575L10.3675 6.33575V8.02747H11.2492V6.53332C12.0051 6.60504 12.2934 6.83918 12.3651 6.94747V8.65747H13.2468V7.34332C14.021 7.4516 14.1468 7.86504 14.1651 7.95504L14.1658 10.8899L14.1117 10.89Z"
212
+ )
213
+ });
214
+ var IconSurveys = createIconBase({
215
+ paths: fill(
216
+ "M20 2H4c-1.1 0-1.99.9-1.99 2L2 22l4-4h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2zm0 14H5.17l-.59.59-.58.58V4h16v12zm-9.5-2H18v-2h-5.5zm3.86-5.87c.2-.2.2-.51 0-.71l-1.77-1.77c-.2-.2-.51-.2-.71 0L6 11.53V14h2.47l5.89-5.87z"
217
+ )
218
+ });
219
+ var IconCohort = createIconBase({
220
+ paths: fill(
221
+ "m4 13c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm1.13 1.1c-.37-.06-.74-.1-1.13-.1-.99 0-1.93.21-2.78.58-.74.32-1.22 1.04-1.22 1.85v1.57h4.5v-1.61c0-.83.23-1.61.63-2.29zm14.87-1.1c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm4 3.43c0-.81-.48-1.53-1.22-1.85-.85-.37-1.79-.58-2.78-.58-.39 0-.76.04-1.13.1.4.68.63 1.46.63 2.29v1.61h4.5zm-7.76-2.78c-1.17-.52-2.61-.9-4.24-.9s-3.07.39-4.24.9c-1.08.48-1.76 1.56-1.76 2.74v1.61h12v-1.61c0-1.18-.68-2.26-1.76-2.74zm-8.17 2.35c.09-.23.13-.39.91-.69.97-.38 1.99-.56 3.02-.56s2.05.18 3.02.56c.77.3.81.46.91.69zm3.93-8c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm0-2c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z"
222
+ )
223
+ });
224
+ var IconRecording = createIconBase({
225
+ paths: fill(
226
+ "m10 8v8l5-4zm9-5h-14c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-14c0-1.1-.9-2-2-2zm0 16h-14v-14h14z"
227
+ )
228
+ });
229
+ var IconFlare = createIconBase({
230
+ paths: fill(
231
+ "m7 11h-6v2h6zm2.17-3.24-2.12-2.12-1.41 1.41 2.12 2.12zm3.83-6.76h-2v6h2zm5.36 6.05-1.41-1.41-2.12 2.12 1.41 1.41zm-1.36 3.95v2h6v-2zm-5-2c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3zm2.83 7.24 2.12 2.12 1.41-1.41-2.12-2.12zm-9.19.71 1.41 1.41 2.12-2.12-1.41-1.41zm5.36 6.05h2v-6h-2z"
232
+ )
233
+ });
234
+ var IconSelectEvents = createIconBase({
235
+ paths: /* @__PURE__ */ jsxs3(Fragment2, { children: [
236
+ fill("M17.5 9L16.56 6.94L14.5 6L16.56 5.06L17.5 3L18.44 5.06L20.5 6L18.44 6.94L17.5 9Z"),
237
+ fill("M6 12.5L6.94 14.56L9 15.5L6.94 16.44L6 18.5L5.06 16.44L3 15.5L5.06 14.56L6 12.5Z"),
238
+ fill("M6 9L5.06 6.94L3 6L5.06 5.06L6 3L6.94 5.06L9 6L6.94 6.94L6 9Z"),
239
+ fill("M16.23 14.26L20 13L10 10L13 20L14.26 16.23L18.53 20.5L20.51 18.52L16.23 14.26Z")
240
+ ] })
241
+ });
242
+ var IconClipboardEdit = createIconBase({
243
+ paths: fill(
244
+ "M21.04 12.13C21.18 12.13 21.31 12.19 21.42 12.3L22.7 13.58C22.92 13.79 22.92 14.14 22.7 14.35L21.7 15.35L19.65 13.3L20.65 12.3C20.76 12.19 20.9 12.13 21.04 12.13M19.07 13.88L21.12 15.93L15.06 22H13V19.94L19.07 13.88M11 19L9 21H5C3.9 21 3 20.1 3 19V5C3 3.9 3.9 3 5 3H9.18C9.6 1.84 10.7 1 12 1C13.3 1 14.4 1.84 14.82 3H19C20.1 3 21 3.9 21 5V9L19 11V5H17V7H7V5H5V19H11M12 3C11.45 3 11 3.45 11 4C11 4.55 11.45 5 12 5C12.55 5 13 4.55 13 4C13 3.45 12.55 3 12 3Z"
245
+ )
246
+ });
247
+ var IconQueryEditor = createIconBase({
248
+ paths: fill(
249
+ "M4,14V17C4,19 7.05,20.72 11,21V18.11L11.13,18C7.12,17.76 4,16.06 4,14M12,13C7.58,13 4,11.21 4,9V12C4,14.21 7.58,16 12,16C12.39,16 12.77,16 13.16,16L17,12.12C15.4,12.72 13.71,13 12,13M12,3C7.58,3 4,4.79 4,7C4,9.21 7.58,11 12,11C16.42,11 20,9.21 20,7C20,4.79 16.42,3 12,3M21,11.13C20.85,11.13 20.71,11.19 20.61,11.3L19.61,12.3L21.66,14.3L22.66,13.3C22.87,13.1 22.88,12.76 22.66,12.53L21.42,11.3C21.32,11.19 21.18,11.13 21.04,11.13M19.04,12.88L13,18.94V21H15.06L21.12,14.93L19.04,12.88Z"
250
+ )
251
+ });
252
+ var IconTuning = createIconBase({
253
+ paths: fill(
254
+ "M3,17V19H9V17H3M3,5V7H13V5H3M13,21V19H21V17H13V15H11V21H13M7,9V11H3V13H7V15H9V9H7M21,13V11H11V13H21M15,9H17V7H21V5H17V3H15V9Z"
255
+ )
256
+ });
257
+ var IconSync = createIconBase({
258
+ paths: fill(
259
+ "m12.5 4v-3l-4 4 4 4v-3c3.31 0 6 2.69 6 6 0 1.01-.25 1.97-.7 2.8l1.46 1.46c.78-1.23 1.24-2.69 1.24-4.26 0-4.42-3.58-8-8-8zm0 14c-3.31 0-6-2.69-6-6 0-1.01.25-1.97.7-2.8l-1.46-1.46c-.78 1.23-1.24 2.69-1.24 4.26 0 4.42 3.58 8 8 8v3l4-4-4-4z"
260
+ )
261
+ });
262
+ var IconPlayCircle = createIconBase({
263
+ paths: fill(
264
+ "M12 2C6.48 2 2 6.48 2 12C2 17.52 6.48 22 12 22C17.52 22 22 17.52 22 12C22 6.48 17.52 2 12 2ZM12 20C7.59 20 4 16.41 4 12C4 7.59 7.59 4 12 4C16.41 4 20 7.59 20 12C20 16.41 16.41 20 12 20ZM9.5 16.5L16.5 12L9.5 7.5V16.5Z"
265
+ )
266
+ });
267
+ var IconGridView = createIconBase({
268
+ paths: fill("M3 3v8h8V3H3zm6 6H5V5h4v4zm-6 4v8h8v-8H3zm6 6H5v-4h4v4zm4-16v8h8V3h-8zm6 6h-4V5h4v4zm-6 4v8h8v-8h-8zm6 6h-4v-4h4v4z")
269
+ });
270
+ var IconListView = createIconBase({
271
+ paths: fill(
272
+ "M3,5v14h18V5H3z M7,7v2H5V7H7z M5,13v-2h2v2H5z M5,15h2v2H5V15z M19,17H9v-2h10V17z M19,13H9v-2h10V13z M19,9H9V7h10V9z"
273
+ )
274
+ });
275
+ var IconPremium = createIconBase({
276
+ paths: fill(
277
+ "m9.68 13.69 2.32-1.76 2.31 1.76-.88-2.85 2.32-1.84h-2.84l-.91-2.81-.91 2.81h-2.84l2.31 1.84zm10.32-3.69c0-4.42-3.58-8-8-8s-8 3.58-8 8c0 2.03.76 3.87 2 5.28v7.72l6-2 6 2v-7.72c1.24-1.41 2-3.25 2-5.28zm-8-6c3.31 0 6 2.69 6 6s-2.69 6-6 6-6-2.69-6-6 2.69-6 6-6zm0 15-4 1.02v-3.1c1.18.68 2.54 1.08 4 1.08s2.82-.4 4-1.08v3.1z"
278
+ )
279
+ });
280
+ var IconGift = createIconBase({
281
+ paths: fill(
282
+ "M14.4495 4.55495C15.264 4.31223 15.8631 4.48426 16.1 4.80007C16.4013 5.20182 16.4765 5.57305 16.4336 5.91424C16.3888 6.27088 16.2084 6.63998 15.9211 7.00139C15.3397 7.73275 14.4193 8.30877 13.8244 8.53186C13.598 8.61674 13.4648 8.85138 13.508 9.08924C13.5511 9.32709 13.7582 9.50002 13.9999 9.50002L19.4999 9.50002V12.5H17.9999C17.7237 12.5 17.4999 12.7239 17.4999 13V20.5H6.49988V14.5C6.49988 14.2239 6.27602 14 5.99988 14C5.72374 14 5.49988 14.2239 5.49988 14.5V21C5.49988 21.2762 5.72374 21.5 5.99988 21.5H17.9999C18.276 21.5 18.4999 21.2762 18.4999 21V13.5H19.9999C20.276 13.5 20.4999 13.2762 20.4999 13V9.00002C20.4999 8.86741 20.4472 8.74023 20.3534 8.64646C20.2597 8.5527 20.1325 8.50002 19.9999 8.50002L15.8202 8.50002C16.1407 8.24235 16.4465 7.94742 16.7039 7.62365C17.0625 7.17257 17.3508 6.63541 17.4258 6.03894C17.5027 5.42702 17.3487 4.79826 16.8999 4.20003C16.2882 3.3845 15.1373 3.30652 14.1639 3.5966C13.3806 3.83005 12.5842 4.3279 12.0008 5.07014C11.4285 4.33982 10.6586 3.86464 9.88727 3.64427C8.91382 3.36616 7.82238 3.47045 7.14633 4.14645C6.65753 4.63523 6.41235 5.18234 6.41347 5.75925C6.41457 6.32144 6.64952 6.84016 6.97799 7.28883C7.30058 7.72946 7.7389 8.13769 8.22434 8.50002L3.99988 8.50002C3.86727 8.50002 3.74009 8.5527 3.64632 8.64646C3.55256 8.74023 3.49988 8.86741 3.49988 9.00002V13C3.49988 13.2762 3.72374 13.5 3.99988 13.5H15.4999C15.776 13.5 15.9999 13.2762 15.9999 13C15.9999 12.7239 15.776 12.5 15.4999 12.5H4.49988V9.50002L9.99995 9.50002C10.2318 9.50002 10.4333 9.34058 10.4866 9.1149C10.5398 8.88921 10.431 8.65651 10.2236 8.55281C9.25206 8.06706 8.29723 7.39797 7.78487 6.69811C7.53216 6.35292 7.41402 6.03722 7.41347 5.7573C7.41295 5.49209 7.51758 5.1894 7.85342 4.85358C8.17738 4.52964 8.83597 4.38393 9.61256 4.6058C10.3657 4.82096 11.1212 5.36045 11.5528 6.22359C11.6375 6.39298 11.8106 6.49997 12 6.49997C12.1894 6.49997 12.3625 6.39297 12.4472 6.22358C12.8783 5.36141 13.672 4.78667 14.4495 4.55495Z"
283
+ )
284
+ });
285
+ var IconRobot = createIconBase({
286
+ paths: fill(
287
+ "M17.5 15.5C17.5 16.61 16.61 17.5 15.5 17.5S13.5 16.61 13.5 15.5 14.4 13.5 15.5 13.5 17.5 14.4 17.5 15.5M8.5 13.5C7.4 13.5 6.5 14.4 6.5 15.5S7.4 17.5 8.5 17.5 10.5 16.61 10.5 15.5 9.61 13.5 8.5 13.5M23 15V18C23 18.55 22.55 19 22 19H21V20C21 21.11 20.11 22 19 22H5C3.9 22 3 21.11 3 20V19H2C1.45 19 1 18.55 1 18V15C1 14.45 1.45 14 2 14H3C3 10.13 6.13 7 10 7H11V5.73C10.4 5.39 10 4.74 10 4C10 2.9 10.9 2 12 2S14 2.9 14 4C14 4.74 13.6 5.39 13 5.73V7H14C17.87 7 21 10.13 21 14H22C22.55 14 23 14.45 23 15M21 16H19V14C19 11.24 16.76 9 14 9H10C7.24 9 5 11.24 5 14V16H3V17H5V20H19V17H21V16Z"
288
+ )
289
+ });
290
+ var IconExclamation = createIconBase({
291
+ paths: /* @__PURE__ */ jsxs3("g", { fill: "currentColor", children: [
292
+ /* @__PURE__ */ jsx5("path", { d: "m12 21c1.1046 0 2-.8954 2-2s-.8954-2-2-2-2 .8954-2 2 .8954 2 2 2z" }),
293
+ /* @__PURE__ */ jsx5("path", { d: "m10 3h4v12h-4z" })
294
+ ] })
295
+ });
296
+ var IconErrorOutline = createIconBase({
297
+ paths: fill(
298
+ "m11 15h2v2h-2zm0-8h2v6h-2zm.99-5c-5.52 0-9.99 4.48-9.99 10s4.47 10 9.99 10c5.53 0 10.01-4.48 10.01-10s-4.48-10-10.01-10zm.01 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"
299
+ )
300
+ });
301
+ var IconInfo = createIconBase({
302
+ name: "IconInfo",
303
+ paths: fill(
304
+ "M11 10h2v7h-2v-7zm0-3h2v2h-2V7zm1-5C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"
305
+ )
306
+ });
307
+ var IconCancel = createIconBase({
308
+ paths: fill(
309
+ "m12 2c-5.53 0-10 4.47-10 10s4.47 10 10 10 10-4.47 10-10-4.47-10-10-10zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8zm3.59-13-3.59 3.59-3.59-3.59-1.41 1.41 3.59 3.59-3.59 3.59 1.41 1.41 3.59-3.59 3.59 3.59 1.41-1.41-3.59-3.59 3.59-3.59z"
310
+ )
311
+ });
312
+ var IconCheckCircle = createIconBase({
313
+ paths: fill(
314
+ "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 15l-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"
315
+ )
316
+ });
317
+ var IconArrowUp = createIconBase({
318
+ paths: fill("M4 12l1.41 1.41L11 7.83V20h2V7.83l5.58 5.59L20 12l-8-8-8 8z")
319
+ });
320
+ var IconArrowDown = createIconBase({
321
+ paths: fill("M20 12l-1.41-1.41L13 16.17V4h-2v12.17l-5.58-5.59L4 12l8 8 8-8z")
322
+ });
323
+ var IconChevronLeft = createIconBasePath("M15.41 7.41L14 6l-6 6 6 6 1.41-1.41L10.83 12z");
324
+ var IconChevronRight = createIconBasePath("M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z");
325
+ var IconChevronDown = createIconBasePath("M7.41 8.59L12 13.17l4.59-4.58L18 10l-6 6-6-6 1.41-1.41z");
326
+ var IconSubArrowRight = createIconBase({
327
+ paths: /* @__PURE__ */ jsx5("g", { transform: "translate(4 5.5)", children: fill("M2 0H0V10H12.01V13L16 9L12.01 5V8H2V0Z") })
328
+ });
329
+ var IconSearch = createIconBasePath(
330
+ "M15.5 14h-.79l-.28-.27A6.471 6.471 0 0 0 16 9.5 6.5 6.5 0 1 0 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19l-4.99-5zm-6 0C7.01 14 5 11.99 5 9.5S7.01 5 9.5 5 14 7.01 14 9.5 11.99 14 9.5 14z"
331
+ );
332
+ var IconBell = createIconBasePath(
333
+ "M12 22c1.1 0 2-.9 2-2h-4c0 1.1.89 2 2 2m6-6v-5c0-3.07-1.64-5.64-4.5-6.32V4c0-.83-.67-1.5-1.5-1.5s-1.5.67-1.5 1.5v.68C7.63 5.36 6 7.92 6 11v5l-2 2v1h16v-1z"
334
+ );
335
+ var IconBellOff = createIconBasePath(
336
+ "M20 18.69 7.84 6.14 5.27 3.49 4 4.76l2.8 2.8v.01c-.52.99-.8 2.16-.8 3.42v5l-2 2v1h13.73l2 2L21 19.72zM12 22c1.11 0 2-.89 2-2h-4c0 1.11.89 2 2 2m6-7.32V11c0-3.08-1.64-5.64-4.5-6.32V4c0-.83-.67-1.5-1.5-1.5s-1.5.67-1.5 1.5v.68c-.15.03-.29.08-.42.12-.1.03-.2.07-.3.11h-.01c-.01 0-.01 0-.02.01-.23.09-.46.2-.68.31 0 0-.01 0-.01.01z"
337
+ );
338
+ var IconPerson = createIconBasePath(
339
+ "M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z"
340
+ );
341
+ var IconHome = createIconBasePath("M10 20v-6h4v6h5v-8h3L12 3 2 12h3v8z");
342
+ var IconPanelRight = createIconBasePath(
343
+ "M3 5v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2zm12 4h-5v10h5V9zm-7 0H5v10h3V9z"
344
+ );
345
+ var IconPlus = createIconBasePath("M19 13h-6v6h-2v-6H5v-2h6V5h2v6h6v2z");
346
+ var IconCheck = createIconBasePath("M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z");
347
+ var IconClose = createIconBasePath("M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z");
348
+ var IconTrash = createIconBasePath("M6 19c0 1.1.9 2 2 2h8c1.1 0 2-.9 2-2V7H6v12zM19 4h-3.5l-1-1h-5l-1 1H5v2h14V4z");
349
+ var IconDownload = createIconBasePath("M19 9h-4V3H9v6H5l7 7 7-7zM5 18v2h14v-2H5z");
350
+ var IconUpload = createIconBasePath("M9 16h6v-6h4l-7-7-7 7h4v6zm-4 2h14v2H5v-2z");
351
+ var IconSave = createIconBasePath(
352
+ "M17 3H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V7l-4-4zm-5 16c-1.66 0-3-1.34-3-3s1.34-3 3-3 3 1.34 3 3-1.34 3-3 3zm3-10H5V5h10v4z"
353
+ );
354
+ var IconCopy = createIconBasePath(
355
+ "M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm3 4H8c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h11c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2zm0 16H8V7h11v14z"
356
+ );
357
+ var IconEdit = createIconBasePath(
358
+ "M3 17.25V21h3.75L17.81 9.94l-3.75-3.75L3 17.25zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34c-.39-.39-1.02-.39-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83z"
359
+ );
360
+ var IconLogout = createIconBasePath(
361
+ "M17 7l-1.41 1.41L18.17 11H8v2h10.17l-2.58 2.59L17 17l5-5zM4 5h8V3H4c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h8v-2H4V5z"
362
+ );
363
+ var IconStar = createIconBasePath(
364
+ "M12 17.27L18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z"
365
+ );
366
+ var IconMail = createIconBasePath(
367
+ "M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4l-8 5-8-5V6l8 5 8-5v2z"
368
+ );
369
+ var IconShoppingCart = createIconBasePath(
370
+ "M7 18c-1.1 0-1.99.9-1.99 2S5.9 22 7 22s2-.9 2-2-.9-2-2-2zM1 2v2h2l3.6 7.59-1.35 2.45c-.16.28-.25.61-.25.96 0 1.1.9 2 2 2h12v-2H7.42c-.14 0-.25-.11-.25-.25l.03-.12.9-1.63h7.45c.75 0 1.41-.41 1.75-1.03l3.58-6.49c.08-.14.12-.31.12-.48 0-.55-.45-1-1-1H5.21l-.94-2H1zm16 16c-1.1 0-1.99.9-1.99 2s.89 2 1.99 2 2-.9 2-2-.9-2-2-2z"
371
+ );
372
+ var IconMoon = createIconBasePath(
373
+ "M12 3c-4.97 0-9 4.03-9 9s4.03 9 9 9 9-4.03 9-9c0-.46-.04-.92-.1-1.36-.98 1.37-2.58 2.26-4.4 2.26-2.98 0-5.4-2.42-5.4-5.4 0-1.81.89-3.42 2.26-4.4-.44-.06-.9-.1-1.36-.1z"
374
+ );
375
+ var IconSun = createIconBasePath(
376
+ "M6.76 4.84l-1.8-1.79-1.41 1.41 1.79 1.79 1.42-1.41zM4 10.5H1v2h3v-2zm9-9.95h-2V3.5h2V.55zm7.45 3.91l-1.41-1.41-1.79 1.79 1.41 1.41 1.79-1.79zm-3.21 13.7l1.79 1.8 1.41-1.41-1.8-1.79-1.4 1.4zM20 10.5v2h3v-2h-3zm-8-5c-3.31 0-6 2.69-6 6s2.69 6 6 6 6-2.69 6-6-2.69-6-6-6zm-1 16.95h2V19.5h-2v2.95zm-7.45-3.91l1.41 1.41 1.79-1.8-1.41-1.41-1.79 1.8z"
377
+ );
378
+ var IconVolume = createIconBasePath(
379
+ "M3 9v6h4l5 5V4L7 9H3zm13.5 3c0-1.77-1.02-3.29-2.5-4.03v8.05c1.48-.73 2.5-2.25 2.5-4.02zM14 3.23v2.06c2.89.86 5 3.54 5 6.71s-2.11 5.85-5 6.71v2.06c4.01-.91 7-4.49 7-8.77s-2.99-7.86-7-8.77z"
380
+ );
381
+ var IconVolumeOff = createIconBasePath(
382
+ "M16.5 12c0-1.77-1.02-3.29-2.5-4.03v2.21l2.45 2.45c.03-.2.05-.41.05-.63zm2.5 0c0 .94-.2 1.82-.54 2.64l1.51 1.51C20.63 14.91 21 13.5 21 12c0-4.28-2.99-7.86-7-8.77v2.06c2.89.86 5 3.54 5 6.71zM4.27 3L3 4.27 7.73 9H3v6h4l5 5v-6.73l4.25 4.25c-.67.52-1.42.93-2.25 1.18v2.06c1.38-.31 2.63-.95 3.69-1.81L19.73 21 21 19.73l-9-9L4.27 3zM12 4L9.91 6.09 12 8.18V4z"
383
+ );
384
+ var IconFlag = createIconBasePath("M14.4 6L14 4H5v17h2v-7h5.6l.4 2h7V6h-5.6z");
385
+ var IconDatabase = createIconBasePath(
386
+ "M12 3C7.58 3 4 4.79 4 7s3.58 4 8 4 8-1.79 8-4-3.58-4-8-4zM4 9v3c0 2.21 3.58 4 8 4s8-1.79 8-4V9c0 2.21-3.58 4-8 4s-8-1.79-8-4zm0 5v3c0 2.21 3.58 4 8 4s8-1.79 8-4v-3c0 2.21-3.58 4-8 4s-8-1.79-8-4z"
387
+ );
388
+ var IconLayers = createIconBasePath("M11.99 18.54l-7.37-5.73L3 14.07l9 7 9-7-1.63-1.27-7.38 5.74zM12 16l7.36-5.73L21 9l-9-7-9 7 1.63 1.27L12 16z");
389
+ var IconBox = createIconBasePath(
390
+ "M21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16z"
391
+ );
392
+ var IconBolt = createIconBasePath(
393
+ "M11 21h-1l1-7H7.5c-.58 0-.57-.32-.38-.66-.19-.34-.04-.12-.07-.12C8.48 10.94 10.42 7.54 11 7V3h1v4c.58 0 .57.32.38.66-.19-.34-.04-.12-.07-.12-.95 2.28-2.96 5.66-3.31 6.22H13l-1 7h-1z"
394
+ );
395
+ var IconRadar = createIconBasePath(
396
+ "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8zm-5.5-2.5l7.51-3.49L17.5 6.5 9.99 9.99 6.5 17.5zm5.5-6.6c.61 0 1.1.49 1.1 1.1s-.49 1.1-1.1 1.1-1.1-.49-1.1-1.1.49-1.1 1.1-1.1z"
397
+ );
398
+ var IconToggle = createIconBasePath(
399
+ "M17 7H7c-2.76 0-5 2.24-5 5s2.24 5 5 5h10c2.76 0 5-2.24 5-5s-2.24-5-5-5zm0 8H7c-1.66 0-3-1.34-3-3s1.34-3 3-3h10c1.66 0 3 1.34 3 3s-1.34 3-3 3zM7 10c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2z"
400
+ );
401
+ var IconRocket = createIconBasePath(
402
+ "M9.19 6.35c-2.04 2.29-3.44 5.58-3.57 5.89L2 10.69l4.05-4.05c.47-.47 1.15-.68 1.81-.55l1.33 1.26zm5.45 8.67l-1.33-1.26c-.66-.13-1.34.08-1.81.55L2 18.31l3.62 3.57c.31-.13 3.6-1.53 5.89-3.57 1.53-1.72 2.52-3.76 2.87-5.02zM12 2c-1.1 0-2 .9-2 2v1.09c2.84.48 5 2.94 5 5.91 0 2.97-2.16 5.43-5 5.91V20c0 1.1.9 2 2 2s2-.9 2-2v-1.09c-2.84-.48-5-2.94-5-5.91 0-2.97 2.16-5.43 5-5.91V4c0-1.1-.9-2-2-2z"
403
+ );
404
+ var IconTerminal = createIconBase({
405
+ name: "IconTerminal",
406
+ paths: /* @__PURE__ */ jsx5(
407
+ "path",
408
+ {
409
+ d: "M3 4v16h18V4H3zm2 2h14v12H5V6zm2 2.2L10.8 12 7 15.8 8.4 17.2l5.2-5.2-5.2-5.2L7 8.2zM13 17h5v-2h-5v2z",
410
+ fill: "currentColor",
411
+ fillRule: "evenodd",
412
+ clipRule: "evenodd"
413
+ }
414
+ )
415
+ });
416
+ var IconOldWindow = createIconBase({
417
+ name: "IconOldWindow",
418
+ paths: /* @__PURE__ */ jsx5(
419
+ "path",
420
+ {
421
+ d: "M3 3v18h18V3H3zm2 7v9h14v-9H5zm1-4h2v1H6V6zm3 0h2v1H9V6z",
422
+ fill: "currentColor",
423
+ fillRule: "evenodd",
424
+ clipRule: "evenodd"
425
+ }
426
+ )
427
+ });
428
+ var IconCommandCursor = createIconBase({
429
+ name: "IconCommandCursor",
430
+ paths: /* @__PURE__ */ jsx5(
431
+ "path",
432
+ {
433
+ d: "M4 3v18h16V3H4zm2 2h12v14H6V5zm1.5 3.5L11 12l-3.5 3.5L9 17l5-5-5-5-1.5 1.5zM13 17h4v-2h-4v2z",
434
+ fill: "currentColor",
435
+ fillRule: "evenodd",
436
+ clipRule: "evenodd"
437
+ }
438
+ )
439
+ });
440
+ var IconDataReel = createIconBase({
441
+ name: "IconDataReel",
442
+ paths: /* @__PURE__ */ jsx5(
443
+ "path",
444
+ {
445
+ d: "M3 5v14h18V5H3zm2 2h14v10H5V7zm3 1a3 3 0 1 0 0 6 3 3 0 0 0 0-6zm8 0a3 3 0 1 0 0 6 3 3 0 0 0 0-6zM10 11h4v1.5h-4V11z",
446
+ fill: "currentColor",
447
+ fillRule: "evenodd",
448
+ clipRule: "evenodd"
449
+ }
450
+ )
451
+ });
452
+ var IconCodePreview = createIconBase({
453
+ name: "IconCodePreview",
454
+ paths: /* @__PURE__ */ jsx5(
455
+ "path",
456
+ {
457
+ d: "M3 3v15h18V3H3zm2 2h14v11H5V5zm3.5 2L5 10.5 8.5 14l1.4-1.4-2.1-2.1 2.1-2.1L8.5 7zm7 0-1.4 1.4 2.1 2.1-2.1 2.1 1.4 1.4 3.5-3.5L15.5 7zM9 20h6v2H9v-2z",
458
+ fill: "currentColor",
459
+ fillRule: "evenodd",
460
+ clipRule: "evenodd"
461
+ }
462
+ )
463
+ });
464
+ var IconInsightBoard = createIconBase({
465
+ name: "IconInsightBoard",
466
+ paths: /* @__PURE__ */ jsx5(
467
+ "path",
468
+ {
469
+ d: "M3 3v18h18V3H3zm2 2h14v3H5V5zm0 5h6v9H5v-9zm8 0h6v4h-6v-4zm0 6h6v3h-6v-3zM6 6h2v1H6V6zm3 0h2v1H9V6z",
470
+ fill: "currentColor",
471
+ fillRule: "evenodd",
472
+ clipRule: "evenodd"
473
+ }
474
+ )
475
+ });
476
+ var IconEventStream = createIconBase({
477
+ name: "IconEventStream",
478
+ paths: /* @__PURE__ */ jsxs3(Fragment2, { children: [
479
+ /* @__PURE__ */ jsx5("path", { d: "M5 4h2v16H5V4z", fill: "currentColor", opacity: "0.45" }),
480
+ fill("M6 3a3 3 0 1 0 0 6 3 3 0 0 0 0-6zm0 8a3 3 0 1 0 0 6 3 3 0 0 0 0-6zm5-6h10v2H11V5zm0 8h7v2h-7v-2zm0 5h10v2H11v-2z")
481
+ ] })
482
+ });
483
+ var IconFeatureGate = createIconBase({
484
+ name: "IconFeatureGate",
485
+ paths: /* @__PURE__ */ jsx5(
486
+ "path",
487
+ {
488
+ d: "M4 3h2v18H4V3zm3 2h12l-3 4 3 4H7V5zm4 1-2.2 4H12l-1 4 4.2-5H12l1-3h-2z",
489
+ fill: "currentColor",
490
+ fillRule: "evenodd",
491
+ clipRule: "evenodd"
492
+ }
493
+ )
494
+ });
495
+ var IconReplayFrame = createIconBase({
496
+ name: "IconReplayFrame",
497
+ paths: /* @__PURE__ */ jsx5(
498
+ "path",
499
+ {
500
+ d: "M3 3v18h18V3H3zm2 2h14v11H5V5zm5 2v7l6-3.5L10 7zm-5 11h9v1H5v-1zm11 0h3v1h-3v-1z",
501
+ fill: "currentColor",
502
+ fillRule: "evenodd",
503
+ clipRule: "evenodd"
504
+ }
505
+ )
506
+ });
507
+ var IconQueryStack = createIconBase({
508
+ name: "IconQueryStack",
509
+ paths: fill(
510
+ "M4 5c0-1.66 3.58-3 8-3s8 1.34 8 3-3.58 3-8 3-8-1.34-8-3zm0 3v3c0 1.66 3.58 3 8 3 .7 0 1.38-.04 2-.12V11.8c-.64.13-1.31.2-2 .2-4.42 0-8-1.34-8-3zm0 6v3c0 1.66 3.58 3 8 3 .7 0 1.38-.04 2-.12v-2.08c-.64.13-1.31.2-2 .2-4.42 0-8-1.34-8-3zm12-1 5 4-5 4v-3h-4v-2h4v-3z"
511
+ )
512
+ });
513
+ var IconExperimentSplit = createIconBase({
514
+ name: "IconExperimentSplit",
515
+ paths: fill(
516
+ "M5 3a3 3 0 1 0 0 6 3 3 0 0 0 0-6zm14 0a3 3 0 1 0 0 6 3 3 0 0 0 0-6zM5 15a3 3 0 1 0 0 6 3 3 0 0 0 0-6zm1-6h2c0 2.2 1.8 4 4 4h2.17A3 3 0 0 1 19 11v2a3 3 0 0 1-4.83-2H12a6 6 0 0 1-6-6v4zm0 4a6 6 0 0 0 6-6h2a8 8 0 0 1-8 8v-2z"
517
+ )
518
+ });
519
+ var IconSurveyCard = createIconBase({
520
+ name: "IconSurveyCard",
521
+ paths: /* @__PURE__ */ jsx5(
522
+ "path",
523
+ {
524
+ d: "M3 3v18h18V3H3zm2 2h14v14H5V5zm2 2h7v2H7V7zm0 4h4v2H7v-2zm7-.4-2.5 2.5-1-1-1.4 1.4 2.4 2.4 3.9-3.9-1.4-1.4zM7 16h10v1H7v-1z",
525
+ fill: "currentColor",
526
+ fillRule: "evenodd",
527
+ clipRule: "evenodd"
528
+ }
529
+ )
530
+ });
531
+ var OLD_UI_ICONS = {
532
+ oldWindow: IconOldWindow,
533
+ commandCursor: IconCommandCursor,
534
+ dataReel: IconDataReel,
535
+ codePreview: IconCodePreview,
536
+ insightBoard: IconInsightBoard,
537
+ eventStream: IconEventStream,
538
+ featureGate: IconFeatureGate,
539
+ replayFrame: IconReplayFrame,
540
+ queryStack: IconQueryStack,
541
+ experimentSplit: IconExperimentSplit,
542
+ surveyCard: IconSurveyCard
543
+ };
544
+ var IconActivity = createIconBasePath(
545
+ "M22 12h-4l-3 9L9 3l-3 9H2v2h6.76l2.24-6.72L15 15l2.24-6.72L19 14h3v-2z"
546
+ );
547
+ var IconFlask = createIconBasePath(
548
+ "M19.8 18.4L14 10.67V6.5l1.35-1.35c.39-.39.39-1.02 0-1.41L14.65 2.7a.9959.9959 0 0 0-1.41 0L9.35 6.54c-.39.39-.39 1.02 0 1.41L10.7 9.3v4.17L4.2 18.4C3.53 19.07 4.04 20.25 5 20.25h14c.96 0 1.47-1.18.8-1.85zM6.91 18.25l5.09-5.09 5.09 5.09H6.91z"
549
+ );
550
+ var IconSpinner = forwardRef4(function IconSpinner2(_a, ref) {
551
+ var _b = _a, { className } = _b, props = __objRest(_b, ["className"]);
552
+ return /* @__PURE__ */ jsx5(IconSync, __spreadValues({ ref, className: cn("ph-icon-spin", className) }, props));
553
+ });
554
+ IconSpinner.displayName = "IconSpinner";
555
+ var CANONICAL_ICONS = {
556
+ activity: IconActivity,
557
+ areaChart: IconAreaChart,
558
+ arrowDown: IconArrowDown,
559
+ arrowUp: IconArrowUp,
560
+ bell: IconBell,
561
+ bellOff: IconBellOff,
562
+ bolt: IconBolt,
563
+ box: IconBox,
564
+ cancel: IconCancel,
565
+ check: IconCheck,
566
+ checkCircle: IconCheckCircle,
567
+ chevronDown: IconChevronDown,
568
+ chevronLeft: IconChevronLeft,
569
+ chevronRight: IconChevronRight,
570
+ clipboardEdit: IconClipboardEdit,
571
+ close: IconClose,
572
+ codePreview: IconCodePreview,
573
+ cohort: IconCohort,
574
+ commandCursor: IconCommandCursor,
575
+ copy: IconCopy,
576
+ cumulativeChart: IconCumulativeChart,
577
+ dataReel: IconDataReel,
578
+ database: IconDatabase,
579
+ download: IconDownload,
580
+ edit: IconEdit,
581
+ errorOutline: IconErrorOutline,
582
+ eventStream: IconEventStream,
583
+ exclamation: IconExclamation,
584
+ experimentSplit: IconExperimentSplit,
585
+ featureGate: IconFeatureGate,
586
+ flag: IconFlag,
587
+ flare: IconFlare,
588
+ flask: IconFlask,
589
+ gift: IconGift,
590
+ gridView: IconGridView,
591
+ handClick: IconHandClick,
592
+ home: IconHome,
593
+ info: IconInfo,
594
+ insightBoard: IconInsightBoard,
595
+ layers: IconLayers,
596
+ listView: IconListView,
597
+ logout: IconLogout,
598
+ mail: IconMail,
599
+ moon: IconMoon,
600
+ oldWindow: IconOldWindow,
601
+ panelRight: IconPanelRight,
602
+ person: IconPerson,
603
+ playCircle: IconPlayCircle,
604
+ plus: IconPlus,
605
+ premium: IconPremium,
606
+ queryEditor: IconQueryEditor,
607
+ queryStack: IconQueryStack,
608
+ radar: IconRadar,
609
+ recording: IconRecording,
610
+ replayFrame: IconReplayFrame,
611
+ robot: IconRobot,
612
+ rocket: IconRocket,
613
+ save: IconSave,
614
+ search: IconSearch,
615
+ selectEvents: IconSelectEvents,
616
+ shoppingCart: IconShoppingCart,
617
+ spinner: IconSpinner,
618
+ star: IconStar,
619
+ subArrowRight: IconSubArrowRight,
620
+ sun: IconSun,
621
+ surveyCard: IconSurveyCard,
622
+ surveys: IconSurveys,
623
+ sync: IconSync,
624
+ tableChart: IconTableChart,
625
+ terminal: IconTerminal,
626
+ toggle: IconToggle,
627
+ trash: IconTrash,
628
+ tuning: IconTuning,
629
+ upload: IconUpload,
630
+ volume: IconVolume,
631
+ volumeOff: IconVolumeOff
632
+ };
633
+ var PH_ICON_ALIASES = {
634
+ clipboard: IconClipboardEdit,
635
+ grid: IconGridView,
636
+ list: IconListView,
637
+ play: IconPlayCircle,
638
+ settings: IconTuning,
639
+ trendingUp: IconArrowUp,
640
+ warning: IconExclamation,
641
+ xCircle: IconCancel
642
+ };
643
+ var PH_ICONS = __spreadValues(__spreadValues({}, CANONICAL_ICONS), PH_ICON_ALIASES);
644
+ for (const [name, Icon] of Object.entries(CANONICAL_ICONS)) {
645
+ const namedIcon = Icon;
646
+ if (!namedIcon.displayName || namedIcon.displayName === "IconGlyph") {
647
+ namedIcon.displayName = `Icon${name[0].toUpperCase()}${name.slice(1)}`;
648
+ }
649
+ }
650
+ var IconByName = forwardRef4(function IconByName2(_a, ref) {
651
+ var _b = _a, { name } = _b, props = __objRest(_b, ["name"]);
652
+ const Icon = PH_ICONS[name];
653
+ return /* @__PURE__ */ jsx5(Icon, __spreadValues({ ref }, props));
654
+ });
655
+ IconByName.displayName = "IconByName";
656
+
657
+ // src/components/ui/Alert.tsx
658
+ import { jsx as jsx6, jsxs as jsxs4 } from "react/jsx-runtime";
659
+ var statusConfig = {
660
+ info: { icon: IconInfo },
661
+ success: { icon: IconCheckCircle },
662
+ warning: { icon: IconExclamation },
663
+ danger: { icon: IconCancel }
664
+ };
665
+ var statusClassMap = {
666
+ info: "ph-alert-info",
667
+ success: "ph-alert-success",
668
+ warning: "ph-alert-warning",
669
+ danger: "ph-alert-danger"
670
+ };
671
+ var Alert = forwardRef5(function Alert2(_a, ref) {
672
+ var _b = _a, {
673
+ status = "info",
674
+ title,
675
+ description,
676
+ icon,
677
+ children,
678
+ className,
679
+ onDismiss,
680
+ live,
681
+ dismissLabel = "Dismiss notification",
682
+ role
683
+ } = _b, props = __objRest(_b, [
684
+ "status",
685
+ "title",
686
+ "description",
687
+ "icon",
688
+ "children",
689
+ "className",
690
+ "onDismiss",
691
+ "live",
692
+ "dismissLabel",
693
+ "role"
694
+ ]);
695
+ const config = statusConfig[status];
696
+ const Icon = config.icon;
697
+ return /* @__PURE__ */ jsxs4(
698
+ "div",
699
+ __spreadProps(__spreadValues({
700
+ ref,
701
+ role: role != null ? role : live === "assertive" ? "alert" : live === "polite" ? "status" : void 0,
702
+ "aria-live": live,
703
+ className: cn("ph-alert", statusClassMap[status], className)
704
+ }, props), {
705
+ children: [
706
+ icon != null ? icon : /* @__PURE__ */ jsx6(Icon, { className: "ph-alert-icon mt-0.5 h-5 w-5 shrink-0", "aria-hidden": true }),
707
+ /* @__PURE__ */ jsxs4("div", { className: "min-w-0 flex-1", children: [
708
+ title && /* @__PURE__ */ jsx6("p", { className: "font-semibold", children: title }),
709
+ description && /* @__PURE__ */ jsx6("p", { className: "mt-1 text-sm text-ph-subtle", children: description }),
710
+ children
711
+ ] }),
712
+ onDismiss && /* @__PURE__ */ jsx6(
713
+ "button",
714
+ {
715
+ type: "button",
716
+ onClick: onDismiss,
717
+ className: "ph-alert-dismiss",
718
+ "aria-label": dismissLabel,
719
+ children: /* @__PURE__ */ jsx6(IconClose, { className: "h-4 w-4", "aria-hidden": true })
720
+ }
721
+ )
722
+ ]
723
+ })
724
+ );
725
+ });
726
+ Alert.displayName = "Alert";
727
+
728
+ // src/components/ui/Badge.tsx
729
+ import { forwardRef as forwardRef6 } from "react";
730
+ import { jsx as jsx7 } from "react/jsx-runtime";
731
+ var variantMap = {
732
+ brand: "ph-badge-brand",
733
+ neutral: "ph-badge-neutral",
734
+ success: "ph-badge-success",
735
+ warning: "ph-badge-warning",
736
+ danger: "ph-badge-danger",
737
+ info: "ph-badge-info",
738
+ outline: "ph-badge-outline"
739
+ };
740
+ var sizeMap = {
741
+ sm: "text-[10px] px-1.5 py-0.5",
742
+ md: ""
743
+ };
744
+ var Badge = forwardRef6(function Badge2(_a, ref) {
745
+ var _b = _a, {
746
+ variant = "neutral",
747
+ size = "md",
748
+ children,
749
+ className
750
+ } = _b, props = __objRest(_b, [
751
+ "variant",
752
+ "size",
753
+ "children",
754
+ "className"
755
+ ]);
756
+ return /* @__PURE__ */ jsx7(
757
+ "span",
758
+ __spreadProps(__spreadValues({
759
+ ref,
760
+ className: cn(
761
+ "ph-badge",
762
+ variantMap[variant],
763
+ sizeMap[size],
764
+ className
765
+ )
766
+ }, props), {
767
+ children
768
+ })
769
+ );
770
+ });
771
+ Badge.displayName = "Badge";
772
+
773
+ // src/components/ui/Card.tsx
774
+ import { forwardRef as forwardRef7 } from "react";
775
+ import { jsx as jsx8, jsxs as jsxs5 } from "react/jsx-runtime";
776
+ var variantMap2 = {
777
+ default: "",
778
+ outlined: "border-2 border-ph-border",
779
+ elevated: "ph-card-elevated",
780
+ highlighted: "ph-card-highlighted"
781
+ };
782
+ var Card = forwardRef7(function Card2(_a, ref) {
783
+ var _b = _a, {
784
+ children,
785
+ title,
786
+ description,
787
+ actions,
788
+ footer,
789
+ media,
790
+ variant = "default",
791
+ className,
792
+ bodyClassName,
793
+ interactive = false,
794
+ titleAs: Title2 = "h3"
795
+ } = _b, props = __objRest(_b, [
796
+ "children",
797
+ "title",
798
+ "description",
799
+ "actions",
800
+ "footer",
801
+ "media",
802
+ "variant",
803
+ "className",
804
+ "bodyClassName",
805
+ "interactive",
806
+ "titleAs"
807
+ ]);
808
+ return /* @__PURE__ */ jsxs5(
809
+ "div",
810
+ __spreadProps(__spreadValues({
811
+ ref,
812
+ className: cn(
813
+ "ph-card",
814
+ variantMap2[variant],
815
+ interactive && "ph-card-interactive",
816
+ className
817
+ )
818
+ }, props), {
819
+ children: [
820
+ media && /* @__PURE__ */ jsx8("div", { className: "ph-card-media", children: media }),
821
+ /* @__PURE__ */ jsxs5("div", { className: cn("ph-card-body", bodyClassName), children: [
822
+ title && /* @__PURE__ */ jsx8(Title2, { className: "ph-card-title", children: title }),
823
+ description && /* @__PURE__ */ jsx8("p", { className: "text-sm text-ph-subtle", children: description }),
824
+ children,
825
+ actions && /* @__PURE__ */ jsx8("div", { className: "ph-card-actions", children: actions })
826
+ ] }),
827
+ footer && /* @__PURE__ */ jsx8("div", { className: "border-t border-ph-border px-6 py-4 text-xs text-ph-subtle", children: footer })
828
+ ]
829
+ })
830
+ );
831
+ });
832
+ Card.displayName = "Card";
833
+
834
+ // src/components/ui/Drawer.tsx
835
+ import { Fragment as Fragment3, jsx as jsx9, jsxs as jsxs6 } from "react/jsx-runtime";
836
+ var sideMap = {
837
+ left: "left-0 border-r",
838
+ right: "right-0 border-l"
839
+ };
840
+ var sizeMap2 = {
841
+ sm: "w-[min(100%,18rem)]",
842
+ md: "w-[min(100%,22rem)]",
843
+ lg: "w-[min(100%,30rem)]"
844
+ };
845
+ function Drawer({
846
+ open = false,
847
+ onClose,
848
+ title,
849
+ children,
850
+ footer,
851
+ side = "right",
852
+ size = "md",
853
+ className,
854
+ showCloseButton = true
855
+ }) {
856
+ if (!open) return null;
857
+ return /* @__PURE__ */ jsxs6(Fragment3, { children: [
858
+ /* @__PURE__ */ jsx9("div", { className: "fixed inset-0 z-[120] bg-black/45 backdrop-blur-[2px]", role: "presentation", onClick: onClose }),
859
+ /* @__PURE__ */ jsxs6(
860
+ "aside",
861
+ {
862
+ className: cn(
863
+ "fixed inset-y-0 z-[130] flex flex-col overflow-y-auto border-ph-border bg-ph-surface shadow-ph-md",
864
+ sideMap[side],
865
+ sizeMap2[size],
866
+ className
867
+ ),
868
+ children: [
869
+ (title || showCloseButton) && /* @__PURE__ */ jsxs6("header", { className: "flex items-center justify-between border-b border-ph-border px-4 py-3", children: [
870
+ /* @__PURE__ */ jsx9("span", { className: "text-sm font-bold text-ph-ink", children: title }),
871
+ showCloseButton && onClose && /* @__PURE__ */ jsx9(Button, { variant: "ghost", className: "ph-btn-circle", onClick: onClose, "aria-label": "Close drawer", children: /* @__PURE__ */ jsx9(IconClose, { className: "h-5 w-5" }) })
872
+ ] }),
873
+ /* @__PURE__ */ jsx9("div", { className: "flex-1", children }),
874
+ footer && /* @__PURE__ */ jsx9("footer", { className: "border-t border-ph-border px-4 py-3", children: footer })
875
+ ]
876
+ }
877
+ )
878
+ ] });
879
+ }
880
+
881
+ // src/components/ui/Kbd.tsx
882
+ import { jsx as jsx10, jsxs as jsxs7 } from "react/jsx-runtime";
883
+ var platformLabels = {
884
+ text: {
885
+ command: "Command",
886
+ cmd: "Command",
887
+ option: "Option",
888
+ alt: "Alt",
889
+ control: "Control",
890
+ ctrl: "Control",
891
+ shift: "Shift"
892
+ },
893
+ mac: {
894
+ command: "\u2318",
895
+ cmd: "\u2318",
896
+ option: "\u2325",
897
+ alt: "\u2325",
898
+ control: "\u2303",
899
+ ctrl: "\u2303",
900
+ shift: "\u21E7"
901
+ },
902
+ windows: {
903
+ command: "Win",
904
+ cmd: "Win",
905
+ option: "Alt",
906
+ alt: "Alt",
907
+ control: "Ctrl",
908
+ ctrl: "Ctrl",
909
+ shift: "Shift"
910
+ }
911
+ };
912
+ var spokenLabels = {
913
+ "\u2318": "Command",
914
+ "\u2325": "Option",
915
+ "\u2303": "Control",
916
+ "\u21E7": "Shift",
917
+ "\u21B5": "Enter",
918
+ "\u23CE": "Enter",
919
+ "\u232B": "Backspace",
920
+ "\u238B": "Escape"
921
+ };
922
+ function Kbd(_a) {
923
+ var _b = _a, {
924
+ variant = "shortcut",
925
+ keys,
926
+ platform = "text",
927
+ separator,
928
+ children,
929
+ className,
930
+ "aria-label": ariaLabel
931
+ } = _b, props = __objRest(_b, [
932
+ "variant",
933
+ "keys",
934
+ "platform",
935
+ "separator",
936
+ "children",
937
+ "className",
938
+ "aria-label"
939
+ ]);
940
+ if (variant === "token") {
941
+ return /* @__PURE__ */ jsx10("code", __spreadProps(__spreadValues({ className: cn("ph-code-token ph-kbd", className), "aria-label": ariaLabel }, props), { children }));
942
+ }
943
+ const sourceKeys = (keys == null ? void 0 : keys.length) ? keys : children != null ? [children] : [];
944
+ const displayKeys = sourceKeys.map((key) => formatKey(key, platform));
945
+ const accessibleLabel = ariaLabel != null ? ariaLabel : getShortcutLabel(displayKeys);
946
+ if (variant === "key") {
947
+ return /* @__PURE__ */ jsx10("kbd", __spreadProps(__spreadValues({ className: cn("ph-keycap", className), "aria-label": accessibleLabel }, props), { children: displayKeys[0] }));
948
+ }
949
+ return /* @__PURE__ */ jsx10("kbd", __spreadProps(__spreadValues({ className: cn("ph-shortcut-group ph-keycap", className), "aria-label": accessibleLabel }, props), { children: displayKeys.map((key, index) => /* @__PURE__ */ jsxs7("span", { className: "contents", children: [
950
+ index > 0 && separator != null ? /* @__PURE__ */ jsx10("span", { className: "ph-shortcut-separator", "aria-hidden": "true", children: separator }) : null,
951
+ /* @__PURE__ */ jsx10("span", { className: "ph-shortcut-key", "aria-hidden": accessibleLabel ? true : void 0, children: key })
952
+ ] }, index)) }));
953
+ }
954
+ function formatKey(key, platform) {
955
+ var _a;
956
+ if (typeof key !== "string") return key;
957
+ return (_a = platformLabels[platform][key.toLowerCase()]) != null ? _a : key;
958
+ }
959
+ function getShortcutLabel(keys) {
960
+ const labels = keys.map((key) => {
961
+ var _a;
962
+ if (typeof key !== "string" && typeof key !== "number") return null;
963
+ const value = String(key);
964
+ return (_a = spokenLabels[value]) != null ? _a : value;
965
+ });
966
+ return labels.every((label) => label != null) ? labels.join(" + ") : void 0;
967
+ }
968
+
969
+ // src/components/ui/Loader.tsx
970
+ import { jsx as jsx11, jsxs as jsxs8 } from "react/jsx-runtime";
971
+ var loaderSizeClass = {
972
+ sm: "ph-loader-sm",
973
+ md: "ph-loader-md",
974
+ lg: "ph-loader-lg"
975
+ };
976
+ var skeletonShapeClass = {
977
+ title: "ph-skeleton-title",
978
+ text: "ph-skeleton-text",
979
+ "short-text": "ph-skeleton-text-short",
980
+ avatar: "ph-skeleton-avatar",
981
+ button: "ph-skeleton-button",
982
+ block: "ph-skeleton-block"
983
+ };
984
+ function Loader(_a) {
985
+ var _b = _a, {
986
+ variant = "spinner",
987
+ size = "md",
988
+ label = "Loading",
989
+ className
990
+ } = _b, props = __objRest(_b, [
991
+ "variant",
992
+ "size",
993
+ "label",
994
+ "className"
995
+ ]);
996
+ return /* @__PURE__ */ jsxs8(
997
+ "span",
998
+ __spreadProps(__spreadValues({
999
+ role: "status",
1000
+ "aria-label": label,
1001
+ className: cn("ph-loader", loaderSizeClass[size], className)
1002
+ }, props), {
1003
+ children: [
1004
+ variant === "spinner" ? /* @__PURE__ */ jsx11("span", { className: "ph-loading", "aria-hidden": true }) : null,
1005
+ variant === "dots" ? /* @__PURE__ */ jsxs8("span", { className: "ph-loading-dots", "aria-hidden": true, children: [
1006
+ /* @__PURE__ */ jsx11("span", {}),
1007
+ /* @__PURE__ */ jsx11("span", {}),
1008
+ /* @__PURE__ */ jsx11("span", {})
1009
+ ] }) : null,
1010
+ variant === "pulse" ? /* @__PURE__ */ jsx11("span", { className: "ph-loading-pulse", "aria-hidden": true }) : null
1011
+ ]
1012
+ })
1013
+ );
1014
+ }
1015
+ function Skeleton(_a) {
1016
+ var _b = _a, { shape = "text", className } = _b, props = __objRest(_b, ["shape", "className"]);
1017
+ return /* @__PURE__ */ jsx11(
1018
+ "span",
1019
+ __spreadValues({
1020
+ className: cn("ph-skeleton", skeletonShapeClass[shape], className),
1021
+ "aria-hidden": "true"
1022
+ }, props)
1023
+ );
1024
+ }
1025
+ function LoadingState(_a) {
1026
+ var _b = _a, {
1027
+ label = "Loading",
1028
+ title = "Loading",
1029
+ description,
1030
+ variant = "spinner",
1031
+ size = "lg",
1032
+ className
1033
+ } = _b, props = __objRest(_b, [
1034
+ "label",
1035
+ "title",
1036
+ "description",
1037
+ "variant",
1038
+ "size",
1039
+ "className"
1040
+ ]);
1041
+ return /* @__PURE__ */ jsxs8("div", __spreadProps(__spreadValues({ className: cn("ph-loading-state", className), role: "status", "aria-label": label }, props), { children: [
1042
+ /* @__PURE__ */ jsx11(Loader, { variant, size, label, "aria-hidden": "true" }),
1043
+ /* @__PURE__ */ jsxs8("div", { className: "ph-loading-state__copy", children: [
1044
+ /* @__PURE__ */ jsx11("strong", { children: title }),
1045
+ description ? /* @__PURE__ */ jsx11("span", { children: description }) : null
1046
+ ] })
1047
+ ] }));
1048
+ }
1049
+
1050
+ // src/components/ui/AuthLayout.tsx
1051
+ import { useId } from "react";
1052
+ import { jsx as jsx12, jsxs as jsxs9 } from "react/jsx-runtime";
1053
+ function AuthLayout(_a) {
1054
+ var _b = _a, { brand, footer, aside, children, className } = _b, props = __objRest(_b, ["brand", "footer", "aside", "children", "className"]);
1055
+ return /* @__PURE__ */ jsxs9("div", __spreadProps(__spreadValues({ className: cn("ph-auth-layout", aside != null && "ph-auth-layout--split", className) }, props), { children: [
1056
+ aside ? /* @__PURE__ */ jsx12("aside", { className: "ph-auth-layout__aside", children: aside }) : null,
1057
+ /* @__PURE__ */ jsx12("div", { className: "ph-auth-layout__main", children: /* @__PURE__ */ jsxs9("div", { className: "ph-auth-layout__column", children: [
1058
+ brand ? /* @__PURE__ */ jsx12("div", { className: "ph-auth-layout__brand", children: brand }) : null,
1059
+ children,
1060
+ footer ? /* @__PURE__ */ jsx12("footer", { className: "ph-auth-layout__footer", children: footer }) : null
1061
+ ] }) })
1062
+ ] }));
1063
+ }
1064
+ function AuthCard(_a) {
1065
+ var _b = _a, { title, description, footer, children, className } = _b, props = __objRest(_b, ["title", "description", "footer", "children", "className"]);
1066
+ const titleId = useId();
1067
+ return /* @__PURE__ */ jsxs9("section", __spreadProps(__spreadValues({ className: cn("ph-auth-card", className), "aria-labelledby": titleId }, props), { children: [
1068
+ /* @__PURE__ */ jsxs9("header", { className: "ph-auth-card__header", children: [
1069
+ /* @__PURE__ */ jsx12("h1", { id: titleId, children: title }),
1070
+ description ? /* @__PURE__ */ jsx12("p", { children: description }) : null
1071
+ ] }),
1072
+ /* @__PURE__ */ jsx12("div", { className: "ph-auth-card__body", children }),
1073
+ footer ? /* @__PURE__ */ jsx12("footer", { className: "ph-auth-card__footer", children: footer }) : null
1074
+ ] }));
1075
+ }
1076
+ function AuthDivider(_a) {
1077
+ var _b = _a, { children = "or continue with", className } = _b, props = __objRest(_b, ["children", "className"]);
1078
+ return /* @__PURE__ */ jsx12("div", __spreadProps(__spreadValues({ className: cn("ph-auth-divider", className) }, props), { children: /* @__PURE__ */ jsx12("span", { children }) }));
1079
+ }
1080
+
1081
+ // src/components/ui/SettingsLayout.tsx
1082
+ import { jsx as jsx13, jsxs as jsxs10 } from "react/jsx-runtime";
1083
+ function SettingsNav(_a) {
1084
+ var _b = _a, { groups, className } = _b, props = __objRest(_b, ["groups", "className"]);
1085
+ return /* @__PURE__ */ jsx13("div", __spreadProps(__spreadValues({ className: cn("ph-settings-nav", className) }, props), { children: groups.map((group, index) => /* @__PURE__ */ jsxs10("div", { className: "ph-settings-nav__group", children: [
1086
+ /* @__PURE__ */ jsx13("h3", { children: group.label }),
1087
+ /* @__PURE__ */ jsx13("div", { className: "ph-settings-nav__items", children: group.items.map((item) => /* @__PURE__ */ jsxs10(
1088
+ "a",
1089
+ {
1090
+ href: item.href,
1091
+ className: cn("ph-settings-nav__item", item.active && "ph-settings-nav__item--active"),
1092
+ "aria-current": item.active ? "page" : void 0,
1093
+ children: [
1094
+ item.icon ? /* @__PURE__ */ jsx13("span", { className: "ph-settings-nav__icon", children: item.icon }) : null,
1095
+ /* @__PURE__ */ jsx13("span", { children: item.label }),
1096
+ item.badge ? /* @__PURE__ */ jsx13("span", { className: "ph-settings-nav__badge", children: item.badge }) : null
1097
+ ]
1098
+ },
1099
+ item.id
1100
+ )) })
1101
+ ] }, index)) }));
1102
+ }
1103
+ function SettingsLayout(_a) {
1104
+ var _b = _a, {
1105
+ title,
1106
+ description,
1107
+ actions,
1108
+ navigation,
1109
+ navigationLabel = "Settings",
1110
+ children,
1111
+ className
1112
+ } = _b, props = __objRest(_b, [
1113
+ "title",
1114
+ "description",
1115
+ "actions",
1116
+ "navigation",
1117
+ "navigationLabel",
1118
+ "children",
1119
+ "className"
1120
+ ]);
1121
+ return /* @__PURE__ */ jsxs10("section", __spreadProps(__spreadValues({ className: cn("ph-settings-layout", className) }, props), { children: [
1122
+ /* @__PURE__ */ jsxs10("header", { className: "ph-settings-layout__header", children: [
1123
+ /* @__PURE__ */ jsxs10("div", { children: [
1124
+ /* @__PURE__ */ jsx13("h2", { children: title }),
1125
+ description ? /* @__PURE__ */ jsx13("p", { children: description }) : null
1126
+ ] }),
1127
+ actions ? /* @__PURE__ */ jsx13("div", { className: "ph-settings-layout__actions", children: actions }) : null
1128
+ ] }),
1129
+ /* @__PURE__ */ jsxs10("details", { className: "ph-settings-layout__mobile-nav", children: [
1130
+ /* @__PURE__ */ jsxs10("summary", { children: [
1131
+ /* @__PURE__ */ jsx13(IconTuning, { className: "h-4 w-4", "aria-hidden": true }),
1132
+ "Settings menu"
1133
+ ] }),
1134
+ /* @__PURE__ */ jsx13("nav", { "aria-label": navigationLabel, children: navigation })
1135
+ ] }),
1136
+ /* @__PURE__ */ jsxs10("div", { className: "ph-settings-layout__grid", children: [
1137
+ /* @__PURE__ */ jsx13("aside", { className: "ph-settings-layout__sidebar", children: /* @__PURE__ */ jsx13("nav", { "aria-label": navigationLabel, children: navigation }) }),
1138
+ /* @__PURE__ */ jsx13("div", { className: "ph-settings-layout__content", children })
1139
+ ] })
1140
+ ] }));
1141
+ }
1142
+
1143
+ // src/components/ui/DropdownMenu.tsx
1144
+ import * as DropdownPrimitive from "@radix-ui/react-dropdown-menu";
1145
+ import { jsx as jsx14, jsxs as jsxs11 } from "react/jsx-runtime";
1146
+ var sizeClass2 = {
1147
+ xs: "ph-btn-xs",
1148
+ sm: "ph-btn-sm",
1149
+ md: "",
1150
+ lg: "ph-btn-lg"
1151
+ };
1152
+ var variantClass2 = {
1153
+ primary: "ph-btn-primary",
1154
+ secondary: "ph-btn-secondary",
1155
+ accent: "ph-btn-accent"
1156
+ };
1157
+ function DropdownContent({
1158
+ children,
1159
+ align = "start",
1160
+ side = "bottom",
1161
+ sideOffset = 7,
1162
+ alignOffset = 0,
1163
+ collisionPadding = 8,
1164
+ avoidCollisions = true,
1165
+ panelClassName
1166
+ }) {
1167
+ return /* @__PURE__ */ jsx14(DropdownPrimitive.Portal, { children: /* @__PURE__ */ jsxs11(
1168
+ DropdownPrimitive.Content,
1169
+ {
1170
+ className: cn("ph-dropdown-panel", panelClassName),
1171
+ align,
1172
+ side,
1173
+ sideOffset,
1174
+ alignOffset,
1175
+ collisionPadding,
1176
+ avoidCollisions,
1177
+ sticky: "partial",
1178
+ children: [
1179
+ children,
1180
+ /* @__PURE__ */ jsx14(DropdownPrimitive.Arrow, { className: "ph-dropdown-arrow", width: 12, height: 6 })
1181
+ ]
1182
+ }
1183
+ ) });
1184
+ }
1185
+ function DropdownMenu(_a) {
1186
+ var _b = _a, {
1187
+ trigger,
1188
+ children,
1189
+ align,
1190
+ side,
1191
+ sideOffset,
1192
+ alignOffset,
1193
+ collisionPadding,
1194
+ avoidCollisions,
1195
+ className,
1196
+ panelClassName,
1197
+ "aria-label": ariaLabel,
1198
+ open,
1199
+ defaultOpen,
1200
+ onOpenChange,
1201
+ modal = false,
1202
+ disabled
1203
+ } = _b, props = __objRest(_b, [
1204
+ "trigger",
1205
+ "children",
1206
+ "align",
1207
+ "side",
1208
+ "sideOffset",
1209
+ "alignOffset",
1210
+ "collisionPadding",
1211
+ "avoidCollisions",
1212
+ "className",
1213
+ "panelClassName",
1214
+ "aria-label",
1215
+ "open",
1216
+ "defaultOpen",
1217
+ "onOpenChange",
1218
+ "modal",
1219
+ "disabled"
1220
+ ]);
1221
+ return /* @__PURE__ */ jsx14("div", __spreadProps(__spreadValues({ className: cn("ph-dropdown", className) }, props), { children: /* @__PURE__ */ jsxs11(
1222
+ DropdownPrimitive.Root,
1223
+ {
1224
+ open,
1225
+ defaultOpen,
1226
+ onOpenChange,
1227
+ modal,
1228
+ children: [
1229
+ /* @__PURE__ */ jsx14(DropdownPrimitive.Trigger, { asChild: true, disabled, children: /* @__PURE__ */ jsx14("button", { type: "button", className: "ph-dropdown-trigger", "aria-label": ariaLabel, children: trigger }) }),
1230
+ /* @__PURE__ */ jsx14(
1231
+ DropdownContent,
1232
+ {
1233
+ align,
1234
+ side,
1235
+ sideOffset,
1236
+ alignOffset,
1237
+ collisionPadding,
1238
+ avoidCollisions,
1239
+ panelClassName,
1240
+ children
1241
+ }
1242
+ )
1243
+ ]
1244
+ }
1245
+ ) }));
1246
+ }
1247
+ function DropdownButton(_a) {
1248
+ var _b = _a, {
1249
+ label,
1250
+ variant = "secondary",
1251
+ outline = false,
1252
+ size = "md",
1253
+ split = false,
1254
+ icon,
1255
+ sideIcon,
1256
+ children,
1257
+ align,
1258
+ side,
1259
+ sideOffset,
1260
+ alignOffset,
1261
+ collisionPadding,
1262
+ avoidCollisions,
1263
+ className,
1264
+ panelClassName,
1265
+ "aria-label": ariaLabel,
1266
+ open,
1267
+ defaultOpen,
1268
+ onOpenChange,
1269
+ modal = false,
1270
+ disabled
1271
+ } = _b, props = __objRest(_b, [
1272
+ "label",
1273
+ "variant",
1274
+ "outline",
1275
+ "size",
1276
+ "split",
1277
+ "icon",
1278
+ "sideIcon",
1279
+ "children",
1280
+ "align",
1281
+ "side",
1282
+ "sideOffset",
1283
+ "alignOffset",
1284
+ "collisionPadding",
1285
+ "avoidCollisions",
1286
+ "className",
1287
+ "panelClassName",
1288
+ "aria-label",
1289
+ "open",
1290
+ "defaultOpen",
1291
+ "onOpenChange",
1292
+ "modal",
1293
+ "disabled"
1294
+ ]);
1295
+ const trailing = sideIcon != null ? sideIcon : /* @__PURE__ */ jsx14(IconChevronDown, { className: "h-4 w-4", "aria-hidden": true });
1296
+ return /* @__PURE__ */ jsx14("div", __spreadProps(__spreadValues({ className: cn("ph-dropdown", className) }, props), { children: /* @__PURE__ */ jsxs11(
1297
+ DropdownPrimitive.Root,
1298
+ {
1299
+ open,
1300
+ defaultOpen,
1301
+ onOpenChange,
1302
+ modal,
1303
+ children: [
1304
+ /* @__PURE__ */ jsx14(DropdownPrimitive.Trigger, { asChild: true, disabled, children: /* @__PURE__ */ jsx14(
1305
+ "button",
1306
+ {
1307
+ type: "button",
1308
+ disabled,
1309
+ className: cn(
1310
+ "ph-btn ph-btn-raised ph-dropdown-button",
1311
+ variantClass2[variant],
1312
+ outline && "ph-btn-outline",
1313
+ sizeClass2[size],
1314
+ split && "ph-btn-split"
1315
+ ),
1316
+ "aria-label": ariaLabel,
1317
+ children: /* @__PURE__ */ jsx14(ButtonChrome, { label, icon, sideIcon: trailing, split })
1318
+ }
1319
+ ) }),
1320
+ /* @__PURE__ */ jsx14(
1321
+ DropdownContent,
1322
+ {
1323
+ align,
1324
+ side,
1325
+ sideOffset,
1326
+ alignOffset,
1327
+ collisionPadding,
1328
+ avoidCollisions,
1329
+ panelClassName,
1330
+ children
1331
+ }
1332
+ )
1333
+ ]
1334
+ }
1335
+ ) }));
1336
+ }
1337
+ function DropdownItem(_a) {
1338
+ var _b = _a, { className, children, disabled } = _b, props = __objRest(_b, ["className", "children", "disabled"]);
1339
+ return /* @__PURE__ */ jsx14(DropdownPrimitive.Item, { asChild: true, disabled, children: /* @__PURE__ */ jsx14(
1340
+ "button",
1341
+ __spreadProps(__spreadValues({
1342
+ type: "button",
1343
+ disabled,
1344
+ className: cn("ph-dropdown-item w-full text-left", className)
1345
+ }, props), {
1346
+ children
1347
+ })
1348
+ ) });
1349
+ }
1350
+ function DropdownRadioGroup(props) {
1351
+ return /* @__PURE__ */ jsx14(DropdownPrimitive.RadioGroup, __spreadValues({}, props));
1352
+ }
1353
+ function DropdownRadioItem(_a) {
1354
+ var _b = _a, { className, children } = _b, props = __objRest(_b, ["className", "children"]);
1355
+ return /* @__PURE__ */ jsxs11(DropdownPrimitive.RadioItem, __spreadProps(__spreadValues({ className: cn("ph-dropdown-item ph-dropdown-radio-item", className) }, props), { children: [
1356
+ /* @__PURE__ */ jsx14("span", { className: "ph-dropdown-item-indicator", "aria-hidden": true, children: /* @__PURE__ */ jsx14(DropdownPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx14(IconCheck, { className: "h-3.5 w-3.5" }) }) }),
1357
+ /* @__PURE__ */ jsx14("span", { children })
1358
+ ] }));
1359
+ }
1360
+
1361
+ // src/components/ui/Input.tsx
1362
+ import { forwardRef as forwardRef8, useId as useId3 } from "react";
1363
+
1364
+ // src/components/ui/FormField.tsx
1365
+ import { useId as useId2 } from "react";
1366
+ import { jsx as jsx15, jsxs as jsxs12 } from "react/jsx-runtime";
1367
+ function FormField(_a) {
1368
+ var _b = _a, {
1369
+ controlId,
1370
+ label,
1371
+ hideLabel = false,
1372
+ helperText,
1373
+ error,
1374
+ required = false,
1375
+ disabled = false,
1376
+ children,
1377
+ className
1378
+ } = _b, props = __objRest(_b, [
1379
+ "controlId",
1380
+ "label",
1381
+ "hideLabel",
1382
+ "helperText",
1383
+ "error",
1384
+ "required",
1385
+ "disabled",
1386
+ "children",
1387
+ "className"
1388
+ ]);
1389
+ const generatedId = useId2();
1390
+ const id = controlId != null ? controlId : generatedId;
1391
+ const descriptionId = helperText && !error ? `${id}-description` : void 0;
1392
+ const errorId = error ? `${id}-error` : void 0;
1393
+ const controlProps = {
1394
+ id,
1395
+ "aria-describedby": descriptionId,
1396
+ "aria-errormessage": errorId,
1397
+ "aria-invalid": error ? true : void 0
1398
+ };
1399
+ return /* @__PURE__ */ jsxs12("div", __spreadProps(__spreadValues({ className: cn("ph-field", className) }, props), { children: [
1400
+ label ? /* @__PURE__ */ jsxs12(
1401
+ "label",
1402
+ {
1403
+ htmlFor: id,
1404
+ className: cn("ph-label", hideLabel && "sr-only", disabled && "opacity-50"),
1405
+ children: [
1406
+ label,
1407
+ required ? /* @__PURE__ */ jsx15("span", { "aria-hidden": "true", children: " *" }) : null
1408
+ ]
1409
+ }
1410
+ ) : null,
1411
+ typeof children === "function" ? children(controlProps) : children,
1412
+ descriptionId ? /* @__PURE__ */ jsx15("p", { id: descriptionId, className: "mt-1 text-xs text-ph-subtle", children: helperText }) : null,
1413
+ errorId ? /* @__PURE__ */ jsx15("p", { id: errorId, className: "mt-1 text-xs font-medium text-ph-danger", children: error }) : null
1414
+ ] }));
1415
+ }
1416
+
1417
+ // src/components/ui/Input.tsx
1418
+ import { jsx as jsx16, jsxs as jsxs13 } from "react/jsx-runtime";
1419
+ var sizeMap3 = {
1420
+ sm: "ph-input-sm",
1421
+ md: "",
1422
+ lg: "ph-input-lg"
1423
+ };
1424
+ function joinIds(...ids) {
1425
+ const value = ids.filter(Boolean).join(" ");
1426
+ return value || void 0;
1427
+ }
1428
+ var Input = forwardRef8(function Input2(_a, ref) {
1429
+ var _b = _a, {
1430
+ id: idProp,
1431
+ label,
1432
+ hideLabel = false,
1433
+ error,
1434
+ helperText,
1435
+ size = "md",
1436
+ variant = "default",
1437
+ className,
1438
+ wrapperClassName,
1439
+ disabled,
1440
+ required,
1441
+ "aria-describedby": ariaDescribedBy
1442
+ } = _b, props = __objRest(_b, [
1443
+ "id",
1444
+ "label",
1445
+ "hideLabel",
1446
+ "error",
1447
+ "helperText",
1448
+ "size",
1449
+ "variant",
1450
+ "className",
1451
+ "wrapperClassName",
1452
+ "disabled",
1453
+ "required",
1454
+ "aria-describedby"
1455
+ ]);
1456
+ const autoId = useId3();
1457
+ const id = idProp != null ? idProp : autoId;
1458
+ const hasError = Boolean(error);
1459
+ return /* @__PURE__ */ jsx16(
1460
+ FormField,
1461
+ {
1462
+ controlId: id,
1463
+ label,
1464
+ hideLabel,
1465
+ helperText,
1466
+ error,
1467
+ required,
1468
+ disabled,
1469
+ className: wrapperClassName,
1470
+ children: (fieldProps) => /* @__PURE__ */ jsx16(
1471
+ "input",
1472
+ __spreadValues(__spreadProps(__spreadValues({}, fieldProps), {
1473
+ ref,
1474
+ disabled,
1475
+ required,
1476
+ "aria-describedby": joinIds(ariaDescribedBy, fieldProps["aria-describedby"]),
1477
+ className: cn(
1478
+ "ph-input w-full",
1479
+ sizeMap3[size],
1480
+ variant === "ghost" && "ph-input-ghost",
1481
+ hasError && "ph-input-error",
1482
+ disabled && "cursor-not-allowed opacity-60",
1483
+ className
1484
+ )
1485
+ }), props)
1486
+ )
1487
+ }
1488
+ );
1489
+ });
1490
+ Input.displayName = "Input";
1491
+ var Select = forwardRef8(function Select2(_a, ref) {
1492
+ var _b = _a, {
1493
+ id: idProp,
1494
+ label,
1495
+ hideLabel = false,
1496
+ error,
1497
+ helperText,
1498
+ size = "md",
1499
+ className,
1500
+ wrapperClassName,
1501
+ disabled,
1502
+ children,
1503
+ required,
1504
+ "aria-describedby": ariaDescribedBy
1505
+ } = _b, props = __objRest(_b, [
1506
+ "id",
1507
+ "label",
1508
+ "hideLabel",
1509
+ "error",
1510
+ "helperText",
1511
+ "size",
1512
+ "className",
1513
+ "wrapperClassName",
1514
+ "disabled",
1515
+ "children",
1516
+ "required",
1517
+ "aria-describedby"
1518
+ ]);
1519
+ const autoId = useId3();
1520
+ const id = idProp != null ? idProp : autoId;
1521
+ const hasError = Boolean(error);
1522
+ return /* @__PURE__ */ jsx16(FormField, { controlId: id, label, hideLabel, helperText, error, required, disabled, className: wrapperClassName, children: (fieldProps) => /* @__PURE__ */ jsx16(
1523
+ "select",
1524
+ __spreadProps(__spreadValues(__spreadProps(__spreadValues({}, fieldProps), {
1525
+ ref,
1526
+ disabled,
1527
+ required,
1528
+ "aria-describedby": joinIds(ariaDescribedBy, fieldProps["aria-describedby"]),
1529
+ className: cn(
1530
+ "ph-select w-full",
1531
+ sizeMap3[size],
1532
+ hasError && "ph-input-error",
1533
+ disabled && "cursor-not-allowed opacity-60",
1534
+ className
1535
+ )
1536
+ }), props), {
1537
+ children
1538
+ })
1539
+ ) });
1540
+ });
1541
+ Select.displayName = "Select";
1542
+ var Textarea = forwardRef8(function Textarea2(_a, ref) {
1543
+ var _b = _a, {
1544
+ id: idProp,
1545
+ label,
1546
+ hideLabel = false,
1547
+ error,
1548
+ helperText,
1549
+ size = "md",
1550
+ className,
1551
+ wrapperClassName,
1552
+ disabled,
1553
+ required,
1554
+ "aria-describedby": ariaDescribedBy
1555
+ } = _b, props = __objRest(_b, [
1556
+ "id",
1557
+ "label",
1558
+ "hideLabel",
1559
+ "error",
1560
+ "helperText",
1561
+ "size",
1562
+ "className",
1563
+ "wrapperClassName",
1564
+ "disabled",
1565
+ "required",
1566
+ "aria-describedby"
1567
+ ]);
1568
+ const autoId = useId3();
1569
+ const id = idProp != null ? idProp : autoId;
1570
+ const hasError = Boolean(error);
1571
+ return /* @__PURE__ */ jsx16(FormField, { controlId: id, label, hideLabel, helperText, error, required, disabled, className: wrapperClassName, children: (fieldProps) => /* @__PURE__ */ jsx16(
1572
+ "textarea",
1573
+ __spreadValues(__spreadProps(__spreadValues({}, fieldProps), {
1574
+ ref,
1575
+ disabled,
1576
+ required,
1577
+ "aria-describedby": joinIds(ariaDescribedBy, fieldProps["aria-describedby"]),
1578
+ className: cn(
1579
+ "ph-textarea w-full",
1580
+ sizeMap3[size],
1581
+ hasError && "ph-input-error",
1582
+ disabled && "cursor-not-allowed opacity-60",
1583
+ className
1584
+ )
1585
+ }), props)
1586
+ ) });
1587
+ });
1588
+ Textarea.displayName = "Textarea";
1589
+ var Checkbox = forwardRef8(function Checkbox2(_a, ref) {
1590
+ var _b = _a, {
1591
+ id: idProp,
1592
+ label,
1593
+ error,
1594
+ helperText,
1595
+ className,
1596
+ wrapperClassName,
1597
+ disabled,
1598
+ "aria-describedby": ariaDescribedBy
1599
+ } = _b, props = __objRest(_b, [
1600
+ "id",
1601
+ "label",
1602
+ "error",
1603
+ "helperText",
1604
+ "className",
1605
+ "wrapperClassName",
1606
+ "disabled",
1607
+ "aria-describedby"
1608
+ ]);
1609
+ const autoId = useId3();
1610
+ const id = idProp != null ? idProp : autoId;
1611
+ const hasError = Boolean(error);
1612
+ const descriptionId = helperText && !hasError ? `${id}-description` : void 0;
1613
+ const errorId = error ? `${id}-error` : void 0;
1614
+ return /* @__PURE__ */ jsxs13("div", { className: cn("ph-control-row", wrapperClassName), children: [
1615
+ /* @__PURE__ */ jsxs13("span", { className: "ph-checkbox-wrap", children: [
1616
+ /* @__PURE__ */ jsx16(
1617
+ "input",
1618
+ __spreadValues({
1619
+ ref,
1620
+ id,
1621
+ type: "checkbox",
1622
+ disabled,
1623
+ "aria-invalid": hasError || void 0,
1624
+ "aria-describedby": joinIds(ariaDescribedBy, descriptionId),
1625
+ "aria-errormessage": errorId,
1626
+ className: cn(
1627
+ "ph-checkbox",
1628
+ hasError && "border-ph-danger",
1629
+ disabled && "cursor-not-allowed opacity-60",
1630
+ className
1631
+ )
1632
+ }, props)
1633
+ ),
1634
+ /* @__PURE__ */ jsx16(IconCheck, { className: "ph-checkbox-icon", "aria-hidden": true })
1635
+ ] }),
1636
+ /* @__PURE__ */ jsxs13("div", { className: "ph-control-copy", children: [
1637
+ /* @__PURE__ */ jsx16("label", { htmlFor: id, className: cn("cursor-pointer", disabled && "opacity-60"), children: label }),
1638
+ descriptionId ? /* @__PURE__ */ jsx16("p", { id: descriptionId, className: "text-xs text-ph-subtle", children: helperText }) : null,
1639
+ errorId ? /* @__PURE__ */ jsx16("p", { id: errorId, className: "text-xs font-medium text-ph-danger", children: error }) : null
1640
+ ] })
1641
+ ] });
1642
+ });
1643
+ Checkbox.displayName = "Checkbox";
1644
+ var Radio = forwardRef8(function Radio2(_a, ref) {
1645
+ var _b = _a, {
1646
+ id: idProp,
1647
+ label,
1648
+ className,
1649
+ wrapperClassName,
1650
+ disabled
1651
+ } = _b, props = __objRest(_b, [
1652
+ "id",
1653
+ "label",
1654
+ "className",
1655
+ "wrapperClassName",
1656
+ "disabled"
1657
+ ]);
1658
+ const autoId = useId3();
1659
+ const id = idProp != null ? idProp : autoId;
1660
+ return /* @__PURE__ */ jsxs13("div", { className: cn("ph-control-row", wrapperClassName, disabled && "opacity-60"), children: [
1661
+ /* @__PURE__ */ jsx16(
1662
+ "input",
1663
+ __spreadValues({
1664
+ ref,
1665
+ id,
1666
+ type: "radio",
1667
+ disabled,
1668
+ className: cn("ph-radio", disabled && "cursor-not-allowed", className)
1669
+ }, props)
1670
+ ),
1671
+ /* @__PURE__ */ jsx16("label", { htmlFor: id, className: cn("cursor-pointer", disabled && "opacity-60"), children: label })
1672
+ ] });
1673
+ });
1674
+ Radio.displayName = "Radio";
1675
+ var Toggle = forwardRef8(function Toggle2(_a, ref) {
1676
+ var _b = _a, {
1677
+ id: idProp,
1678
+ label,
1679
+ className,
1680
+ wrapperClassName,
1681
+ disabled
1682
+ } = _b, props = __objRest(_b, [
1683
+ "id",
1684
+ "label",
1685
+ "className",
1686
+ "wrapperClassName",
1687
+ "disabled"
1688
+ ]);
1689
+ const autoId = useId3();
1690
+ const id = idProp != null ? idProp : autoId;
1691
+ return /* @__PURE__ */ jsxs13("label", { className: cn("ph-control-row-between", wrapperClassName, disabled && "opacity-60"), children: [
1692
+ /* @__PURE__ */ jsx16("span", { className: disabled ? "opacity-60" : void 0, children: label }),
1693
+ /* @__PURE__ */ jsx16(
1694
+ "input",
1695
+ __spreadValues({
1696
+ ref,
1697
+ id,
1698
+ type: "checkbox",
1699
+ role: "switch",
1700
+ disabled,
1701
+ className: cn("ph-toggle", disabled && "cursor-not-allowed", className)
1702
+ }, props)
1703
+ )
1704
+ ] });
1705
+ });
1706
+ Toggle.displayName = "Toggle";
1707
+ var Range = forwardRef8(function Range2(_a, ref) {
1708
+ var _b = _a, {
1709
+ id: idProp,
1710
+ label,
1711
+ minLabel,
1712
+ maxLabel,
1713
+ valueLabel,
1714
+ wrapperClassName,
1715
+ className
1716
+ } = _b, props = __objRest(_b, [
1717
+ "id",
1718
+ "label",
1719
+ "minLabel",
1720
+ "maxLabel",
1721
+ "valueLabel",
1722
+ "wrapperClassName",
1723
+ "className"
1724
+ ]);
1725
+ const autoId = useId3();
1726
+ const id = idProp != null ? idProp : autoId;
1727
+ return /* @__PURE__ */ jsxs13("div", { className: cn("ph-field", wrapperClassName), children: [
1728
+ label && /* @__PURE__ */ jsx16("label", { htmlFor: id, className: "ph-label", children: label }),
1729
+ /* @__PURE__ */ jsx16("input", __spreadValues({ ref, id, type: "range", className: cn("ph-range", className) }, props)),
1730
+ (minLabel || valueLabel || maxLabel) && /* @__PURE__ */ jsxs13("div", { className: "flex justify-between text-xs text-ph-mutedtext", children: [
1731
+ /* @__PURE__ */ jsx16("span", { children: minLabel }),
1732
+ /* @__PURE__ */ jsx16("span", { children: valueLabel }),
1733
+ /* @__PURE__ */ jsx16("span", { children: maxLabel })
1734
+ ] })
1735
+ ] });
1736
+ });
1737
+ Range.displayName = "Range";
1738
+ var FileUpload = forwardRef8(function FileUpload2(_a, ref) {
1739
+ var _b = _a, {
1740
+ id: idProp,
1741
+ label,
1742
+ prompt = "Drop file or browse",
1743
+ wrapperClassName,
1744
+ className
1745
+ } = _b, props = __objRest(_b, [
1746
+ "id",
1747
+ "label",
1748
+ "prompt",
1749
+ "wrapperClassName",
1750
+ "className"
1751
+ ]);
1752
+ const autoId = useId3();
1753
+ const id = idProp != null ? idProp : autoId;
1754
+ return /* @__PURE__ */ jsxs13("div", { className: cn("ph-field", wrapperClassName), children: [
1755
+ label && /* @__PURE__ */ jsx16("label", { htmlFor: id, className: "ph-label", children: label }),
1756
+ /* @__PURE__ */ jsxs13("label", { htmlFor: id, className: "ph-file-upload", children: [
1757
+ /* @__PURE__ */ jsx16("input", __spreadValues({ ref, id, type: "file", className: cn("sr-only", className) }, props)),
1758
+ prompt
1759
+ ] })
1760
+ ] });
1761
+ });
1762
+ FileUpload.displayName = "FileUpload";
1763
+
1764
+ // src/components/ui/Modal.tsx
1765
+ import * as Dialog from "@radix-ui/react-dialog";
1766
+ import { useRef } from "react";
1767
+ import { jsx as jsx17, jsxs as jsxs14 } from "react/jsx-runtime";
1768
+ var sizeMap4 = {
1769
+ sm: "max-w-sm",
1770
+ md: "max-w-lg",
1771
+ lg: "max-w-2xl",
1772
+ xl: "max-w-4xl",
1773
+ full: "max-w-none"
1774
+ };
1775
+ function Modal({
1776
+ open = false,
1777
+ onClose,
1778
+ title,
1779
+ description,
1780
+ children,
1781
+ footer,
1782
+ size = "md",
1783
+ className,
1784
+ showCloseButton = true,
1785
+ closeOnOutsideClick = true,
1786
+ closeOnEscape = true,
1787
+ "aria-label": ariaLabel
1788
+ }) {
1789
+ const canDismiss = Boolean(onClose);
1790
+ const restoreFocusRef = useRef(null);
1791
+ return /* @__PURE__ */ jsx17(
1792
+ Dialog.Root,
1793
+ {
1794
+ open,
1795
+ onOpenChange: (nextOpen) => {
1796
+ if (!nextOpen) onClose == null ? void 0 : onClose();
1797
+ },
1798
+ children: /* @__PURE__ */ jsxs14(Dialog.Portal, { children: [
1799
+ /* @__PURE__ */ jsx17(Dialog.Overlay, { className: "ph-modal-overlay" }),
1800
+ /* @__PURE__ */ jsxs14(
1801
+ Dialog.Content,
1802
+ __spreadProps(__spreadValues({
1803
+ className: cn("ph-modal-panel", sizeMap4[size], className),
1804
+ "aria-label": ariaLabel
1805
+ }, description ? {} : { "aria-describedby": void 0 }), {
1806
+ onOpenAutoFocus: () => {
1807
+ restoreFocusRef.current = document.activeElement instanceof HTMLElement ? document.activeElement : null;
1808
+ },
1809
+ onCloseAutoFocus: (event) => {
1810
+ var _a;
1811
+ event.preventDefault();
1812
+ (_a = restoreFocusRef.current) == null ? void 0 : _a.focus();
1813
+ },
1814
+ onEscapeKeyDown: (event) => {
1815
+ if (!canDismiss || !closeOnEscape) event.preventDefault();
1816
+ },
1817
+ onPointerDownOutside: (event) => {
1818
+ if (!canDismiss || !closeOnOutsideClick) event.preventDefault();
1819
+ },
1820
+ children: [
1821
+ title ? null : /* @__PURE__ */ jsx17(Dialog.Title, { className: "sr-only", children: ariaLabel != null ? ariaLabel : "Dialog" }),
1822
+ title || description || showCloseButton && canDismiss ? /* @__PURE__ */ jsxs14("header", { className: "ph-modal-header", children: [
1823
+ /* @__PURE__ */ jsxs14("div", { className: "min-w-0", children: [
1824
+ title ? /* @__PURE__ */ jsx17(Dialog.Title, { className: "text-lg font-bold text-ph-ink", children: title }) : null,
1825
+ description ? /* @__PURE__ */ jsx17(Dialog.Description, { className: "mt-1 text-sm text-ph-subtle", children: description }) : null
1826
+ ] }),
1827
+ showCloseButton && canDismiss ? /* @__PURE__ */ jsx17(Dialog.Close, { asChild: true, children: /* @__PURE__ */ jsx17("button", { type: "button", className: "ph-modal-close", "aria-label": "Close dialog", children: /* @__PURE__ */ jsx17(IconClose, { className: "h-5 w-5", "aria-hidden": true }) }) }) : null
1828
+ ] }) : null,
1829
+ /* @__PURE__ */ jsx17("div", { className: "ph-modal-body", children }),
1830
+ footer ? /* @__PURE__ */ jsx17("div", { className: "ph-modal-footer", children: footer }) : null
1831
+ ]
1832
+ })
1833
+ )
1834
+ ] })
1835
+ }
1836
+ );
1837
+ }
1838
+
1839
+ // src/components/ui/Navigation.tsx
1840
+ import { jsx as jsx18, jsxs as jsxs15 } from "react/jsx-runtime";
1841
+ function Breadcrumbs({ items, label = "Breadcrumb", className }) {
1842
+ return /* @__PURE__ */ jsx18("nav", { "aria-label": label, className: cn("ph-breadcrumbs", className), children: items.map((item, index) => /* @__PURE__ */ jsxs15("span", { className: "contents", children: [
1843
+ index > 0 ? /* @__PURE__ */ jsx18("span", { className: "ph-breadcrumb-sep", "aria-hidden": "true", children: "/" }) : null,
1844
+ item.current || !item.href ? /* @__PURE__ */ jsx18("span", { className: "ph-breadcrumb-current", "aria-current": item.current ? "page" : void 0, children: item.label }) : /* @__PURE__ */ jsx18("a", { href: item.href, className: "ph-breadcrumb-link", children: item.label })
1845
+ ] }, `${item.label}-${index}`)) });
1846
+ }
1847
+ function Pagination({
1848
+ page,
1849
+ totalPages,
1850
+ onPageChange,
1851
+ label = "Pagination",
1852
+ compact = false,
1853
+ className
1854
+ }) {
1855
+ const pages = compact ? [Math.max(1, page - 1), page, Math.min(totalPages, page + 1)] : [1, 2, 3, totalPages];
1856
+ const uniquePages = Array.from(new Set(pages)).filter((n) => n >= 1 && n <= totalPages);
1857
+ return /* @__PURE__ */ jsxs15("nav", { "aria-label": label, className: cn("ph-pagination", className), children: [
1858
+ /* @__PURE__ */ jsx18(
1859
+ "button",
1860
+ {
1861
+ type: "button",
1862
+ className: "ph-pagination-btn",
1863
+ disabled: page <= 1,
1864
+ "aria-label": "Previous page",
1865
+ onClick: () => onPageChange == null ? void 0 : onPageChange(page - 1),
1866
+ children: /* @__PURE__ */ jsx18(IconChevronLeft, { className: "mx-auto h-4 w-4", "aria-hidden": true })
1867
+ }
1868
+ ),
1869
+ uniquePages.map((pageNumber, index) => /* @__PURE__ */ jsxs15("span", { className: "contents", children: [
1870
+ !compact && index === uniquePages.length - 1 && pageNumber > 4 ? /* @__PURE__ */ jsx18("span", { className: "ph-pagination-ellipsis", "aria-hidden": "true", children: "..." }) : null,
1871
+ /* @__PURE__ */ jsx18(
1872
+ "button",
1873
+ {
1874
+ type: "button",
1875
+ className: cn("ph-pagination-btn", pageNumber === page && "ph-pagination-btn-active"),
1876
+ "aria-current": pageNumber === page ? "page" : void 0,
1877
+ onClick: () => onPageChange == null ? void 0 : onPageChange(pageNumber),
1878
+ children: pageNumber
1879
+ }
1880
+ )
1881
+ ] }, pageNumber)),
1882
+ /* @__PURE__ */ jsx18(
1883
+ "button",
1884
+ {
1885
+ type: "button",
1886
+ className: "ph-pagination-btn",
1887
+ disabled: page >= totalPages,
1888
+ "aria-label": "Next page",
1889
+ onClick: () => onPageChange == null ? void 0 : onPageChange(page + 1),
1890
+ children: /* @__PURE__ */ jsx18(IconChevronRight, { className: "mx-auto h-4 w-4", "aria-hidden": true })
1891
+ }
1892
+ )
1893
+ ] });
1894
+ }
1895
+
1896
+ // src/components/ui/Panel.tsx
1897
+ import { jsx as jsx19, jsxs as jsxs16 } from "react/jsx-runtime";
1898
+ function Panel(_a) {
1899
+ var _b = _a, { title, description, children, className } = _b, props = __objRest(_b, ["title", "description", "children", "className"]);
1900
+ return /* @__PURE__ */ jsxs16("div", __spreadProps(__spreadValues({ className: cn("ph-panel", className) }, props), { children: [
1901
+ title && /* @__PURE__ */ jsx19("h3", { className: "text-sm font-semibold uppercase tracking-wider text-ph-mutedtext", children: title }),
1902
+ description && /* @__PURE__ */ jsx19("p", { className: "text-sm text-ph-subtle", children: description }),
1903
+ children
1904
+ ] }));
1905
+ }
1906
+
1907
+ // src/components/ui/Rating.tsx
1908
+ import { jsx as jsx20, jsxs as jsxs17 } from "react/jsx-runtime";
1909
+ function Rating(_a) {
1910
+ var _b = _a, {
1911
+ label,
1912
+ value = 0,
1913
+ max = 5,
1914
+ readOnly = true,
1915
+ onChange,
1916
+ className,
1917
+ wrapperClassName
1918
+ } = _b, props = __objRest(_b, [
1919
+ "label",
1920
+ "value",
1921
+ "max",
1922
+ "readOnly",
1923
+ "onChange",
1924
+ "className",
1925
+ "wrapperClassName"
1926
+ ]);
1927
+ const stars = Array.from({ length: max }, (_, index) => index + 1);
1928
+ return /* @__PURE__ */ jsxs17("div", { className: cn("ph-field", wrapperClassName), children: [
1929
+ label && /* @__PURE__ */ jsx20("span", { className: "ph-label", children: label }),
1930
+ /* @__PURE__ */ jsx20(
1931
+ "div",
1932
+ __spreadProps(__spreadValues({
1933
+ className: cn("ph-rating flex", className),
1934
+ role: readOnly ? "img" : "radiogroup",
1935
+ "aria-label": label != null ? label : `Rating: ${value} out of ${max}`
1936
+ }, props), {
1937
+ children: stars.map((star) => {
1938
+ const active = star <= value;
1939
+ if (readOnly) {
1940
+ return /* @__PURE__ */ jsx20(
1941
+ IconStar,
1942
+ {
1943
+ className: cn("h-6 w-6", active ? "text-amber-500" : "text-ph-border"),
1944
+ "aria-hidden": true
1945
+ },
1946
+ star
1947
+ );
1948
+ }
1949
+ return /* @__PURE__ */ jsx20(
1950
+ "button",
1951
+ {
1952
+ type: "button",
1953
+ className: "rounded p-0.5 transition hover:scale-105 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-ph-brand",
1954
+ role: "radio",
1955
+ "aria-checked": active,
1956
+ "aria-label": `${star} out of ${max}`,
1957
+ onClick: () => onChange == null ? void 0 : onChange(star),
1958
+ children: /* @__PURE__ */ jsx20(IconStar, { className: cn("h-6 w-6", active ? "text-amber-500" : "text-ph-border") })
1959
+ },
1960
+ star
1961
+ );
1962
+ })
1963
+ })
1964
+ )
1965
+ ] });
1966
+ }
1967
+
1968
+ // src/components/ui/SearchInput.tsx
1969
+ import { useId as useId4 } from "react";
1970
+ import { jsx as jsx21, jsxs as jsxs18 } from "react/jsx-runtime";
1971
+ function SearchInput(_a) {
1972
+ var _b = _a, {
1973
+ id: idProp,
1974
+ label = "Search",
1975
+ hideLabel = false,
1976
+ shortcut,
1977
+ density = "default",
1978
+ className,
1979
+ wrapperClassName,
1980
+ placeholder
1981
+ } = _b, props = __objRest(_b, [
1982
+ "id",
1983
+ "label",
1984
+ "hideLabel",
1985
+ "shortcut",
1986
+ "density",
1987
+ "className",
1988
+ "wrapperClassName",
1989
+ "placeholder"
1990
+ ]);
1991
+ const autoId = useId4();
1992
+ const id = idProp != null ? idProp : autoId;
1993
+ return /* @__PURE__ */ jsxs18("div", { className: cn("relative", wrapperClassName), children: [
1994
+ /* @__PURE__ */ jsx21("label", { htmlFor: id, className: hideLabel ? "sr-only" : "ph-label mb-1.5 block", children: label }),
1995
+ /* @__PURE__ */ jsxs18("div", { className: "relative", children: [
1996
+ shortcut != null ? /* @__PURE__ */ jsx21(
1997
+ "span",
1998
+ {
1999
+ className: "ph-shortcut pointer-events-none absolute left-3 top-1/2 z-10 -translate-y-1/2 text-xs",
2000
+ "aria-hidden": true,
2001
+ children: shortcut
2002
+ }
2003
+ ) : null,
2004
+ /* @__PURE__ */ jsx21(
2005
+ "input",
2006
+ __spreadValues({
2007
+ id,
2008
+ type: "search",
2009
+ placeholder,
2010
+ "aria-label": hideLabel ? label : void 0,
2011
+ className: cn(
2012
+ "ph-input w-full",
2013
+ density === "compact" && "max-w-xs !min-h-[2rem] py-1.5 text-sm",
2014
+ shortcut != null && "pl-[3.25rem]",
2015
+ className
2016
+ )
2017
+ }, props)
2018
+ )
2019
+ ] })
2020
+ ] });
2021
+ }
2022
+ function SearchGroup(_a) {
2023
+ var _b = _a, {
2024
+ id: idProp,
2025
+ label = "Search records",
2026
+ submitLabel = "Search",
2027
+ placeholder = "Persons, actions, flags\u2026",
2028
+ wrapperClassName,
2029
+ className
2030
+ } = _b, props = __objRest(_b, [
2031
+ "id",
2032
+ "label",
2033
+ "submitLabel",
2034
+ "placeholder",
2035
+ "wrapperClassName",
2036
+ "className"
2037
+ ]);
2038
+ const autoId = useId4();
2039
+ const id = idProp != null ? idProp : autoId;
2040
+ return /* @__PURE__ */ jsxs18("div", { className: cn("ph-field", wrapperClassName), children: [
2041
+ /* @__PURE__ */ jsx21("label", { htmlFor: id, className: "ph-label", children: label }),
2042
+ /* @__PURE__ */ jsxs18("div", { className: "ph-search-group flex w-full max-w-lg min-h-[2.3125rem] items-stretch divide-x divide-ph-border", children: [
2043
+ /* @__PURE__ */ jsx21(
2044
+ "input",
2045
+ __spreadValues({
2046
+ id,
2047
+ type: "search",
2048
+ placeholder,
2049
+ className: cn("ph-input ph-input-group-field min-w-0 flex-1", className)
2050
+ }, props)
2051
+ ),
2052
+ /* @__PURE__ */ jsx21(
2053
+ Button,
2054
+ {
2055
+ type: "submit",
2056
+ variant: "primary",
2057
+ icon: /* @__PURE__ */ jsx21(IconSearch, { className: "h-4 w-4", "aria-hidden": true }),
2058
+ className: "ph-search-group__submit",
2059
+ "aria-label": submitLabel
2060
+ }
2061
+ )
2062
+ ] })
2063
+ ] });
2064
+ }
2065
+
2066
+ // src/components/ui/Table.tsx
2067
+ import { jsx as jsx22, jsxs as jsxs19 } from "react/jsx-runtime";
2068
+ function Table({
2069
+ data,
2070
+ columns,
2071
+ zebra = false,
2072
+ compact = false,
2073
+ ribbon = false,
2074
+ getRowStyle,
2075
+ className,
2076
+ caption
2077
+ }) {
2078
+ return /* @__PURE__ */ jsx22("div", { className: cn("ph-table-wrap", compact && "ph-table-compact", className), children: /* @__PURE__ */ jsxs19("table", { className: cn("ph-table", zebra && "ph-table-zebra", ribbon && "ph-table--ribbon"), children: [
2079
+ caption && /* @__PURE__ */ jsx22("caption", { className: "sr-only", children: caption }),
2080
+ /* @__PURE__ */ jsx22("thead", { children: /* @__PURE__ */ jsx22("tr", { children: columns.map((col) => /* @__PURE__ */ jsx22("th", { className: col.className, children: col.header }, col.key)) }) }),
2081
+ /* @__PURE__ */ jsx22("tbody", { children: data.map((row, i) => /* @__PURE__ */ jsx22("tr", { style: getRowStyle == null ? void 0 : getRowStyle(row), children: columns.map((col) => /* @__PURE__ */ jsx22("td", { className: col.className, children: col.cell(row) }, col.key)) }, i)) })
2082
+ ] }) });
2083
+ }
2084
+
2085
+ // src/components/ui/Stat.tsx
2086
+ import { jsx as jsx23, jsxs as jsxs20 } from "react/jsx-runtime";
2087
+ var toneMap = {
2088
+ default: "text-ph-ink",
2089
+ brand: "text-ph-brand",
2090
+ blue: "text-ph-blue",
2091
+ purple: "text-ph-purple",
2092
+ warning: "text-amber-900"
2093
+ };
2094
+ var statMap = {
2095
+ default: "",
2096
+ brand: "",
2097
+ blue: "",
2098
+ purple: "",
2099
+ warning: "border-amber-200 bg-amber-50/70"
2100
+ };
2101
+ function Stat(_a) {
2102
+ var _b = _a, { icon, label, value, footer, tone = "default", className } = _b, props = __objRest(_b, ["icon", "label", "value", "footer", "tone", "className"]);
2103
+ return /* @__PURE__ */ jsxs20("article", __spreadProps(__spreadValues({ className: cn("ph-stat", statMap[tone], className) }, props), { children: [
2104
+ icon && /* @__PURE__ */ jsx23("div", { className: cn("mb-2 h-7 w-7", toneMap[tone]), children: icon }),
2105
+ /* @__PURE__ */ jsx23("div", { className: cn("ph-stat-label", tone === "warning" && toneMap[tone]), children: label }),
2106
+ /* @__PURE__ */ jsx23("div", { className: cn("ph-stat-val", toneMap[tone]), children: value }),
2107
+ footer && /* @__PURE__ */ jsx23("p", { className: "text-xs text-ph-subtle", children: footer })
2108
+ ] }));
2109
+ }
2110
+
2111
+ // src/components/ui/Toast.tsx
2112
+ import { jsx as jsx24, jsxs as jsxs21 } from "react/jsx-runtime";
2113
+ var statusConfig2 = {
2114
+ info: { icon: IconErrorOutline, color: "text-ph-info", bg: "ph-toast-info" },
2115
+ success: { icon: IconCheckCircle, color: "text-ph-success", bg: "ph-toast-success" },
2116
+ warning: { icon: IconExclamation, color: "text-ph-warning", bg: "ph-toast-warning" },
2117
+ danger: { icon: IconCancel, color: "text-ph-danger", bg: "ph-toast-danger" }
2118
+ };
2119
+ function Toast({
2120
+ status = "info",
2121
+ title,
2122
+ description,
2123
+ onDismiss,
2124
+ className
2125
+ }) {
2126
+ const config = statusConfig2[status];
2127
+ const Icon = config.icon;
2128
+ return /* @__PURE__ */ jsxs21("div", { className: cn("ph-toast", config.bg, className), children: [
2129
+ /* @__PURE__ */ jsx24(Icon, { className: cn("mt-0.5 h-5 w-5 shrink-0", config.color), "aria-hidden": true }),
2130
+ /* @__PURE__ */ jsxs21("div", { className: "pr-8", children: [
2131
+ /* @__PURE__ */ jsx24("div", { className: "font-semibold", children: title }),
2132
+ description && /* @__PURE__ */ jsx24("p", { className: "mt-1 text-xs text-ph-subtle", children: description })
2133
+ ] }),
2134
+ onDismiss && /* @__PURE__ */ jsx24(
2135
+ "button",
2136
+ {
2137
+ type: "button",
2138
+ "aria-label": `Dismiss ${title}`,
2139
+ className: "absolute right-2 top-2 ph-btn ph-btn-ghost ph-btn-xs ph-btn-circle",
2140
+ onClick: onDismiss,
2141
+ children: /* @__PURE__ */ jsx24(IconClose, { className: "h-4 w-4" })
2142
+ }
2143
+ )
2144
+ ] });
2145
+ }
2146
+ function ToastStack({ children, className }) {
2147
+ return /* @__PURE__ */ jsx24("div", { className: cn("ph-toast-stack", className), children });
2148
+ }
2149
+
2150
+ // src/components/ui/Tabs.tsx
2151
+ import { jsx as jsx25 } from "react/jsx-runtime";
2152
+ function Tabs({ items, value, onChange, variant = "pill", className }) {
2153
+ if (variant === "underline") {
2154
+ return /* @__PURE__ */ jsx25("div", { className: cn("flex gap-6 border-b border-ph-border", className), children: items.map((item) => /* @__PURE__ */ jsx25(
2155
+ "button",
2156
+ {
2157
+ type: "button",
2158
+ onClick: () => onChange(item.value),
2159
+ className: cn(
2160
+ "-mb-px border-b-2 pb-2 text-sm font-semibold transition",
2161
+ value === item.value ? "border-ph-brand text-ph-ink" : "border-transparent text-ph-mutedtext hover:text-ph-ink"
2162
+ ),
2163
+ children: item.label
2164
+ },
2165
+ item.value
2166
+ )) });
2167
+ }
2168
+ return /* @__PURE__ */ jsx25("div", { className: cn("ph-tabs-row inline-flex", className), children: items.map((item) => /* @__PURE__ */ jsx25(
2169
+ "button",
2170
+ {
2171
+ type: "button",
2172
+ onClick: () => onChange(item.value),
2173
+ className: cn("ph-tab", value === item.value && "ph-tab-active"),
2174
+ children: item.label
2175
+ },
2176
+ item.value
2177
+ )) });
2178
+ }
2179
+
2180
+ // src/components/ui/ThemeDomSync.tsx
2181
+ import { useLayoutEffect } from "react";
2182
+
2183
+ // src/themes/registry.ts
2184
+ var DEFAULT_THEME_ID = "hedgehog-light";
2185
+ var THEMES = [
2186
+ {
2187
+ id: "hedgehog-light",
2188
+ name: "HedgeHog Light",
2189
+ description: "Default Quill warm greys and orange Lemon chrome.",
2190
+ colorScheme: "light",
2191
+ group: "HedgeHog"
2192
+ },
2193
+ {
2194
+ id: "hedgehog-dark",
2195
+ name: "HedgeHog Dark",
2196
+ description: "Dark app shell with HedgeHog orange accents.",
2197
+ colorScheme: "dark",
2198
+ group: "HedgeHog"
2199
+ },
2200
+ {
2201
+ id: "catppuccin-light",
2202
+ name: "Catppuccin Light",
2203
+ description: "Catppuccin Latte \u2014 soft pastels and mauve accent.",
2204
+ colorScheme: "light",
2205
+ group: "Catppuccin"
2206
+ },
2207
+ {
2208
+ id: "catppuccin-dark",
2209
+ name: "Catppuccin Dark",
2210
+ description: "Catppuccin Mocha \u2014 deep base and lavender peach.",
2211
+ colorScheme: "dark",
2212
+ group: "Catppuccin"
2213
+ },
2214
+ {
2215
+ id: "sheets",
2216
+ name: "Sheets",
2217
+ description: "Spreadsheet green on office neutrals.",
2218
+ colorScheme: "light",
2219
+ group: "Productivity"
2220
+ },
2221
+ {
2222
+ id: "sheets-dark",
2223
+ name: "Sheets Dark",
2224
+ description: "Dark shell with spreadsheet green accent.",
2225
+ colorScheme: "dark",
2226
+ group: "Productivity"
2227
+ },
2228
+ {
2229
+ id: "note",
2230
+ name: "Note",
2231
+ description: "Notebook purple on lavender-white chrome.",
2232
+ colorScheme: "light",
2233
+ group: "Productivity"
2234
+ },
2235
+ {
2236
+ id: "note-dark",
2237
+ name: "Note Dark",
2238
+ description: "Dark notebook purple \u2014 night reading mode.",
2239
+ colorScheme: "dark",
2240
+ group: "Productivity"
2241
+ },
2242
+ {
2243
+ id: "presentation",
2244
+ name: "Presentation",
2245
+ description: "Orange-red on office neutrals.",
2246
+ colorScheme: "light",
2247
+ group: "Productivity"
2248
+ },
2249
+ {
2250
+ id: "presentation-dark",
2251
+ name: "Presentation Dark",
2252
+ description: "Dark shell with orange-red accent.",
2253
+ colorScheme: "dark",
2254
+ group: "Productivity"
2255
+ },
2256
+ {
2257
+ id: "socials",
2258
+ name: "Socials",
2259
+ description: "Meta blue accent on familiar social greys.",
2260
+ colorScheme: "light",
2261
+ group: "Social"
2262
+ },
2263
+ {
2264
+ id: "socials-dark",
2265
+ name: "Socials Dark",
2266
+ description: "Social dark mode \u2014 #18191A base and Meta blue.",
2267
+ colorScheme: "dark",
2268
+ group: "Social"
2269
+ },
2270
+ {
2271
+ id: "chats-light",
2272
+ name: "Chats Light",
2273
+ description: "Aubergine brand on clean workspace neutrals.",
2274
+ colorScheme: "light",
2275
+ group: "Chats"
2276
+ },
2277
+ {
2278
+ id: "chats-dark",
2279
+ name: "Chats Dark",
2280
+ description: "Dark sidebar \u2014 #1A1D21 base and green highlights.",
2281
+ colorScheme: "dark",
2282
+ group: "Chats"
2283
+ },
2284
+ {
2285
+ id: "xenide-light",
2286
+ name: "Xenide Light",
2287
+ description: "xenide.io light \u2014 Excel green + purple on neutral greys.",
2288
+ colorScheme: "light",
2289
+ group: "Xenide"
2290
+ },
2291
+ {
2292
+ id: "xenide-dark",
2293
+ name: "Xenide Dark",
2294
+ description: "xenide.io dark \u2014 #0A0A0F base, emerald green + violet.",
2295
+ colorScheme: "dark",
2296
+ group: "Xenide"
2297
+ },
2298
+ {
2299
+ id: "bikini-bottom",
2300
+ name: "Bikini Bottom",
2301
+ description: "SpongeBob palette \u2014 ocean canvas, readable surfaces, character accents.",
2302
+ colorScheme: "light",
2303
+ group: "Fun"
2304
+ },
2305
+ {
2306
+ id: "bikini-bottom-dark",
2307
+ name: "Bikini Bottom Dark",
2308
+ description: "Bikini Bottom at night \u2014 deep ocean with neon character accents.",
2309
+ colorScheme: "dark",
2310
+ group: "Fun"
2311
+ },
2312
+ {
2313
+ id: "turtletime",
2314
+ name: "TurtleTime",
2315
+ description: "Turtle mascot palette \u2014 shell orange, leaf green, and warm cream.",
2316
+ colorScheme: "light",
2317
+ group: "Fun"
2318
+ },
2319
+ {
2320
+ id: "turtletime-dark",
2321
+ name: "TurtleTime Dark",
2322
+ description: "TurtleTime after dusk \u2014 dark olive shell with bright orange clock accents.",
2323
+ colorScheme: "dark",
2324
+ group: "Fun"
2325
+ },
2326
+ {
2327
+ id: "github-light",
2328
+ name: "GitHub Light",
2329
+ description: "GitHub Primer \u2014 #f6f8fa canvas and emphasis blue accents.",
2330
+ colorScheme: "light",
2331
+ group: "GitHub"
2332
+ },
2333
+ {
2334
+ id: "github-dark",
2335
+ name: "GitHub Dark",
2336
+ description: "GitHub dark dimmed \u2014 #0d1117 base and #4493f8 links.",
2337
+ colorScheme: "dark",
2338
+ group: "GitHub"
2339
+ },
2340
+ {
2341
+ id: "rosepine-light",
2342
+ name: "Ros\xE9 Pine Dawn",
2343
+ description: "Ros\xE9 Pine Dawn \u2014 warm paper base with muted iris accents.",
2344
+ colorScheme: "light",
2345
+ group: "Ros\xE9 Pine"
2346
+ },
2347
+ {
2348
+ id: "rosepine-dark",
2349
+ name: "Ros\xE9 Pine",
2350
+ description: "Ros\xE9 Pine Main \u2014 moonlit base with iris and love accents.",
2351
+ colorScheme: "dark",
2352
+ group: "Ros\xE9 Pine"
2353
+ },
2354
+ {
2355
+ id: "notion",
2356
+ name: "Notion",
2357
+ description: "Notion light \u2014 warm off-white canvas, Notion blue accent, signature dark text.",
2358
+ colorScheme: "light",
2359
+ group: "Productivity"
2360
+ },
2361
+ {
2362
+ id: "notion-dark",
2363
+ name: "Notion Dark",
2364
+ description: "Notion dark mode \u2014 dark charcoal canvas with blue accent and clean typography.",
2365
+ colorScheme: "dark",
2366
+ group: "Productivity"
2367
+ },
2368
+ {
2369
+ id: "deepsea-light",
2370
+ name: "Tokyo Night Day",
2371
+ description: "Tokyo Night Day \u2014 soft bluish greys with vivid blue and purple accents.",
2372
+ colorScheme: "light",
2373
+ group: "Tokyo Night"
2374
+ },
2375
+ {
2376
+ id: "deepsea-dark",
2377
+ name: "Tokyo Night",
2378
+ description: "Tokyo Night \u2014 #1a1b26 base with signature blue, cyan, and purple.",
2379
+ colorScheme: "dark",
2380
+ group: "Tokyo Night"
2381
+ },
2382
+ {
2383
+ id: "kraken-light",
2384
+ name: "Kraken Light",
2385
+ description: "Medium-inspired warm paper, editorial black actions, and classic publication yellow.",
2386
+ colorScheme: "light",
2387
+ group: "Kraken"
2388
+ },
2389
+ {
2390
+ id: "kraken-dark",
2391
+ name: "Kraken Dark",
2392
+ description: "Medium-inspired night reading canvas with white actions and classic publication yellow.",
2393
+ colorScheme: "dark",
2394
+ group: "Kraken"
2395
+ }
2396
+ ];
2397
+ var THEME_GROUPS = Array.from(new Set(THEMES.map((theme) => theme.group)));
2398
+ function isThemeId(value) {
2399
+ return THEMES.some((theme) => theme.id === value);
2400
+ }
2401
+ function getTheme(id) {
2402
+ return THEMES.find((theme) => theme.id === id);
2403
+ }
2404
+
2405
+ // src/themes/init-theme.ts
2406
+ var STORAGE_KEY = "ph-theme";
2407
+ var VALID_THEMES = THEMES.map((theme) => theme.id);
2408
+ var THEME_INIT_SCRIPT = `(function(){try{var k="${STORAGE_KEY}",d="${DEFAULT_THEME_ID}",v=${JSON.stringify(VALID_THEMES)},t=localStorage.getItem(k);if(t==="xenide")t="xenide-light";if(!t||v.indexOf(t)<0)t=d;document.documentElement.setAttribute("data-theme",t)}catch(e){document.documentElement.setAttribute("data-theme","${DEFAULT_THEME_ID}")}})();`;
2409
+ function persistTheme(themeId) {
2410
+ if (typeof window === "undefined") {
2411
+ return;
2412
+ }
2413
+ if (!isThemeId(themeId)) {
2414
+ return;
2415
+ }
2416
+ document.documentElement.setAttribute("data-theme", themeId);
2417
+ localStorage.setItem(STORAGE_KEY, themeId);
2418
+ }
2419
+ function readStoredTheme() {
2420
+ if (typeof window === "undefined") {
2421
+ return DEFAULT_THEME_ID;
2422
+ }
2423
+ const stored = localStorage.getItem(STORAGE_KEY);
2424
+ if (stored === "xenide") {
2425
+ return "xenide-light";
2426
+ }
2427
+ return stored && isThemeId(stored) ? stored : DEFAULT_THEME_ID;
2428
+ }
2429
+
2430
+ // src/components/ui/ThemeDomSync.tsx
2431
+ function ThemeDomSync() {
2432
+ useLayoutEffect(() => {
2433
+ persistTheme(readStoredTheme());
2434
+ }, []);
2435
+ return null;
2436
+ }
2437
+
2438
+ // src/components/ui/ThemeManager.tsx
2439
+ import { useLayoutEffect as useLayoutEffect2 } from "react";
2440
+ import { Fragment as Fragment4, jsx as jsx26 } from "react/jsx-runtime";
2441
+ function ThemeManager({ children }) {
2442
+ useLayoutEffect2(() => {
2443
+ persistTheme(readStoredTheme());
2444
+ }, []);
2445
+ return /* @__PURE__ */ jsx26(Fragment4, { children });
2446
+ }
2447
+
2448
+ // src/components/ui/ThemeSwitcher.tsx
2449
+ import { useEffect, useState } from "react";
2450
+ import { jsx as jsx27, jsxs as jsxs22 } from "react/jsx-runtime";
2451
+ function ThemeSwitcher({ className }) {
2452
+ const [themeId, setThemeId] = useState("hedgehog-light");
2453
+ useEffect(() => {
2454
+ const id = readStoredTheme();
2455
+ persistTheme(id);
2456
+ setThemeId(id);
2457
+ }, []);
2458
+ return /* @__PURE__ */ jsxs22("label", { className: cn("flex min-w-0 items-center gap-2", className), children: [
2459
+ /* @__PURE__ */ jsx27("span", { className: "shrink-0 text-xs font-medium text-ph-mutedtext sm:text-sm", children: "Theme" }),
2460
+ /* @__PURE__ */ jsx27(
2461
+ "select",
2462
+ {
2463
+ className: "ph-select max-w-[11rem] !min-h-[2rem] py-1 pl-2.5 pr-8 text-xs sm:max-w-[14rem] sm:text-sm",
2464
+ value: themeId,
2465
+ "aria-label": "Colour theme",
2466
+ onChange: (event) => {
2467
+ const next = event.target.value;
2468
+ persistTheme(next);
2469
+ setThemeId(next);
2470
+ },
2471
+ children: THEME_GROUPS.map((group) => /* @__PURE__ */ jsx27("optgroup", { label: group, children: THEMES.filter((theme) => theme.group === group).map((theme) => /* @__PURE__ */ jsx27("option", { value: theme.id, children: theme.name }, theme.id)) }, group))
2472
+ }
2473
+ )
2474
+ ] });
2475
+ }
2476
+
2477
+ // src/components/ui/Accordion.tsx
2478
+ import { useState as useState2 } from "react";
2479
+ import { jsx as jsx28, jsxs as jsxs23 } from "react/jsx-runtime";
2480
+ function Accordion({
2481
+ items,
2482
+ allowMultiple = false,
2483
+ defaultOpen = [],
2484
+ className
2485
+ }) {
2486
+ const [openItems, setOpenItems] = useState2(new Set(defaultOpen));
2487
+ const toggleItem = (id) => {
2488
+ setOpenItems((prev) => {
2489
+ const next = new Set(prev);
2490
+ if (next.has(id)) {
2491
+ next.delete(id);
2492
+ } else {
2493
+ if (!allowMultiple) {
2494
+ next.clear();
2495
+ }
2496
+ next.add(id);
2497
+ }
2498
+ return next;
2499
+ });
2500
+ };
2501
+ return /* @__PURE__ */ jsx28("div", { className: cn("divide-y divide-ph-border rounded-xl border border-ph-border bg-ph-surface", className), children: items.map((item) => {
2502
+ const isOpen = openItems.has(item.id);
2503
+ return /* @__PURE__ */ jsxs23("div", { className: "first:rounded-t-xl last:rounded-b-xl", children: [
2504
+ /* @__PURE__ */ jsxs23(
2505
+ "button",
2506
+ {
2507
+ type: "button",
2508
+ onClick: () => toggleItem(item.id),
2509
+ className: "flex w-full items-center justify-between px-5 py-4 text-left transition hover:bg-ph-muted",
2510
+ children: [
2511
+ /* @__PURE__ */ jsx28("span", { className: "font-semibold text-ph-ink", children: item.title }),
2512
+ /* @__PURE__ */ jsx28(
2513
+ IconChevronDown,
2514
+ {
2515
+ className: cn(
2516
+ "h-5 w-5 text-ph-mutedtext transition-transform duration-200",
2517
+ isOpen && "rotate-180"
2518
+ )
2519
+ }
2520
+ )
2521
+ ]
2522
+ }
2523
+ ),
2524
+ /* @__PURE__ */ jsx28(
2525
+ "div",
2526
+ {
2527
+ className: cn(
2528
+ "grid transition-all duration-200",
2529
+ isOpen ? "grid-rows-[1fr]" : "grid-rows-[0fr]"
2530
+ ),
2531
+ children: /* @__PURE__ */ jsx28("div", { className: "overflow-hidden", children: /* @__PURE__ */ jsx28("div", { className: "px-5 pb-4 text-ph-subtle", children: item.content }) })
2532
+ }
2533
+ )
2534
+ ] }, item.id);
2535
+ }) });
2536
+ }
2537
+
2538
+ // src/components/ui/Stepper.tsx
2539
+ import { jsx as jsx29, jsxs as jsxs24 } from "react/jsx-runtime";
2540
+ function Stepper({ steps, currentStep, className }) {
2541
+ return /* @__PURE__ */ jsx29("div", { className: cn("flex items-start gap-2", className), children: steps.map((step, index) => {
2542
+ const isCompleted = index < currentStep;
2543
+ const isCurrent = index === currentStep;
2544
+ const isPending = index > currentStep;
2545
+ const isError = step.status === "error";
2546
+ return /* @__PURE__ */ jsxs24("div", { className: "flex flex-1 items-start gap-2", children: [
2547
+ /* @__PURE__ */ jsxs24("div", { className: "flex flex-1 flex-col items-center", children: [
2548
+ /* @__PURE__ */ jsx29(
2549
+ "div",
2550
+ {
2551
+ className: cn(
2552
+ "flex h-9 w-9 items-center justify-center rounded-full text-sm font-bold transition-colors",
2553
+ isCompleted && "bg-ph-success text-[var(--ph-on-success)]",
2554
+ isCurrent && !isError && "bg-ph-brand text-[var(--ph-on-accent)] ring-4 ring-ph-brand/20",
2555
+ isCurrent && isError && "bg-ph-danger text-[var(--ph-on-danger)]",
2556
+ isPending && "bg-ph-muted text-ph-mutedtext"
2557
+ ),
2558
+ children: isCompleted ? /* @__PURE__ */ jsx29(IconCheck, { className: "h-5 w-5", "aria-hidden": true }) : index + 1
2559
+ }
2560
+ ),
2561
+ /* @__PURE__ */ jsxs24("div", { className: "mt-2 text-center", children: [
2562
+ /* @__PURE__ */ jsx29(
2563
+ "p",
2564
+ {
2565
+ className: cn(
2566
+ "text-sm font-semibold",
2567
+ isCurrent && "text-ph-ink",
2568
+ !isCurrent && "text-ph-mutedtext"
2569
+ ),
2570
+ children: step.label
2571
+ }
2572
+ ),
2573
+ step.description && /* @__PURE__ */ jsx29("p", { className: "mt-0.5 text-xs text-ph-mutedtext", children: step.description })
2574
+ ] })
2575
+ ] }),
2576
+ index < steps.length - 1 && /* @__PURE__ */ jsx29(
2577
+ "div",
2578
+ {
2579
+ className: cn(
2580
+ "mt-4 h-0.5 flex-1 rounded-full transition-colors",
2581
+ isCompleted ? "bg-ph-success" : "bg-ph-border"
2582
+ )
2583
+ }
2584
+ )
2585
+ ] }, step.id);
2586
+ }) });
2587
+ }
2588
+
2589
+ // src/components/ui/SegmentedControl.tsx
2590
+ import { jsx as jsx30, jsxs as jsxs25 } from "react/jsx-runtime";
2591
+ function SegmentedControl({ options, value, onChange, className }) {
2592
+ return /* @__PURE__ */ jsx30(
2593
+ "div",
2594
+ {
2595
+ className: cn(
2596
+ "inline-flex rounded-lg bg-ph-muted p-1",
2597
+ className
2598
+ ),
2599
+ children: options.map((option) => /* @__PURE__ */ jsxs25(
2600
+ "button",
2601
+ {
2602
+ type: "button",
2603
+ onClick: () => onChange(option.value),
2604
+ className: cn(
2605
+ "relative flex items-center gap-1.5 rounded-md px-3.5 py-1.5 text-sm font-medium transition-all",
2606
+ value === option.value ? "bg-ph-surface text-ph-ink shadow-ph" : "text-ph-subtle hover:text-ph-ink"
2607
+ ),
2608
+ children: [
2609
+ option.icon && /* @__PURE__ */ jsx30("span", { className: "h-4 w-4", children: option.icon }),
2610
+ option.label
2611
+ ]
2612
+ },
2613
+ option.value
2614
+ ))
2615
+ }
2616
+ );
2617
+ }
2618
+
2619
+ // src/components/ui/CommandPalette.tsx
2620
+ import { useState as useState3, useEffect as useEffect2, useRef as useRef2 } from "react";
2621
+ import { jsx as jsx31, jsxs as jsxs26 } from "react/jsx-runtime";
2622
+ function CommandPalette({
2623
+ items,
2624
+ isOpen,
2625
+ onClose,
2626
+ placeholder = "Type a command or search...",
2627
+ className
2628
+ }) {
2629
+ const [query, setQuery] = useState3("");
2630
+ const [selectedIndex, setSelectedIndex] = useState3(0);
2631
+ const inputRef = useRef2(null);
2632
+ const filtered = items.filter(
2633
+ (item) => item.label.toLowerCase().includes(query.toLowerCase())
2634
+ );
2635
+ useEffect2(() => {
2636
+ var _a;
2637
+ if (isOpen) {
2638
+ setQuery("");
2639
+ setSelectedIndex(0);
2640
+ (_a = inputRef.current) == null ? void 0 : _a.focus();
2641
+ }
2642
+ }, [isOpen]);
2643
+ useEffect2(() => {
2644
+ const handleKeyDown = (e) => {
2645
+ var _a;
2646
+ if (!isOpen) return;
2647
+ switch (e.key) {
2648
+ case "ArrowDown":
2649
+ e.preventDefault();
2650
+ setSelectedIndex((i) => (i + 1) % filtered.length);
2651
+ break;
2652
+ case "ArrowUp":
2653
+ e.preventDefault();
2654
+ setSelectedIndex((i) => (i - 1 + filtered.length) % filtered.length);
2655
+ break;
2656
+ case "Enter":
2657
+ e.preventDefault();
2658
+ (_a = filtered[selectedIndex]) == null ? void 0 : _a.onSelect();
2659
+ onClose();
2660
+ break;
2661
+ case "Escape":
2662
+ onClose();
2663
+ break;
2664
+ }
2665
+ };
2666
+ window.addEventListener("keydown", handleKeyDown);
2667
+ return () => window.removeEventListener("keydown", handleKeyDown);
2668
+ }, [isOpen, filtered, selectedIndex, onClose]);
2669
+ if (!isOpen) return null;
2670
+ return /* @__PURE__ */ jsx31("div", { className: "fixed inset-0 z-50 flex items-start justify-center bg-black/40 pt-[20vh] backdrop-blur-sm", children: /* @__PURE__ */ jsxs26(
2671
+ "div",
2672
+ {
2673
+ className: cn(
2674
+ "w-full max-w-xl overflow-hidden rounded-xl border border-ph-border bg-ph-surface shadow-ph-md",
2675
+ className
2676
+ ),
2677
+ children: [
2678
+ /* @__PURE__ */ jsxs26("div", { className: "flex items-center gap-3 border-b border-ph-border px-4 py-3", children: [
2679
+ /* @__PURE__ */ jsx31(IconSearch, { className: "h-5 w-5 text-ph-mutedtext" }),
2680
+ /* @__PURE__ */ jsx31(
2681
+ "input",
2682
+ {
2683
+ ref: inputRef,
2684
+ type: "text",
2685
+ value: query,
2686
+ onChange: (e) => {
2687
+ setQuery(e.target.value);
2688
+ setSelectedIndex(0);
2689
+ },
2690
+ placeholder,
2691
+ className: "flex-1 bg-transparent text-ph-ink outline-none placeholder:text-ph-mutedtext"
2692
+ }
2693
+ ),
2694
+ /* @__PURE__ */ jsx31("kbd", { className: "rounded border border-ph-border bg-ph-muted px-1.5 py-0.5 text-xs text-ph-mutedtext", children: "ESC" })
2695
+ ] }),
2696
+ /* @__PURE__ */ jsx31("div", { className: "max-h-[50vh] overflow-y-auto py-2", children: filtered.length === 0 ? /* @__PURE__ */ jsx31("div", { className: "px-4 py-8 text-center text-sm text-ph-mutedtext", children: "No results found." }) : filtered.map((item, index) => /* @__PURE__ */ jsxs26(
2697
+ "button",
2698
+ {
2699
+ type: "button",
2700
+ onClick: () => {
2701
+ item.onSelect();
2702
+ onClose();
2703
+ },
2704
+ onMouseEnter: () => setSelectedIndex(index),
2705
+ className: cn(
2706
+ "flex w-full items-center gap-3 px-4 py-2.5 text-left text-sm transition-colors",
2707
+ index === selectedIndex ? "bg-ph-muted text-ph-ink" : "text-ph-subtle"
2708
+ ),
2709
+ children: [
2710
+ item.icon && /* @__PURE__ */ jsx31("span", { className: "h-5 w-5", children: item.icon }),
2711
+ /* @__PURE__ */ jsx31("span", { className: "flex-1", children: item.label }),
2712
+ item.shortcut && /* @__PURE__ */ jsx31("kbd", { className: "rounded border border-ph-border bg-ph-surface px-1.5 py-0.5 text-xs text-ph-mutedtext", children: item.shortcut })
2713
+ ]
2714
+ },
2715
+ item.id
2716
+ )) })
2717
+ ]
2718
+ }
2719
+ ) });
2720
+ }
2721
+
2722
+ // src/components/ui/Calendar.tsx
2723
+ import { useState as useState4 } from "react";
2724
+ import { jsx as jsx32, jsxs as jsxs27 } from "react/jsx-runtime";
2725
+ function Calendar({ value, onChange, className }) {
2726
+ const [currentMonth, setCurrentMonth] = useState4(value || /* @__PURE__ */ new Date());
2727
+ const today = /* @__PURE__ */ new Date();
2728
+ const year = currentMonth.getFullYear();
2729
+ const month = currentMonth.getMonth();
2730
+ const firstDay = new Date(year, month, 1).getDay();
2731
+ const daysInMonth = new Date(year, month + 1, 0).getDate();
2732
+ const prevMonth = () => setCurrentMonth(new Date(year, month - 1, 1));
2733
+ const nextMonth = () => setCurrentMonth(new Date(year, month + 1, 1));
2734
+ const monthNames = [
2735
+ "January",
2736
+ "February",
2737
+ "March",
2738
+ "April",
2739
+ "May",
2740
+ "June",
2741
+ "July",
2742
+ "August",
2743
+ "September",
2744
+ "October",
2745
+ "November",
2746
+ "December"
2747
+ ];
2748
+ const weekDays = ["Su", "Mo", "Tu", "We", "Th", "Fr", "Sa"];
2749
+ const isSelected = (day) => {
2750
+ if (!value) return false;
2751
+ return value.getDate() === day && value.getMonth() === month && value.getFullYear() === year;
2752
+ };
2753
+ const isToday = (day) => {
2754
+ return today.getDate() === day && today.getMonth() === month && today.getFullYear() === year;
2755
+ };
2756
+ const handleSelect = (day) => {
2757
+ onChange == null ? void 0 : onChange(new Date(year, month, day));
2758
+ };
2759
+ const days = [];
2760
+ for (let i = 0; i < firstDay; i++) {
2761
+ days.push(null);
2762
+ }
2763
+ for (let i = 1; i <= daysInMonth; i++) {
2764
+ days.push(i);
2765
+ }
2766
+ return /* @__PURE__ */ jsxs27("div", { className: cn("w-[280px] rounded-xl border border-ph-border bg-ph-surface p-4 shadow-ph", className), children: [
2767
+ /* @__PURE__ */ jsxs27("div", { className: "mb-4 flex items-center justify-between", children: [
2768
+ /* @__PURE__ */ jsx32(
2769
+ "button",
2770
+ {
2771
+ type: "button",
2772
+ onClick: prevMonth,
2773
+ "aria-label": "Previous month",
2774
+ className: "rounded-lg p-1 text-ph-subtle transition hover:bg-ph-muted hover:text-ph-ink",
2775
+ children: /* @__PURE__ */ jsx32(IconChevronLeft, { className: "h-5 w-5", "aria-hidden": true })
2776
+ }
2777
+ ),
2778
+ /* @__PURE__ */ jsxs27("span", { className: "text-sm font-semibold text-ph-ink", children: [
2779
+ monthNames[month],
2780
+ " ",
2781
+ year
2782
+ ] }),
2783
+ /* @__PURE__ */ jsx32(
2784
+ "button",
2785
+ {
2786
+ type: "button",
2787
+ onClick: nextMonth,
2788
+ "aria-label": "Next month",
2789
+ className: "rounded-lg p-1 text-ph-subtle transition hover:bg-ph-muted hover:text-ph-ink",
2790
+ children: /* @__PURE__ */ jsx32(IconChevronRight, { className: "h-5 w-5", "aria-hidden": true })
2791
+ }
2792
+ )
2793
+ ] }),
2794
+ /* @__PURE__ */ jsxs27("div", { className: "grid grid-cols-7 gap-1", children: [
2795
+ weekDays.map((day) => /* @__PURE__ */ jsx32("div", { className: "py-1 text-center text-xs font-medium text-ph-mutedtext", children: day }, day)),
2796
+ days.map((day, index) => /* @__PURE__ */ jsx32("div", { className: "aspect-square", children: day && /* @__PURE__ */ jsx32(
2797
+ "button",
2798
+ {
2799
+ type: "button",
2800
+ onClick: () => handleSelect(day),
2801
+ className: cn(
2802
+ "flex h-full w-full items-center justify-center rounded-lg text-sm transition-colors",
2803
+ isSelected(day) ? "bg-ph-brand font-semibold text-[var(--ph-on-accent)] shadow-ph" : isToday(day) ? "bg-ph-muted font-semibold text-ph-brand ring-1 ring-ph-brand/30" : "text-ph-ink hover:bg-ph-muted"
2804
+ ),
2805
+ children: day
2806
+ }
2807
+ ) }, index))
2808
+ ] })
2809
+ ] });
2810
+ }
2811
+
2812
+ // src/components/ui/HoverCard.tsx
2813
+ import { useState as useState5 } from "react";
2814
+ import { jsx as jsx33, jsxs as jsxs28 } from "react/jsx-runtime";
2815
+ function HoverCard({ trigger, children, className }) {
2816
+ const [isVisible, setIsVisible] = useState5(false);
2817
+ return /* @__PURE__ */ jsxs28(
2818
+ "div",
2819
+ {
2820
+ className: "relative inline-block",
2821
+ onMouseEnter: () => setIsVisible(true),
2822
+ onMouseLeave: () => setIsVisible(false),
2823
+ children: [
2824
+ trigger,
2825
+ /* @__PURE__ */ jsxs28(
2826
+ "div",
2827
+ {
2828
+ className: cn(
2829
+ "absolute left-1/2 top-full z-50 mt-2 w-64 -translate-x-1/2 rounded-lg border border-ph-border bg-ph-surface p-4 shadow-ph-md transition-all duration-150",
2830
+ isVisible ? "visible translate-y-0 opacity-100" : "invisible -translate-y-1 opacity-0",
2831
+ className
2832
+ ),
2833
+ children: [
2834
+ /* @__PURE__ */ jsx33("div", { className: "absolute -top-1.5 left-1/2 h-3 w-3 -translate-x-1/2 rotate-45 border-l border-t border-ph-border bg-ph-surface" }),
2835
+ /* @__PURE__ */ jsx33("div", { className: "relative", children })
2836
+ ]
2837
+ }
2838
+ )
2839
+ ]
2840
+ }
2841
+ );
2842
+ }
2843
+
2844
+ // src/components/ui/EmptyState.tsx
2845
+ import { jsx as jsx34, jsxs as jsxs29 } from "react/jsx-runtime";
2846
+ function EmptyState({ icon, title, description, action, className }) {
2847
+ return /* @__PURE__ */ jsxs29(
2848
+ "div",
2849
+ {
2850
+ className: cn(
2851
+ "flex flex-col items-center justify-center rounded-xl border border-dashed border-ph-border bg-ph-muted/50 px-8 py-16 text-center",
2852
+ className
2853
+ ),
2854
+ children: [
2855
+ icon && /* @__PURE__ */ jsx34("div", { className: "mb-4 flex h-14 w-14 items-center justify-center rounded-full bg-ph-muted text-ph-mutedtext", children: icon }),
2856
+ /* @__PURE__ */ jsx34("h3", { className: "text-base font-semibold text-ph-ink", children: title }),
2857
+ description && /* @__PURE__ */ jsx34("p", { className: "mt-1 max-w-sm text-sm text-ph-subtle", children: description }),
2858
+ action && /* @__PURE__ */ jsx34("div", { className: "mt-4", children: action })
2859
+ ]
2860
+ }
2861
+ );
2862
+ }
2863
+
2864
+ // src/components/ui/FilterChips.tsx
2865
+ import { Fragment as Fragment5, jsx as jsx35, jsxs as jsxs30 } from "react/jsx-runtime";
2866
+ function FilterChips({
2867
+ chips,
2868
+ onToggle,
2869
+ onRemove,
2870
+ className,
2871
+ "aria-label": ariaLabel = "Applied filters"
2872
+ }) {
2873
+ return /* @__PURE__ */ jsx35("div", { className: cn("ph-filter-chips", className), role: "group", "aria-label": ariaLabel, children: chips.map((chip) => {
2874
+ var _a;
2875
+ const label = (_a = chip.removeLabel) != null ? _a : getChipText(chip);
2876
+ const content = /* @__PURE__ */ jsxs30(Fragment5, { children: [
2877
+ /* @__PURE__ */ jsx35("span", { className: "ph-filter-chip__label", children: chip.label }),
2878
+ chip.value != null ? /* @__PURE__ */ jsx35("span", { className: "ph-filter-chip__value", children: chip.value }) : null
2879
+ ] });
2880
+ return /* @__PURE__ */ jsxs30(
2881
+ "span",
2882
+ {
2883
+ className: cn("ph-filter-chip", chip.active && "ph-filter-chip--active"),
2884
+ "data-state": chip.active ? "on" : "off",
2885
+ children: [
2886
+ onToggle ? /* @__PURE__ */ jsx35(
2887
+ "button",
2888
+ {
2889
+ type: "button",
2890
+ className: "ph-filter-chip__main",
2891
+ "aria-pressed": Boolean(chip.active),
2892
+ onClick: () => onToggle(chip.id),
2893
+ children: content
2894
+ }
2895
+ ) : /* @__PURE__ */ jsx35("span", { className: "ph-filter-chip__main", children: content }),
2896
+ chip.active && onRemove ? /* @__PURE__ */ jsx35(
2897
+ "button",
2898
+ {
2899
+ type: "button",
2900
+ className: "ph-filter-chip__remove",
2901
+ "aria-label": `Remove ${label} filter`,
2902
+ onClick: () => onRemove(chip.id),
2903
+ children: /* @__PURE__ */ jsx35(IconClose, { className: "h-3 w-3", "aria-hidden": true })
2904
+ }
2905
+ ) : null
2906
+ ]
2907
+ },
2908
+ chip.id
2909
+ );
2910
+ }) });
2911
+ }
2912
+ function getChipText(chip) {
2913
+ const label = typeof chip.label === "string" || typeof chip.label === "number" ? String(chip.label) : chip.id;
2914
+ const value = typeof chip.value === "string" || typeof chip.value === "number" ? String(chip.value) : null;
2915
+ return value ? `${label}: ${value}` : label;
2916
+ }
2917
+
2918
+ // src/components/ui/FilterBar.tsx
2919
+ import { jsx as jsx36, jsxs as jsxs31 } from "react/jsx-runtime";
2920
+ function FilterBar(_a) {
2921
+ var _b = _a, {
2922
+ children,
2923
+ label = "Filters and sorting",
2924
+ onClear,
2925
+ clearLabel = "Clear all",
2926
+ resultCount,
2927
+ className
2928
+ } = _b, props = __objRest(_b, [
2929
+ "children",
2930
+ "label",
2931
+ "onClear",
2932
+ "clearLabel",
2933
+ "resultCount",
2934
+ "className"
2935
+ ]);
2936
+ return /* @__PURE__ */ jsxs31("div", __spreadProps(__spreadValues({ className: cn("ph-filter-bar", className) }, props), { children: [
2937
+ /* @__PURE__ */ jsxs31("div", { className: "ph-filter-bar__controls", role: "group", "aria-label": label, children: [
2938
+ children,
2939
+ onClear ? /* @__PURE__ */ jsx36("button", { type: "button", className: "ph-filter-bar__clear", onClick: onClear, children: clearLabel }) : null
2940
+ ] }),
2941
+ resultCount != null ? /* @__PURE__ */ jsx36("output", { className: "ph-filter-bar__results", "aria-live": "polite", children: resultCount }) : null
2942
+ ] }));
2943
+ }
2944
+ function FilterMenu({
2945
+ label,
2946
+ value,
2947
+ options,
2948
+ onValueChange,
2949
+ placeholder = "Any",
2950
+ align = "start",
2951
+ disabled,
2952
+ className
2953
+ }) {
2954
+ var _a;
2955
+ const selected = options.find((option) => option.value === value);
2956
+ const displayValue = (_a = selected == null ? void 0 : selected.label) != null ? _a : placeholder;
2957
+ const accessibleValue = selected ? getOptionText(selected) : String(placeholder);
2958
+ return /* @__PURE__ */ jsx36(
2959
+ DropdownMenu,
2960
+ {
2961
+ "aria-label": `${label}: ${accessibleValue}`,
2962
+ align,
2963
+ disabled,
2964
+ className,
2965
+ trigger: /* @__PURE__ */ jsxs31("span", { className: cn("ph-filter-menu-trigger", selected && "ph-filter-menu-trigger--active"), children: [
2966
+ /* @__PURE__ */ jsx36(IconTuning, { className: "h-3.5 w-3.5", "aria-hidden": true }),
2967
+ /* @__PURE__ */ jsx36("span", { className: "ph-filter-menu-trigger__label", children: label }),
2968
+ /* @__PURE__ */ jsx36("span", { className: "ph-filter-menu-trigger__value", children: displayValue })
2969
+ ] }),
2970
+ children: /* @__PURE__ */ jsx36(DropdownRadioGroup, { value, onValueChange, children: options.map((option) => /* @__PURE__ */ jsx36(
2971
+ DropdownRadioItem,
2972
+ {
2973
+ value: option.value,
2974
+ textValue: getOptionText(option),
2975
+ disabled: option.disabled,
2976
+ children: option.label
2977
+ },
2978
+ option.value
2979
+ )) })
2980
+ }
2981
+ );
2982
+ }
2983
+ function SortMenu({
2984
+ label,
2985
+ value,
2986
+ options,
2987
+ onValueChange,
2988
+ direction = "descending",
2989
+ align = "end",
2990
+ disabled,
2991
+ className
2992
+ }) {
2993
+ const selected = options.find((option) => option.value === value);
2994
+ return /* @__PURE__ */ jsx36(
2995
+ DropdownMenu,
2996
+ {
2997
+ "aria-label": `${label}: ${selected ? getOptionText(selected) : "Choose sort order"}`,
2998
+ align,
2999
+ disabled,
3000
+ className,
3001
+ trigger: /* @__PURE__ */ jsxs31("span", { className: "ph-filter-menu-trigger ph-sort-menu-trigger", children: [
3002
+ /* @__PURE__ */ jsx36(
3003
+ IconArrowDown,
3004
+ {
3005
+ className: cn("h-3.5 w-3.5", direction === "ascending" && "rotate-180"),
3006
+ "aria-hidden": true
3007
+ }
3008
+ ),
3009
+ /* @__PURE__ */ jsx36("span", { className: "ph-filter-menu-trigger__label", children: label }),
3010
+ selected ? /* @__PURE__ */ jsx36("span", { className: "ph-filter-menu-trigger__value", children: selected.label }) : null
3011
+ ] }),
3012
+ children: /* @__PURE__ */ jsx36(DropdownRadioGroup, { value, onValueChange, children: options.map((option) => /* @__PURE__ */ jsx36(
3013
+ DropdownRadioItem,
3014
+ {
3015
+ value: option.value,
3016
+ textValue: getOptionText(option),
3017
+ disabled: option.disabled,
3018
+ children: option.label
3019
+ },
3020
+ option.value
3021
+ )) })
3022
+ }
3023
+ );
3024
+ }
3025
+ function getOptionText(option) {
3026
+ if (option.textValue) return option.textValue;
3027
+ if (typeof option.label === "string" || typeof option.label === "number") return String(option.label);
3028
+ return option.value;
3029
+ }
3030
+
3031
+ // src/components/ui/FilterControls.tsx
3032
+ import { jsx as jsx37, jsxs as jsxs32 } from "react/jsx-runtime";
3033
+ function FilterControls(_a) {
3034
+ var _b = _a, {
3035
+ children,
3036
+ barProps,
3037
+ chipsProps,
3038
+ emptyState,
3039
+ className
3040
+ } = _b, props = __objRest(_b, [
3041
+ "children",
3042
+ "barProps",
3043
+ "chipsProps",
3044
+ "emptyState",
3045
+ "className"
3046
+ ]);
3047
+ const hasChips = Boolean(chipsProps == null ? void 0 : chipsProps.chips.length);
3048
+ return /* @__PURE__ */ jsxs32("div", __spreadProps(__spreadValues({ className: cn("ph-filter-controls", className) }, props), { children: [
3049
+ /* @__PURE__ */ jsx37(FilterBar, __spreadProps(__spreadValues({}, barProps), { children })),
3050
+ hasChips && chipsProps ? /* @__PURE__ */ jsx37(FilterChips, __spreadValues({}, chipsProps)) : emptyState != null ? emptyState : null
3051
+ ] }));
3052
+ }
3053
+
3054
+ // src/components/ui/CodeBlock.tsx
3055
+ import { useState as useState6 } from "react";
3056
+ import { jsx as jsx38, jsxs as jsxs33 } from "react/jsx-runtime";
3057
+ function CodeBlock({ code, language = "tsx", filename, className }) {
3058
+ const [copied, setCopied] = useState6(false);
3059
+ const handleCopy = async () => {
3060
+ await navigator.clipboard.writeText(code);
3061
+ setCopied(true);
3062
+ setTimeout(() => setCopied(false), 2e3);
3063
+ };
3064
+ return /* @__PURE__ */ jsxs33("div", { className: cn("overflow-hidden rounded-lg border border-ph-border bg-[#1a1a2e]", className), children: [
3065
+ (filename || language) && /* @__PURE__ */ jsxs33("div", { className: "flex items-center justify-between border-b border-white/10 px-4 py-2", children: [
3066
+ /* @__PURE__ */ jsxs33("div", { className: "flex items-center gap-2", children: [
3067
+ /* @__PURE__ */ jsxs33("div", { className: "flex gap-1.5", children: [
3068
+ /* @__PURE__ */ jsx38("div", { className: "h-3 w-3 rounded-full bg-red-400" }),
3069
+ /* @__PURE__ */ jsx38("div", { className: "h-3 w-3 rounded-full bg-amber-400" }),
3070
+ /* @__PURE__ */ jsx38("div", { className: "h-3 w-3 rounded-full bg-emerald-400" })
3071
+ ] }),
3072
+ filename && /* @__PURE__ */ jsx38("span", { className: "ml-2 text-xs text-white/60", children: filename })
3073
+ ] }),
3074
+ /* @__PURE__ */ jsx38(
3075
+ "button",
3076
+ {
3077
+ type: "button",
3078
+ onClick: handleCopy,
3079
+ className: "text-xs text-white/60 transition hover:text-white",
3080
+ children: copied ? "Copied!" : "Copy"
3081
+ }
3082
+ )
3083
+ ] }),
3084
+ /* @__PURE__ */ jsx38("pre", { className: "overflow-x-auto p-4 text-sm leading-relaxed", children: /* @__PURE__ */ jsx38("code", { className: "font-mono text-[#e4e4e7]", children: code }) })
3085
+ ] });
3086
+ }
3087
+
3088
+ // src/components/ui/ComponentDocs.tsx
3089
+ import { jsx as jsx39, jsxs as jsxs34 } from "react/jsx-runtime";
3090
+ function ComponentDocs({ title = "Props & variants", rows, defaultOpen = false, className }) {
3091
+ return /* @__PURE__ */ jsxs34("details", { className: cn("ph-panel group overflow-hidden p-0", className), open: defaultOpen, children: [
3092
+ /* @__PURE__ */ jsxs34("summary", { className: "flex cursor-pointer list-none items-center justify-between gap-4 border-b border-ph-border px-4 py-3 transition hover:bg-ph-muted/60 [&::-webkit-details-marker]:hidden", children: [
3093
+ /* @__PURE__ */ jsx39("h3", { className: "text-xs font-semibold uppercase tracking-wider text-ph-mutedtext", children: title }),
3094
+ /* @__PURE__ */ jsxs34("span", { className: "rounded-full border border-ph-border bg-ph-surface px-2 py-1 text-[10px] font-semibold uppercase tracking-wider text-ph-mutedtext transition group-open:bg-ph-brand group-open:text-white", children: [
3095
+ /* @__PURE__ */ jsx39("span", { className: "group-open:hidden", children: "Show" }),
3096
+ /* @__PURE__ */ jsx39("span", { className: "hidden group-open:inline", children: "Hide" })
3097
+ ] })
3098
+ ] }),
3099
+ /* @__PURE__ */ jsx39("div", { className: "overflow-x-auto border-t border-ph-border", children: /* @__PURE__ */ jsxs34("table", { className: "w-full text-left text-sm", children: [
3100
+ /* @__PURE__ */ jsx39("thead", { className: "bg-ph-muted text-xs uppercase tracking-wider text-ph-mutedtext", children: /* @__PURE__ */ jsxs34("tr", { children: [
3101
+ /* @__PURE__ */ jsx39("th", { className: "px-4 py-2 font-semibold", children: "Prop" }),
3102
+ /* @__PURE__ */ jsx39("th", { className: "px-4 py-2 font-semibold", children: "Type" }),
3103
+ /* @__PURE__ */ jsx39("th", { className: "px-4 py-2 font-semibold", children: "Default" }),
3104
+ /* @__PURE__ */ jsx39("th", { className: "px-4 py-2 font-semibold", children: "Use" })
3105
+ ] }) }),
3106
+ /* @__PURE__ */ jsx39("tbody", { className: "divide-y divide-ph-border", children: rows.map((row) => {
3107
+ var _a;
3108
+ return /* @__PURE__ */ jsxs34("tr", { children: [
3109
+ /* @__PURE__ */ jsx39("td", { className: "px-4 py-3 align-top font-mono text-xs text-ph-ink", children: row.name }),
3110
+ /* @__PURE__ */ jsx39("td", { className: "px-4 py-3 align-top font-mono text-xs text-ph-subtle", children: row.type }),
3111
+ /* @__PURE__ */ jsx39("td", { className: "px-4 py-3 align-top font-mono text-xs text-ph-subtle", children: (_a = row.defaultValue) != null ? _a : "-" }),
3112
+ /* @__PURE__ */ jsx39("td", { className: "px-4 py-3 align-top text-ph-subtle", children: row.description })
3113
+ ] }, row.name);
3114
+ }) })
3115
+ ] }) })
3116
+ ] });
3117
+ }
3118
+
3119
+ // src/components/ui/ShowcaseWrapper.tsx
3120
+ import { useState as useState7 } from "react";
3121
+ import { jsx as jsx40, jsxs as jsxs35 } from "react/jsx-runtime";
3122
+ function ShowcaseWrapper({
3123
+ id,
3124
+ title,
3125
+ description,
3126
+ docs,
3127
+ code,
3128
+ filename = "Example.tsx",
3129
+ children,
3130
+ className
3131
+ }) {
3132
+ var _a;
3133
+ const [showCode, setShowCode] = useState7(false);
3134
+ const fallbackId = (_a = titleIdMap[title]) != null ? _a : title.toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-|-$/g, "");
3135
+ return /* @__PURE__ */ jsxs35("section", { id: id != null ? id : fallbackId, className: cn("scroll-mt-20", className), children: [
3136
+ /* @__PURE__ */ jsxs35("div", { className: "ph-h2-rule mb-8", children: [
3137
+ /* @__PURE__ */ jsxs35("div", { className: "flex items-center gap-1.5", children: [
3138
+ /* @__PURE__ */ jsx40("h2", { children: title }),
3139
+ /* @__PURE__ */ jsx40(
3140
+ "button",
3141
+ {
3142
+ type: "button",
3143
+ onClick: () => setShowCode(!showCode),
3144
+ className: cn(
3145
+ "flex h-10 w-10 items-center justify-center rounded-full border transition-all",
3146
+ showCode ? "border-ph-brand bg-ph-brand text-[var(--ph-on-accent)] shadow-lg shadow-ph-brand/25" : "border-ph-border bg-ph-surface text-ph-subtle hover:border-ph-brand hover:text-ph-brand"
3147
+ ),
3148
+ title: showCode ? "Hide code" : "Show code",
3149
+ "aria-label": showCode ? "Hide code" : "Show code",
3150
+ children: /* @__PURE__ */ jsx40(IconCodePreview, { className: "h-5 w-5", "aria-hidden": true })
3151
+ }
3152
+ )
3153
+ ] }),
3154
+ /* @__PURE__ */ jsx40("hr", {})
3155
+ ] }),
3156
+ description && /* @__PURE__ */ jsx40("p", { className: "mb-6 text-sm text-ph-subtle", children: description }),
3157
+ docs && /* @__PURE__ */ jsx40("div", { className: "mb-6", children: docs }),
3158
+ /* @__PURE__ */ jsxs35(
3159
+ "div",
3160
+ {
3161
+ className: cn(
3162
+ "gap-6",
3163
+ showCode ? "lg:grid lg:grid-cols-[1fr,minmax(360px,420px)]" : "block"
3164
+ ),
3165
+ children: [
3166
+ /* @__PURE__ */ jsx40("div", { className: cn("min-w-0", showCode && "lg:pr-2"), children }),
3167
+ /* @__PURE__ */ jsx40(
3168
+ "div",
3169
+ {
3170
+ className: cn(
3171
+ "transition-all duration-300",
3172
+ showCode ? "block opacity-100" : "hidden opacity-0 lg:hidden"
3173
+ ),
3174
+ children: /* @__PURE__ */ jsx40("div", { className: "sticky top-20", children: /* @__PURE__ */ jsx40(CodeBlock, { code, filename }) })
3175
+ }
3176
+ )
3177
+ ]
3178
+ }
3179
+ )
3180
+ ] });
3181
+ }
3182
+ var titleIdMap = {
3183
+ "Icons": "icons",
3184
+ "Colour tokens": "colors",
3185
+ "Buttons": "buttons",
3186
+ "Badges": "badges",
3187
+ "Alerts": "alerts",
3188
+ "Toasts": "toasts",
3189
+ "Cards": "cards",
3190
+ "Forms": "forms",
3191
+ "Inputs & Forms": "forms",
3192
+ "Tables": "tables",
3193
+ "Accordion": "accordion",
3194
+ "Calendar": "calendar",
3195
+ "Hover Card": "hovercard",
3196
+ "Modals": "modals",
3197
+ "Drawers": "drawers",
3198
+ "Navigation chrome": "navigation",
3199
+ "Navigation utilities": "utilities",
3200
+ "Stepper": "stepper",
3201
+ "Command Palette": "command",
3202
+ "Filter Chips": "filters",
3203
+ "Empty State": "emptystate",
3204
+ "Charts (PostHog-style)": "charts",
3205
+ "Dashboard shells": "dashboard",
3206
+ "Tabs": "tabs",
3207
+ "Dropdowns": "dropdowns",
3208
+ "Progress & loading": "progress",
3209
+ "Tooltip": "tooltip",
3210
+ "Avatars": "avatars",
3211
+ "Stats & conversational UI": "stats",
3212
+ "Timeline": "timeline",
3213
+ "Countdown motif": "countdown",
3214
+ "Keyboard glyphs": "kbd",
3215
+ "Icon swap": "swap",
3216
+ "Stacked surfaces": "stack",
3217
+ "Diff slider": "diff",
3218
+ "Badge hotspots": "indicator",
3219
+ "Terminal capture": "code-mockup"
3220
+ };
3221
+
3222
+ // src/components/ui/CollapsibleSection.tsx
3223
+ import { useId as useId5, useState as useState8 } from "react";
3224
+ import { jsx as jsx41, jsxs as jsxs36 } from "react/jsx-runtime";
3225
+ function CollapsibleSection({ title, children, defaultOpen = true, id }) {
3226
+ const [isOpen, setIsOpen] = useState8(defaultOpen);
3227
+ const generatedId = useId5();
3228
+ const contentId = `${id != null ? id : generatedId}-content`;
3229
+ return /* @__PURE__ */ jsxs36("section", { id, className: "scroll-mt-20", children: [
3230
+ /* @__PURE__ */ jsxs36(
3231
+ "button",
3232
+ {
3233
+ type: "button",
3234
+ onClick: () => setIsOpen(!isOpen),
3235
+ "aria-expanded": isOpen,
3236
+ "aria-controls": contentId,
3237
+ className: "mb-6 flex w-full items-center justify-between rounded-lg border border-ph-border bg-ph-muted px-5 py-4 text-left transition hover:bg-ph-muted/80",
3238
+ children: [
3239
+ /* @__PURE__ */ jsx41("span", { className: "text-lg font-bold text-ph-ink", children: title }),
3240
+ /* @__PURE__ */ jsx41(
3241
+ IconChevronDown,
3242
+ {
3243
+ className: cn(
3244
+ "h-5 w-5 text-ph-subtle transition-transform duration-200",
3245
+ isOpen && "rotate-180"
3246
+ ),
3247
+ "aria-hidden": true
3248
+ }
3249
+ )
3250
+ ]
3251
+ }
3252
+ ),
3253
+ /* @__PURE__ */ jsx41(
3254
+ "div",
3255
+ {
3256
+ id: contentId,
3257
+ "aria-hidden": !isOpen,
3258
+ className: cn(
3259
+ "overflow-hidden transition-all duration-300",
3260
+ isOpen ? "max-h-[50000px] opacity-100" : "max-h-0 opacity-0"
3261
+ ),
3262
+ children
3263
+ }
3264
+ )
3265
+ ] });
3266
+ }
3267
+
3268
+ // src/components/ui/Typography.tsx
3269
+ import { jsx as jsx42 } from "react/jsx-runtime";
3270
+ var toneMap2 = {
3271
+ default: "text-ph-ink",
3272
+ muted: "text-ph-mutedtext",
3273
+ subtle: "text-ph-subtle",
3274
+ brand: "text-ph-brand",
3275
+ danger: "text-ph-danger",
3276
+ success: "text-ph-success",
3277
+ warning: "text-ph-warning",
3278
+ info: "text-ph-info",
3279
+ inherit: ""
3280
+ };
3281
+ var weightMap = {
3282
+ normal: "font-normal",
3283
+ medium: "font-medium",
3284
+ semibold: "font-semibold",
3285
+ bold: "font-bold",
3286
+ extrabold: "font-extrabold"
3287
+ };
3288
+ function textClass(base, tone, weight, truncate, className) {
3289
+ return cn(base, toneMap2[tone], weight && weightMap[weight], truncate && "truncate", className);
3290
+ }
3291
+ function Display({
3292
+ children,
3293
+ tone = "default",
3294
+ weight,
3295
+ truncate,
3296
+ className
3297
+ }) {
3298
+ return /* @__PURE__ */ jsx42("h1", { className: textClass("text-4xl font-extrabold tracking-tight md:text-5xl", tone, weight, truncate, className), children });
3299
+ }
3300
+ function H1({ children, tone = "default", weight, truncate, className }) {
3301
+ return /* @__PURE__ */ jsx42("h1", { className: textClass("text-3xl font-bold tracking-tight md:text-4xl", tone, weight, truncate, className), children });
3302
+ }
3303
+ function H2({ children, tone = "default", weight, truncate, className }) {
3304
+ return /* @__PURE__ */ jsx42("h2", { className: textClass("text-2xl font-bold tracking-tight", tone, weight, truncate, className), children });
3305
+ }
3306
+ function H3({ children, tone = "default", weight, truncate, className }) {
3307
+ return /* @__PURE__ */ jsx42("h3", { className: textClass("text-xl font-semibold", tone, weight, truncate, className), children });
3308
+ }
3309
+ function H4({ children, tone = "default", weight, truncate, className }) {
3310
+ return /* @__PURE__ */ jsx42("h4", { className: textClass("text-lg font-semibold", tone, weight, truncate, className), children });
3311
+ }
3312
+ function H5({ children, tone = "default", weight, truncate, className }) {
3313
+ return /* @__PURE__ */ jsx42("h5", { className: textClass("text-base font-semibold", tone, weight, truncate, className), children });
3314
+ }
3315
+ function P({ children, tone = "default", weight, truncate, className }) {
3316
+ return /* @__PURE__ */ jsx42("p", { className: textClass("text-base leading-relaxed", tone, weight, truncate, className), children });
3317
+ }
3318
+ function Small({ children, tone = "default", weight, truncate, className }) {
3319
+ return /* @__PURE__ */ jsx42("span", { className: textClass("text-sm leading-relaxed", tone, weight, truncate, className), children });
3320
+ }
3321
+ function Caption({ children, tone = "muted", weight, truncate, className }) {
3322
+ return /* @__PURE__ */ jsx42("span", { className: textClass("text-[11px] font-medium uppercase tracking-wider", tone, weight, truncate, className), children });
3323
+ }
3324
+ function Overline({ children, tone = "muted", weight, truncate, className }) {
3325
+ return /* @__PURE__ */ jsx42("span", { className: textClass("text-[10px] font-bold uppercase tracking-[0.15em]", tone, weight, truncate, className), children });
3326
+ }
3327
+ function Lead({ children, tone = "subtle", weight, truncate, className }) {
3328
+ return /* @__PURE__ */ jsx42("p", { className: textClass("text-lg leading-relaxed", tone, weight, truncate, className), children });
3329
+ }
3330
+ function Mono({ children, tone = "default", weight, truncate, className }) {
3331
+ return /* @__PURE__ */ jsx42("code", { className: textClass("text-sm font-mono leading-relaxed", tone, weight, truncate, className), children });
3332
+ }
3333
+ function Label({ children, tone = "default", weight, truncate, className }) {
3334
+ return /* @__PURE__ */ jsx42("label", { className: textClass("text-sm font-medium", tone, weight, truncate, className), children });
3335
+ }
3336
+
3337
+ // src/components/ui/Avatar.tsx
3338
+ import { jsx as jsx43, jsxs as jsxs37 } from "react/jsx-runtime";
3339
+ var sizeMap5 = {
3340
+ xs: "h-8 w-8 text-[10px]",
3341
+ sm: "h-10 w-10 text-xs",
3342
+ md: "h-12 w-12 text-base",
3343
+ lg: "h-16 w-16 text-xl",
3344
+ xl: "h-24 w-24 text-3xl"
3345
+ };
3346
+ var statusMap = {
3347
+ online: "bg-emerald-500",
3348
+ offline: "bg-ph-mutedtext",
3349
+ away: "bg-amber-400",
3350
+ busy: "bg-ph-danger"
3351
+ };
3352
+ function Avatar(_a) {
3353
+ var _b = _a, {
3354
+ label,
3355
+ icon,
3356
+ size = "md",
3357
+ color = "bg-ph-brand text-white",
3358
+ status,
3359
+ badge,
3360
+ className
3361
+ } = _b, props = __objRest(_b, [
3362
+ "label",
3363
+ "icon",
3364
+ "size",
3365
+ "color",
3366
+ "status",
3367
+ "badge",
3368
+ "className"
3369
+ ]);
3370
+ return /* @__PURE__ */ jsxs37("div", __spreadProps(__spreadValues({ className: cn("relative inline-flex shrink-0", className) }, props), { children: [
3371
+ /* @__PURE__ */ jsx43(
3372
+ "div",
3373
+ {
3374
+ className: cn(
3375
+ "flex items-center justify-center rounded-full border border-ph-border font-bold shadow-ph",
3376
+ sizeMap5[size],
3377
+ color
3378
+ ),
3379
+ children: icon || label
3380
+ }
3381
+ ),
3382
+ status && /* @__PURE__ */ jsx43(
3383
+ "span",
3384
+ {
3385
+ className: cn(
3386
+ "absolute bottom-0 right-1 h-2.5 w-2.5 rounded-full border-2 border-white",
3387
+ statusMap[status]
3388
+ )
3389
+ }
3390
+ ),
3391
+ badge && /* @__PURE__ */ jsx43("span", { className: "absolute -bottom-1 -right-1 flex min-w-[22px] items-center justify-center rounded-full bg-ph-brand px-1.5 py-px text-[10px] font-bold text-white", children: badge })
3392
+ ] }));
3393
+ }
3394
+ function AvatarGroup(_a) {
3395
+ var _b = _a, { children, max, className } = _b, props = __objRest(_b, ["children", "max", "className"]);
3396
+ const items = Array.isArray(children) ? children : [children];
3397
+ const visible = max ? items.slice(0, max) : items;
3398
+ const remaining = max ? items.length - max : 0;
3399
+ return /* @__PURE__ */ jsxs37("div", __spreadProps(__spreadValues({ className: cn("-space-x-3 flex rtl:space-x-reverse", className) }, props), { children: [
3400
+ visible,
3401
+ remaining > 0 && /* @__PURE__ */ jsx43(
3402
+ Avatar,
3403
+ {
3404
+ label: `+${remaining}`,
3405
+ size: "md",
3406
+ color: "bg-ph-toolbar text-ph-subtle"
3407
+ }
3408
+ )
3409
+ ] }));
3410
+ }
3411
+
3412
+ // src/components/ui/Progress.tsx
3413
+ import { jsx as jsx44, jsxs as jsxs38 } from "react/jsx-runtime";
3414
+ var sizeMap6 = {
3415
+ sm: "h-1",
3416
+ md: "h-2",
3417
+ lg: "h-3"
3418
+ };
3419
+ function Progress(_a) {
3420
+ var _b = _a, {
3421
+ value,
3422
+ max = 100,
3423
+ color = "bg-ph-brand",
3424
+ label,
3425
+ showPercentage = false,
3426
+ size = "md",
3427
+ className
3428
+ } = _b, props = __objRest(_b, [
3429
+ "value",
3430
+ "max",
3431
+ "color",
3432
+ "label",
3433
+ "showPercentage",
3434
+ "size",
3435
+ "className"
3436
+ ]);
3437
+ const percentage = Math.min(100, Math.max(0, value / max * 100));
3438
+ return /* @__PURE__ */ jsxs38("div", __spreadProps(__spreadValues({ className: cn("w-full", className) }, props), { children: [
3439
+ (label || showPercentage) && /* @__PURE__ */ jsxs38("div", { className: "mb-1.5 flex justify-between text-sm text-ph-subtle", children: [
3440
+ label && /* @__PURE__ */ jsx44("span", { children: label }),
3441
+ showPercentage && /* @__PURE__ */ jsxs38("span", { className: "tabular-nums", children: [
3442
+ Math.round(percentage),
3443
+ "%"
3444
+ ] })
3445
+ ] }),
3446
+ /* @__PURE__ */ jsx44("div", { className: cn("ph-progress", sizeMap6[size]), children: /* @__PURE__ */ jsx44(
3447
+ "div",
3448
+ {
3449
+ className: cn("ph-progress-bar", color),
3450
+ style: { width: `${percentage}%` },
3451
+ role: "progressbar",
3452
+ "aria-valuenow": value,
3453
+ "aria-valuemin": 0,
3454
+ "aria-valuemax": max
3455
+ }
3456
+ ) })
3457
+ ] }));
3458
+ }
3459
+
3460
+ // src/components/ui/ChatBubble.tsx
3461
+ import { jsx as jsx45, jsxs as jsxs39 } from "react/jsx-runtime";
3462
+ function ChatBubble(_a) {
3463
+ var _b = _a, {
3464
+ children,
3465
+ avatar,
3466
+ name,
3467
+ time,
3468
+ variant = "from",
3469
+ footer,
3470
+ className
3471
+ } = _b, props = __objRest(_b, [
3472
+ "children",
3473
+ "avatar",
3474
+ "name",
3475
+ "time",
3476
+ "variant",
3477
+ "footer",
3478
+ "className"
3479
+ ]);
3480
+ const isSelf = variant === "self";
3481
+ return /* @__PURE__ */ jsxs39(
3482
+ "div",
3483
+ __spreadProps(__spreadValues({
3484
+ className: cn(
3485
+ "flex gap-3",
3486
+ isSelf && "flex-row-reverse",
3487
+ className
3488
+ )
3489
+ }, props), {
3490
+ children: [
3491
+ avatar && /* @__PURE__ */ jsx45("div", { className: "shrink-0", children: avatar }),
3492
+ /* @__PURE__ */ jsxs39("div", { className: cn("min-w-0 flex-1", isSelf && "text-right"), children: [
3493
+ (name || time) && /* @__PURE__ */ jsxs39(
3494
+ "header",
3495
+ {
3496
+ className: cn(
3497
+ "flex gap-2 text-xs text-ph-mutedtext",
3498
+ isSelf && "flex-row-reverse justify-end"
3499
+ ),
3500
+ children: [
3501
+ name && /* @__PURE__ */ jsx45("span", { className: "font-semibold text-ph-ink", children: name }),
3502
+ time && /* @__PURE__ */ jsx45("span", { children: time })
3503
+ ]
3504
+ }
3505
+ ),
3506
+ /* @__PURE__ */ jsx45(
3507
+ "div",
3508
+ {
3509
+ className: cn(
3510
+ "mt-2 inline-block text-left shadow-ph",
3511
+ isSelf ? "ph-chat-self" : "ph-chat-from"
3512
+ ),
3513
+ children
3514
+ }
3515
+ ),
3516
+ footer && /* @__PURE__ */ jsx45("footer", { className: "mt-2 text-[11px] text-ph-mutedtext", children: footer })
3517
+ ] })
3518
+ ]
3519
+ })
3520
+ );
3521
+ }
3522
+
3523
+ // src/components/ui/Terminal.tsx
3524
+ import { Fragment as Fragment6, jsx as jsx46, jsxs as jsxs40 } from "react/jsx-runtime";
3525
+ function Terminal(_a) {
3526
+ var _b = _a, {
3527
+ title = "sandbox",
3528
+ lines,
3529
+ children,
3530
+ className
3531
+ } = _b, props = __objRest(_b, [
3532
+ "title",
3533
+ "lines",
3534
+ "children",
3535
+ "className"
3536
+ ]);
3537
+ return /* @__PURE__ */ jsxs40(
3538
+ "div",
3539
+ __spreadProps(__spreadValues({
3540
+ className: cn(
3541
+ "overflow-hidden rounded-xl border border-ph-border shadow-ph-md",
3542
+ className
3543
+ )
3544
+ }, props), {
3545
+ children: [
3546
+ /* @__PURE__ */ jsxs40("header", { className: "flex items-center gap-2 border-b border-ph-border bg-ph-muted px-4 py-3", children: [
3547
+ /* @__PURE__ */ jsx46("div", { className: "h-3 w-3 rounded-full bg-red-400" }),
3548
+ /* @__PURE__ */ jsx46("div", { className: "h-3 w-3 rounded-full bg-amber-400" }),
3549
+ /* @__PURE__ */ jsx46("div", { className: "h-3 w-3 rounded-full bg-emerald-400" }),
3550
+ title && /* @__PURE__ */ jsx46("span", { className: "text-xs font-medium text-ph-mutedtext", children: title })
3551
+ ] }),
3552
+ /* @__PURE__ */ jsx46("div", { className: "ph-code rounded-none border-x-0 border-b-0 text-[13px] leading-relaxed", children: children || /* @__PURE__ */ jsx46(Fragment6, { children: lines == null ? void 0 : lines.map((line, i) => {
3553
+ const text = typeof line === "string" ? line : line.text;
3554
+ const color = typeof line === "string" ? void 0 : line.color;
3555
+ return /* @__PURE__ */ jsxs40("span", { children: [
3556
+ /* @__PURE__ */ jsx46("span", { className: color || "text-neutral-600", children: text }),
3557
+ i < lines.length - 1 && /* @__PURE__ */ jsx46("br", {})
3558
+ ] }, i);
3559
+ }) }) })
3560
+ ]
3561
+ })
3562
+ );
3563
+ }
3564
+
3565
+ // src/components/ui/Indicator.tsx
3566
+ import { jsx as jsx47, jsxs as jsxs41 } from "react/jsx-runtime";
3567
+ var positionMap = {
3568
+ "top-right": "-right-[2px] -top-[2px]",
3569
+ "top-left": "-left-[2px] -top-[2px]",
3570
+ "bottom-right": "-right-[2px] -bottom-[2px]",
3571
+ "bottom-left": "-left-[2px] -bottom-[2px]"
3572
+ };
3573
+ function Indicator(_a) {
3574
+ var _b = _a, {
3575
+ children,
3576
+ badge,
3577
+ color = "bg-ph-brand",
3578
+ position = "top-right",
3579
+ dot = false,
3580
+ className
3581
+ } = _b, props = __objRest(_b, [
3582
+ "children",
3583
+ "badge",
3584
+ "color",
3585
+ "position",
3586
+ "dot",
3587
+ "className"
3588
+ ]);
3589
+ return /* @__PURE__ */ jsxs41("div", __spreadProps(__spreadValues({ className: cn("relative inline-flex items-center justify-center", className) }, props), { children: [
3590
+ dot ? /* @__PURE__ */ jsx47(
3591
+ "span",
3592
+ {
3593
+ className: cn(
3594
+ "absolute z-10 h-2.5 w-2.5 rounded-full border-2 border-white",
3595
+ color,
3596
+ positionMap[position]
3597
+ )
3598
+ }
3599
+ ) : badge != null ? /* @__PURE__ */ jsx47(
3600
+ "span",
3601
+ {
3602
+ className: cn(
3603
+ "absolute z-10 flex min-h-[22px] min-w-[22px] items-center justify-center rounded-full px-1 text-[11px] font-bold text-white",
3604
+ color,
3605
+ positionMap[position]
3606
+ ),
3607
+ children: badge
3608
+ }
3609
+ ) : null,
3610
+ children
3611
+ ] }));
3612
+ }
3613
+
3614
+ // src/components/ui/Timeline.tsx
3615
+ import { jsx as jsx48, jsxs as jsxs42 } from "react/jsx-runtime";
3616
+ function Timeline(_a) {
3617
+ var _b = _a, {
3618
+ events,
3619
+ alternate = false,
3620
+ className
3621
+ } = _b, props = __objRest(_b, [
3622
+ "events",
3623
+ "alternate",
3624
+ "className"
3625
+ ]);
3626
+ return /* @__PURE__ */ jsx48(
3627
+ "ol",
3628
+ __spreadProps(__spreadValues({
3629
+ className: cn("relative space-y-8", className)
3630
+ }, props), {
3631
+ children: events.map((event, idx) => {
3632
+ const align = alternate && idx % 2 !== 0 ? "lg:flex-row-reverse" : "";
3633
+ return /* @__PURE__ */ jsxs42("li", { className: cn("relative flex gap-6", align), children: [
3634
+ /* @__PURE__ */ jsx48(
3635
+ "div",
3636
+ {
3637
+ className: cn(
3638
+ "relative z-10 flex h-12 w-12 shrink-0 items-center justify-center rounded-full ring-8 ring-ph-muted shadow-md",
3639
+ event.color || "bg-ph-brand text-white"
3640
+ ),
3641
+ children: event.icon
3642
+ }
3643
+ ),
3644
+ /* @__PURE__ */ jsxs42("article", { className: "flex-1 rounded-xl border border-ph-border bg-ph-surface p-4 shadow-ph", children: [
3645
+ /* @__PURE__ */ jsxs42("div", { className: "flex flex-wrap items-baseline gap-3", children: [
3646
+ /* @__PURE__ */ jsx48("h4", { className: "text-base font-semibold text-ph-ink", children: event.title }),
3647
+ event.time && /* @__PURE__ */ jsx48("time", { className: "text-[11px] font-semibold uppercase tracking-wide text-ph-mutedtext", children: event.time })
3648
+ ] }),
3649
+ event.description && /* @__PURE__ */ jsx48("p", { className: "mt-2 text-sm text-ph-subtle", children: event.description })
3650
+ ] })
3651
+ ] }, event.id);
3652
+ })
3653
+ })
3654
+ );
3655
+ }
3656
+
3657
+ export {
3658
+ ButtonChrome,
3659
+ cn,
3660
+ Button,
3661
+ IconBase,
3662
+ createIconBase,
3663
+ createIconBasePath,
3664
+ IconAreaChart,
3665
+ IconCumulativeChart,
3666
+ IconTableChart,
3667
+ IconHandClick,
3668
+ IconSurveys,
3669
+ IconCohort,
3670
+ IconRecording,
3671
+ IconFlare,
3672
+ IconSelectEvents,
3673
+ IconClipboardEdit,
3674
+ IconQueryEditor,
3675
+ IconTuning,
3676
+ IconSync,
3677
+ IconPlayCircle,
3678
+ IconGridView,
3679
+ IconListView,
3680
+ IconPremium,
3681
+ IconGift,
3682
+ IconRobot,
3683
+ IconExclamation,
3684
+ IconErrorOutline,
3685
+ IconInfo,
3686
+ IconCancel,
3687
+ IconCheckCircle,
3688
+ IconArrowUp,
3689
+ IconArrowDown,
3690
+ IconChevronLeft,
3691
+ IconChevronRight,
3692
+ IconChevronDown,
3693
+ IconSubArrowRight,
3694
+ IconSearch,
3695
+ IconBell,
3696
+ IconBellOff,
3697
+ IconPerson,
3698
+ IconHome,
3699
+ IconPanelRight,
3700
+ IconPlus,
3701
+ IconCheck,
3702
+ IconClose,
3703
+ IconTrash,
3704
+ IconDownload,
3705
+ IconUpload,
3706
+ IconSave,
3707
+ IconCopy,
3708
+ IconEdit,
3709
+ IconLogout,
3710
+ IconStar,
3711
+ IconMail,
3712
+ IconShoppingCart,
3713
+ IconMoon,
3714
+ IconSun,
3715
+ IconVolume,
3716
+ IconVolumeOff,
3717
+ IconFlag,
3718
+ IconDatabase,
3719
+ IconLayers,
3720
+ IconBox,
3721
+ IconBolt,
3722
+ IconRadar,
3723
+ IconToggle,
3724
+ IconRocket,
3725
+ IconTerminal,
3726
+ IconOldWindow,
3727
+ IconCommandCursor,
3728
+ IconDataReel,
3729
+ IconCodePreview,
3730
+ IconInsightBoard,
3731
+ IconEventStream,
3732
+ IconFeatureGate,
3733
+ IconReplayFrame,
3734
+ IconQueryStack,
3735
+ IconExperimentSplit,
3736
+ IconSurveyCard,
3737
+ OLD_UI_ICONS,
3738
+ IconActivity,
3739
+ IconFlask,
3740
+ IconSpinner,
3741
+ CANONICAL_ICONS,
3742
+ PH_ICON_ALIASES,
3743
+ PH_ICONS,
3744
+ IconByName,
3745
+ Alert,
3746
+ Badge,
3747
+ Card,
3748
+ Drawer,
3749
+ Kbd,
3750
+ Loader,
3751
+ Skeleton,
3752
+ LoadingState,
3753
+ AuthLayout,
3754
+ AuthCard,
3755
+ AuthDivider,
3756
+ SettingsNav,
3757
+ SettingsLayout,
3758
+ DropdownMenu,
3759
+ DropdownButton,
3760
+ DropdownItem,
3761
+ DropdownRadioGroup,
3762
+ DropdownRadioItem,
3763
+ FormField,
3764
+ Input,
3765
+ Select,
3766
+ Textarea,
3767
+ Checkbox,
3768
+ Radio,
3769
+ Toggle,
3770
+ Range,
3771
+ FileUpload,
3772
+ Modal,
3773
+ Breadcrumbs,
3774
+ Pagination,
3775
+ Panel,
3776
+ Rating,
3777
+ SearchInput,
3778
+ SearchGroup,
3779
+ Table,
3780
+ Stat,
3781
+ Toast,
3782
+ ToastStack,
3783
+ Tabs,
3784
+ DEFAULT_THEME_ID,
3785
+ THEMES,
3786
+ THEME_GROUPS,
3787
+ isThemeId,
3788
+ getTheme,
3789
+ THEME_INIT_SCRIPT,
3790
+ persistTheme,
3791
+ readStoredTheme,
3792
+ ThemeDomSync,
3793
+ ThemeManager,
3794
+ ThemeSwitcher,
3795
+ Accordion,
3796
+ Stepper,
3797
+ SegmentedControl,
3798
+ CommandPalette,
3799
+ Calendar,
3800
+ HoverCard,
3801
+ EmptyState,
3802
+ FilterChips,
3803
+ FilterBar,
3804
+ FilterMenu,
3805
+ SortMenu,
3806
+ FilterControls,
3807
+ CodeBlock,
3808
+ ComponentDocs,
3809
+ ShowcaseWrapper,
3810
+ CollapsibleSection,
3811
+ Display,
3812
+ H1,
3813
+ H2,
3814
+ H3,
3815
+ H4,
3816
+ H5,
3817
+ P,
3818
+ Small,
3819
+ Caption,
3820
+ Overline,
3821
+ Lead,
3822
+ Mono,
3823
+ Label,
3824
+ Avatar,
3825
+ AvatarGroup,
3826
+ Progress,
3827
+ ChatBubble,
3828
+ Terminal,
3829
+ Indicator,
3830
+ Timeline
3831
+ };