svelte-docsmith 0.1.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 (192) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +162 -0
  3. package/dist/clipboard.svelte.d.ts +6 -0
  4. package/dist/clipboard.svelte.js +27 -0
  5. package/dist/config.d.ts +79 -0
  6. package/dist/config.js +55 -0
  7. package/dist/content.d.ts +10 -0
  8. package/dist/content.js +4 -0
  9. package/dist/highlight.d.ts +17 -0
  10. package/dist/highlight.js +34 -0
  11. package/dist/index.d.ts +20 -0
  12. package/dist/index.js +26 -0
  13. package/dist/markdown-layout.svelte +21 -0
  14. package/dist/markdown-layout.svelte.d.ts +18 -0
  15. package/dist/preprocess.d.ts +33 -0
  16. package/dist/preprocess.js +65 -0
  17. package/dist/shadcn.d.ts +12 -0
  18. package/dist/shadcn.js +5 -0
  19. package/dist/theme.css +201 -0
  20. package/dist/themes/amethyst.css +76 -0
  21. package/dist/themes/bubblegum.css +79 -0
  22. package/dist/themes/claude.css +79 -0
  23. package/dist/themes/evergreen.css +76 -0
  24. package/dist/themes/graphite.css +79 -0
  25. package/dist/themes/mono.css +79 -0
  26. package/dist/themes/nord.css +79 -0
  27. package/dist/themes/ocean.css +76 -0
  28. package/dist/themes/rose.css +78 -0
  29. package/dist/themes/tangerine.css +81 -0
  30. package/dist/toc/from-content.d.ts +11 -0
  31. package/dist/toc/from-content.js +18 -0
  32. package/dist/toc/index.d.ts +3 -0
  33. package/dist/toc/index.js +3 -0
  34. package/dist/toc/toc.svelte.d.ts +26 -0
  35. package/dist/toc/toc.svelte.js +74 -0
  36. package/dist/toc/types.d.ts +11 -0
  37. package/dist/toc/types.js +1 -0
  38. package/dist/types.d.ts +13 -0
  39. package/dist/types.js +1 -0
  40. package/dist/ui/accordion-item.svelte +24 -0
  41. package/dist/ui/accordion-item.svelte.d.ts +9 -0
  42. package/dist/ui/accordion.svelte +45 -0
  43. package/dist/ui/accordion.svelte.d.ts +15 -0
  44. package/dist/ui/background-pattern.svelte +17 -0
  45. package/dist/ui/background-pattern.svelte.d.ts +26 -0
  46. package/dist/ui/badge.svelte +54 -0
  47. package/dist/ui/badge.svelte.d.ts +12 -0
  48. package/dist/ui/callout.svelte +125 -0
  49. package/dist/ui/callout.svelte.d.ts +13 -0
  50. package/dist/ui/card-grid.svelte +10 -0
  51. package/dist/ui/card-grid.svelte.d.ts +7 -0
  52. package/dist/ui/card.svelte +52 -0
  53. package/dist/ui/card.svelte.d.ts +14 -0
  54. package/dist/ui/copy-button.svelte +30 -0
  55. package/dist/ui/copy-button.svelte.d.ts +9 -0
  56. package/dist/ui/file-tree-item.svelte +70 -0
  57. package/dist/ui/file-tree-item.svelte.d.ts +14 -0
  58. package/dist/ui/file-tree.svelte +34 -0
  59. package/dist/ui/file-tree.svelte.d.ts +7 -0
  60. package/dist/ui/icons/github.svelte +14 -0
  61. package/dist/ui/icons/github.svelte.d.ts +6 -0
  62. package/dist/ui/kbd.svelte +11 -0
  63. package/dist/ui/kbd.svelte.d.ts +7 -0
  64. package/dist/ui/layouts/breadcrumbs.svelte +37 -0
  65. package/dist/ui/layouts/breadcrumbs.svelte.d.ts +10 -0
  66. package/dist/ui/layouts/docs-footer.svelte +40 -0
  67. package/dist/ui/layouts/docs-footer.svelte.d.ts +7 -0
  68. package/dist/ui/layouts/docs-header.svelte +109 -0
  69. package/dist/ui/layouts/docs-header.svelte.d.ts +18 -0
  70. package/dist/ui/layouts/docs-mobile-header.svelte +106 -0
  71. package/dist/ui/layouts/docs-mobile-header.svelte.d.ts +18 -0
  72. package/dist/ui/layouts/docs-shell.svelte +133 -0
  73. package/dist/ui/layouts/docs-shell.svelte.d.ts +25 -0
  74. package/dist/ui/layouts/docs-sidebar.svelte +36 -0
  75. package/dist/ui/layouts/docs-sidebar.svelte.d.ts +8 -0
  76. package/dist/ui/layouts/prev-next-nav.svelte +32 -0
  77. package/dist/ui/layouts/prev-next-nav.svelte.d.ts +8 -0
  78. package/dist/ui/live-example.svelte +67 -0
  79. package/dist/ui/live-example.svelte.d.ts +10 -0
  80. package/dist/ui/markdown/code.svelte +11 -0
  81. package/dist/ui/markdown/code.svelte.d.ts +7 -0
  82. package/dist/ui/markdown/h2.svelte +13 -0
  83. package/dist/ui/markdown/h2.svelte.d.ts +4 -0
  84. package/dist/ui/markdown/h3.svelte +13 -0
  85. package/dist/ui/markdown/h3.svelte.d.ts +4 -0
  86. package/dist/ui/markdown/index.d.ts +5 -0
  87. package/dist/ui/markdown/index.js +5 -0
  88. package/dist/ui/markdown/pre.svelte +88 -0
  89. package/dist/ui/markdown/pre.svelte.d.ts +7 -0
  90. package/dist/ui/markdown/table.svelte +80 -0
  91. package/dist/ui/markdown/table.svelte.d.ts +7 -0
  92. package/dist/ui/markdown/types.d.ts +3 -0
  93. package/dist/ui/markdown/types.js +1 -0
  94. package/dist/ui/prop.svelte +130 -0
  95. package/dist/ui/prop.svelte.d.ts +16 -0
  96. package/dist/ui/props-table.svelte +127 -0
  97. package/dist/ui/props-table.svelte.d.ts +9 -0
  98. package/dist/ui/shadcn/accordion/accordion-content.svelte +27 -0
  99. package/dist/ui/shadcn/accordion/accordion-content.svelte.d.ts +4 -0
  100. package/dist/ui/shadcn/accordion/accordion-item.svelte +17 -0
  101. package/dist/ui/shadcn/accordion/accordion-item.svelte.d.ts +4 -0
  102. package/dist/ui/shadcn/accordion/accordion-trigger.svelte +38 -0
  103. package/dist/ui/shadcn/accordion/accordion-trigger.svelte.d.ts +8 -0
  104. package/dist/ui/shadcn/accordion/accordion.svelte +19 -0
  105. package/dist/ui/shadcn/accordion/accordion.svelte.d.ts +4 -0
  106. package/dist/ui/shadcn/accordion/index.d.ts +5 -0
  107. package/dist/ui/shadcn/accordion/index.js +7 -0
  108. package/dist/ui/shadcn/badge/badge.svelte +50 -0
  109. package/dist/ui/shadcn/badge/badge.svelte.d.ts +38 -0
  110. package/dist/ui/shadcn/badge/index.d.ts +2 -0
  111. package/dist/ui/shadcn/badge/index.js +2 -0
  112. package/dist/ui/shadcn/button/button.svelte +89 -0
  113. package/dist/ui/shadcn/button/button.svelte.d.ts +70 -0
  114. package/dist/ui/shadcn/button/index.d.ts +2 -0
  115. package/dist/ui/shadcn/button/index.js +4 -0
  116. package/dist/ui/shadcn/popover/index.d.ts +9 -0
  117. package/dist/ui/shadcn/popover/index.js +11 -0
  118. package/dist/ui/shadcn/popover/popover-close.svelte +7 -0
  119. package/dist/ui/shadcn/popover/popover-close.svelte.d.ts +4 -0
  120. package/dist/ui/shadcn/popover/popover-content.svelte +31 -0
  121. package/dist/ui/shadcn/popover/popover-content.svelte.d.ts +10 -0
  122. package/dist/ui/shadcn/popover/popover-description.svelte +20 -0
  123. package/dist/ui/shadcn/popover/popover-description.svelte.d.ts +5 -0
  124. package/dist/ui/shadcn/popover/popover-header.svelte +20 -0
  125. package/dist/ui/shadcn/popover/popover-header.svelte.d.ts +5 -0
  126. package/dist/ui/shadcn/popover/popover-portal.svelte +7 -0
  127. package/dist/ui/shadcn/popover/popover-portal.svelte.d.ts +3 -0
  128. package/dist/ui/shadcn/popover/popover-title.svelte +15 -0
  129. package/dist/ui/shadcn/popover/popover-title.svelte.d.ts +5 -0
  130. package/dist/ui/shadcn/popover/popover-trigger.svelte +17 -0
  131. package/dist/ui/shadcn/popover/popover-trigger.svelte.d.ts +4 -0
  132. package/dist/ui/shadcn/popover/popover.svelte +7 -0
  133. package/dist/ui/shadcn/popover/popover.svelte.d.ts +3 -0
  134. package/dist/ui/shadcn/scroll-area/index.d.ts +3 -0
  135. package/dist/ui/shadcn/scroll-area/index.js +5 -0
  136. package/dist/ui/shadcn/scroll-area/scroll-area-scrollbar.svelte +30 -0
  137. package/dist/ui/shadcn/scroll-area/scroll-area-scrollbar.svelte.d.ts +4 -0
  138. package/dist/ui/shadcn/scroll-area/scroll-area.svelte +43 -0
  139. package/dist/ui/shadcn/scroll-area/scroll-area.svelte.d.ts +11 -0
  140. package/dist/ui/shadcn/separator/index.d.ts +2 -0
  141. package/dist/ui/shadcn/separator/index.js +4 -0
  142. package/dist/ui/shadcn/separator/separator.svelte +23 -0
  143. package/dist/ui/shadcn/separator/separator.svelte.d.ts +4 -0
  144. package/dist/ui/shadcn/sheet/index.d.ts +11 -0
  145. package/dist/ui/shadcn/sheet/index.js +13 -0
  146. package/dist/ui/shadcn/sheet/sheet-close.svelte +7 -0
  147. package/dist/ui/shadcn/sheet/sheet-close.svelte.d.ts +4 -0
  148. package/dist/ui/shadcn/sheet/sheet-content.svelte +55 -0
  149. package/dist/ui/shadcn/sheet/sheet-content.svelte.d.ts +15 -0
  150. package/dist/ui/shadcn/sheet/sheet-description.svelte +17 -0
  151. package/dist/ui/shadcn/sheet/sheet-description.svelte.d.ts +4 -0
  152. package/dist/ui/shadcn/sheet/sheet-footer.svelte +20 -0
  153. package/dist/ui/shadcn/sheet/sheet-footer.svelte.d.ts +5 -0
  154. package/dist/ui/shadcn/sheet/sheet-header.svelte +20 -0
  155. package/dist/ui/shadcn/sheet/sheet-header.svelte.d.ts +5 -0
  156. package/dist/ui/shadcn/sheet/sheet-overlay.svelte +17 -0
  157. package/dist/ui/shadcn/sheet/sheet-overlay.svelte.d.ts +4 -0
  158. package/dist/ui/shadcn/sheet/sheet-portal.svelte +7 -0
  159. package/dist/ui/shadcn/sheet/sheet-portal.svelte.d.ts +3 -0
  160. package/dist/ui/shadcn/sheet/sheet-title.svelte +17 -0
  161. package/dist/ui/shadcn/sheet/sheet-title.svelte.d.ts +4 -0
  162. package/dist/ui/shadcn/sheet/sheet-trigger.svelte +7 -0
  163. package/dist/ui/shadcn/sheet/sheet-trigger.svelte.d.ts +4 -0
  164. package/dist/ui/shadcn/sheet/sheet.svelte +7 -0
  165. package/dist/ui/shadcn/sheet/sheet.svelte.d.ts +3 -0
  166. package/dist/ui/shadcn/tabs/index.d.ts +5 -0
  167. package/dist/ui/shadcn/tabs/index.js +7 -0
  168. package/dist/ui/shadcn/tabs/tabs-content.svelte +17 -0
  169. package/dist/ui/shadcn/tabs/tabs-content.svelte.d.ts +4 -0
  170. package/dist/ui/shadcn/tabs/tabs-list.svelte +40 -0
  171. package/dist/ui/shadcn/tabs/tabs-list.svelte.d.ts +25 -0
  172. package/dist/ui/shadcn/tabs/tabs-trigger.svelte +23 -0
  173. package/dist/ui/shadcn/tabs/tabs-trigger.svelte.d.ts +4 -0
  174. package/dist/ui/shadcn/tabs/tabs.svelte +19 -0
  175. package/dist/ui/shadcn/tabs/tabs.svelte.d.ts +4 -0
  176. package/dist/ui/step.svelte +82 -0
  177. package/dist/ui/step.svelte.d.ts +9 -0
  178. package/dist/ui/steps.svelte +71 -0
  179. package/dist/ui/steps.svelte.d.ts +7 -0
  180. package/dist/ui/tab-item.svelte +14 -0
  181. package/dist/ui/tab-item.svelte.d.ts +6 -0
  182. package/dist/ui/table-of-contents.svelte +114 -0
  183. package/dist/ui/table-of-contents.svelte.d.ts +9 -0
  184. package/dist/ui/tabs.svelte +29 -0
  185. package/dist/ui/tabs.svelte.d.ts +8 -0
  186. package/dist/ui/theme-provider.svelte +23 -0
  187. package/dist/ui/theme-provider.svelte.d.ts +10 -0
  188. package/dist/ui/theme-toggle.svelte +22 -0
  189. package/dist/ui/theme-toggle.svelte.d.ts +6 -0
  190. package/dist/vite.d.ts +32 -0
  191. package/dist/vite.js +216 -0
  192. package/package.json +115 -0
@@ -0,0 +1,55 @@
1
+ <script lang="ts" module>
2
+ export type Side = 'top' | 'right' | 'bottom' | 'left';
3
+ </script>
4
+
5
+ <script lang="ts">
6
+ import { Dialog as SheetPrimitive } from 'bits-ui';
7
+ import type { Snippet } from 'svelte';
8
+ import SheetPortal from './sheet-portal.svelte';
9
+ import SheetOverlay from './sheet-overlay.svelte';
10
+ import { Button } from '../button/index.js';
11
+ import XIcon from '@lucide/svelte/icons/x';
12
+ import { cn, type WithoutChildrenOrChild } from '../../../shadcn.js';
13
+ import type { ComponentProps } from 'svelte';
14
+
15
+ let {
16
+ ref = $bindable(null),
17
+ class: className,
18
+ side = 'right',
19
+ showCloseButton = true,
20
+ portalProps,
21
+ children,
22
+ ...restProps
23
+ }: WithoutChildrenOrChild<SheetPrimitive.ContentProps> & {
24
+ portalProps?: WithoutChildrenOrChild<ComponentProps<typeof SheetPortal>>;
25
+ side?: Side;
26
+ showCloseButton?: boolean;
27
+ children: Snippet;
28
+ } = $props();
29
+ </script>
30
+
31
+ <SheetPortal {...portalProps}>
32
+ <SheetOverlay />
33
+ <SheetPrimitive.Content
34
+ bind:ref
35
+ data-slot="sheet-content"
36
+ data-side={side}
37
+ class={cn(
38
+ 'bg-popover text-popover-foreground fixed z-50 flex flex-col gap-4 bg-clip-padding text-sm shadow-lg transition duration-200 ease-in-out data-[side=bottom]:inset-x-0 data-[side=bottom]:bottom-0 data-[side=bottom]:h-auto data-[side=bottom]:border-t data-[side=left]:inset-y-0 data-[side=left]:left-0 data-[side=left]:h-full data-[side=left]:w-3/4 data-[side=left]:border-r data-[side=right]:inset-y-0 data-[side=right]:right-0 data-[side=right]:h-full data-[side=right]:w-3/4 data-[side=right]:border-l data-[side=top]:inset-x-0 data-[side=top]:top-0 data-[side=top]:h-auto data-[side=top]:border-b data-[side=left]:sm:max-w-sm data-[side=right]:sm:max-w-sm data-open:animate-in data-open:fade-in-0 data-[side=bottom]:data-open:slide-in-from-bottom-10 data-[side=left]:data-open:slide-in-from-left-10 data-[side=right]:data-open:slide-in-from-right-10 data-[side=top]:data-open:slide-in-from-top-10 data-closed:animate-out data-closed:fade-out-0 data-[side=bottom]:data-closed:slide-out-to-bottom-10 data-[side=left]:data-closed:slide-out-to-left-10 data-[side=right]:data-closed:slide-out-to-right-10 data-[side=top]:data-closed:slide-out-to-top-10',
39
+ className
40
+ )}
41
+ {...restProps}
42
+ >
43
+ {@render children?.()}
44
+ {#if showCloseButton}
45
+ <SheetPrimitive.Close data-slot="sheet-close">
46
+ {#snippet child({ props })}
47
+ <Button variant="ghost" class="absolute top-4 right-4" size="icon-sm" {...props}>
48
+ <XIcon />
49
+ <span class="sr-only">Close</span>
50
+ </Button>
51
+ {/snippet}
52
+ </SheetPrimitive.Close>
53
+ {/if}
54
+ </SheetPrimitive.Content>
55
+ </SheetPortal>
@@ -0,0 +1,15 @@
1
+ export type Side = 'top' | 'right' | 'bottom' | 'left';
2
+ import { Dialog as SheetPrimitive } from 'bits-ui';
3
+ import type { Snippet } from 'svelte';
4
+ import SheetPortal from './sheet-portal.svelte';
5
+ import { type WithoutChildrenOrChild } from '../../../shadcn.js';
6
+ import type { ComponentProps } from 'svelte';
7
+ type $$ComponentProps = WithoutChildrenOrChild<SheetPrimitive.ContentProps> & {
8
+ portalProps?: WithoutChildrenOrChild<ComponentProps<typeof SheetPortal>>;
9
+ side?: Side;
10
+ showCloseButton?: boolean;
11
+ children: Snippet;
12
+ };
13
+ declare const SheetContent: import("svelte").Component<$$ComponentProps, {}, "ref">;
14
+ type SheetContent = ReturnType<typeof SheetContent>;
15
+ export default SheetContent;
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import { Dialog as SheetPrimitive } from 'bits-ui';
3
+ import { cn } from '../../../shadcn.js';
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ class: className,
8
+ ...restProps
9
+ }: SheetPrimitive.DescriptionProps = $props();
10
+ </script>
11
+
12
+ <SheetPrimitive.Description
13
+ bind:ref
14
+ data-slot="sheet-description"
15
+ class={cn('text-muted-foreground text-sm', className)}
16
+ {...restProps}
17
+ />
@@ -0,0 +1,4 @@
1
+ import { Dialog as SheetPrimitive } from 'bits-ui';
2
+ declare const SheetDescription: import("svelte").Component<SheetPrimitive.DescriptionProps, {}, "ref">;
3
+ type SheetDescription = ReturnType<typeof SheetDescription>;
4
+ export default SheetDescription;
@@ -0,0 +1,20 @@
1
+ <script lang="ts">
2
+ import { cn, type WithElementRef } from '../../../shadcn.js';
3
+ import type { HTMLAttributes } from 'svelte/elements';
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ class: className,
8
+ children,
9
+ ...restProps
10
+ }: WithElementRef<HTMLAttributes<HTMLDivElement>> = $props();
11
+ </script>
12
+
13
+ <div
14
+ bind:this={ref}
15
+ data-slot="sheet-footer"
16
+ class={cn('gap-2 p-4 mt-auto flex flex-col', className)}
17
+ {...restProps}
18
+ >
19
+ {@render children?.()}
20
+ </div>
@@ -0,0 +1,5 @@
1
+ import { type WithElementRef } from '../../../shadcn.js';
2
+ import type { HTMLAttributes } from 'svelte/elements';
3
+ declare const SheetFooter: import("svelte").Component<WithElementRef<HTMLAttributes<HTMLDivElement>>, {}, "ref">;
4
+ type SheetFooter = ReturnType<typeof SheetFooter>;
5
+ export default SheetFooter;
@@ -0,0 +1,20 @@
1
+ <script lang="ts">
2
+ import type { HTMLAttributes } from 'svelte/elements';
3
+ import { cn, type WithElementRef } from '../../../shadcn.js';
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ class: className,
8
+ children,
9
+ ...restProps
10
+ }: WithElementRef<HTMLAttributes<HTMLDivElement>> = $props();
11
+ </script>
12
+
13
+ <div
14
+ bind:this={ref}
15
+ data-slot="sheet-header"
16
+ class={cn('gap-1.5 p-4 flex flex-col', className)}
17
+ {...restProps}
18
+ >
19
+ {@render children?.()}
20
+ </div>
@@ -0,0 +1,5 @@
1
+ import type { HTMLAttributes } from 'svelte/elements';
2
+ import { type WithElementRef } from '../../../shadcn.js';
3
+ declare const SheetHeader: import("svelte").Component<WithElementRef<HTMLAttributes<HTMLDivElement>>, {}, "ref">;
4
+ type SheetHeader = ReturnType<typeof SheetHeader>;
5
+ export default SheetHeader;
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import { Dialog as SheetPrimitive } from 'bits-ui';
3
+ import { cn } from '../../../shadcn.js';
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ class: className,
8
+ ...restProps
9
+ }: SheetPrimitive.OverlayProps = $props();
10
+ </script>
11
+
12
+ <SheetPrimitive.Overlay
13
+ bind:ref
14
+ data-slot="sheet-overlay"
15
+ class={cn('bg-black/10 supports-backdrop-filter:backdrop-blur-xs fixed inset-0 z-50', className)}
16
+ {...restProps}
17
+ />
@@ -0,0 +1,4 @@
1
+ import { Dialog as SheetPrimitive } from 'bits-ui';
2
+ declare const SheetOverlay: import("svelte").Component<SheetPrimitive.OverlayProps, {}, "ref">;
3
+ type SheetOverlay = ReturnType<typeof SheetOverlay>;
4
+ export default SheetOverlay;
@@ -0,0 +1,7 @@
1
+ <script lang="ts">
2
+ import { Dialog as SheetPrimitive } from 'bits-ui';
3
+
4
+ let { ...restProps }: SheetPrimitive.PortalProps = $props();
5
+ </script>
6
+
7
+ <SheetPrimitive.Portal {...restProps} />
@@ -0,0 +1,3 @@
1
+ declare const SheetPortal: import("svelte").Component<import("bits-ui").PortalProps, {}, "">;
2
+ type SheetPortal = ReturnType<typeof SheetPortal>;
3
+ export default SheetPortal;
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import { Dialog as SheetPrimitive } from 'bits-ui';
3
+ import { cn } from '../../../shadcn.js';
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ class: className,
8
+ ...restProps
9
+ }: SheetPrimitive.TitleProps = $props();
10
+ </script>
11
+
12
+ <SheetPrimitive.Title
13
+ bind:ref
14
+ data-slot="sheet-title"
15
+ class={cn('text-foreground font-medium', className)}
16
+ {...restProps}
17
+ />
@@ -0,0 +1,4 @@
1
+ import { Dialog as SheetPrimitive } from 'bits-ui';
2
+ declare const SheetTitle: import("svelte").Component<SheetPrimitive.TitleProps, {}, "ref">;
3
+ type SheetTitle = ReturnType<typeof SheetTitle>;
4
+ export default SheetTitle;
@@ -0,0 +1,7 @@
1
+ <script lang="ts">
2
+ import { Dialog as SheetPrimitive } from 'bits-ui';
3
+
4
+ let { ref = $bindable(null), ...restProps }: SheetPrimitive.TriggerProps = $props();
5
+ </script>
6
+
7
+ <SheetPrimitive.Trigger bind:ref data-slot="sheet-trigger" {...restProps} />
@@ -0,0 +1,4 @@
1
+ import { Dialog as SheetPrimitive } from 'bits-ui';
2
+ declare const SheetTrigger: import("svelte").Component<SheetPrimitive.TriggerProps, {}, "ref">;
3
+ type SheetTrigger = ReturnType<typeof SheetTrigger>;
4
+ export default SheetTrigger;
@@ -0,0 +1,7 @@
1
+ <script lang="ts">
2
+ import { Dialog as SheetPrimitive } from 'bits-ui';
3
+
4
+ let { open = $bindable(false), ...restProps }: SheetPrimitive.RootProps = $props();
5
+ </script>
6
+
7
+ <SheetPrimitive.Root bind:open {...restProps} />
@@ -0,0 +1,3 @@
1
+ declare const Sheet: import("svelte").Component<import("bits-ui").AlertDialogRootPropsWithoutHTML, {}, "open">;
2
+ type Sheet = ReturnType<typeof Sheet>;
3
+ export default Sheet;
@@ -0,0 +1,5 @@
1
+ import Root from './tabs.svelte';
2
+ import Content from './tabs-content.svelte';
3
+ import List, { tabsListVariants, type TabsListVariant } from './tabs-list.svelte';
4
+ import Trigger from './tabs-trigger.svelte';
5
+ export { Root, Content, List, Trigger, tabsListVariants, type TabsListVariant, Root as Tabs, Content as TabsContent, List as TabsList, Trigger as TabsTrigger };
@@ -0,0 +1,7 @@
1
+ import Root from './tabs.svelte';
2
+ import Content from './tabs-content.svelte';
3
+ import List, { tabsListVariants } from './tabs-list.svelte';
4
+ import Trigger from './tabs-trigger.svelte';
5
+ export { Root, Content, List, Trigger, tabsListVariants,
6
+ //
7
+ Root as Tabs, Content as TabsContent, List as TabsList, Trigger as TabsTrigger };
@@ -0,0 +1,17 @@
1
+ <script lang="ts">
2
+ import { Tabs as TabsPrimitive } from 'bits-ui';
3
+ import { cn } from '../../../shadcn.js';
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ class: className,
8
+ ...restProps
9
+ }: TabsPrimitive.ContentProps = $props();
10
+ </script>
11
+
12
+ <TabsPrimitive.Content
13
+ bind:ref
14
+ data-slot="tabs-content"
15
+ class={cn('text-sm flex-1 outline-none', className)}
16
+ {...restProps}
17
+ />
@@ -0,0 +1,4 @@
1
+ import { Tabs as TabsPrimitive } from 'bits-ui';
2
+ declare const TabsContent: import("svelte").Component<TabsPrimitive.ContentProps, {}, "ref">;
3
+ type TabsContent = ReturnType<typeof TabsContent>;
4
+ export default TabsContent;
@@ -0,0 +1,40 @@
1
+ <script lang="ts" module>
2
+ import { tv, type VariantProps } from 'tailwind-variants';
3
+
4
+ export const tabsListVariants = tv({
5
+ base: 'rounded-lg p-[3px] group-data-horizontal/tabs:h-9 data-[variant=line]:rounded-none group/tabs-list text-muted-foreground inline-flex w-fit items-center justify-center group-data-[orientation=vertical]/tabs:h-fit group-data-[orientation=vertical]/tabs:flex-col',
6
+ variants: {
7
+ variant: {
8
+ default: 'cn-tabs-list-variant-default bg-muted',
9
+ line: 'cn-tabs-list-variant-line gap-1 bg-transparent'
10
+ }
11
+ },
12
+ defaultVariants: {
13
+ variant: 'default'
14
+ }
15
+ });
16
+
17
+ export type TabsListVariant = VariantProps<typeof tabsListVariants>['variant'];
18
+ </script>
19
+
20
+ <script lang="ts">
21
+ import { Tabs as TabsPrimitive } from 'bits-ui';
22
+ import { cn } from '../../../shadcn.js';
23
+
24
+ let {
25
+ ref = $bindable(null),
26
+ variant = 'default',
27
+ class: className,
28
+ ...restProps
29
+ }: TabsPrimitive.ListProps & {
30
+ variant?: TabsListVariant;
31
+ } = $props();
32
+ </script>
33
+
34
+ <TabsPrimitive.List
35
+ bind:ref
36
+ data-slot="tabs-list"
37
+ data-variant={variant}
38
+ class={cn(tabsListVariants({ variant }), className)}
39
+ {...restProps}
40
+ />
@@ -0,0 +1,25 @@
1
+ import { type VariantProps } from 'tailwind-variants';
2
+ export declare const tabsListVariants: import("tailwind-variants").TVReturnType<{
3
+ variant: {
4
+ default: string;
5
+ line: string;
6
+ };
7
+ }, undefined, "rounded-lg p-[3px] group-data-horizontal/tabs:h-9 data-[variant=line]:rounded-none group/tabs-list text-muted-foreground inline-flex w-fit items-center justify-center group-data-[orientation=vertical]/tabs:h-fit group-data-[orientation=vertical]/tabs:flex-col", {
8
+ variant: {
9
+ default: string;
10
+ line: string;
11
+ };
12
+ }, undefined, import("tailwind-variants").TVReturnType<{
13
+ variant: {
14
+ default: string;
15
+ line: string;
16
+ };
17
+ }, undefined, "rounded-lg p-[3px] group-data-horizontal/tabs:h-9 data-[variant=line]:rounded-none group/tabs-list text-muted-foreground inline-flex w-fit items-center justify-center group-data-[orientation=vertical]/tabs:h-fit group-data-[orientation=vertical]/tabs:flex-col", unknown, unknown, undefined>>;
18
+ export type TabsListVariant = VariantProps<typeof tabsListVariants>['variant'];
19
+ import { Tabs as TabsPrimitive } from 'bits-ui';
20
+ type $$ComponentProps = TabsPrimitive.ListProps & {
21
+ variant?: TabsListVariant;
22
+ };
23
+ declare const TabsList: import("svelte").Component<$$ComponentProps, {}, "ref">;
24
+ type TabsList = ReturnType<typeof TabsList>;
25
+ export default TabsList;
@@ -0,0 +1,23 @@
1
+ <script lang="ts">
2
+ import { Tabs as TabsPrimitive } from 'bits-ui';
3
+ import { cn } from '../../../shadcn.js';
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ class: className,
8
+ ...restProps
9
+ }: TabsPrimitive.TriggerProps = $props();
10
+ </script>
11
+
12
+ <TabsPrimitive.Trigger
13
+ bind:ref
14
+ data-slot="tabs-trigger"
15
+ class={cn(
16
+ "gap-1.5 rounded-md border border-transparent px-2 py-1 text-sm font-medium has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 group-data-[variant=default]/tabs-list:data-active:shadow-sm group-data-[variant=line]/tabs-list:data-active:shadow-none [&_svg:not([class*='size-'])]:size-4 focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:outline-ring text-foreground/60 hover:text-foreground dark:text-muted-foreground dark:hover:text-foreground relative inline-flex h-[calc(100%-1px)] flex-1 items-center justify-center whitespace-nowrap transition-all group-data-[orientation=vertical]/tabs:w-full group-data-[orientation=vertical]/tabs:justify-start focus-visible:ring-[3px] focus-visible:outline-1 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0",
17
+ 'group-data-[variant=line]/tabs-list:bg-transparent group-data-[variant=line]/tabs-list:data-active:bg-transparent dark:group-data-[variant=line]/tabs-list:data-active:border-transparent dark:group-data-[variant=line]/tabs-list:data-active:bg-transparent',
18
+ 'data-active:bg-background dark:data-active:text-foreground dark:data-active:border-input dark:data-active:bg-input/30 data-active:text-foreground',
19
+ 'after:bg-foreground after:absolute after:opacity-0 after:transition-opacity group-data-[orientation=horizontal]/tabs:after:inset-x-0 group-data-[orientation=horizontal]/tabs:after:bottom-[-5px] group-data-[orientation=horizontal]/tabs:after:h-0.5 group-data-[orientation=vertical]/tabs:after:inset-y-0 group-data-[orientation=vertical]/tabs:after:-right-1 group-data-[orientation=vertical]/tabs:after:w-0.5 group-data-[variant=line]/tabs-list:data-active:after:opacity-100',
20
+ className
21
+ )}
22
+ {...restProps}
23
+ />
@@ -0,0 +1,4 @@
1
+ import { Tabs as TabsPrimitive } from 'bits-ui';
2
+ declare const TabsTrigger: import("svelte").Component<TabsPrimitive.TriggerProps, {}, "ref">;
3
+ type TabsTrigger = ReturnType<typeof TabsTrigger>;
4
+ export default TabsTrigger;
@@ -0,0 +1,19 @@
1
+ <script lang="ts">
2
+ import { Tabs as TabsPrimitive } from 'bits-ui';
3
+ import { cn } from '../../../shadcn.js';
4
+
5
+ let {
6
+ ref = $bindable(null),
7
+ value = $bindable(''),
8
+ class: className,
9
+ ...restProps
10
+ }: TabsPrimitive.RootProps = $props();
11
+ </script>
12
+
13
+ <TabsPrimitive.Root
14
+ bind:ref
15
+ bind:value
16
+ data-slot="tabs"
17
+ class={cn('gap-2 group/tabs flex data-[orientation=horizontal]:flex-col', className)}
18
+ {...restProps}
19
+ />
@@ -0,0 +1,4 @@
1
+ import { Tabs as TabsPrimitive } from 'bits-ui';
2
+ declare const Tabs: import("svelte").Component<TabsPrimitive.RootProps, {}, "ref" | "value">;
3
+ type Tabs = ReturnType<typeof Tabs>;
4
+ export default Tabs;
@@ -0,0 +1,82 @@
1
+ <script lang="ts">
2
+ import type { Snippet } from 'svelte';
3
+
4
+ const {
5
+ title,
6
+ children
7
+ }: {
8
+ /** Optional heading for the step. */
9
+ title?: string;
10
+ children?: Snippet;
11
+ } = $props();
12
+ </script>
13
+
14
+ <!--
15
+ One step in a <Steps>. Auto-numbered via a CSS counter shared with the parent,
16
+ so it needs no preprocessor and works in both markdown and plain .svelte.
17
+ -->
18
+ <div class="step">
19
+ <div class="step-marker" aria-hidden="true"></div>
20
+ <div class="step-content">
21
+ {#if title}<p class="step-title">{title}</p>{/if}
22
+ {#if children}{@render children()}{/if}
23
+ </div>
24
+ </div>
25
+
26
+ <style>
27
+ .step {
28
+ counter-increment: docsmith-step;
29
+ position: relative;
30
+ padding: 0 0 1.5rem 2.5rem;
31
+ }
32
+ /* Connector line, centered under the badge, sitting behind it (z-index) so
33
+ it never cuts across the number; hidden on the last step. */
34
+ .step::after {
35
+ content: '';
36
+ position: absolute;
37
+ left: 0.8rem;
38
+ top: 0;
39
+ bottom: 0;
40
+ width: 1px;
41
+ background: var(--border);
42
+ z-index: 0;
43
+ }
44
+ .step:last-child {
45
+ padding-bottom: 0;
46
+ }
47
+ .step:last-child::after {
48
+ display: none;
49
+ }
50
+ .step-marker {
51
+ position: absolute;
52
+ left: 0;
53
+ top: -0.15rem;
54
+ z-index: 1;
55
+ display: flex;
56
+ align-items: center;
57
+ justify-content: center;
58
+ width: 1.6rem;
59
+ height: 1.6rem;
60
+ border-radius: 9999px;
61
+ background: var(--primary);
62
+ color: var(--primary-foreground);
63
+ font-size: 0.8rem;
64
+ font-weight: 600;
65
+ font-variant-numeric: tabular-nums;
66
+ /* Ring in the page bg so the connector visually stops at the badge edge. */
67
+ box-shadow: 0 0 0 4px var(--background);
68
+ }
69
+ .step-marker::before {
70
+ content: counter(docsmith-step);
71
+ }
72
+ .step-title {
73
+ margin: 0 0 0.4rem;
74
+ font-weight: 600;
75
+ }
76
+ .step-content :global(:first-child) {
77
+ margin-top: 0;
78
+ }
79
+ .step-content :global(:last-child) {
80
+ margin-bottom: 0;
81
+ }
82
+ </style>
@@ -0,0 +1,9 @@
1
+ import type { Snippet } from 'svelte';
2
+ type $$ComponentProps = {
3
+ /** Optional heading for the step. */
4
+ title?: string;
5
+ children?: Snippet;
6
+ };
7
+ declare const Step: import("svelte").Component<$$ComponentProps, {}, "">;
8
+ type Step = ReturnType<typeof Step>;
9
+ export default Step;
@@ -0,0 +1,71 @@
1
+ <script lang="ts">
2
+ import type { Snippet } from 'svelte';
3
+
4
+ // A numbered walkthrough. Two ways to author it, both work anywhere
5
+ // (markdown pages AND plain .svelte components):
6
+ //
7
+ // <Steps>
8
+ // <Step title="First">Do this.</Step>
9
+ // <Step title="Then">Do that.</Step>
10
+ // </Steps>
11
+ //
12
+ // Or, as a convenience inside markdown, a plain ordered list:
13
+ //
14
+ // <Steps>
15
+ //
16
+ // 1. Do this.
17
+ // 2. Do that.
18
+ //
19
+ // </Steps>
20
+ const { children }: { children: Snippet } = $props();
21
+ </script>
22
+
23
+ <div class="steps">{@render children()}</div>
24
+
25
+ <style>
26
+ .steps {
27
+ counter-reset: docsmith-step;
28
+ }
29
+
30
+ /* Markdown convenience: a plain ordered list renders as numbered steps too.
31
+ (In a .svelte file there is no mdsvex to produce this <ol>, so prefer
32
+ <Step> there — this block simply does nothing when no <ol> is present.) */
33
+ .steps :global(ol) {
34
+ counter-reset: docsmith-step;
35
+ list-style: none;
36
+ margin: 1.5rem 0;
37
+ padding: 0;
38
+ }
39
+ .steps :global(ol > li) {
40
+ counter-increment: docsmith-step;
41
+ position: relative;
42
+ margin-left: 0.8rem;
43
+ padding: 0 0 1.5rem 2rem;
44
+ border-left: 1px solid var(--border);
45
+ }
46
+ .steps :global(ol > li:last-child) {
47
+ border-left-color: transparent;
48
+ padding-bottom: 0;
49
+ }
50
+ .steps :global(ol > li)::before {
51
+ content: counter(docsmith-step);
52
+ position: absolute;
53
+ left: 0;
54
+ top: -0.15rem;
55
+ transform: translateX(-50%);
56
+ display: flex;
57
+ align-items: center;
58
+ justify-content: center;
59
+ width: 1.6rem;
60
+ height: 1.6rem;
61
+ border-radius: 9999px;
62
+ background: var(--primary);
63
+ color: var(--primary-foreground);
64
+ font-size: 0.8rem;
65
+ font-weight: 600;
66
+ font-variant-numeric: tabular-nums;
67
+ }
68
+ .steps :global(ol > li > :first-child) {
69
+ margin-top: 0;
70
+ }
71
+ </style>
@@ -0,0 +1,7 @@
1
+ import type { Snippet } from 'svelte';
2
+ type $$ComponentProps = {
3
+ children: Snippet;
4
+ };
5
+ declare const Steps: import("svelte").Component<$$ComponentProps, {}, "">;
6
+ type Steps = ReturnType<typeof Steps>;
7
+ export default Steps;
@@ -0,0 +1,14 @@
1
+ <script lang="ts">
2
+ import * as Tabs from './shadcn/tabs/index.js';
3
+ import type { WithChildren } from '../types.js';
4
+
5
+ type TabsItemProps = {
6
+ value: string;
7
+ };
8
+
9
+ const { children, value }: WithChildren<TabsItemProps> = $props();
10
+ </script>
11
+
12
+ <Tabs.Content {value}>
13
+ {@render children()}
14
+ </Tabs.Content>
@@ -0,0 +1,6 @@
1
+ import type { WithChildren } from '../types.js';
2
+ declare const TabItem: import("svelte").Component<WithChildren<{
3
+ value: string;
4
+ }>, {}, "">;
5
+ type TabItem = ReturnType<typeof TabItem>;
6
+ export default TabItem;