@petrarca/sonnet-playground 0.1.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 (72) hide show
  1. package/dist/PlayAdvancedComponents-ZYK66UII.js +8 -0
  2. package/dist/PlayColorPalette-IWECRZUS.js +8 -0
  3. package/dist/PlayCoreComponents-F2OFSQZK.js +8 -0
  4. package/dist/PlayDataComponents-BA3NA225.js +8 -0
  5. package/dist/PlayFormComponents-MZC7CNES.js +8 -0
  6. package/dist/PlayFormWidgets-IWJJQ5XL.js +8 -0
  7. package/dist/PlayForms-FOF3XE6G.js +7 -0
  8. package/dist/PlayGraph-RHFIDAS3.js +7 -0
  9. package/dist/PlayJsonEditor-SYZYEJEA.js +7 -0
  10. package/dist/PlayJsonEditor-SYZYEJEA.js.map +1 -0
  11. package/dist/PlayShellApi-3T4FZPEV.js +8 -0
  12. package/dist/PlayShellApi-3T4FZPEV.js.map +1 -0
  13. package/dist/PlayTypography-T6SMPHUB.js +8 -0
  14. package/dist/PlayTypography-T6SMPHUB.js.map +1 -0
  15. package/dist/chunk-4S2ITDB3.js +322 -0
  16. package/dist/chunk-4S2ITDB3.js.map +1 -0
  17. package/dist/chunk-4Y4JFKAK.js +240 -0
  18. package/dist/chunk-4Y4JFKAK.js.map +1 -0
  19. package/dist/{chunk-QIETZUEN.js → chunk-6DZ3TSV4.js} +66 -71
  20. package/dist/chunk-6DZ3TSV4.js.map +1 -0
  21. package/dist/{chunk-CYNK2P2Q.js → chunk-7IBZEHLI.js} +14 -13
  22. package/dist/chunk-7IBZEHLI.js.map +1 -0
  23. package/dist/chunk-C2EZ2ECG.js +40 -0
  24. package/dist/chunk-C2EZ2ECG.js.map +1 -0
  25. package/dist/{chunk-A3IK3CVW.js → chunk-DA3BIB5N.js} +24 -25
  26. package/dist/{chunk-A3IK3CVW.js.map → chunk-DA3BIB5N.js.map} +1 -1
  27. package/dist/{chunk-TZGJH7YS.js → chunk-DKLALDHR.js} +325 -331
  28. package/dist/chunk-DKLALDHR.js.map +1 -0
  29. package/dist/chunk-DZB6WFHA.js +401 -0
  30. package/dist/chunk-DZB6WFHA.js.map +1 -0
  31. package/dist/{chunk-KAT24CQQ.js → chunk-FZ3ZC7VM.js} +8 -6
  32. package/dist/chunk-FZ3ZC7VM.js.map +1 -0
  33. package/dist/chunk-MT4ILA37.js +563 -0
  34. package/dist/chunk-MT4ILA37.js.map +1 -0
  35. package/dist/chunk-QCK2M4KD.js +907 -0
  36. package/dist/chunk-QCK2M4KD.js.map +1 -0
  37. package/dist/chunk-SBKZRIJC.js +316 -0
  38. package/dist/chunk-SBKZRIJC.js.map +1 -0
  39. package/dist/index.d.ts +10 -6
  40. package/dist/index.js +52 -16
  41. package/dist/index.js.map +1 -1
  42. package/dist/pages/index.d.ts +26 -11
  43. package/dist/pages/index.js +23 -11
  44. package/package.json +6 -5
  45. package/dist/PlayColorPalette-UFMTJTUB.js +0 -8
  46. package/dist/PlayCoreComponents-7QCDFQLT.js +0 -7
  47. package/dist/PlayDataComponents-GZSRTW4F.js +0 -7
  48. package/dist/PlayFormComponents-RJB6WZHD.js +0 -7
  49. package/dist/PlayFormWidgets-OFV7TJKH.js +0 -7
  50. package/dist/PlayForms-24XX5DC6.js +0 -7
  51. package/dist/PlayJsonEditor-4L5INQPU.js +0 -7
  52. package/dist/PlayTypography-ID6DLFZD.js +0 -8
  53. package/dist/chunk-5V27QDAY.js +0 -617
  54. package/dist/chunk-5V27QDAY.js.map +0 -1
  55. package/dist/chunk-CYNK2P2Q.js.map +0 -1
  56. package/dist/chunk-FTN2A5YL.js +0 -20
  57. package/dist/chunk-FTN2A5YL.js.map +0 -1
  58. package/dist/chunk-GYKEPHHA.js +0 -1154
  59. package/dist/chunk-GYKEPHHA.js.map +0 -1
  60. package/dist/chunk-KAT24CQQ.js.map +0 -1
  61. package/dist/chunk-P7I5IDXA.js +0 -432
  62. package/dist/chunk-P7I5IDXA.js.map +0 -1
  63. package/dist/chunk-QIETZUEN.js.map +0 -1
  64. package/dist/chunk-TZGJH7YS.js.map +0 -1
  65. /package/dist/{PlayColorPalette-UFMTJTUB.js.map → PlayAdvancedComponents-ZYK66UII.js.map} +0 -0
  66. /package/dist/{PlayCoreComponents-7QCDFQLT.js.map → PlayColorPalette-IWECRZUS.js.map} +0 -0
  67. /package/dist/{PlayDataComponents-GZSRTW4F.js.map → PlayCoreComponents-F2OFSQZK.js.map} +0 -0
  68. /package/dist/{PlayFormComponents-RJB6WZHD.js.map → PlayDataComponents-BA3NA225.js.map} +0 -0
  69. /package/dist/{PlayFormWidgets-OFV7TJKH.js.map → PlayFormComponents-MZC7CNES.js.map} +0 -0
  70. /package/dist/{PlayForms-24XX5DC6.js.map → PlayFormWidgets-IWJJQ5XL.js.map} +0 -0
  71. /package/dist/{PlayJsonEditor-4L5INQPU.js.map → PlayForms-FOF3XE6G.js.map} +0 -0
  72. /package/dist/{PlayTypography-ID6DLFZD.js.map → PlayGraph-RHFIDAS3.js.map} +0 -0
@@ -0,0 +1,907 @@
1
+ import {
2
+ PlaygroundSection
3
+ } from "./chunk-C2EZ2ECG.js";
4
+
5
+ // src/pages/PlayCoreComponents.tsx
6
+ import { useState } from "react";
7
+ import { toast } from "sonner";
8
+ import {
9
+ Spinner,
10
+ Button,
11
+ Badge,
12
+ Alert,
13
+ AlertDescription,
14
+ AlertTitle,
15
+ Separator,
16
+ Input,
17
+ Textarea,
18
+ Checkbox,
19
+ Label,
20
+ Avatar,
21
+ AvatarImage,
22
+ AvatarFallback,
23
+ Tooltip,
24
+ TooltipContent,
25
+ TooltipProvider,
26
+ TooltipTrigger,
27
+ Card,
28
+ CardContent,
29
+ CardDescription,
30
+ CardFooter,
31
+ CardHeader,
32
+ CardTitle,
33
+ Dialog,
34
+ DialogContent,
35
+ DialogDescription,
36
+ DialogFooter,
37
+ DialogHeader,
38
+ DialogTitle,
39
+ DialogTrigger
40
+ } from "@petrarca/sonnet-ui";
41
+ import { useClipboard, useDisclosure } from "@petrarca/sonnet-core/hooks";
42
+ import { Info, AlertTriangle, CheckCircle } from "lucide-react";
43
+ import { jsx, jsxs } from "react/jsx-runtime";
44
+ function PlayCoreComponents() {
45
+ const [spinnerSize, setSpinnerSize] = useState("md");
46
+ const clipboard = useClipboard({ timeout: 2e3 });
47
+ const [disclosureOpened, disclosureHandlers] = useDisclosure(false);
48
+ return /* @__PURE__ */ jsxs("div", { className: "space-y-6", children: [
49
+ /* @__PURE__ */ jsxs("div", { children: [
50
+ /* @__PURE__ */ jsx("h1", { children: "Core UI Components" }),
51
+ /* @__PURE__ */ jsx("p", { className: "text-sm text-muted-foreground mt-1", children: "Test all core UI components in isolation before production deployment. Each component is verified here first." })
52
+ ] }),
53
+ /* @__PURE__ */ jsxs("div", { className: "space-y-6", children: [
54
+ /* @__PURE__ */ jsx(
55
+ PlaygroundSection,
56
+ {
57
+ title: "Buttons",
58
+ description: "shadcn/ui Button component with all variants and sizes.",
59
+ variant: "card",
60
+ children: /* @__PURE__ */ jsxs("div", { className: "space-y-6", children: [
61
+ /* @__PURE__ */ jsxs("div", { children: [
62
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "Variants" }),
63
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap gap-3", children: [
64
+ /* @__PURE__ */ jsx(Button, { children: "Default" }),
65
+ /* @__PURE__ */ jsx(Button, { variant: "secondary", children: "Secondary" }),
66
+ /* @__PURE__ */ jsx(Button, { variant: "destructive", children: "Destructive" }),
67
+ /* @__PURE__ */ jsx(Button, { variant: "outline", children: "Outline" }),
68
+ /* @__PURE__ */ jsx(Button, { variant: "ghost", children: "Ghost" }),
69
+ /* @__PURE__ */ jsx(Button, { variant: "link", children: "Link" })
70
+ ] })
71
+ ] }),
72
+ /* @__PURE__ */ jsx(Separator, {}),
73
+ /* @__PURE__ */ jsxs("div", { children: [
74
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "Sizes" }),
75
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap items-center gap-3", children: [
76
+ /* @__PURE__ */ jsx(Button, { size: "sm", children: "Small" }),
77
+ /* @__PURE__ */ jsx(Button, { size: "default", children: "Default" }),
78
+ /* @__PURE__ */ jsx(Button, { size: "lg", children: "Large" }),
79
+ /* @__PURE__ */ jsx(Button, { size: "icon", children: "\u{1F50D}" })
80
+ ] })
81
+ ] }),
82
+ /* @__PURE__ */ jsx(Separator, {}),
83
+ /* @__PURE__ */ jsxs("div", { children: [
84
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "States" }),
85
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap gap-3", children: [
86
+ /* @__PURE__ */ jsx(Button, { disabled: true, children: "Disabled" }),
87
+ /* @__PURE__ */ jsx(Button, { variant: "outline", disabled: true, children: "Disabled Outline" })
88
+ ] })
89
+ ] })
90
+ ] })
91
+ }
92
+ ),
93
+ /* @__PURE__ */ jsx(
94
+ PlaygroundSection,
95
+ {
96
+ title: "Badges",
97
+ description: "Badge component with different variants.",
98
+ variant: "card",
99
+ children: /* @__PURE__ */ jsxs("div", { className: "space-y-4", children: [
100
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap items-center gap-3", children: [
101
+ /* @__PURE__ */ jsx(Badge, { children: "Default" }),
102
+ /* @__PURE__ */ jsx(Badge, { variant: "secondary", children: "Secondary" }),
103
+ /* @__PURE__ */ jsx(Badge, { variant: "destructive", children: "Destructive" }),
104
+ /* @__PURE__ */ jsx(Badge, { variant: "outline", children: "Outline" })
105
+ ] }),
106
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap items-center gap-3", children: [
107
+ /* @__PURE__ */ jsx("span", { className: "text-sm text-muted-foreground", children: "Status:" }),
108
+ /* @__PURE__ */ jsx(Badge, { variant: "default", children: "Active" }),
109
+ /* @__PURE__ */ jsx(Badge, { variant: "secondary", children: "Pending" }),
110
+ /* @__PURE__ */ jsx(Badge, { variant: "destructive", children: "Error" })
111
+ ] })
112
+ ] })
113
+ }
114
+ ),
115
+ /* @__PURE__ */ jsx(
116
+ PlaygroundSection,
117
+ {
118
+ title: "Alerts",
119
+ description: "Alert component for important messages.",
120
+ variant: "card",
121
+ children: /* @__PURE__ */ jsxs("div", { className: "space-y-4", children: [
122
+ /* @__PURE__ */ jsxs(Alert, { children: [
123
+ /* @__PURE__ */ jsx(Info, { className: "h-4 w-4" }),
124
+ /* @__PURE__ */ jsx(AlertTitle, { children: "Info" }),
125
+ /* @__PURE__ */ jsx(AlertDescription, { children: "This is an informational message." })
126
+ ] }),
127
+ /* @__PURE__ */ jsxs(Alert, { variant: "default", children: [
128
+ /* @__PURE__ */ jsx(CheckCircle, { className: "h-4 w-4" }),
129
+ /* @__PURE__ */ jsx(AlertTitle, { children: "Success" }),
130
+ /* @__PURE__ */ jsx(AlertDescription, { children: "Your operation completed successfully." })
131
+ ] }),
132
+ /* @__PURE__ */ jsxs(Alert, { variant: "destructive", children: [
133
+ /* @__PURE__ */ jsx(AlertTriangle, { className: "h-4 w-4" }),
134
+ /* @__PURE__ */ jsx(AlertTitle, { children: "Error" }),
135
+ /* @__PURE__ */ jsx(AlertDescription, { children: "There was a problem with your request." })
136
+ ] })
137
+ ] })
138
+ }
139
+ ),
140
+ /* @__PURE__ */ jsx(
141
+ PlaygroundSection,
142
+ {
143
+ title: "Cards",
144
+ description: "Card component for content containers.",
145
+ variant: "card",
146
+ children: /* @__PURE__ */ jsxs("div", { className: "grid grid-cols-1 md:grid-cols-2 gap-4", children: [
147
+ /* @__PURE__ */ jsxs(Card, { children: [
148
+ /* @__PURE__ */ jsxs(CardHeader, { children: [
149
+ /* @__PURE__ */ jsx(CardTitle, { children: "Simple Card" }),
150
+ /* @__PURE__ */ jsx(CardDescription, { children: "Basic card with header and content" })
151
+ ] }),
152
+ /* @__PURE__ */ jsx(CardContent, { children: /* @__PURE__ */ jsx("p", { className: "text-sm text-muted-foreground", children: "This is a simple card component with header and content sections." }) })
153
+ ] }),
154
+ /* @__PURE__ */ jsxs(Card, { children: [
155
+ /* @__PURE__ */ jsxs(CardHeader, { children: [
156
+ /* @__PURE__ */ jsx(CardTitle, { children: "Card with Footer" }),
157
+ /* @__PURE__ */ jsx(CardDescription, { children: "Includes footer with actions" })
158
+ ] }),
159
+ /* @__PURE__ */ jsx(CardContent, { children: /* @__PURE__ */ jsx("p", { className: "text-sm text-muted-foreground", children: "This card has a footer section for actions." }) }),
160
+ /* @__PURE__ */ jsxs(CardFooter, { className: "flex gap-2", children: [
161
+ /* @__PURE__ */ jsx(Button, { variant: "outline", size: "sm", children: "Cancel" }),
162
+ /* @__PURE__ */ jsx(Button, { size: "sm", children: "Save" })
163
+ ] })
164
+ ] }),
165
+ /* @__PURE__ */ jsxs(Card, { className: "col-span-1 md:col-span-2", children: [
166
+ /* @__PURE__ */ jsxs(CardHeader, { children: [
167
+ /* @__PURE__ */ jsx(CardTitle, { children: "Full Width Card" }),
168
+ /* @__PURE__ */ jsx(CardDescription, { children: "This card spans the full width" })
169
+ ] }),
170
+ /* @__PURE__ */ jsx(CardContent, { children: /* @__PURE__ */ jsxs("div", { className: "space-y-2", children: [
171
+ /* @__PURE__ */ jsx("p", { className: "text-sm text-muted-foreground", children: "Cards can be combined with other components for rich layouts." }),
172
+ /* @__PURE__ */ jsxs("div", { className: "flex gap-2", children: [
173
+ /* @__PURE__ */ jsx(Badge, { children: "Feature" }),
174
+ /* @__PURE__ */ jsx(Badge, { variant: "secondary", children: "New" })
175
+ ] })
176
+ ] }) })
177
+ ] })
178
+ ] })
179
+ }
180
+ ),
181
+ /* @__PURE__ */ jsx(
182
+ PlaygroundSection,
183
+ {
184
+ title: "Separator",
185
+ description: "Visual separator for content sections.",
186
+ variant: "card",
187
+ children: /* @__PURE__ */ jsxs("div", { className: "space-y-4", children: [
188
+ /* @__PURE__ */ jsxs("div", { children: [
189
+ /* @__PURE__ */ jsx("p", { className: "text-sm", children: "Content above separator" }),
190
+ /* @__PURE__ */ jsx(Separator, { className: "my-4" }),
191
+ /* @__PURE__ */ jsx("p", { className: "text-sm", children: "Content below separator" })
192
+ ] }),
193
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-4", children: [
194
+ /* @__PURE__ */ jsx("p", { className: "text-sm", children: "Vertical separator" }),
195
+ /* @__PURE__ */ jsx(Separator, { orientation: "vertical", className: "h-6" }),
196
+ /* @__PURE__ */ jsx("p", { className: "text-sm", children: "Between items" })
197
+ ] })
198
+ ] })
199
+ }
200
+ ),
201
+ /* @__PURE__ */ jsx(
202
+ PlaygroundSection,
203
+ {
204
+ title: "Tooltips",
205
+ description: "Tooltip component for additional information on hover.",
206
+ variant: "card",
207
+ children: /* @__PURE__ */ jsx(TooltipProvider, { children: /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap gap-6", children: [
208
+ /* @__PURE__ */ jsxs(Tooltip, { children: [
209
+ /* @__PURE__ */ jsx(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx(Button, { variant: "outline", children: "Hover me" }) }),
210
+ /* @__PURE__ */ jsx(TooltipContent, { children: /* @__PURE__ */ jsx("p", { children: "This is a tooltip" }) })
211
+ ] }),
212
+ /* @__PURE__ */ jsxs(Tooltip, { children: [
213
+ /* @__PURE__ */ jsx(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx(Button, { children: "Top (default)" }) }),
214
+ /* @__PURE__ */ jsx(TooltipContent, { children: /* @__PURE__ */ jsx("p", { children: "Tooltip positioned at top" }) })
215
+ ] }),
216
+ /* @__PURE__ */ jsxs(Tooltip, { children: [
217
+ /* @__PURE__ */ jsx(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx(Button, { variant: "secondary", children: "With icon \u{1F3AF}" }) }),
218
+ /* @__PURE__ */ jsx(TooltipContent, { children: /* @__PURE__ */ jsx("p", { children: "Tooltips work with any trigger element" }) })
219
+ ] })
220
+ ] }) })
221
+ }
222
+ ),
223
+ /* @__PURE__ */ jsx(
224
+ PlaygroundSection,
225
+ {
226
+ title: "Dialogs",
227
+ description: "shadcn/ui Dialog component for modal interactions.",
228
+ variant: "card",
229
+ children: /* @__PURE__ */ jsxs("div", { className: "space-y-6", children: [
230
+ /* @__PURE__ */ jsxs("div", { children: [
231
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "Basic Dialog" }),
232
+ /* @__PURE__ */ jsxs(Dialog, { children: [
233
+ /* @__PURE__ */ jsx(DialogTrigger, { asChild: true, children: /* @__PURE__ */ jsx(Button, { variant: "outline", children: "Open Dialog" }) }),
234
+ /* @__PURE__ */ jsxs(DialogContent, { children: [
235
+ /* @__PURE__ */ jsxs(DialogHeader, { children: [
236
+ /* @__PURE__ */ jsx(DialogTitle, { children: "Dialog Title" }),
237
+ /* @__PURE__ */ jsx(DialogDescription, { children: "This is a basic dialog with a title and description." })
238
+ ] }),
239
+ /* @__PURE__ */ jsx("div", { className: "py-4", children: /* @__PURE__ */ jsx("p", { className: "text-sm text-muted-foreground", children: "Dialog content goes here. You can add any components or text you need." }) }),
240
+ /* @__PURE__ */ jsxs(DialogFooter, { children: [
241
+ /* @__PURE__ */ jsx(Button, { variant: "outline", children: "Cancel" }),
242
+ /* @__PURE__ */ jsx(Button, { children: "Confirm" })
243
+ ] })
244
+ ] })
245
+ ] })
246
+ ] }),
247
+ /* @__PURE__ */ jsx(Separator, {}),
248
+ /* @__PURE__ */ jsxs("div", { children: [
249
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "Confirmation Dialog" }),
250
+ /* @__PURE__ */ jsxs(Dialog, { children: [
251
+ /* @__PURE__ */ jsx(DialogTrigger, { asChild: true, children: /* @__PURE__ */ jsx(Button, { variant: "destructive", children: "Delete Item" }) }),
252
+ /* @__PURE__ */ jsxs(DialogContent, { children: [
253
+ /* @__PURE__ */ jsxs(DialogHeader, { children: [
254
+ /* @__PURE__ */ jsx(DialogTitle, { children: "Are you absolutely sure?" }),
255
+ /* @__PURE__ */ jsx(DialogDescription, { children: "This action cannot be undone. This will permanently delete your data from our servers." })
256
+ ] }),
257
+ /* @__PURE__ */ jsxs(DialogFooter, { children: [
258
+ /* @__PURE__ */ jsx(Button, { variant: "outline", children: "Cancel" }),
259
+ /* @__PURE__ */ jsx(
260
+ Button,
261
+ {
262
+ variant: "destructive",
263
+ onClick: () => {
264
+ toast.success("Item deleted");
265
+ },
266
+ children: "Delete"
267
+ }
268
+ )
269
+ ] })
270
+ ] })
271
+ ] })
272
+ ] }),
273
+ /* @__PURE__ */ jsx(Separator, {}),
274
+ /* @__PURE__ */ jsxs("div", { children: [
275
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "Dialog with Form" }),
276
+ /* @__PURE__ */ jsxs(Dialog, { children: [
277
+ /* @__PURE__ */ jsx(DialogTrigger, { asChild: true, children: /* @__PURE__ */ jsx(Button, { children: "Add New Item" }) }),
278
+ /* @__PURE__ */ jsxs(DialogContent, { children: [
279
+ /* @__PURE__ */ jsxs(DialogHeader, { children: [
280
+ /* @__PURE__ */ jsx(DialogTitle, { children: "Add New Item" }),
281
+ /* @__PURE__ */ jsx(DialogDescription, { children: "Fill in the details below to add a new item." })
282
+ ] }),
283
+ /* @__PURE__ */ jsxs("div", { className: "grid gap-4 py-4", children: [
284
+ /* @__PURE__ */ jsxs("div", { className: "grid gap-2", children: [
285
+ /* @__PURE__ */ jsx(Label, { htmlFor: "name", children: "Name" }),
286
+ /* @__PURE__ */ jsx(
287
+ Input,
288
+ {
289
+ id: "name",
290
+ type: "text",
291
+ placeholder: "Enter name..."
292
+ }
293
+ )
294
+ ] }),
295
+ /* @__PURE__ */ jsxs("div", { className: "grid gap-2", children: [
296
+ /* @__PURE__ */ jsx(Label, { htmlFor: "description", children: "Description" }),
297
+ /* @__PURE__ */ jsx(
298
+ Textarea,
299
+ {
300
+ id: "description",
301
+ placeholder: "Enter description...",
302
+ rows: 3
303
+ }
304
+ )
305
+ ] })
306
+ ] }),
307
+ /* @__PURE__ */ jsxs(DialogFooter, { children: [
308
+ /* @__PURE__ */ jsx(Button, { variant: "outline", children: "Cancel" }),
309
+ /* @__PURE__ */ jsx(
310
+ Button,
311
+ {
312
+ onClick: () => {
313
+ toast.success("Item added");
314
+ },
315
+ children: "Add Item"
316
+ }
317
+ )
318
+ ] })
319
+ ] })
320
+ ] })
321
+ ] }),
322
+ /* @__PURE__ */ jsx(Separator, {}),
323
+ /* @__PURE__ */ jsxs("div", { children: [
324
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "Information Dialog" }),
325
+ /* @__PURE__ */ jsxs(Dialog, { children: [
326
+ /* @__PURE__ */ jsx(DialogTrigger, { asChild: true, children: /* @__PURE__ */ jsx(Button, { variant: "secondary", children: "View Details" }) }),
327
+ /* @__PURE__ */ jsxs(DialogContent, { className: "max-w-2xl", children: [
328
+ /* @__PURE__ */ jsxs(DialogHeader, { children: [
329
+ /* @__PURE__ */ jsx(DialogTitle, { children: "System Information" }),
330
+ /* @__PURE__ */ jsx(DialogDescription, { children: "Detailed information about the current system status." })
331
+ ] }),
332
+ /* @__PURE__ */ jsxs("div", { className: "space-y-4 py-4", children: [
333
+ /* @__PURE__ */ jsxs("div", { className: "grid grid-cols-2 gap-4", children: [
334
+ /* @__PURE__ */ jsxs("div", { children: [
335
+ /* @__PURE__ */ jsx("p", { className: "text-sm font-medium text-foreground", children: "Status" }),
336
+ /* @__PURE__ */ jsx(Badge, { variant: "default", className: "mt-1", children: "Active" })
337
+ ] }),
338
+ /* @__PURE__ */ jsxs("div", { children: [
339
+ /* @__PURE__ */ jsx("p", { className: "text-sm font-medium text-foreground", children: "Version" }),
340
+ /* @__PURE__ */ jsx("p", { className: "text-sm text-muted-foreground mt-1", children: "1.0.0" })
341
+ ] }),
342
+ /* @__PURE__ */ jsxs("div", { children: [
343
+ /* @__PURE__ */ jsx("p", { className: "text-sm font-medium text-foreground", children: "Environment" }),
344
+ /* @__PURE__ */ jsx("p", { className: "text-sm text-muted-foreground mt-1", children: "Production" })
345
+ ] }),
346
+ /* @__PURE__ */ jsxs("div", { children: [
347
+ /* @__PURE__ */ jsx("p", { className: "text-sm font-medium text-foreground", children: "Region" }),
348
+ /* @__PURE__ */ jsx("p", { className: "text-sm text-muted-foreground mt-1", children: "US-East" })
349
+ ] })
350
+ ] }),
351
+ /* @__PURE__ */ jsx(Separator, {}),
352
+ /* @__PURE__ */ jsxs("div", { children: [
353
+ /* @__PURE__ */ jsx("p", { className: "text-sm font-medium text-foreground mb-2", children: "Description" }),
354
+ /* @__PURE__ */ jsx("p", { className: "text-sm text-muted-foreground", children: "This is an example of an information dialog that displays system details. It can contain various types of content including badges, separators, and structured data." })
355
+ ] })
356
+ ] }),
357
+ /* @__PURE__ */ jsx(DialogFooter, { children: /* @__PURE__ */ jsx(Button, { children: "Close" }) })
358
+ ] })
359
+ ] })
360
+ ] })
361
+ ] })
362
+ }
363
+ ),
364
+ /* @__PURE__ */ jsx(
365
+ PlaygroundSection,
366
+ {
367
+ title: "Form Inputs",
368
+ description: "shadcn/ui Input, Textarea, and Checkbox components.",
369
+ variant: "card",
370
+ children: /* @__PURE__ */ jsxs("div", { className: "space-y-6", children: [
371
+ /* @__PURE__ */ jsxs("div", { children: [
372
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "Input" }),
373
+ /* @__PURE__ */ jsxs("div", { className: "space-y-4 max-w-md", children: [
374
+ /* @__PURE__ */ jsxs("div", { children: [
375
+ /* @__PURE__ */ jsx(Label, { htmlFor: "input-default", children: "Default Input" }),
376
+ /* @__PURE__ */ jsx(
377
+ Input,
378
+ {
379
+ id: "input-default",
380
+ type: "text",
381
+ placeholder: "Enter text..."
382
+ }
383
+ )
384
+ ] }),
385
+ /* @__PURE__ */ jsxs("div", { children: [
386
+ /* @__PURE__ */ jsx(Label, { htmlFor: "input-email", children: "Email Input" }),
387
+ /* @__PURE__ */ jsx(
388
+ Input,
389
+ {
390
+ id: "input-email",
391
+ type: "email",
392
+ placeholder: "email@example.com"
393
+ }
394
+ )
395
+ ] }),
396
+ /* @__PURE__ */ jsxs("div", { children: [
397
+ /* @__PURE__ */ jsx(Label, { htmlFor: "input-password", children: "Password Input" }),
398
+ /* @__PURE__ */ jsx(
399
+ Input,
400
+ {
401
+ id: "input-password",
402
+ type: "password",
403
+ placeholder: "Enter password..."
404
+ }
405
+ )
406
+ ] }),
407
+ /* @__PURE__ */ jsxs("div", { children: [
408
+ /* @__PURE__ */ jsx(Label, { htmlFor: "input-disabled", children: "Disabled Input" }),
409
+ /* @__PURE__ */ jsx(
410
+ Input,
411
+ {
412
+ id: "input-disabled",
413
+ type: "text",
414
+ placeholder: "Disabled...",
415
+ disabled: true
416
+ }
417
+ )
418
+ ] }),
419
+ /* @__PURE__ */ jsxs("div", { children: [
420
+ /* @__PURE__ */ jsx(Label, { htmlFor: "input-readonly", children: "Read-only Input" }),
421
+ /* @__PURE__ */ jsx(
422
+ Input,
423
+ {
424
+ id: "input-readonly",
425
+ type: "text",
426
+ value: "Read-only value",
427
+ readOnly: true
428
+ }
429
+ )
430
+ ] })
431
+ ] })
432
+ ] }),
433
+ /* @__PURE__ */ jsx(Separator, {}),
434
+ /* @__PURE__ */ jsxs("div", { children: [
435
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "Textarea" }),
436
+ /* @__PURE__ */ jsxs("div", { className: "space-y-4 max-w-md", children: [
437
+ /* @__PURE__ */ jsxs("div", { children: [
438
+ /* @__PURE__ */ jsx(Label, { htmlFor: "textarea-default", children: "Default Textarea" }),
439
+ /* @__PURE__ */ jsx(
440
+ Textarea,
441
+ {
442
+ id: "textarea-default",
443
+ placeholder: "Enter multi-line text..."
444
+ }
445
+ )
446
+ ] }),
447
+ /* @__PURE__ */ jsxs("div", { children: [
448
+ /* @__PURE__ */ jsx(Label, { htmlFor: "textarea-rows", children: "Textarea with Custom Rows" }),
449
+ /* @__PURE__ */ jsx(
450
+ Textarea,
451
+ {
452
+ id: "textarea-rows",
453
+ placeholder: "This has 5 rows...",
454
+ rows: 5
455
+ }
456
+ )
457
+ ] }),
458
+ /* @__PURE__ */ jsxs("div", { children: [
459
+ /* @__PURE__ */ jsx(Label, { htmlFor: "textarea-disabled", children: "Disabled Textarea" }),
460
+ /* @__PURE__ */ jsx(
461
+ Textarea,
462
+ {
463
+ id: "textarea-disabled",
464
+ placeholder: "Disabled...",
465
+ disabled: true
466
+ }
467
+ )
468
+ ] }),
469
+ /* @__PURE__ */ jsxs("div", { children: [
470
+ /* @__PURE__ */ jsx(Label, { htmlFor: "textarea-value", children: "Textarea with Value" }),
471
+ /* @__PURE__ */ jsx(
472
+ Textarea,
473
+ {
474
+ id: "textarea-value",
475
+ value: "This is some pre-filled text in the textarea.",
476
+ readOnly: true
477
+ }
478
+ )
479
+ ] })
480
+ ] })
481
+ ] }),
482
+ /* @__PURE__ */ jsx(Separator, {}),
483
+ /* @__PURE__ */ jsxs("div", { children: [
484
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "Checkbox" }),
485
+ /* @__PURE__ */ jsxs("div", { className: "space-y-4", children: [
486
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center space-x-2", children: [
487
+ /* @__PURE__ */ jsx(Checkbox, { id: "checkbox-default" }),
488
+ /* @__PURE__ */ jsx(Label, { htmlFor: "checkbox-default", children: "Default Checkbox" })
489
+ ] }),
490
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center space-x-2", children: [
491
+ /* @__PURE__ */ jsx(Checkbox, { id: "checkbox-checked", defaultChecked: true }),
492
+ /* @__PURE__ */ jsx(Label, { htmlFor: "checkbox-checked", children: "Checked by Default" })
493
+ ] }),
494
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center space-x-2", children: [
495
+ /* @__PURE__ */ jsx(Checkbox, { id: "checkbox-disabled", disabled: true }),
496
+ /* @__PURE__ */ jsx(Label, { htmlFor: "checkbox-disabled", children: "Disabled Checkbox" })
497
+ ] }),
498
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center space-x-2", children: [
499
+ /* @__PURE__ */ jsx(Checkbox, { id: "checkbox-disabled-checked", disabled: true, checked: true }),
500
+ /* @__PURE__ */ jsx(Label, { htmlFor: "checkbox-disabled-checked", children: "Disabled & Checked" })
501
+ ] }),
502
+ /* @__PURE__ */ jsx(Separator, { className: "my-4" }),
503
+ /* @__PURE__ */ jsxs("div", { className: "space-y-3", children: [
504
+ /* @__PURE__ */ jsx("p", { className: "text-sm font-medium", children: "Multiple Checkboxes Example:" }),
505
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center space-x-2", children: [
506
+ /* @__PURE__ */ jsx(Checkbox, { id: "terms" }),
507
+ /* @__PURE__ */ jsx(Label, { htmlFor: "terms", children: "Accept terms and conditions" })
508
+ ] }),
509
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center space-x-2", children: [
510
+ /* @__PURE__ */ jsx(Checkbox, { id: "marketing" }),
511
+ /* @__PURE__ */ jsx(Label, { htmlFor: "marketing", children: "Send me marketing emails" })
512
+ ] }),
513
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center space-x-2", children: [
514
+ /* @__PURE__ */ jsx(Checkbox, { id: "newsletter", defaultChecked: true }),
515
+ /* @__PURE__ */ jsx(Label, { htmlFor: "newsletter", children: "Subscribe to newsletter" })
516
+ ] })
517
+ ] })
518
+ ] })
519
+ ] })
520
+ ] })
521
+ }
522
+ ),
523
+ /* @__PURE__ */ jsx(
524
+ PlaygroundSection,
525
+ {
526
+ title: "Label",
527
+ description: "Label component for form fields with proper accessibility.",
528
+ variant: "card",
529
+ children: /* @__PURE__ */ jsxs("div", { className: "space-y-6", children: [
530
+ /* @__PURE__ */ jsxs("div", { children: [
531
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "Basic Usage" }),
532
+ /* @__PURE__ */ jsxs("div", { className: "space-y-4", children: [
533
+ /* @__PURE__ */ jsxs("div", { className: "space-y-2", children: [
534
+ /* @__PURE__ */ jsx(Label, { htmlFor: "email", children: "Email Address" }),
535
+ /* @__PURE__ */ jsx(
536
+ Input,
537
+ {
538
+ id: "email",
539
+ type: "email",
540
+ placeholder: "Enter your email"
541
+ }
542
+ )
543
+ ] }),
544
+ /* @__PURE__ */ jsxs("div", { className: "space-y-2", children: [
545
+ /* @__PURE__ */ jsx(Label, { htmlFor: "username", children: "Username" }),
546
+ /* @__PURE__ */ jsx(Input, { id: "username", placeholder: "Choose a username" })
547
+ ] }),
548
+ /* @__PURE__ */ jsxs("div", { className: "space-y-2", children: [
549
+ /* @__PURE__ */ jsx(Label, { htmlFor: "bio", children: "Bio" }),
550
+ /* @__PURE__ */ jsx(Textarea, { id: "bio", placeholder: "Tell us about yourself" })
551
+ ] })
552
+ ] })
553
+ ] }),
554
+ /* @__PURE__ */ jsx(Separator, {}),
555
+ /* @__PURE__ */ jsxs("div", { children: [
556
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "With Checkbox" }),
557
+ /* @__PURE__ */ jsxs("div", { className: "space-y-3", children: [
558
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center space-x-2", children: [
559
+ /* @__PURE__ */ jsx(Checkbox, { id: "terms-label" }),
560
+ /* @__PURE__ */ jsx(Label, { htmlFor: "terms-label", children: "Accept terms and conditions" })
561
+ ] }),
562
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center space-x-2", children: [
563
+ /* @__PURE__ */ jsx(Checkbox, { id: "newsletter-label" }),
564
+ /* @__PURE__ */ jsx(Label, { htmlFor: "newsletter-label", children: "Subscribe to newsletter" })
565
+ ] })
566
+ ] })
567
+ ] }),
568
+ /* @__PURE__ */ jsx(Separator, {}),
569
+ /* @__PURE__ */ jsxs("div", { children: [
570
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "Disabled State" }),
571
+ /* @__PURE__ */ jsxs("div", { className: "space-y-2", children: [
572
+ /* @__PURE__ */ jsx(Label, { htmlFor: "disabled-input", className: "opacity-50", children: "Disabled Field" }),
573
+ /* @__PURE__ */ jsx(
574
+ Input,
575
+ {
576
+ id: "disabled-input",
577
+ disabled: true,
578
+ placeholder: "This field is disabled"
579
+ }
580
+ )
581
+ ] })
582
+ ] })
583
+ ] })
584
+ }
585
+ ),
586
+ /* @__PURE__ */ jsx(
587
+ PlaygroundSection,
588
+ {
589
+ title: "Avatar",
590
+ description: "Avatar component for displaying user profile images with fallback support.",
591
+ variant: "card",
592
+ children: /* @__PURE__ */ jsxs("div", { className: "space-y-6", children: [
593
+ /* @__PURE__ */ jsxs("div", { children: [
594
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "Basic Avatars" }),
595
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-4", children: [
596
+ /* @__PURE__ */ jsxs(Avatar, { children: [
597
+ /* @__PURE__ */ jsx(
598
+ AvatarImage,
599
+ {
600
+ src: "https://github.com/shadcn.png",
601
+ alt: "@shadcn"
602
+ }
603
+ ),
604
+ /* @__PURE__ */ jsx(AvatarFallback, { children: "CN" })
605
+ ] }),
606
+ /* @__PURE__ */ jsxs(Avatar, { children: [
607
+ /* @__PURE__ */ jsx(
608
+ AvatarImage,
609
+ {
610
+ src: "https://github.com/vercel.png",
611
+ alt: "@vercel"
612
+ }
613
+ ),
614
+ /* @__PURE__ */ jsx(AvatarFallback, { children: "VC" })
615
+ ] }),
616
+ /* @__PURE__ */ jsxs(Avatar, { children: [
617
+ /* @__PURE__ */ jsx(
618
+ AvatarImage,
619
+ {
620
+ src: "https://github.com/react.png",
621
+ alt: "@react"
622
+ }
623
+ ),
624
+ /* @__PURE__ */ jsx(AvatarFallback, { children: "RC" })
625
+ ] })
626
+ ] })
627
+ ] }),
628
+ /* @__PURE__ */ jsx(Separator, {}),
629
+ /* @__PURE__ */ jsxs("div", { children: [
630
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "Fallback Only (No Image)" }),
631
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-4", children: [
632
+ /* @__PURE__ */ jsx(Avatar, { children: /* @__PURE__ */ jsx(AvatarFallback, { children: "JD" }) }),
633
+ /* @__PURE__ */ jsx(Avatar, { children: /* @__PURE__ */ jsx(AvatarFallback, { children: "AB" }) }),
634
+ /* @__PURE__ */ jsx(Avatar, { children: /* @__PURE__ */ jsx(AvatarFallback, { children: "XY" }) }),
635
+ /* @__PURE__ */ jsx(Avatar, { children: /* @__PURE__ */ jsx(AvatarFallback, { className: "bg-primary text-primary-foreground", children: "DB" }) }),
636
+ /* @__PURE__ */ jsx(Avatar, { children: /* @__PURE__ */ jsx(AvatarFallback, { className: "bg-secondary text-secondary-foreground", children: "GH" }) })
637
+ ] })
638
+ ] }),
639
+ /* @__PURE__ */ jsx(Separator, {}),
640
+ /* @__PURE__ */ jsxs("div", { children: [
641
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "With User Information" }),
642
+ /* @__PURE__ */ jsxs("div", { className: "space-y-4", children: [
643
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
644
+ /* @__PURE__ */ jsxs(Avatar, { children: [
645
+ /* @__PURE__ */ jsx(
646
+ AvatarImage,
647
+ {
648
+ src: "https://github.com/shadcn.png",
649
+ alt: "@shadcn"
650
+ }
651
+ ),
652
+ /* @__PURE__ */ jsx(AvatarFallback, { children: "CN" })
653
+ ] }),
654
+ /* @__PURE__ */ jsxs("div", { children: [
655
+ /* @__PURE__ */ jsx("p", { className: "text-sm font-medium text-foreground", children: "John Doe" }),
656
+ /* @__PURE__ */ jsx("p", { className: "text-xs text-faint-foreground", children: "john.doe@example.com" })
657
+ ] })
658
+ ] }),
659
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
660
+ /* @__PURE__ */ jsx(Avatar, { children: /* @__PURE__ */ jsx(AvatarFallback, { className: "bg-primary text-primary-foreground", children: "JD" }) }),
661
+ /* @__PURE__ */ jsxs("div", { children: [
662
+ /* @__PURE__ */ jsx("p", { className: "text-sm font-medium text-foreground", children: "Jane Smith" }),
663
+ /* @__PURE__ */ jsx("p", { className: "text-xs text-faint-foreground", children: "jane.smith@example.com" })
664
+ ] })
665
+ ] }),
666
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
667
+ /* @__PURE__ */ jsx(Avatar, { children: /* @__PURE__ */ jsx(AvatarFallback, { className: "bg-destructive text-destructive-foreground", children: "AS" }) }),
668
+ /* @__PURE__ */ jsxs("div", { children: [
669
+ /* @__PURE__ */ jsx("p", { className: "text-sm font-medium text-foreground", children: "Alex Johnson" }),
670
+ /* @__PURE__ */ jsx("p", { className: "text-xs text-faint-foreground", children: "alex.j@example.com" })
671
+ ] })
672
+ ] })
673
+ ] })
674
+ ] }),
675
+ /* @__PURE__ */ jsx(Separator, {}),
676
+ /* @__PURE__ */ jsxs("div", { children: [
677
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "Custom Sizes" }),
678
+ /* @__PURE__ */ jsxs("div", { className: "flex items-end gap-4", children: [
679
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center gap-2", children: [
680
+ /* @__PURE__ */ jsx(Avatar, { className: "h-8 w-8", children: /* @__PURE__ */ jsx(AvatarFallback, { className: "text-xs", children: "SM" }) }),
681
+ /* @__PURE__ */ jsx("span", { className: "text-xs text-muted-foreground", children: "Small" })
682
+ ] }),
683
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center gap-2", children: [
684
+ /* @__PURE__ */ jsx(Avatar, { children: /* @__PURE__ */ jsx(AvatarFallback, { children: "MD" }) }),
685
+ /* @__PURE__ */ jsx("span", { className: "text-xs text-muted-foreground", children: "Default" })
686
+ ] }),
687
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center gap-2", children: [
688
+ /* @__PURE__ */ jsx(Avatar, { className: "h-16 w-16", children: /* @__PURE__ */ jsx(AvatarFallback, { className: "text-lg", children: "LG" }) }),
689
+ /* @__PURE__ */ jsx("span", { className: "text-xs text-muted-foreground", children: "Large" })
690
+ ] }),
691
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center gap-2", children: [
692
+ /* @__PURE__ */ jsx(Avatar, { className: "h-20 w-20", children: /* @__PURE__ */ jsx(AvatarFallback, { className: "text-xl", children: "XL" }) }),
693
+ /* @__PURE__ */ jsx("span", { className: "text-xs text-muted-foreground", children: "Extra Large" })
694
+ ] })
695
+ ] })
696
+ ] })
697
+ ] })
698
+ }
699
+ ),
700
+ /* @__PURE__ */ jsx(
701
+ PlaygroundSection,
702
+ {
703
+ title: "Notifications",
704
+ description: "Toast notifications using Sonner. Test all variants and behaviors.",
705
+ variant: "card",
706
+ children: /* @__PURE__ */ jsxs("div", { className: "flex flex-wrap gap-3", children: [
707
+ /* @__PURE__ */ jsx(
708
+ Button,
709
+ {
710
+ variant: "outline",
711
+ size: "sm",
712
+ onClick: () => toast.success("Success! Operation completed."),
713
+ children: "Success"
714
+ }
715
+ ),
716
+ /* @__PURE__ */ jsx(
717
+ Button,
718
+ {
719
+ variant: "outline",
720
+ size: "sm",
721
+ onClick: () => toast.error("Error! Something went wrong."),
722
+ children: "Error"
723
+ }
724
+ ),
725
+ /* @__PURE__ */ jsx(
726
+ Button,
727
+ {
728
+ variant: "outline",
729
+ size: "sm",
730
+ onClick: () => toast.warning("Warning! Please be careful."),
731
+ children: "Warning"
732
+ }
733
+ ),
734
+ /* @__PURE__ */ jsx(
735
+ Button,
736
+ {
737
+ variant: "outline",
738
+ size: "sm",
739
+ onClick: () => toast.info("Info: Here is some information."),
740
+ children: "Info"
741
+ }
742
+ ),
743
+ /* @__PURE__ */ jsx(
744
+ Button,
745
+ {
746
+ variant: "outline",
747
+ size: "sm",
748
+ onClick: () => {
749
+ toast.success("First notification");
750
+ setTimeout(() => toast.info("Second notification"), 500);
751
+ setTimeout(() => toast.warning("Third notification"), 1e3);
752
+ },
753
+ children: "Multiple"
754
+ }
755
+ ),
756
+ /* @__PURE__ */ jsx(
757
+ Button,
758
+ {
759
+ variant: "outline",
760
+ size: "sm",
761
+ onClick: () => toast("Custom message", {
762
+ description: "This is a custom notification with description",
763
+ duration: 5e3
764
+ }),
765
+ children: "Custom"
766
+ }
767
+ )
768
+ ] })
769
+ }
770
+ ),
771
+ /* @__PURE__ */ jsx(
772
+ PlaygroundSection,
773
+ {
774
+ title: "Spinner Component",
775
+ description: "Loading spinner with different sizes.",
776
+ variant: "card",
777
+ children: /* @__PURE__ */ jsxs("div", { className: "space-y-4", children: [
778
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
779
+ /* @__PURE__ */ jsx("span", { className: "text-sm font-medium text-muted-foreground", children: "Size:" }),
780
+ /* @__PURE__ */ jsx(
781
+ Button,
782
+ {
783
+ variant: spinnerSize === "sm" ? "default" : "outline",
784
+ size: "sm",
785
+ onClick: () => setSpinnerSize("sm"),
786
+ children: "Small"
787
+ }
788
+ ),
789
+ /* @__PURE__ */ jsx(
790
+ Button,
791
+ {
792
+ variant: spinnerSize === "md" ? "default" : "outline",
793
+ size: "sm",
794
+ onClick: () => setSpinnerSize("md"),
795
+ children: "Medium"
796
+ }
797
+ ),
798
+ /* @__PURE__ */ jsx(
799
+ Button,
800
+ {
801
+ variant: spinnerSize === "lg" ? "default" : "outline",
802
+ size: "sm",
803
+ onClick: () => setSpinnerSize("lg"),
804
+ children: "Large"
805
+ }
806
+ )
807
+ ] }),
808
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-8 p-6 bg-muted/50 rounded-md", children: [
809
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center gap-2", children: [
810
+ /* @__PURE__ */ jsx(Spinner, { size: "sm" }),
811
+ /* @__PURE__ */ jsx("span", { className: "text-xs text-muted-foreground", children: "Small (16px)" })
812
+ ] }),
813
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center gap-2", children: [
814
+ /* @__PURE__ */ jsx(Spinner, { size: "md" }),
815
+ /* @__PURE__ */ jsx("span", { className: "text-xs text-muted-foreground", children: "Medium (24px)" })
816
+ ] }),
817
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center gap-2", children: [
818
+ /* @__PURE__ */ jsx(Spinner, { size: "lg" }),
819
+ /* @__PURE__ */ jsx("span", { className: "text-xs text-muted-foreground", children: "Large (32px)" })
820
+ ] }),
821
+ /* @__PURE__ */ jsxs("div", { className: "flex flex-col items-center gap-2", children: [
822
+ /* @__PURE__ */ jsx(Spinner, { size: spinnerSize }),
823
+ /* @__PURE__ */ jsxs("span", { className: "text-xs text-muted-foreground", children: [
824
+ "Selected: ",
825
+ spinnerSize
826
+ ] })
827
+ ] })
828
+ ] })
829
+ ] })
830
+ }
831
+ ),
832
+ /* @__PURE__ */ jsxs(
833
+ PlaygroundSection,
834
+ {
835
+ title: "Custom Hooks",
836
+ description: "Test custom hooks from @petrarca/sonnet-core.",
837
+ variant: "card",
838
+ children: [
839
+ /* @__PURE__ */ jsxs("div", { className: "mb-6", children: [
840
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "useClipboard Hook" }),
841
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
842
+ /* @__PURE__ */ jsx(
843
+ Button,
844
+ {
845
+ variant: "outline",
846
+ size: "sm",
847
+ onClick: () => clipboard.copy("Hello from clipboard!"),
848
+ children: clipboard.copied ? "\u2713 Copied!" : "Copy Text"
849
+ }
850
+ ),
851
+ /* @__PURE__ */ jsxs("span", { className: "text-sm text-muted-foreground", children: [
852
+ "State: ",
853
+ clipboard.copied ? "Copied" : "Ready",
854
+ clipboard.error && ` (Error: ${clipboard.error.message})`
855
+ ] })
856
+ ] })
857
+ ] }),
858
+ /* @__PURE__ */ jsxs("div", { children: [
859
+ /* @__PURE__ */ jsx("h4", { className: "mb-3", children: "useDisclosure Hook" }),
860
+ /* @__PURE__ */ jsxs("div", { className: "space-y-3", children: [
861
+ /* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3", children: [
862
+ /* @__PURE__ */ jsx(
863
+ Button,
864
+ {
865
+ variant: "outline",
866
+ size: "sm",
867
+ onClick: disclosureHandlers.open,
868
+ children: "Open"
869
+ }
870
+ ),
871
+ /* @__PURE__ */ jsx(
872
+ Button,
873
+ {
874
+ variant: "outline",
875
+ size: "sm",
876
+ onClick: disclosureHandlers.close,
877
+ children: "Close"
878
+ }
879
+ ),
880
+ /* @__PURE__ */ jsx(
881
+ Button,
882
+ {
883
+ variant: "outline",
884
+ size: "sm",
885
+ onClick: disclosureHandlers.toggle,
886
+ children: "Toggle"
887
+ }
888
+ ),
889
+ /* @__PURE__ */ jsxs("span", { className: "text-sm text-muted-foreground", children: [
890
+ "State: ",
891
+ disclosureOpened ? "Open" : "Closed"
892
+ ] })
893
+ ] }),
894
+ disclosureOpened && /* @__PURE__ */ jsx("div", { className: "p-4 bg-muted border rounded-md", children: /* @__PURE__ */ jsx("p", { className: "text-sm", children: "This content is visible when disclosure is open!" }) })
895
+ ] })
896
+ ] })
897
+ ]
898
+ }
899
+ )
900
+ ] })
901
+ ] });
902
+ }
903
+
904
+ export {
905
+ PlayCoreComponents
906
+ };
907
+ //# sourceMappingURL=chunk-QCK2M4KD.js.map