@foundrykit/components 2.1.4 → 2.2.1

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 (107) hide show
  1. package/dist/chunk-4WYKNDYY.js +91 -0
  2. package/dist/chunk-4WYKNDYY.js.map +1 -0
  3. package/dist/chunk-5CXNMTIN.js +84 -0
  4. package/dist/chunk-5CXNMTIN.js.map +1 -0
  5. package/dist/chunk-B5ZTF5MZ.js +203 -0
  6. package/dist/chunk-B5ZTF5MZ.js.map +1 -0
  7. package/dist/chunk-EDNWBEKV.js +51 -0
  8. package/dist/chunk-EDNWBEKV.js.map +1 -0
  9. package/dist/chunk-ID7BFTID.js +248 -0
  10. package/dist/chunk-ID7BFTID.js.map +1 -0
  11. package/dist/chunk-IYBHXVCH.js +181 -0
  12. package/dist/chunk-IYBHXVCH.js.map +1 -0
  13. package/dist/chunk-KQZEF7PS.js +71 -0
  14. package/dist/chunk-KQZEF7PS.js.map +1 -0
  15. package/dist/chunk-P3GSYR7O.js +889 -0
  16. package/dist/chunk-P3GSYR7O.js.map +1 -0
  17. package/dist/chunk-PKSRYDN4.js +168 -0
  18. package/dist/chunk-PKSRYDN4.js.map +1 -0
  19. package/dist/chunk-SFM7ZMG2.js +104 -0
  20. package/dist/chunk-SFM7ZMG2.js.map +1 -0
  21. package/dist/chunk-TLQQZJUR.js +126 -0
  22. package/dist/chunk-TLQQZJUR.js.map +1 -0
  23. package/dist/chunk-UE7CDYEN.js +59 -0
  24. package/dist/chunk-UE7CDYEN.js.map +1 -0
  25. package/dist/chunk-UG7YS3D5.js +198 -0
  26. package/dist/chunk-UG7YS3D5.js.map +1 -0
  27. package/dist/components/advanced-search-bar/index.d.ts +308 -0
  28. package/dist/components/advanced-search-bar/index.js +34 -0
  29. package/dist/components/advanced-search-bar/index.js.map +1 -0
  30. package/dist/components/calendar/index.d.ts +20 -0
  31. package/dist/components/calendar/index.js +11 -0
  32. package/dist/components/calendar/index.js.map +1 -0
  33. package/dist/components/carousel/index.d.ts +40 -0
  34. package/dist/components/carousel/index.js +17 -0
  35. package/dist/components/carousel/index.js.map +1 -0
  36. package/dist/components/chart/index.d.ts +59 -0
  37. package/dist/components/chart/index.js +21 -0
  38. package/dist/components/chart/index.js.map +1 -0
  39. package/dist/components/combobox/index.d.ts +33 -0
  40. package/dist/components/combobox/index.js +10 -0
  41. package/dist/components/combobox/index.js.map +1 -0
  42. package/dist/components/command/index.d.ts +33 -0
  43. package/dist/components/command/index.js +25 -0
  44. package/dist/components/command/index.js.map +1 -0
  45. package/dist/components/data-table/index.d.ts +17 -0
  46. package/dist/components/data-table/index.js +9 -0
  47. package/dist/components/data-table/index.js.map +1 -0
  48. package/dist/components/date-picker/index.d.ts +17 -0
  49. package/dist/components/date-picker/index.js +9 -0
  50. package/dist/components/date-picker/index.js.map +1 -0
  51. package/dist/components/form/index.d.ts +37 -0
  52. package/dist/components/form/index.js +23 -0
  53. package/dist/components/form/index.js.map +1 -0
  54. package/dist/components/input-otp/index.d.ts +30 -0
  55. package/dist/components/input-otp/index.js +15 -0
  56. package/dist/components/input-otp/index.js.map +1 -0
  57. package/dist/components/pagination/index.d.ts +26 -0
  58. package/dist/components/pagination/index.js +20 -0
  59. package/dist/components/pagination/index.js.map +1 -0
  60. package/dist/components/search-bar/index.d.ts +17 -0
  61. package/dist/components/search-bar/index.js +9 -0
  62. package/dist/components/search-bar/index.js.map +1 -0
  63. package/dist/components/sidebar/index.d.ts +70 -0
  64. package/dist/components/sidebar/index.js +652 -0
  65. package/dist/components/sidebar/index.js.map +1 -0
  66. package/dist/components/theme-toggle/index.d.ts +20 -0
  67. package/dist/components/theme-toggle/index.js +9 -0
  68. package/dist/components/theme-toggle/index.js.map +1 -0
  69. package/dist/index.d.ts +27 -582
  70. package/dist/index.js +74 -2280
  71. package/dist/index.js.map +1 -1
  72. package/package.json +15 -8
  73. package/.turbo/turbo-build.log +0 -17
  74. package/.turbo/turbo-type-check.log +0 -4
  75. package/CHANGELOG.md +0 -351
  76. package/src/components/advanced-search-bar/config.ts +0 -223
  77. package/src/components/advanced-search-bar/index.tsx +0 -1415
  78. package/src/components/calendar/config.ts +0 -51
  79. package/src/components/calendar/index.tsx +0 -225
  80. package/src/components/carousel/config.ts +0 -28
  81. package/src/components/carousel/index.tsx +0 -258
  82. package/src/components/chart/config.ts +0 -28
  83. package/src/components/chart/index.tsx +0 -365
  84. package/src/components/combobox/config.ts +0 -28
  85. package/src/components/combobox/index.tsx +0 -101
  86. package/src/components/command/config.ts +0 -804
  87. package/src/components/command/index.tsx +0 -195
  88. package/src/components/data-table/config.ts +0 -28
  89. package/src/components/data-table/index.tsx +0 -124
  90. package/src/components/date-picker/config.ts +0 -55
  91. package/src/components/date-picker/index.tsx +0 -207
  92. package/src/components/form/config.ts +0 -21
  93. package/src/components/form/index.tsx +0 -150
  94. package/src/components/input-otp/config.ts +0 -28
  95. package/src/components/input-otp/index.tsx +0 -92
  96. package/src/components/pagination/config.ts +0 -367
  97. package/src/components/pagination/index.tsx +0 -135
  98. package/src/components/search-bar/config.ts +0 -58
  99. package/src/components/search-bar/index.tsx +0 -70
  100. package/src/components/sidebar/config.ts +0 -29
  101. package/src/components/sidebar/index.tsx +0 -723
  102. package/src/components/theme-toggle/config.ts +0 -58
  103. package/src/components/theme-toggle/index.tsx +0 -35
  104. package/src/index.ts +0 -82
  105. package/tsconfig.json +0 -12
  106. package/tsconfig.lint.json +0 -8
  107. package/tsup.config.ts +0 -11
@@ -1,804 +0,0 @@
1
- import type { ComponentConfig } from '@foundrykit/types';
2
-
3
- export const commandConfig: ComponentConfig = {
4
- name: 'Command',
5
- description:
6
- 'A command palette component for searching and executing commands',
7
- category: 'components',
8
- tags: ['search', 'palette', 'commands', 'interactive', 'accessible'],
9
- preview: {
10
- type: 'static',
11
- html: '<div class="flex h-12 w-full items-center justify-center rounded-md bg-gray-200"><div class="flex h-9 w-64 items-center gap-2 rounded-md border border-gray-300 bg-white px-3 py-2 text-sm"><div class="h-4 w-4 opacity-50">🔍</div><span class="text-gray-500">Search commands...</span></div></div>',
12
- },
13
- additionalImports: {
14
- icons: {
15
- library: 'lucide-react',
16
- imports: [
17
- 'SearchIcon',
18
- 'CalendarIcon',
19
- 'SmileIcon',
20
- 'CalculatorIcon',
21
- 'FileIcon',
22
- 'FolderIcon',
23
- 'SaveIcon',
24
- 'SettingsIcon',
25
- 'FileTextIcon',
26
- 'FolderOpenIcon',
27
- 'FileSpreadsheetIcon',
28
- 'ZapIcon',
29
- 'RocketIcon',
30
- ],
31
- },
32
- },
33
- variants: [
34
- {
35
- name: 'Basic Command Palette',
36
- description: 'Simple command palette with search functionality',
37
- code: `<CommandDialog>
38
- <CommandInput placeholder="Type a command or search..." />
39
- <CommandList>
40
- <CommandEmpty>No results found.</CommandEmpty>
41
- <CommandGroup heading="Suggestions">
42
- <CommandItem>
43
- <CalendarIcon className="mr-2 h-4 w-4" />
44
- <span>Calendar</span>
45
- </CommandItem>
46
- <CommandItem>
47
- <SmileIcon className="mr-2 h-4 w-4" />
48
- <span>Search Emoji</span>
49
- </CommandItem>
50
- <CommandItem>
51
- <CalculatorIcon className="mr-2 h-4 w-4" />
52
- <span>Calculator</span>
53
- </CommandItem>
54
- </CommandGroup>
55
- </CommandList>
56
- </CommandDialog>`,
57
- preview: {
58
- type: 'component',
59
- component: 'div',
60
- props: {
61
- className: 'w-96 max-w-sm mx-auto',
62
- children: {
63
- type: 'Command',
64
- props: {
65
- className: 'rounded-lg border shadow-md',
66
- children: [
67
- {
68
- type: 'CommandInput',
69
- props: { placeholder: 'Type a command or search...' },
70
- },
71
- {
72
- type: 'CommandList',
73
- props: {
74
- children: [
75
- {
76
- type: 'CommandEmpty',
77
- props: { children: 'No results found.' },
78
- },
79
- {
80
- type: 'CommandGroup',
81
- props: {
82
- heading: 'Suggestions',
83
- children: [
84
- {
85
- type: 'CommandItem',
86
- props: {
87
- children: [
88
- {
89
- type: 'CalendarIcon',
90
- props: { className: 'mr-2 h-4 w-4' },
91
- },
92
- {
93
- type: 'span',
94
- props: { children: 'Calendar' },
95
- },
96
- ],
97
- },
98
- },
99
- {
100
- type: 'CommandItem',
101
- props: {
102
- children: [
103
- {
104
- type: 'SmileIcon',
105
- props: { className: 'mr-2 h-4 w-4' },
106
- },
107
- {
108
- type: 'span',
109
- props: { children: 'Search Emoji' },
110
- },
111
- ],
112
- },
113
- },
114
- {
115
- type: 'CommandItem',
116
- props: {
117
- children: [
118
- {
119
- type: 'CalculatorIcon',
120
- props: { className: 'mr-2 h-4 w-4' },
121
- },
122
- {
123
- type: 'span',
124
- props: { children: 'Calculator' },
125
- },
126
- ],
127
- },
128
- },
129
- ],
130
- },
131
- },
132
- ],
133
- },
134
- },
135
- ],
136
- },
137
- },
138
- },
139
- },
140
- },
141
- {
142
- name: 'With Shortcuts',
143
- description: 'Command palette with keyboard shortcuts',
144
- code: `<CommandDialog>
145
- <CommandInput placeholder="Type a command or search..." />
146
- <CommandList>
147
- <CommandEmpty>No results found.</CommandEmpty>
148
- <CommandGroup heading="Actions">
149
- <CommandItem>
150
- <FileIcon className="mr-2 h-4 w-4" />
151
- <span>New File</span>
152
- <CommandShortcut>⌘N</CommandShortcut>
153
- </CommandItem>
154
- <CommandItem>
155
- <FolderIcon className="mr-2 h-4 w-4" />
156
- <span>Open Folder</span>
157
- <CommandShortcut>⌘O</CommandShortcut>
158
- </CommandItem>
159
- <CommandItem>
160
- <SaveIcon className="mr-2 h-4 w-4" />
161
- <span>Save</span>
162
- <CommandShortcut>⌘S</CommandShortcut>
163
- </CommandItem>
164
- </CommandGroup>
165
- <CommandSeparator />
166
- <CommandGroup heading="Navigation">
167
- <CommandItem>
168
- <SearchIcon className="mr-2 h-4 w-4" />
169
- <span>Search</span>
170
- <CommandShortcut>⌘F</CommandShortcut>
171
- </CommandItem>
172
- <CommandItem>
173
- <SettingsIcon className="mr-2 h-4 w-4" />
174
- <span>Settings</span>
175
- <CommandShortcut>⌘,</CommandShortcut>
176
- </CommandItem>
177
- </CommandGroup>
178
- </CommandList>
179
- </CommandDialog>`,
180
- preview: {
181
- type: 'component',
182
- component: 'div',
183
- props: {
184
- className: 'w-96 max-w-sm mx-auto',
185
- children: {
186
- type: 'Command',
187
- props: {
188
- className: 'rounded-lg border shadow-md',
189
- children: [
190
- {
191
- type: 'CommandInput',
192
- props: { placeholder: 'Type a command or search...' },
193
- },
194
- {
195
- type: 'CommandList',
196
- props: {
197
- children: [
198
- {
199
- type: 'CommandEmpty',
200
- props: { children: 'No results found.' },
201
- },
202
- {
203
- type: 'CommandGroup',
204
- props: {
205
- heading: 'Actions',
206
- children: [
207
- {
208
- type: 'CommandItem',
209
- props: {
210
- children: [
211
- {
212
- type: 'FileIcon',
213
- props: { className: 'mr-2 h-4 w-4' },
214
- },
215
- {
216
- type: 'span',
217
- props: { children: 'New File' },
218
- },
219
- {
220
- type: 'CommandShortcut',
221
- props: { children: '⌘N' },
222
- },
223
- ],
224
- },
225
- },
226
- {
227
- type: 'CommandItem',
228
- props: {
229
- children: [
230
- {
231
- type: 'FolderIcon',
232
- props: { className: 'mr-2 h-4 w-4' },
233
- },
234
- {
235
- type: 'span',
236
- props: { children: 'Open Folder' },
237
- },
238
- {
239
- type: 'CommandShortcut',
240
- props: { children: '⌘O' },
241
- },
242
- ],
243
- },
244
- },
245
- {
246
- type: 'CommandItem',
247
- props: {
248
- children: [
249
- {
250
- type: 'SaveIcon',
251
- props: { className: 'mr-2 h-4 w-4' },
252
- },
253
- { type: 'span', props: { children: 'Save' } },
254
- {
255
- type: 'CommandShortcut',
256
- props: { children: '⌘S' },
257
- },
258
- ],
259
- },
260
- },
261
- ],
262
- },
263
- },
264
- { type: 'CommandSeparator', props: {} },
265
- {
266
- type: 'CommandGroup',
267
- props: {
268
- heading: 'Navigation',
269
- children: [
270
- {
271
- type: 'CommandItem',
272
- props: {
273
- children: [
274
- {
275
- type: 'SearchIcon',
276
- props: { className: 'mr-2 h-4 w-4' },
277
- },
278
- {
279
- type: 'span',
280
- props: { children: 'Search' },
281
- },
282
- {
283
- type: 'CommandShortcut',
284
- props: { children: '⌘F' },
285
- },
286
- ],
287
- },
288
- },
289
- {
290
- type: 'CommandItem',
291
- props: {
292
- children: [
293
- {
294
- type: 'SettingsIcon',
295
- props: { className: 'mr-2 h-4 w-4' },
296
- },
297
- {
298
- type: 'span',
299
- props: { children: 'Settings' },
300
- },
301
- {
302
- type: 'CommandShortcut',
303
- props: { children: '⌘,' },
304
- },
305
- ],
306
- },
307
- },
308
- ],
309
- },
310
- },
311
- ],
312
- },
313
- },
314
- ],
315
- },
316
- },
317
- },
318
- },
319
- },
320
- {
321
- name: 'Inline Command',
322
- description: 'Command component without dialog wrapper',
323
- code: `<div className="w-96">
324
- <Command>
325
- <CommandInput placeholder="Search..." />
326
- <CommandList>
327
- <CommandEmpty>No results found.</CommandEmpty>
328
- <CommandGroup heading="Fruits">
329
- <CommandItem>Apple</CommandItem>
330
- <CommandItem>Banana</CommandItem>
331
- <CommandItem>Cherry</CommandItem>
332
- <CommandItem>Dragon fruit</CommandItem>
333
- <CommandItem>Elderberry</CommandItem>
334
- </CommandGroup>
335
- <CommandSeparator />
336
- <CommandGroup heading="Vegetables">
337
- <CommandItem>Asparagus</CommandItem>
338
- <CommandItem>Broccoli</CommandItem>
339
- <CommandItem>Carrot</CommandItem>
340
- <CommandItem>Dill</CommandItem>
341
- <CommandItem>Eggplant</CommandItem>
342
- </CommandGroup>
343
- </CommandList>
344
- </Command>
345
- </div>`,
346
- preview: {
347
- type: 'component',
348
- component: 'div',
349
- props: {
350
- className: 'w-96',
351
- children: {
352
- type: 'Command',
353
- props: {
354
- children: [
355
- {
356
- type: 'CommandInput',
357
- props: { placeholder: 'Search...' },
358
- },
359
- {
360
- type: 'CommandList',
361
- props: {
362
- children: [
363
- {
364
- type: 'CommandEmpty',
365
- props: { children: 'No results found.' },
366
- },
367
- {
368
- type: 'CommandGroup',
369
- props: {
370
- heading: 'Fruits',
371
- children: [
372
- {
373
- type: 'CommandItem',
374
- props: { children: 'Apple' },
375
- },
376
- {
377
- type: 'CommandItem',
378
- props: { children: 'Banana' },
379
- },
380
- {
381
- type: 'CommandItem',
382
- props: { children: 'Cherry' },
383
- },
384
- {
385
- type: 'CommandItem',
386
- props: { children: 'Dragon fruit' },
387
- },
388
- {
389
- type: 'CommandItem',
390
- props: { children: 'Elderberry' },
391
- },
392
- ],
393
- },
394
- },
395
- { type: 'CommandSeparator', props: {} },
396
- {
397
- type: 'CommandGroup',
398
- props: {
399
- heading: 'Vegetables',
400
- children: [
401
- {
402
- type: 'CommandItem',
403
- props: { children: 'Asparagus' },
404
- },
405
- {
406
- type: 'CommandItem',
407
- props: { children: 'Broccoli' },
408
- },
409
- {
410
- type: 'CommandItem',
411
- props: { children: 'Carrot' },
412
- },
413
- {
414
- type: 'CommandItem',
415
- props: { children: 'Dill' },
416
- },
417
- {
418
- type: 'CommandItem',
419
- props: { children: 'Eggplant' },
420
- },
421
- ],
422
- },
423
- },
424
- ],
425
- },
426
- },
427
- ],
428
- },
429
- },
430
- },
431
- },
432
- },
433
- {
434
- name: 'With Icons and Descriptions',
435
- description: 'Command items with icons and detailed descriptions',
436
- code: `<CommandDialog>
437
- <CommandInput placeholder="Search for a command..." />
438
- <CommandList>
439
- <CommandEmpty>No results found.</CommandEmpty>
440
- <CommandGroup heading="Recent">
441
- <CommandItem>
442
- <FileTextIcon className="mr-2 h-4 w-4" />
443
- <div className="flex flex-col">
444
- <span>Create new document</span>
445
- <span className="text-xs text-muted-foreground">
446
- Start with a blank document
447
- </span>
448
- </div>
449
- </CommandItem>
450
- <CommandItem>
451
- <FolderOpenIcon className="mr-2 h-4 w-4" />
452
- <div className="flex flex-col">
453
- <span>Open recent</span>
454
- <span className="text-xs text-muted-foreground">
455
- Open a recently used file
456
- </span>
457
- </div>
458
- </CommandItem>
459
- </CommandGroup>
460
- <CommandSeparator />
461
- <CommandGroup heading="Templates">
462
- <CommandItem>
463
- <FileIcon className="mr-2 h-4 w-4" />
464
- <div className="flex flex-col">
465
- <span>Blog post</span>
466
- <span className="text-xs text-muted-foreground">
467
- Create a new blog post
468
- </span>
469
- </div>
470
- </CommandItem>
471
- <CommandItem>
472
- <FileSpreadsheetIcon className="mr-2 h-4 w-4" />
473
- <div className="flex flex-col">
474
- <span>Invoice</span>
475
- <span className="text-xs text-muted-foreground">
476
- Create a new invoice
477
- </span>
478
- </div>
479
- </CommandItem>
480
- </CommandGroup>
481
- </CommandList>
482
- </CommandDialog>`,
483
- preview: {
484
- type: 'component',
485
- component: 'div',
486
- props: {
487
- className: 'w-96 max-w-sm mx-auto',
488
- children: {
489
- type: 'Command',
490
- props: {
491
- className: 'rounded-lg border shadow-md',
492
- children: [
493
- {
494
- type: 'CommandInput',
495
- props: { placeholder: 'Search for a command...' },
496
- },
497
- {
498
- type: 'CommandList',
499
- props: {
500
- children: [
501
- {
502
- type: 'CommandEmpty',
503
- props: { children: 'No results found.' },
504
- },
505
- {
506
- type: 'CommandGroup',
507
- props: {
508
- heading: 'Recent',
509
- children: [
510
- {
511
- type: 'CommandItem',
512
- props: {
513
- children: [
514
- {
515
- type: 'FileTextIcon',
516
- props: { className: 'mr-2 h-4 w-4' },
517
- },
518
- {
519
- type: 'div',
520
- props: {
521
- className: 'flex flex-col',
522
- children: [
523
- {
524
- type: 'span',
525
- props: {
526
- children: 'Create new document',
527
- },
528
- },
529
- {
530
- type: 'span',
531
- props: {
532
- className:
533
- 'text-xs text-muted-foreground',
534
- children:
535
- 'Start with a blank document',
536
- },
537
- },
538
- ],
539
- },
540
- },
541
- ],
542
- },
543
- },
544
- {
545
- type: 'CommandItem',
546
- props: {
547
- children: [
548
- {
549
- type: 'FolderOpenIcon',
550
- props: { className: 'mr-2 h-4 w-4' },
551
- },
552
- {
553
- type: 'div',
554
- props: {
555
- className: 'flex flex-col',
556
- children: [
557
- {
558
- type: 'span',
559
- props: { children: 'Open recent' },
560
- },
561
- {
562
- type: 'span',
563
- props: {
564
- className:
565
- 'text-xs text-muted-foreground',
566
- children:
567
- 'Open a recently used file',
568
- },
569
- },
570
- ],
571
- },
572
- },
573
- ],
574
- },
575
- },
576
- ],
577
- },
578
- },
579
- { type: 'CommandSeparator', props: {} },
580
- {
581
- type: 'CommandGroup',
582
- props: {
583
- heading: 'Templates',
584
- children: [
585
- {
586
- type: 'CommandItem',
587
- props: {
588
- children: [
589
- {
590
- type: 'FileIcon',
591
- props: { className: 'mr-2 h-4 w-4' },
592
- },
593
- {
594
- type: 'div',
595
- props: {
596
- className: 'flex flex-col',
597
- children: [
598
- {
599
- type: 'span',
600
- props: { children: 'Blog post' },
601
- },
602
- {
603
- type: 'span',
604
- props: {
605
- className:
606
- 'text-xs text-muted-foreground',
607
- children: 'Create a new blog post',
608
- },
609
- },
610
- ],
611
- },
612
- },
613
- ],
614
- },
615
- },
616
- {
617
- type: 'CommandItem',
618
- props: {
619
- children: [
620
- {
621
- type: 'FileSpreadsheetIcon',
622
- props: { className: 'mr-2 h-4 w-4' },
623
- },
624
- {
625
- type: 'div',
626
- props: {
627
- className: 'flex flex-col',
628
- children: [
629
- {
630
- type: 'span',
631
- props: { children: 'Invoice' },
632
- },
633
- {
634
- type: 'span',
635
- props: {
636
- className:
637
- 'text-xs text-muted-foreground',
638
- children: 'Create a new invoice',
639
- },
640
- },
641
- ],
642
- },
643
- },
644
- ],
645
- },
646
- },
647
- ],
648
- },
649
- },
650
- ],
651
- },
652
- },
653
- ],
654
- },
655
- },
656
- },
657
- },
658
- },
659
- {
660
- name: 'Custom Styling',
661
- description: 'Command palette with custom styling and themes',
662
- code: `<CommandDialog className="max-w-2xl">
663
- <CommandInput
664
- placeholder="Search anything..."
665
- className="border-0 focus:ring-0"
666
- />
667
- <CommandList className="max-h-96">
668
- <CommandEmpty className="py-8">
669
- <SearchIcon className="mx-auto h-8 w-8 text-muted-foreground" />
670
- <p className="mt-2 text-sm text-muted-foreground">No results found</p>
671
- <p className="text-xs text-muted-foreground">
672
- Try searching for something else
673
- </p>
674
- </CommandEmpty>
675
- <CommandGroup heading="Quick Actions" className="[&_[cmdk-group-heading]]:text-primary">
676
- <CommandItem className="aria-selected:bg-primary aria-selected:text-primary-foreground">
677
- <ZapIcon className="mr-2 h-4 w-4" />
678
- <span>Quick Start</span>
679
- <CommandShortcut>⌘K</CommandShortcut>
680
- </CommandItem>
681
- <CommandItem className="aria-selected:bg-primary aria-selected:text-primary-foreground">
682
- <RocketIcon className="mr-2 h-4 w-4" />
683
- <span>Deploy</span>
684
- <CommandShortcut>⌘D</CommandShortcut>
685
- </CommandItem>
686
- </CommandGroup>
687
- </CommandList>
688
- </CommandDialog>`,
689
- preview: {
690
- type: 'component',
691
- component: 'div',
692
- props: {
693
- className: 'w-96 max-w-sm mx-auto',
694
- children: {
695
- type: 'Command',
696
- props: {
697
- className: 'rounded-lg border shadow-md',
698
- children: [
699
- {
700
- type: 'CommandInput',
701
- props: {
702
- placeholder: 'Search anything...',
703
- className: 'border-0 focus:ring-0',
704
- },
705
- },
706
- {
707
- type: 'CommandList',
708
- props: {
709
- className: 'max-h-96',
710
- children: [
711
- {
712
- type: 'CommandEmpty',
713
- props: {
714
- className: 'py-8',
715
- children: [
716
- {
717
- type: 'SearchIcon',
718
- props: {
719
- className:
720
- 'mx-auto h-8 w-8 text-muted-foreground',
721
- },
722
- },
723
- {
724
- type: 'p',
725
- props: {
726
- className: 'mt-2 text-sm text-muted-foreground',
727
- children: 'No results found',
728
- },
729
- },
730
- {
731
- type: 'p',
732
- props: {
733
- className: 'text-xs text-muted-foreground',
734
- children: 'Try searching for something else',
735
- },
736
- },
737
- ],
738
- },
739
- },
740
- {
741
- type: 'CommandGroup',
742
- props: {
743
- heading: 'Quick Actions',
744
- className: '[&_[cmdk-group-heading]]:text-primary',
745
- children: [
746
- {
747
- type: 'CommandItem',
748
- props: {
749
- className:
750
- 'aria-selected:bg-primary aria-selected:text-primary-foreground',
751
- children: [
752
- {
753
- type: 'ZapIcon',
754
- props: { className: 'mr-2 h-4 w-4' },
755
- },
756
- {
757
- type: 'span',
758
- props: { children: 'Quick Start' },
759
- },
760
- {
761
- type: 'CommandShortcut',
762
- props: { children: '⌘K' },
763
- },
764
- ],
765
- },
766
- },
767
- {
768
- type: 'CommandItem',
769
- props: {
770
- className:
771
- 'aria-selected:bg-primary aria-selected:text-primary-foreground',
772
- children: [
773
- {
774
- type: 'RocketIcon',
775
- props: { className: 'mr-2 h-4 w-4' },
776
- },
777
- {
778
- type: 'span',
779
- props: { children: 'Deploy' },
780
- },
781
- {
782
- type: 'CommandShortcut',
783
- props: { children: '⌘D' },
784
- },
785
- ],
786
- },
787
- },
788
- ],
789
- },
790
- },
791
- ],
792
- },
793
- },
794
- ],
795
- },
796
- },
797
- },
798
- },
799
- },
800
- ],
801
- dependencies: ['utils', 'dialog'],
802
- packageDependencies: ['cmdk'],
803
- files: ['components/command/index.tsx'],
804
- };