-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathregistry.json
More file actions
701 lines (701 loc) · 27 KB
/
Copy pathregistry.json
File metadata and controls
701 lines (701 loc) · 27 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
{
"$schema": "https://shadcn-svelte.com/schema/registry.json",
"name": "codeworks-ui",
"homepage": "https://ui.akcodeworks.com",
"aliases": {
"lib": "$lib",
"ui": "$lib/components/ui",
"components": "$lib/components",
"utils": "$lib/utils",
"hooks": "$lib/hooks"
},
"items": [
{
"name": "aura",
"type": "registry:ui",
"title": "Aura",
"description": "Wraps content in an animated luminous aura with color, material, size, and speed variants.",
"dependencies": [],
"registryDependencies": ["utils"],
"files": [
{ "path": "src/lib/components/ui/aura/aura.svelte", "type": "registry:ui" },
{ "path": "src/lib/components/ui/aura/index.ts", "type": "registry:ui" }
],
"meta": {
"docs": {
"usage": "Wrap a single child with Aura. The child remains directly inside the wrapper, so buttons, inputs, cards, and custom components work without structural changes. Choose a visual variant and size, then use class to match the wrapper radius to your content. Pass color for a single CSS color or colors for a custom multi-color palette. Background colors and animation durations are also customizable, and reduced-motion preferences are respected.",
"moreExamples": [
{
"name": "variants",
"title": "Visual variants",
"description": "Choose from default, dual, rainbow, holo, glow, gold, and silver treatments."
},
{
"name": "customization",
"title": "Sizes and customization",
"description": "Control aura thickness, CSS colors, backdrop color, and animation duration."
}
],
"api": [
{
"name": "variant",
"type": "default | dual | rainbow | holo | glow | gold | silver",
"default": "default"
},
{ "name": "size", "type": "xs | sm | md | lg | xl", "default": "md" },
{ "name": "color", "type": "CSS color", "default": "currentColor" },
{ "name": "colors", "type": "CSS color[]", "default": "[]" },
{ "name": "backgroundColor", "type": "CSS color", "default": "transparent" },
{ "name": "duration", "type": "number (milliseconds)", "default": "6000" },
{ "name": "class", "type": "string", "default": "—" },
{ "name": "children", "type": "Snippet", "default": "required" }
]
}
}
},
{
"name": "chat",
"type": "registry:ui",
"title": "Chat",
"description": "A composable chat interface with aligned messages, message content, and an accessible composer.",
"dependencies": [],
"registryDependencies": ["utils"],
"files": [
{ "path": "src/lib/components/ui/chat/chat.svelte", "type": "registry:ui" },
{
"path": "src/lib/components/ui/chat/chat-messages.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/chat/chat-message.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/chat/chat-content.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/chat/chat-composer.svelte",
"type": "registry:ui"
},
{ "path": "src/lib/components/ui/chat/index.ts", "type": "registry:ui" }
],
"meta": {
"docs": {
"demo": "chat-basic",
"usage": "Compose Root, Messages, Message, Content, and Composer. Message defaults to the right side; pass side=\"left\" for incoming messages. Bind Composer's value and handle messages with onSend.",
"moreExamples": [
{
"name": "support",
"title": "Avatars and message metadata",
"description": "Combine avatars, presence, timestamps, delivery states, and an interactive composer."
},
{
"name": "project",
"title": "Custom message content",
"description": "Use custom message content for sender names, attachments, dividers, and delivery details."
}
],
"api": [
{ "name": "Message.side", "type": "left | right", "default": "right" },
{ "name": "Composer.value", "type": "string", "default": "''" },
{
"name": "Composer.onSend",
"type": "(message: string) => void | Promise<void>",
"default": "—"
},
{ "name": "Composer.clearOnSend", "type": "boolean", "default": "true" },
{ "name": "Composer.submitOnEnter", "type": "boolean", "default": "true" },
{ "name": "Composer.disabled", "type": "boolean", "default": "false" }
]
}
}
},
{
"name": "code",
"type": "registry:ui",
"title": "Code",
"description": "Syntax-highlighted code display with Svelte support and one-click copying.",
"dependencies": ["shiki@^4.4.3"],
"registryDependencies": ["utils"],
"files": [
{ "path": "src/lib/components/ui/code/code.svelte", "type": "registry:ui" },
{ "path": "src/lib/components/ui/code/highlighter.ts", "type": "registry:ui" },
{ "path": "src/lib/components/ui/code/index.ts", "type": "registry:ui" }
],
"meta": {
"docs": {
"usage": "Pass the source text, its language, and an optional filename label. The highlighter is shared across every instance.",
"moreExamples": [
{
"name": "languages",
"title": "Languages",
"description": "Highlight TypeScript, JSON, and shell commands with language-aware labels."
},
{
"name": "presentation",
"title": "Presentation controls",
"description": "Hide the copy action, customize the label, and control the code block dimensions with Tailwind classes."
}
],
"api": [
{ "name": "code", "type": "string", "default": "required" },
{
"name": "language",
"type": "svelte | typescript | javascript | json | shellscript | text",
"default": "svelte"
},
{ "name": "label", "type": "string", "default": "language" },
{ "name": "showCopy", "type": "boolean", "default": "true" }
]
}
}
},
{
"name": "context-menu",
"type": "registry:ui",
"title": "Context Menu",
"description": "A composable right-click menu with nested submenus, selectable items, shortcuts, and icon-friendly actions.",
"dependencies": ["bits-ui@^2.19.0"],
"registryDependencies": ["utils"],
"files": [
{
"path": "src/lib/components/ui/context-menu/context-menu.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/context-menu-trigger.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/context-menu-content.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/context-menu-item.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/context-menu-checkbox-item.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/context-menu-radio-group.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/context-menu-radio-item.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/context-menu-group.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/context-menu-group-heading.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/context-menu-label.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/context-menu-shortcut.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/context-menu-separator.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/context-menu-sub.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/context-menu-sub-trigger.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/context-menu-sub-content.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/context-menu-portal.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/context-menu/index.ts",
"type": "registry:ui"
}
],
"meta": {
"docs": {
"usage": "Compose Root, Trigger, Content, and Item using the ContextMenu namespace. Add Sub, SubTrigger, and SubContent for any depth of nested menu. CheckboxItem and RadioGroup provide persistent selection state through Svelte bindings. For action icons, import components from the icon library configured by shadcn and render them directly inside an Item or SubTrigger; the menu automatically sizes and aligns SVG icons.",
"moreExamples": [
{
"name": "nested",
"title": "Icons and nested submenus",
"description": "Compose multiple submenu levels and render tree-shakeable icon components directly inside actions."
},
{
"name": "selections",
"title": "Checkboxes and radio groups",
"description": "Build stateful view controls with checked items, exclusive choices, groups, and disabled actions."
}
],
"api": [
{ "name": "Root.open", "type": "boolean (bindable)", "default": "false" },
{ "name": "Trigger", "type": "Bits UI trigger props", "default": "—" },
{ "name": "Content", "type": "Bits UI content props", "default": "—" },
{ "name": "Item.variant", "type": "default | destructive", "default": "default" },
{ "name": "Item.inset", "type": "boolean", "default": "false" },
{ "name": "CheckboxItem.checked", "type": "boolean (bindable)", "default": "false" },
{ "name": "RadioGroup.value", "type": "string (bindable)", "default": "''" },
{ "name": "Sub.open", "type": "boolean (bindable)", "default": "false" },
{ "name": "class", "type": "string", "default": "—" }
]
}
}
},
{
"name": "install",
"type": "registry:ui",
"title": "Install",
"description": "A persistent package-manager switcher for installation commands.",
"dependencies": ["bits-ui@^2.19.0"],
"registryDependencies": ["utils", "local:code"],
"files": [
{ "path": "src/lib/components/ui/install/install.svelte", "type": "registry:ui" },
{ "path": "src/lib/components/ui/install/index.ts", "type": "registry:ui" }
],
"meta": {
"docs": {
"usage": "Pass package-manager command prefixes through values and the shared package or CLI arguments through script. Install joins them with one space and remembers the active manager.",
"moreExamples": [
{
"name": "runners",
"title": "CLI runners",
"description": "Combine each manager's runner prefix with one shared CLI script."
},
{
"name": "options",
"title": "Labels and availability",
"description": "Use custom labels, disable unavailable choices, and isolate remembered selections with a storage key."
}
],
"api": [
{
"name": "values",
"type": "Array<{ value: string; command: string; label?: string; disabled?: boolean }>",
"default": "required"
},
{ "name": "script", "type": "string", "default": "required" },
{
"name": "storageKey",
"type": "string",
"default": "codeworks-ui:package-manager"
}
]
}
}
},
{
"name": "holographic",
"type": "registry:ui",
"title": "Holographic",
"description": "Applies an animated holographic spectrum and shimmer over any content.",
"dependencies": [],
"registryDependencies": ["utils"],
"files": [
{
"path": "src/lib/components/ui/holographic/holographic.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/holographic/index.ts",
"type": "registry:ui"
}
],
"meta": {
"docs": {
"usage": "Wrap any content and optionally pass CSS color values. Shape and border radius are controlled through class; no radius is applied by default. Empty color arrays use the built-in spectrum, and reduced-motion preferences are respected.",
"moreExamples": [
{
"name": "intensity",
"title": "Intensity and speed",
"description": "Tune the shimmer from barely-there polish to a stronger accent and control its duration."
},
{
"name": "content",
"title": "Any shape or content",
"description": "Apply the effect to interactive controls and cards while owning the shape entirely through Tailwind classes."
}
],
"api": [
{ "name": "colors", "type": "string[]", "default": "built-in spectrum" },
{ "name": "intensity", "type": "number (0–1)", "default": "0.16" },
{ "name": "duration", "type": "number (milliseconds)", "default": "5000" },
{ "name": "class", "type": "string", "default": "—" },
{ "name": "children", "type": "Snippet", "default": "required" }
]
}
}
},
{
"name": "mention-input",
"type": "registry:ui",
"title": "Mention Input",
"description": "A customizable mention-aware textarea with keyboard suggestions, multiple triggers, and application-defined mention actions.",
"dependencies": [],
"registryDependencies": ["utils"],
"files": [
{
"path": "src/lib/components/ui/mention-input/mention-input.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/mention-input/index.ts",
"type": "registry:ui"
}
],
"meta": {
"docs": {
"usage": "Pass MentionItem objects and bind value for a controlled textarea. Type a configured trigger to open suggestions, then use the pointer, arrow keys, Enter, or Tab to insert a mention. Each item can define its own onMention action, while the component-level onMention observes every selection. Use onSearch to load remote results, filter to replace local matching, formatMention to control inserted text, and the suggestion and empty snippets plus Tailwind class props to own the presentation.",
"moreExamples": [
{
"name": "custom",
"title": "Custom styling and actions",
"description": "Render rich suggestions, search keywords, customize every layer with Tailwind, and run an item-specific action after insertion."
},
{
"name": "triggers",
"title": "People and channels",
"description": "Use multiple trigger characters, customize inserted text, and respond to every selected mention."
},
{
"name": "event",
"title": "Mention event payload",
"description": "Select a mention and inspect every field delivered to global and item-specific callbacks."
}
],
"api": [
{ "name": "items", "type": "MentionItem[]", "default": "required" },
{ "name": "value", "type": "string (bindable)", "default": "''" },
{
"name": "onValueChange",
"type": "(value: string) => void",
"default": "—"
},
{
"name": "onMention",
"type": "(event: MentionEvent) => void | Promise<void>",
"default": "—"
},
{
"name": "MentionItem.onMention",
"type": "(event: MentionEvent) => void | Promise<void>",
"default": "—"
},
{
"name": "MentionEvent.item",
"type": "MentionItem",
"default": "—",
"description": "The complete selected item, including its id, label, optional data, and item-specific action."
},
{
"name": "MentionEvent.trigger",
"type": "string",
"default": "—",
"description": "The trigger that opened the suggestions, such as @ or #."
},
{
"name": "MentionEvent.query",
"type": "string",
"default": "—",
"description": "The text typed after the trigger and before selecting the suggestion."
},
{
"name": "MentionEvent.start",
"type": "number",
"default": "—",
"description": "The starting character index of the trigger in the value before insertion."
},
{
"name": "MentionEvent.end",
"type": "number",
"default": "—",
"description": "The ending character index of the query in the value before insertion."
},
{
"name": "MentionEvent.mention",
"type": "string",
"default": "—",
"description": "The exact formatted mention inserted into the textarea."
},
{
"name": "MentionEvent.value",
"type": "string",
"default": "—",
"description": "The complete textarea value immediately after insertion."
},
{
"name": "onSearch",
"type": "(query: string, trigger: string) => void | Promise<void>",
"default": "—"
},
{
"name": "filter",
"type": "(item, query, trigger) => boolean",
"default": "label, value, and keywords"
},
{
"name": "formatMention",
"type": "(item, trigger) => string",
"default": "trigger + item value or label"
},
{ "name": "triggers", "type": "string[]", "default": "['@']" },
{ "name": "minQueryLength", "type": "number", "default": "0" },
{ "name": "maxSuggestions", "type": "number", "default": "8" },
{ "name": "allowSpaces", "type": "boolean", "default": "false" },
{ "name": "open", "type": "boolean (bindable)", "default": "false" },
{ "name": "suggestion", "type": "Snippet", "default": "—" },
{ "name": "empty", "type": "Snippet", "default": "—" },
{ "name": "class", "type": "string", "default": "—" },
{ "name": "inputClass", "type": "string", "default": "—" },
{ "name": "menuClass", "type": "string", "default": "—" },
{ "name": "itemClass", "type": "string", "default": "—" },
{ "name": "emptyClass", "type": "string", "default": "—" }
]
}
}
},
{
"name": "navbar",
"type": "registry:ui",
"title": "Navbar",
"description": "A responsive navigation bar with shadcn Popover subroutes and an automatic Sheet menu on mobile.",
"dependencies": [],
"registryDependencies": ["popover", "sheet", "utils"],
"files": [
{
"path": "src/lib/components/ui/navbar/navbar.svelte",
"type": "registry:ui"
},
{
"path": "src/lib/components/ui/navbar/index.ts",
"type": "registry:ui"
}
],
"meta": {
"docs": {
"usage": "Pass an array of navigation items and optionally give an item a subroutes array. Subroutes open in a shadcn Popover on desktop and render as an easy-to-scan nested list in the mobile Sheet. Use showParentLink when a group does not have a true overview route, mobileShowDescriptions for a more compact mobile list, and popoverClass or subroutesClass to size dense menus with Tailwind. Active, disabled, external, described, and badged links are supported at both levels. Use snippets for a custom brand, desktop actions, mobile actions below the Sheet heading, and true footer content. Set forceMobile when the compact navigation should be shown regardless of viewport width. The Sheet closes automatically when a mobile link is selected.",
"moreExamples": [
{
"name": "actions",
"title": "Branding and composed actions",
"description": "Add a custom brand, Popover subroutes, badges, calls to action, and a nested Context Menu account control."
},
{
"name": "mobile",
"title": "Mobile behavior",
"description": "See how subroutes become a touch-friendly nested hierarchy inside the mobile Sheet."
}
],
"api": [
{
"name": "items",
"type": "NavbarItem[]",
"default": "required"
},
{
"name": "NavbarItem.subroutes",
"type": "NavbarSubroute[]",
"default": "—"
},
{
"name": "NavbarItem.showParentLink",
"type": "boolean",
"default": "true"
},
{
"name": "NavbarItem.popoverClass",
"type": "string",
"default": "—"
},
{
"name": "NavbarItem.subroutesClass",
"type": "string",
"default": "—"
},
{
"name": "NavbarItem.mobileShowDescriptions",
"type": "boolean",
"default": "true"
},
{ "name": "brand", "type": "string | Snippet", "default": "Brand" },
{ "name": "brandHref", "type": "string", "default": "/" },
{
"name": "breakpoint",
"type": "sm | md | lg | xl | 2xl",
"default": "md"
},
{ "name": "forceMobile", "type": "boolean", "default": "false" },
{ "name": "mobileSide", "type": "left | right", "default": "right" },
{ "name": "open", "type": "boolean (bindable)", "default": "false" },
{
"name": "onOpenChange",
"type": "(open: boolean) => void",
"default": "—"
},
{ "name": "actions", "type": "Snippet", "default": "—" },
{ "name": "mobileActions", "type": "Snippet", "default": "—" },
{ "name": "mobileFooter", "type": "Snippet", "default": "—" },
{ "name": "containerClass", "type": "string", "default": "—" },
{ "name": "contentClass", "type": "string", "default": "—" },
{ "name": "class", "type": "string", "default": "—" }
]
}
}
},
{
"name": "stat",
"type": "registry:ui",
"title": "Stat",
"description": "Displays related numbers and supporting data in composable horizontal, vertical, or responsive blocks.",
"dependencies": [],
"registryDependencies": ["utils"],
"files": [
{ "path": "src/lib/components/ui/stat/stat.svelte", "type": "registry:ui" },
{ "path": "src/lib/components/ui/stat/stat-item.svelte", "type": "registry:ui" },
{ "path": "src/lib/components/ui/stat/stat-title.svelte", "type": "registry:ui" },
{ "path": "src/lib/components/ui/stat/stat-value.svelte", "type": "registry:ui" },
{ "path": "src/lib/components/ui/stat/stat-description.svelte", "type": "registry:ui" },
{ "path": "src/lib/components/ui/stat/stat-figure.svelte", "type": "registry:ui" },
{ "path": "src/lib/components/ui/stat/stat-actions.svelte", "type": "registry:ui" },
{ "path": "src/lib/components/ui/stat/index.ts", "type": "registry:ui" }
],
"meta": {
"docs": {
"usage": "Compose Root, Item, Title, Value, and Description. Add Figure for an icon or image and Actions for controls. Root defaults to a horizontal layout; use vertical or responsive when the stats should stack, including on smaller screens.",
"moreExamples": [
{
"name": "dashboard",
"title": "Responsive dashboard",
"description": "Combine figures, semantic colors, and multiple values in a layout that stacks on smaller screens."
},
{
"name": "actions",
"title": "Actions and alignment",
"description": "Add controls or center individual stat items with ordinary Tailwind classes."
}
],
"api": [
{
"name": "Root.direction",
"type": "horizontal | vertical | responsive",
"default": "horizontal"
},
{ "name": "class", "type": "string", "default": "—" },
{ "name": "children", "type": "Snippet", "default": "required" }
]
}
}
},
{
"name": "steps",
"type": "registry:ui",
"title": "Steps",
"description": "Shows progress through a sequence with composable steps, states, colors, and responsive orientations.",
"dependencies": [],
"registryDependencies": ["utils"],
"files": [
{ "path": "src/lib/components/ui/steps/steps.svelte", "type": "registry:ui" },
{ "path": "src/lib/components/ui/steps/steps-item.svelte", "type": "registry:ui" },
{ "path": "src/lib/components/ui/steps/steps-context.ts", "type": "registry:ui" },
{ "path": "src/lib/components/ui/steps/index.ts", "type": "registry:ui" }
],
"meta": {
"docs": {
"usage": "Compose Root and Item. Root controls horizontal, vertical, or responsive layout. Each Item accepts a pending, current, or complete state and an optional semantic color variant. Pass indicator as text, a number, or a snippet for icons and custom markup. The underlying ordered list preserves the process order for assistive technology.",
"moreExamples": [
{
"name": "directions",
"title": "Vertical and responsive",
"description": "Use a vertical sequence or switch automatically from vertical on mobile to horizontal on larger screens."
},
{
"name": "variants",
"title": "Colors and custom indicators",
"description": "Communicate success, warnings, and errors with semantic variants and snippet-based indicator content."
}
],
"api": [
{
"name": "Root.direction",
"type": "horizontal | vertical | responsive",
"default": "horizontal"
},
{
"name": "Item.state",
"type": "pending | current | complete",
"default": "pending"
},
{
"name": "Item.variant",
"type": "primary | secondary | accent | neutral | info | success | warning | destructive",
"default": "primary"
},
{ "name": "Item.indicator", "type": "string | number | Snippet", "default": "—" },
{ "name": "class", "type": "string", "default": "—" },
{ "name": "Item.indicatorClass", "type": "string", "default": "—" },
{ "name": "Item.labelClass", "type": "string", "default": "—" },
{ "name": "children", "type": "Snippet", "default": "required" }
]
}
}
},
{
"name": "tooltip",
"type": "registry:ui",
"title": "Tooltip",
"description": "Displays concise contextual information on hover, keyboard focus, or touch-friendly tap.",
"dependencies": ["bits-ui@^2.19.0"],
"registryDependencies": ["utils"],
"files": [
{ "path": "src/lib/components/ui/tooltip/tooltip.svelte", "type": "registry:ui" },
{ "path": "src/lib/components/ui/tooltip/index.ts", "type": "registry:ui" }
],
"meta": {
"docs": {
"usage": "Wrap a single control or element and pass content as text or a snippet. The tooltip opens on pointer hover and keyboard focus, toggles on touch tap, closes on outside interaction or Escape, avoids viewport edges, and keeps a mobile-safe maximum width. Keep tooltip content concise and non-interactive; use a popover for buttons or form controls.",
"moreExamples": [
{
"name": "placements",
"title": "Placement",
"description": "Position the tooltip on any side while collision handling keeps it inside the viewport."
},
{
"name": "content",
"title": "Rich content",
"description": "Use a snippet for concise formatted content while preserving tooltip semantics."
}
],
"api": [
{ "name": "content", "type": "string | Snippet", "default": "required" },
{ "name": "open", "type": "boolean", "default": "false" },
{ "name": "side", "type": "top | right | bottom | left", "default": "top" },
{ "name": "align", "type": "start | center | end", "default": "center" },
{ "name": "sideOffset", "type": "number", "default": "8" },
{ "name": "delayDuration", "type": "number", "default": "300" },
{ "name": "tapToOpen", "type": "boolean", "default": "true" },
{ "name": "showArrow", "type": "boolean", "default": "true" },
{ "name": "disabled", "type": "boolean", "default": "false" },
{ "name": "class", "type": "string", "default": "—" },
{ "name": "contentClass", "type": "string", "default": "—" },
{ "name": "children", "type": "Snippet", "default": "required" }
]
}
}
}
]
}