uisv 0.0.12 → 0.0.13

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 (75) hide show
  1. package/dist/components/accordion.svelte +108 -0
  2. package/dist/components/accordion.svelte.d.ts +58 -0
  3. package/dist/components/alert.svelte +271 -0
  4. package/dist/components/alert.svelte.d.ts +23 -0
  5. package/dist/components/badge.svelte +225 -0
  6. package/dist/components/badge.svelte.d.ts +19 -0
  7. package/dist/components/banner.svelte +254 -0
  8. package/dist/components/banner.svelte.d.ts +23 -0
  9. package/dist/components/button/button.svelte +105 -0
  10. package/dist/components/button/button.svelte.d.ts +4 -0
  11. package/dist/components/button/index.d.ts +48 -0
  12. package/dist/components/button/index.js +4 -0
  13. package/dist/components/button/style.d.ts +148 -0
  14. package/dist/components/button/style.js +248 -0
  15. package/dist/components/card.svelte +70 -0
  16. package/dist/components/card.svelte.d.ts +17 -0
  17. package/dist/components/checkbox-group.svelte +258 -0
  18. package/dist/components/checkbox-group.svelte.d.ts +26 -0
  19. package/dist/components/checkbox.svelte +175 -0
  20. package/dist/components/checkbox.svelte.d.ts +27 -0
  21. package/dist/components/chip.svelte +82 -0
  22. package/dist/components/chip.svelte.d.ts +17 -0
  23. package/dist/components/color-picker.svelte +48 -0
  24. package/dist/components/color-picker.svelte.d.ts +10 -0
  25. package/dist/components/h1.svelte +15 -0
  26. package/dist/components/h1.svelte.d.ts +3 -0
  27. package/dist/components/h2.svelte +19 -0
  28. package/dist/components/h2.svelte.d.ts +3 -0
  29. package/dist/components/h3.svelte +16 -0
  30. package/dist/components/h3.svelte.d.ts +3 -0
  31. package/dist/components/h4.svelte +19 -0
  32. package/dist/components/h4.svelte.d.ts +3 -0
  33. package/dist/components/h5.svelte +19 -0
  34. package/dist/components/h5.svelte.d.ts +3 -0
  35. package/dist/components/h6.svelte +19 -0
  36. package/dist/components/h6.svelte.d.ts +3 -0
  37. package/dist/components/index.d.ts +42 -0
  38. package/dist/components/index.js +42 -0
  39. package/dist/components/input/index.d.ts +54 -0
  40. package/dist/components/input/index.js +2 -0
  41. package/dist/components/input/input.svelte +103 -0
  42. package/dist/components/input/input.svelte.d.ts +4 -0
  43. package/dist/components/input/style.d.ts +316 -0
  44. package/dist/components/input/style.js +128 -0
  45. package/dist/components/input-time/index.d.ts +375 -0
  46. package/dist/components/input-time/index.js +144 -0
  47. package/dist/components/input-time/input-time.svelte +39 -0
  48. package/dist/components/input-time/input-time.svelte.d.ts +4 -0
  49. package/dist/components/kbd.svelte +239 -0
  50. package/dist/components/kbd.svelte.d.ts +40 -0
  51. package/dist/components/p.svelte +9 -0
  52. package/dist/components/p.svelte.d.ts +3 -0
  53. package/dist/components/pin-input.svelte +162 -0
  54. package/dist/components/pin-input.svelte.d.ts +25 -0
  55. package/dist/components/placeholder.svelte +34 -0
  56. package/dist/components/placeholder.svelte.d.ts +3 -0
  57. package/dist/components/popover.svelte +151 -0
  58. package/dist/components/popover.svelte.d.ts +88 -0
  59. package/dist/components/progress.svelte +124 -0
  60. package/dist/components/progress.svelte.d.ts +21 -0
  61. package/dist/components/select.svelte +171 -0
  62. package/dist/components/select.svelte.d.ts +50 -0
  63. package/dist/components/slider.svelte +172 -0
  64. package/dist/components/slider.svelte.d.ts +44 -0
  65. package/dist/components/switch.svelte +180 -0
  66. package/dist/components/switch.svelte.d.ts +27 -0
  67. package/dist/components/tabs.svelte +246 -0
  68. package/dist/components/tabs.svelte.d.ts +34 -0
  69. package/dist/index.d.ts +4 -0
  70. package/dist/index.js +3 -0
  71. package/dist/utilities.svelte.d.ts +24 -0
  72. package/dist/utilities.svelte.js +47 -0
  73. package/dist/vite.d.ts +51 -0
  74. package/dist/vite.js +157 -0
  75. package/package.json +2 -2
@@ -0,0 +1,175 @@
1
+ <script module lang="ts">
2
+ import { type PropColor, isComponent, isSnippet } from '../index.js';
3
+ import type { Snippet } from 'svelte';
4
+ import type { ClassNameValue } from 'tailwind-merge';
5
+ import { tv } from 'tailwind-variants';
6
+ import type { Component } from 'vitest-browser-svelte';
7
+
8
+ export type CheckboxProps = {
9
+ value?: boolean | 'intermediate';
10
+ color?: PropColor;
11
+ size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl';
12
+ disabled?: boolean;
13
+ icon?: string | Snippet | Component;
14
+ intermediateicon?: string | Snippet | Component;
15
+ label?: string | Snippet;
16
+ description?: string | Snippet;
17
+ required?: boolean;
18
+ indicator?: 'start' | 'end' | 'hidden';
19
+ as?: string;
20
+ ui?: {
21
+ root?: ClassNameValue;
22
+ container?: ClassNameValue;
23
+ icon?: ClassNameValue;
24
+ label?: ClassNameValue;
25
+ description?: ClassNameValue;
26
+ };
27
+ };
28
+ </script>
29
+
30
+ <script lang="ts">
31
+ let {
32
+ value = $bindable(false),
33
+ color = 'primary',
34
+ size = 'md',
35
+ disabled,
36
+ icon = 'i-lucide-check',
37
+ intermediateicon = 'i-lucide-minus',
38
+ label,
39
+ description,
40
+ required,
41
+ indicator = 'start',
42
+ as = 'div',
43
+ ui = {}
44
+ }: CheckboxProps = $props();
45
+ const id = $props.id();
46
+
47
+ const classes = $derived.by(() =>
48
+ tv({
49
+ slots: {
50
+ root: 'relative flex-inline gap-2',
51
+ container:
52
+ 'rounded-md border border-neutral-200 relative transition m-0.5 mr-0 grid place-items-center',
53
+ icon: 'pi text-white',
54
+ label: 'text-sm font-medium',
55
+ description: 'text-sm text-neutral-500'
56
+ },
57
+ variants: {
58
+ color: {
59
+ primary: {
60
+ container: [value && 'bg-primary-500 border-primary-500 text-primary-500']
61
+ },
62
+ surface: {
63
+ container: [value && 'bg-neutral-900 border-neutral-900 text-neutral-900']
64
+ },
65
+ info: {
66
+ container: [value && 'bg-info-500 border-info-500 text-info-500']
67
+ },
68
+ success: {
69
+ container: [value && 'bg-success-500 border-success-500 text-success-500']
70
+ },
71
+ warning: {
72
+ container: [value && 'bg-warning-500 border-warning-500 text-warning-500']
73
+ },
74
+ error: {
75
+ container: [value && 'bg-error-500 border-error-500 text-error-500']
76
+ }
77
+ },
78
+ size: {
79
+ xs: {
80
+ container: 'size-3',
81
+ icon: 'size-3'
82
+ },
83
+ sm: {
84
+ container: 'size-3.5',
85
+ icon: 'size-3.5'
86
+ },
87
+ md: {
88
+ container: 'size-4',
89
+ icon: 'size-4'
90
+ },
91
+ lg: {
92
+ container: 'size-4.5',
93
+ icon: 'size-4.5'
94
+ },
95
+ xl: {
96
+ container: 'size-5',
97
+ icon: 'size-5'
98
+ }
99
+ },
100
+ indicator: {
101
+ start: '',
102
+ end: {
103
+ root: 'flex-row-reverse'
104
+ },
105
+ hidden: {
106
+ container: 'hidden'
107
+ }
108
+ }
109
+ },
110
+ compoundVariants: []
111
+ })({ color, size, indicator })
112
+ );
113
+ </script>
114
+
115
+ <svelte:element
116
+ this={as}
117
+ data-state={value ? 'checked' : 'unchecked'}
118
+ class={classes.root({
119
+ class: [disabled && 'opacity-50', ui.root]
120
+ })}
121
+ >
122
+ <button
123
+ {id}
124
+ aria-label="checkbox"
125
+ class={classes.container({ class: [ui.container] })}
126
+ onclick={() => {
127
+ if (disabled) return;
128
+ if (value === 'intermediate') return (value = true);
129
+ value = !value;
130
+ }}
131
+ >
132
+ {@render Icon(icon, [value !== true && 'opacity-0'])}
133
+ {@render Icon(intermediateicon, [value !== 'intermediate' && 'opacity-0'])}
134
+ </button>
135
+
136
+ {#if label}
137
+ <div class="flex flex-col justify-start">
138
+ <label
139
+ for={id}
140
+ class={classes.label({
141
+ class: [required ? 'after:content-["*"] after:text-error-500' : '', ui.label]
142
+ })}
143
+ >
144
+ {#if typeof label === 'string'}
145
+ {label}
146
+ {:else}
147
+ {@render label()}
148
+ {/if}
149
+ </label>
150
+
151
+ {#if description}
152
+ <div class={classes.description({ class: ui.description })}>
153
+ {#if typeof description === 'string'}
154
+ {description}
155
+ {:else}
156
+ {@render description()}
157
+ {/if}
158
+ </div>
159
+ {/if}
160
+ </div>
161
+ {/if}
162
+ </svelte:element>
163
+
164
+ {#snippet Icon(ico?: CheckboxProps['icon'], icon_class?: ClassNameValue)}
165
+ <div class={['absolute', icon_class]}>
166
+ {#if typeof ico === 'string'}
167
+ <div class={classes.icon({ class: [ico, ui.icon] })}></div>
168
+ {:else if isSnippet(ico)}
169
+ {@render ico()}
170
+ {:else if isComponent(ico)}
171
+ {@const Iconn = ico}
172
+ <Iconn />
173
+ {/if}
174
+ </div>
175
+ {/snippet}
@@ -0,0 +1,27 @@
1
+ import { type PropColor } from '../index.js';
2
+ import type { Snippet } from 'svelte';
3
+ import type { ClassNameValue } from 'tailwind-merge';
4
+ import type { Component } from 'vitest-browser-svelte';
5
+ export type CheckboxProps = {
6
+ value?: boolean | 'intermediate';
7
+ color?: PropColor;
8
+ size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl';
9
+ disabled?: boolean;
10
+ icon?: string | Snippet | Component;
11
+ intermediateicon?: string | Snippet | Component;
12
+ label?: string | Snippet;
13
+ description?: string | Snippet;
14
+ required?: boolean;
15
+ indicator?: 'start' | 'end' | 'hidden';
16
+ as?: string;
17
+ ui?: {
18
+ root?: ClassNameValue;
19
+ container?: ClassNameValue;
20
+ icon?: ClassNameValue;
21
+ label?: ClassNameValue;
22
+ description?: ClassNameValue;
23
+ };
24
+ };
25
+ declare const Checkbox: import("svelte").Component<CheckboxProps, {}, "value">;
26
+ type Checkbox = ReturnType<typeof Checkbox>;
27
+ export default Checkbox;
@@ -0,0 +1,82 @@
1
+ <script module lang="ts">
2
+ import type { PropColor } from '../index.js';
3
+ import type { Snippet } from 'svelte';
4
+ import type { ClassNameValue } from 'tailwind-merge';
5
+ import { tv } from 'tailwind-variants';
6
+
7
+ export type ChipProps = {
8
+ children: Snippet;
9
+ text?: string;
10
+ color?: PropColor;
11
+ position?: 'top-left' | 'top-right' | 'bottom-right' | 'bottom-left';
12
+ size?: number;
13
+ ui?: {
14
+ base?: ClassNameValue;
15
+ chip?: ClassNameValue;
16
+ };
17
+ };
18
+ </script>
19
+
20
+ <script lang="ts">
21
+ let {
22
+ children,
23
+ text,
24
+ color = 'primary',
25
+ position = 'top-right',
26
+ size = 8,
27
+ ui = {}
28
+ }: ChipProps = $props();
29
+
30
+ const classes = $derived.by(() =>
31
+ tv({
32
+ slots: {
33
+ base: 'relative inline-flex items-center justify-center shrink-0',
34
+ chip: [
35
+ 'absolute rounded-full ring ring-white flex items-center justify-center text-white font-medium whitespace-nowrap',
36
+ '-translate-y-1/2 translate-x-1/2 px-0.5'
37
+ ]
38
+ },
39
+ variants: {
40
+ color: {
41
+ primary: {
42
+ chip: 'bg-primary'
43
+ },
44
+ surface: {
45
+ chip: 'bg-surface'
46
+ },
47
+ success: {
48
+ chip: 'bg-success'
49
+ },
50
+ info: {
51
+ chip: 'bg-info'
52
+ },
53
+ warning: {
54
+ chip: 'bg-warning'
55
+ },
56
+ error: {
57
+ chip: 'bg-error'
58
+ }
59
+ },
60
+ position: {
61
+ 'top-right': { chip: 'top-0 right-0' },
62
+ 'bottom-right': { chip: 'bottom-0 right-0' },
63
+ 'top-left': { chip: 'top-0 left-0' },
64
+ 'bottom-left': { chip: 'bottom-0 left-0' }
65
+ }
66
+ }
67
+ })({ color, position })
68
+ );
69
+ </script>
70
+
71
+ <div class={classes.base({ class: [ui.base] })}>
72
+ {@render children()}
73
+
74
+ <span
75
+ class={classes.chip({ class: ui.chip })}
76
+ style:height="{size}px"
77
+ style:min-width="{size}px"
78
+ style:font-size="{size}px"
79
+ >
80
+ {text}
81
+ </span>
82
+ </div>
@@ -0,0 +1,17 @@
1
+ import type { PropColor } from '../index.js';
2
+ import type { Snippet } from 'svelte';
3
+ import type { ClassNameValue } from 'tailwind-merge';
4
+ export type ChipProps = {
5
+ children: Snippet;
6
+ text?: string;
7
+ color?: PropColor;
8
+ position?: 'top-left' | 'top-right' | 'bottom-right' | 'bottom-left';
9
+ size?: number;
10
+ ui?: {
11
+ base?: ClassNameValue;
12
+ chip?: ClassNameValue;
13
+ };
14
+ };
15
+ declare const Chip: import("svelte").Component<ChipProps, {}, "">;
16
+ type Chip = ReturnType<typeof Chip>;
17
+ export default Chip;
@@ -0,0 +1,48 @@
1
+ <script module lang="ts">
2
+ import { ColorTranslator } from 'colortranslator';
3
+ import { tv } from 'tailwind-variants';
4
+
5
+ export type ColorPickerProps = {
6
+ throttle?: number;
7
+ disabled?: boolean;
8
+ value?: string;
9
+ format?: 'hex' | 'rgb' | 'hsl' | 'cmyk' | 'lab';
10
+ size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl';
11
+ };
12
+ </script>
13
+
14
+ <script lang="ts">
15
+ let {
16
+ throttle = 50,
17
+ disabled,
18
+ value = $bindable('#FFF'),
19
+ format = 'hex',
20
+ size = 'md',
21
+ }: ColorPickerProps = $props();
22
+
23
+ const translated = $derived(new ColorTranslator(value));
24
+
25
+ const classes = $derived(
26
+ tv({
27
+ slots: {
28
+ root: '',
29
+ picker: '',
30
+ select: '',
31
+ track: '',
32
+ thumb: '',
33
+ },
34
+ variants: {
35
+ size: {
36
+ xs: {},
37
+ sm: {},
38
+ md: {},
39
+ lg: {},
40
+ xl: {},
41
+ },
42
+ },
43
+ })({ size }),
44
+ );
45
+ </script>
46
+
47
+ <!-- linear-gradient(0deg,red,#f0f 17%,#00f 33%,#0ff,#0f0 67%,#ff0 83%,red) -->
48
+ <div></div>
@@ -0,0 +1,10 @@
1
+ export type ColorPickerProps = {
2
+ throttle?: number;
3
+ disabled?: boolean;
4
+ value?: string;
5
+ format?: 'hex' | 'rgb' | 'hsl' | 'cmyk' | 'lab';
6
+ size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl';
7
+ };
8
+ declare const ColorPicker: import("svelte").Component<ColorPickerProps, {}, "value">;
9
+ type ColorPicker = ReturnType<typeof ColorPicker>;
10
+ export default ColorPicker;
@@ -0,0 +1,15 @@
1
+ <script lang="ts">
2
+ import type { SvelteHTMLElements } from 'svelte/elements';
3
+ import { cn } from 'tailwind-variants';
4
+ const { children, class: classes, ...rest }: SvelteHTMLElements['h1'] = $props();
5
+ </script>
6
+
7
+ <h1
8
+ {...rest}
9
+ class={cn(
10
+ 'text-4xl font-bold mb-8 scroll-mt-[calc(45px+var(--ui-header-height))] lg:scroll-mt-(--ui-header-height)',
11
+ classes,
12
+ )}
13
+ >
14
+ {@render children?.()}
15
+ </h1>
@@ -0,0 +1,3 @@
1
+ declare const H1: import("svelte").Component<import("svelte/elements").HTMLAttributes<HTMLHeadingElement>, {}, "">;
2
+ type H1 = ReturnType<typeof H1>;
3
+ export default H1;
@@ -0,0 +1,19 @@
1
+ <script lang="ts">
2
+ import type { SvelteHTMLElements } from 'svelte/elements';
3
+ import { cn } from 'tailwind-variants';
4
+ const { children, class: classes, ...rest }: SvelteHTMLElements['h2'] = $props();
5
+ </script>
6
+
7
+ <h2
8
+ {...rest}
9
+ class={cn(
10
+ 'relative text-2xl text-highlighted font-bold mt-12 mb-6',
11
+ 'scroll-mt-[calc(48px+45px+var(--ui-header-height))] lg:scroll-mt-[calc(48px+var(--ui-header-height))]',
12
+ '[&>a]:(focus-visible:outline-primary)',
13
+ '[&>a>code]:(transition-colors border-dashed font-bold text-xl/7)',
14
+ 'hover:[&>a>code]:(border-primary text-primary)',
15
+ classes,
16
+ )}
17
+ >
18
+ {@render children?.()}
19
+ </h2>
@@ -0,0 +1,3 @@
1
+ declare const H2: import("svelte").Component<import("svelte/elements").HTMLAttributes<HTMLHeadingElement>, {}, "">;
2
+ type H2 = ReturnType<typeof H2>;
3
+ export default H2;
@@ -0,0 +1,16 @@
1
+ <script lang="ts">
2
+ import type { SvelteHTMLElements } from 'svelte/elements';
3
+ import { cn } from 'tailwind-variants';
4
+ const { children, class: classes, ...rest }: SvelteHTMLElements['h3'] = $props();
5
+ </script>
6
+
7
+ <h3
8
+ {...rest}
9
+ class={cn(
10
+ 'relative text-xl text-highlighted font-bold mt-8 mb-3 scroll-mt-[calc(32px+45px+var(--ui-header-height))] lg:scroll-mt-[calc(32px+var(--ui-header-height))] [&>a]:focus-visible:outline-primary [&>a>code]:border-dashed hover:[&>a>code]:border-primary hover:[&>a>code]:text-primary [&>a>code]:text-lg/6 [&>a>code]:font-bold',
11
+ '[&>a>code]:transition-colors',
12
+ classes,
13
+ )}
14
+ >
15
+ {@render children?.()}
16
+ </h3>
@@ -0,0 +1,3 @@
1
+ declare const H3: import("svelte").Component<import("svelte/elements").HTMLAttributes<HTMLHeadingElement>, {}, "">;
2
+ type H3 = ReturnType<typeof H3>;
3
+ export default H3;
@@ -0,0 +1,19 @@
1
+ <script lang="ts">
2
+ import type { SvelteHTMLElements } from 'svelte/elements';
3
+ import { cn } from 'tailwind-variants';
4
+ const { children, class: classes, ...rest }: SvelteHTMLElements['h4'] = $props();
5
+ </script>
6
+
7
+ <h4
8
+ {...rest}
9
+ class={cn(
10
+ 'relative text-2xl text-highlighted font-bold mt-12 mb-6',
11
+ 'scroll-mt-[calc(48px+45px+var(--ui-header-height))] lg:scroll-mt-[calc(48px+var(--ui-header-height))]',
12
+ 'hover:[&>a>code]:(border-primary text-primary)',
13
+ '[&>a>code]:(transition-colors text-xl/7 font-bold border-dashed)',
14
+ '[&>a]:focus-visible:outline-primary',
15
+ classes,
16
+ )}
17
+ >
18
+ {@render children?.()}
19
+ </h4>
@@ -0,0 +1,3 @@
1
+ declare const H4: import("svelte").Component<import("svelte/elements").HTMLAttributes<HTMLHeadingElement>, {}, "">;
2
+ type H4 = ReturnType<typeof H4>;
3
+ export default H4;
@@ -0,0 +1,19 @@
1
+ <script lang="ts">
2
+ import type { SvelteHTMLElements } from 'svelte/elements';
3
+ import { cn } from 'tailwind-variants';
4
+ const { children, class: classes, ...rest }: SvelteHTMLElements['h5'] = $props();
5
+ </script>
6
+
7
+ <h5
8
+ {...rest}
9
+ class={cn(
10
+ 'relative text-2xl text-highlighted font-bold mt-12 mb-6',
11
+ 'scroll-mt-[calc(48px+45px+var(--ui-header-height))] lg:scroll-mt-[calc(48px+var(--ui-header-height))]',
12
+ 'hover:[&>a>code]:(border-primary text-primary)',
13
+ '[&>a>code]:(transition-colors text-xl/7 font-bold border-dashed)',
14
+ '[&>a]:focus-visible:outline-primary',
15
+ classes,
16
+ )}
17
+ >
18
+ {@render children?.()}
19
+ </h5>
@@ -0,0 +1,3 @@
1
+ declare const H5: import("svelte").Component<import("svelte/elements").HTMLAttributes<HTMLHeadingElement>, {}, "">;
2
+ type H5 = ReturnType<typeof H5>;
3
+ export default H5;
@@ -0,0 +1,19 @@
1
+ <script lang="ts">
2
+ import type { SvelteHTMLElements } from 'svelte/elements';
3
+ import { cn } from 'tailwind-variants';
4
+ const { children, class: classes, ...rest }: SvelteHTMLElements['h6'] = $props();
5
+ </script>
6
+
7
+ <h6
8
+ {...rest}
9
+ class={cn(
10
+ 'relative text-2xl text-highlighted font-bold mt-12 mb-6',
11
+ 'scroll-mt-[calc(48px+45px+var(--ui-header-height))] lg:scroll-mt-[calc(48px+var(--ui-header-height))]',
12
+ 'hover:[&>a>code]:(border-primary text-primary)',
13
+ '[&>a>code]:(transition-colors text-xl/7 font-bold border-dashed)',
14
+ '[&>a]:focus-visible:outline-primary',
15
+ classes,
16
+ )}
17
+ >
18
+ {@render children?.()}
19
+ </h6>
@@ -0,0 +1,3 @@
1
+ declare const H6: import("svelte").Component<import("svelte/elements").HTMLAttributes<HTMLHeadingElement>, {}, "">;
2
+ type H6 = ReturnType<typeof H6>;
3
+ export default H6;
@@ -0,0 +1,42 @@
1
+ export * from './button/index.js';
2
+ export * from './input/index.js';
3
+ export * from './input-time/index.js';
4
+ export * from './badge.svelte';
5
+ export { default as Badge } from './badge.svelte';
6
+ export * from './alert.svelte';
7
+ export { default as Alert } from './alert.svelte';
8
+ export * from './banner.svelte';
9
+ export { default as Banner } from './banner.svelte';
10
+ export * from './progress.svelte';
11
+ export { default as Progress } from './progress.svelte';
12
+ export * from './card.svelte';
13
+ export { default as Card } from './card.svelte';
14
+ export * from './chip.svelte';
15
+ export { default as Chip } from './chip.svelte';
16
+ export * from './switch.svelte';
17
+ export { default as Switch } from './switch.svelte';
18
+ export * from './slider.svelte';
19
+ export { default as Slider } from './slider.svelte';
20
+ export * from './checkbox.svelte';
21
+ export { default as Checkbox } from './checkbox.svelte';
22
+ export * from './checkbox-group.svelte';
23
+ export { default as CheckboxGroup } from './checkbox-group.svelte';
24
+ export { default as H1 } from './h1.svelte';
25
+ export { default as H2 } from './h2.svelte';
26
+ export { default as H3 } from './h3.svelte';
27
+ export { default as H4 } from './h4.svelte';
28
+ export { default as H5 } from './h5.svelte';
29
+ export { default as H6 } from './h6.svelte';
30
+ export { default as P } from './p.svelte';
31
+ export * from './pin-input.svelte';
32
+ export { default as PinInput } from './pin-input.svelte';
33
+ export * from './accordion.svelte';
34
+ export { default as Accordion } from './accordion.svelte';
35
+ export * from './kbd.svelte';
36
+ export { default as Kbd } from './kbd.svelte';
37
+ export * from './tabs.svelte';
38
+ export { default as Tabs } from './tabs.svelte';
39
+ export * from './color-picker.svelte';
40
+ export { default as ColorPicker } from './color-picker.svelte';
41
+ export * from './select.svelte';
42
+ export { default as Select } from './select.svelte';
@@ -0,0 +1,42 @@
1
+ export * from './button/index.js';
2
+ export * from './input/index.js';
3
+ export * from './input-time/index.js';
4
+ export * from './badge.svelte';
5
+ export { default as Badge } from './badge.svelte';
6
+ export * from './alert.svelte';
7
+ export { default as Alert } from './alert.svelte';
8
+ export * from './banner.svelte';
9
+ export { default as Banner } from './banner.svelte';
10
+ export * from './progress.svelte';
11
+ export { default as Progress } from './progress.svelte';
12
+ export * from './card.svelte';
13
+ export { default as Card } from './card.svelte';
14
+ export * from './chip.svelte';
15
+ export { default as Chip } from './chip.svelte';
16
+ export * from './switch.svelte';
17
+ export { default as Switch } from './switch.svelte';
18
+ export * from './slider.svelte';
19
+ export { default as Slider } from './slider.svelte';
20
+ export * from './checkbox.svelte';
21
+ export { default as Checkbox } from './checkbox.svelte';
22
+ export * from './checkbox-group.svelte';
23
+ export { default as CheckboxGroup } from './checkbox-group.svelte';
24
+ export { default as H1 } from './h1.svelte';
25
+ export { default as H2 } from './h2.svelte';
26
+ export { default as H3 } from './h3.svelte';
27
+ export { default as H4 } from './h4.svelte';
28
+ export { default as H5 } from './h5.svelte';
29
+ export { default as H6 } from './h6.svelte';
30
+ export { default as P } from './p.svelte';
31
+ export * from './pin-input.svelte';
32
+ export { default as PinInput } from './pin-input.svelte';
33
+ export * from './accordion.svelte';
34
+ export { default as Accordion } from './accordion.svelte';
35
+ export * from './kbd.svelte';
36
+ export { default as Kbd } from './kbd.svelte';
37
+ export * from './tabs.svelte';
38
+ export { default as Tabs } from './tabs.svelte';
39
+ export * from './color-picker.svelte';
40
+ export { default as ColorPicker } from './color-picker.svelte';
41
+ export * from './select.svelte';
42
+ export { default as Select } from './select.svelte';
@@ -0,0 +1,54 @@
1
+ import type { PropColor } from '../../index.js';
2
+ import type { Component, Snippet } from 'svelte';
3
+ import type { SvelteHTMLElements } from 'svelte/elements';
4
+ import type { ClassNameValue } from 'tailwind-merge';
5
+ import type { MaskInputOptions } from 'maska';
6
+ export { default as Input } from './input.svelte';
7
+ export * from './style.js';
8
+ export type InputProps = Omit<SvelteHTMLElements['input'], 'size'> & {
9
+ name?: string;
10
+ /**
11
+ * The placeholder text when the input is empty.
12
+ */
13
+ placeholder?: string;
14
+ /**
15
+ * @default primary
16
+ */
17
+ color?: PropColor;
18
+ /**
19
+ * @default outline
20
+ */
21
+ variant?: 'outline' | 'soft' | 'subtle' | 'ghost' | 'none';
22
+ /**
23
+ * @default md
24
+ */
25
+ size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl';
26
+ /**
27
+ * @default off
28
+ */
29
+ autocomplete?: 'on' | 'off';
30
+ /**
31
+ * @default false
32
+ */
33
+ autofocus?: boolean | number;
34
+ disabled?: boolean;
35
+ /**
36
+ * Highlight the ring color like a focus state.
37
+ */
38
+ highlight?: boolean;
39
+ value?: string;
40
+ icon?: string | Snippet | Component;
41
+ iconposition?: 'leading' | 'trailing';
42
+ leading?: string | Snippet | Component;
43
+ trailing?: string | Snippet | Component;
44
+ loading?: boolean;
45
+ loadingicon?: string | Snippet | Component;
46
+ mask?: string | MaskInputOptions;
47
+ ui?: {
48
+ root?: ClassNameValue;
49
+ base?: ClassNameValue;
50
+ leading?: ClassNameValue;
51
+ icon?: ClassNameValue;
52
+ trailing?: ClassNameValue;
53
+ };
54
+ };
@@ -0,0 +1,2 @@
1
+ export { default as Input } from './input.svelte';
2
+ export * from './style.js';