ui-svelte 0.2.11 → 0.2.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.
- package/README.md +2 -2
- package/dist/charts/ArcChart.svelte +9 -14
- package/dist/charts/ArcChart.svelte.d.ts +3 -3
- package/dist/charts/AreaChart.svelte +347 -118
- package/dist/charts/AreaChart.svelte.d.ts +33 -4
- package/dist/charts/BarChart.svelte +288 -66
- package/dist/charts/BarChart.svelte.d.ts +26 -1
- package/dist/charts/Candlestick.svelte +53 -50
- package/dist/charts/Candlestick.svelte.d.ts +8 -8
- package/dist/charts/LineChart.svelte +391 -91
- package/dist/charts/LineChart.svelte.d.ts +26 -3
- package/dist/charts/PieChart.svelte +333 -92
- package/dist/charts/PieChart.svelte.d.ts +33 -5
- package/dist/charts/css/arc-chart.css +3 -3
- package/dist/charts/css/area-chart.css +127 -29
- package/dist/charts/css/bar-chart.css +114 -8
- package/dist/charts/css/candlestick.css +2 -0
- package/dist/charts/css/line-chart.css +111 -13
- package/dist/charts/css/pie-chart.css +92 -20
- package/dist/control/Audio.svelte +86 -44
- package/dist/control/Audio.svelte.d.ts +4 -1
- package/dist/control/Button.svelte +18 -27
- package/dist/control/Button.svelte.d.ts +3 -2
- package/dist/control/Fab.svelte +103 -0
- package/dist/control/Fab.svelte.d.ts +25 -0
- package/dist/control/IconButton.svelte +17 -27
- package/dist/control/IconButton.svelte.d.ts +3 -3
- package/dist/control/Image.svelte +123 -0
- package/dist/control/Image.svelte.d.ts +13 -0
- package/dist/control/Record.svelte +141 -98
- package/dist/control/Record.svelte.d.ts +2 -1
- package/dist/control/ToggleGroup.svelte +22 -8
- package/dist/control/ToggleGroup.svelte.d.ts +2 -1
- package/dist/control/ToggleTheme.svelte +13 -11
- package/dist/control/ToggleTheme.svelte.d.ts +3 -2
- package/dist/control/Video.svelte +57 -29
- package/dist/control/Video.svelte.d.ts +1 -0
- package/dist/control/css/btn.css +200 -152
- package/dist/control/css/fab.css +84 -0
- package/dist/control/css/image.css +56 -0
- package/dist/control/css/media.css +95 -30
- package/dist/control/css/toggle-group.css +253 -84
- package/dist/control/css/video.css +1 -14
- package/dist/css/animations.css +5 -9
- package/dist/css/base.css +13 -347
- package/dist/css/decorations.css +561 -0
- package/dist/css/rich-text.css +485 -0
- package/dist/css/transitions.css +158 -0
- package/dist/css/typography.css +291 -0
- package/dist/css/utilities.css +0 -4
- package/dist/display/Accordion.svelte +28 -4
- package/dist/display/Accordion.svelte.d.ts +2 -1
- package/dist/display/Alert.svelte +32 -12
- package/dist/display/Alert.svelte.d.ts +2 -3
- package/dist/display/Avatar.svelte +23 -18
- package/dist/display/Avatar.svelte.d.ts +4 -1
- package/dist/display/AvatarGroup.svelte +20 -18
- package/dist/display/AvatarGroup.svelte.d.ts +6 -3
- package/dist/display/Badge.svelte +11 -4
- package/dist/display/Badge.svelte.d.ts +2 -1
- package/dist/display/Card.svelte +15 -14
- package/dist/display/Card.svelte.d.ts +2 -3
- package/dist/display/Carousel.svelte +130 -99
- package/dist/display/Carousel.svelte.d.ts +6 -4
- package/dist/display/ChatBox.svelte +245 -106
- package/dist/display/ChatBox.svelte.d.ts +32 -5
- package/dist/display/Chip.svelte +31 -17
- package/dist/display/Chip.svelte.d.ts +3 -2
- package/dist/display/Code.svelte +7 -4
- package/dist/display/Code.svelte.d.ts +1 -0
- package/dist/display/Collapsible.svelte +30 -4
- package/dist/display/Collapsible.svelte.d.ts +2 -1
- package/dist/display/Countdown.svelte +169 -0
- package/dist/display/Countdown.svelte.d.ts +21 -0
- package/dist/display/Empty.svelte +37 -3
- package/dist/display/Empty.svelte.d.ts +3 -0
- package/dist/display/Item.svelte +42 -11
- package/dist/display/Item.svelte.d.ts +4 -2
- package/dist/display/Map.svelte +488 -0
- package/dist/display/Map.svelte.d.ts +44 -0
- package/dist/display/Marquee.svelte +0 -2
- package/dist/display/Section.svelte +14 -12
- package/dist/display/Section.svelte.d.ts +2 -3
- package/dist/display/Skeleton.svelte +32 -0
- package/dist/display/Skeleton.svelte.d.ts +10 -0
- package/dist/display/Table.svelte +94 -132
- package/dist/display/Table.svelte.d.ts +10 -1
- package/dist/display/css/accordion.css +349 -52
- package/dist/display/css/alert.css +38 -18
- package/dist/display/css/avatar-group.css +38 -75
- package/dist/display/css/avatar.css +139 -121
- package/dist/display/css/badge.css +50 -27
- package/dist/display/css/card.css +123 -71
- package/dist/display/css/carousel.css +25 -5
- package/dist/display/css/chat-box.css +158 -26
- package/dist/display/css/chip.css +142 -68
- package/dist/display/css/code.css +2 -6
- package/dist/display/css/collapsible.css +349 -45
- package/dist/display/css/countdown.css +206 -0
- package/dist/display/css/divider.css +8 -6
- package/dist/display/css/empty.css +7 -0
- package/dist/display/css/item.css +330 -84
- package/dist/display/css/map.css +164 -0
- package/dist/display/css/marquee.css +0 -3
- package/dist/display/css/section.css +89 -65
- package/dist/display/css/skeleton.css +58 -0
- package/dist/display/css/table.css +309 -193
- package/dist/form/Checkbox.svelte +11 -5
- package/dist/form/Checkbox.svelte.d.ts +2 -1
- package/dist/form/ColorField.svelte +601 -0
- package/dist/form/ColorField.svelte.d.ts +29 -0
- package/dist/form/ComboBox.svelte +24 -9
- package/dist/form/ComboBox.svelte.d.ts +2 -2
- package/dist/form/CsvField.svelte +62 -136
- package/dist/form/CsvField.svelte.d.ts +2 -2
- package/dist/form/DateField.svelte +33 -15
- package/dist/form/DateField.svelte.d.ts +2 -1
- package/dist/form/DateRange.svelte +436 -0
- package/dist/form/DateRange.svelte.d.ts +24 -0
- package/dist/form/DragDrop.svelte +578 -0
- package/dist/form/DragDrop.svelte.d.ts +33 -0
- package/dist/form/Dropzone.svelte +28 -8
- package/dist/form/Dropzone.svelte.d.ts +2 -2
- package/dist/form/Editor.svelte +626 -0
- package/dist/form/Editor.svelte.d.ts +50 -0
- package/dist/form/ImageCropper.svelte +422 -61
- package/dist/form/ImageCropper.svelte.d.ts +15 -1
- package/dist/form/{PasswordStrength.svelte → PasswordField.svelte} +58 -24
- package/dist/form/{PasswordStrength.svelte.d.ts → PasswordField.svelte.d.ts} +6 -5
- package/dist/form/PhoneField.svelte +26 -14
- package/dist/form/PhoneField.svelte.d.ts +4 -3
- package/dist/form/PinField.svelte +39 -31
- package/dist/form/PinField.svelte.d.ts +3 -3
- package/dist/form/RadioGroup.svelte +9 -5
- package/dist/form/RadioGroup.svelte.d.ts +1 -1
- package/dist/form/Select.svelte +20 -19
- package/dist/form/Select.svelte.d.ts +2 -2
- package/dist/form/Slider.svelte +10 -4
- package/dist/form/Slider.svelte.d.ts +2 -1
- package/dist/form/TextField.svelte +29 -11
- package/dist/form/TextField.svelte.d.ts +5 -4
- package/dist/form/Textarea.svelte +15 -6
- package/dist/form/Textarea.svelte.d.ts +2 -2
- package/dist/form/Toggle.svelte +7 -3
- package/dist/form/Toggle.svelte.d.ts +1 -1
- package/dist/form/css/checkbox.css +18 -2
- package/dist/form/css/color-field.css +141 -0
- package/dist/form/css/control.css +193 -82
- package/dist/form/css/csv-field.css +221 -0
- package/dist/form/css/date-range.css +122 -0
- package/dist/form/css/date.css +24 -2
- package/dist/form/css/drag-drop.css +234 -0
- package/dist/form/css/dropzone.css +153 -34
- package/dist/form/css/editor.css +367 -0
- package/dist/form/css/field.css +4 -0
- package/dist/form/css/image-cropper.css +242 -20
- package/dist/form/css/radio-group.css +26 -1
- package/dist/form/css/select.css +2 -2
- package/dist/form/css/slider.css +37 -0
- package/dist/form/css/textarea.css +178 -75
- package/dist/form/css/toggle.css +15 -3
- package/dist/hooks/use-chat.svelte.js +1 -1
- package/dist/hooks/use-form.svelte.js +3 -3
- package/dist/hooks/use-search.svelte.js +0 -3
- package/dist/hooks/use-table.svelte.d.ts +1 -0
- package/dist/hooks/use-table.svelte.js +6 -0
- package/dist/icons/index.d.ts +34 -2
- package/dist/icons/index.js +36 -4
- package/dist/index.css +44 -49
- package/dist/index.d.ts +14 -4
- package/dist/index.js +13 -3
- package/dist/layout/AppBar.svelte +22 -14
- package/dist/layout/AppBar.svelte.d.ts +2 -1
- package/dist/layout/Footer.svelte +19 -11
- package/dist/layout/Footer.svelte.d.ts +2 -1
- package/dist/layout/Provider.svelte +32 -9
- package/dist/layout/Provider.svelte.d.ts +3 -1
- package/dist/layout/Sidebar.svelte +17 -8
- package/dist/layout/Sidebar.svelte.d.ts +2 -1
- package/dist/layout/css/app-bar.css +63 -66
- package/dist/layout/css/footer.css +62 -65
- package/dist/layout/css/sidebar.css +120 -59
- package/dist/navigation/BottomNav.svelte +51 -14
- package/dist/navigation/FooterGroup.svelte +1 -1
- package/dist/navigation/NavMenu.svelte +47 -23
- package/dist/navigation/NavMenu.svelte.d.ts +29 -0
- package/dist/navigation/Pagination.svelte +158 -0
- package/dist/navigation/Pagination.svelte.d.ts +18 -0
- package/dist/navigation/SideNav.svelte +30 -25
- package/dist/navigation/SideNav.svelte.d.ts +2 -3
- package/dist/navigation/Tabs.svelte +17 -7
- package/dist/navigation/Tabs.svelte.d.ts +2 -2
- package/dist/navigation/css/bottom-nav.css +319 -257
- package/dist/navigation/css/footer-group.css +1 -1
- package/dist/navigation/css/footer-nav.css +1 -1
- package/dist/navigation/css/nav-menu.css +331 -106
- package/dist/navigation/css/pagination.css +74 -0
- package/dist/navigation/css/side-nav.css +514 -75
- package/dist/navigation/css/tabs.css +246 -52
- package/dist/overlay/AlertDialog.svelte +58 -0
- package/dist/overlay/AlertDialog.svelte.d.ts +14 -25
- package/dist/overlay/Command.svelte +347 -0
- package/dist/overlay/Command.svelte.d.ts +33 -25
- package/dist/overlay/Drawer.svelte +49 -21
- package/dist/overlay/Drawer.svelte.d.ts +2 -2
- package/dist/overlay/Dropdown.svelte +3 -3
- package/dist/overlay/Modal.svelte +51 -16
- package/dist/overlay/Modal.svelte.d.ts +3 -3
- package/dist/overlay/Toast.svelte +41 -17
- package/dist/overlay/Toast.svelte.d.ts +1 -1
- package/dist/overlay/Tooltip.svelte +36 -27
- package/dist/overlay/Tooltip.svelte.d.ts +2 -2
- package/dist/overlay/css/command.css +68 -0
- package/dist/overlay/css/drawer.css +63 -24
- package/dist/overlay/css/dropdown.css +1 -1
- package/dist/overlay/css/hovercard.css +1 -1
- package/dist/overlay/css/modal.css +79 -27
- package/dist/overlay/css/toast.css +40 -24
- package/dist/overlay/css/tooltip.css +110 -67
- package/dist/stores/theme.svelte.js +44 -12
- package/dist/stores/toast.svelte.d.ts +4 -4
- package/dist/stores/toast.svelte.js +2 -2
- package/package.json +1 -1
- package/dist/utils/charts.d.ts +0 -27
- package/dist/utils/charts.js +0 -140
package/dist/form/css/select.css
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
@layer components {
|
|
2
2
|
.select-popover {
|
|
3
|
-
@apply max-h-56 flex flex-col gap-2 p-2 my-1 overflow-hidden;
|
|
4
|
-
@apply bg-background text-on-background rounded-
|
|
3
|
+
@apply max-h-56 flex flex-col gap-2 p-2 my-1 overflow-hidden w-full;
|
|
4
|
+
@apply bg-background text-on-background rounded-box;
|
|
5
5
|
@apply invisible opacity-0 transition-opacity duration-300 ease-in-out;
|
|
6
6
|
@apply shadow shadow-muted;
|
|
7
7
|
position: fixed;
|
package/dist/form/css/slider.css
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
@layer components {
|
|
2
2
|
.slider-wrapper {
|
|
3
3
|
@apply flex flex-col gap-0.5 w-full;
|
|
4
|
+
@apply transition-all duration-300;
|
|
4
5
|
}
|
|
5
6
|
.slider-info {
|
|
6
7
|
@apply flex justify-between items-center text-sm font-medium leading-none;
|
|
@@ -49,6 +50,42 @@
|
|
|
49
50
|
@apply bg-on-muted;
|
|
50
51
|
}
|
|
51
52
|
}
|
|
53
|
+
&.is-success {
|
|
54
|
+
--slider-color: var(--color-success);
|
|
55
|
+
&::-webkit-slider-thumb {
|
|
56
|
+
@apply bg-success;
|
|
57
|
+
}
|
|
58
|
+
&::-moz-range-thumb {
|
|
59
|
+
@apply bg-success;
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
&.is-info {
|
|
63
|
+
--slider-color: var(--color-info);
|
|
64
|
+
&::-webkit-slider-thumb {
|
|
65
|
+
@apply bg-info;
|
|
66
|
+
}
|
|
67
|
+
&::-moz-range-thumb {
|
|
68
|
+
@apply bg-info;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
&.is-warning {
|
|
72
|
+
--slider-color: var(--color-warning);
|
|
73
|
+
&::-webkit-slider-thumb {
|
|
74
|
+
@apply bg-warning;
|
|
75
|
+
}
|
|
76
|
+
&::-moz-range-thumb {
|
|
77
|
+
@apply bg-warning;
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
&.is-danger {
|
|
81
|
+
--slider-color: var(--color-danger);
|
|
82
|
+
&::-webkit-slider-thumb {
|
|
83
|
+
@apply bg-danger;
|
|
84
|
+
}
|
|
85
|
+
&::-moz-range-thumb {
|
|
86
|
+
@apply bg-danger;
|
|
87
|
+
}
|
|
88
|
+
}
|
|
52
89
|
&.is-sm {
|
|
53
90
|
@apply h-1 my-1;
|
|
54
91
|
&::-webkit-slider-thumb {
|
|
@@ -7,124 +7,227 @@
|
|
|
7
7
|
.textarea-control-label {
|
|
8
8
|
@apply absolute left-3 top-3;
|
|
9
9
|
@apply transition-all duration-300;
|
|
10
|
-
}
|
|
11
10
|
|
|
12
|
-
|
|
13
|
-
|
|
11
|
+
&.is-active {
|
|
12
|
+
@apply text-xs left-3 top-1 translate-y-px!;
|
|
13
|
+
}
|
|
14
14
|
}
|
|
15
15
|
|
|
16
|
-
.textarea-control
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
.textarea-control {
|
|
17
|
+
&.is-sm {
|
|
18
|
+
@apply text-sm py-2;
|
|
19
|
+
}
|
|
19
20
|
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
21
|
+
&.is-md {
|
|
22
|
+
@apply text-base py-2.5;
|
|
23
|
+
}
|
|
23
24
|
|
|
24
|
-
|
|
25
|
-
|
|
25
|
+
&.is-lg {
|
|
26
|
+
@apply text-xl py-3;
|
|
26
27
|
|
|
27
|
-
|
|
28
|
-
|
|
28
|
+
.textarea-control-label.is-active {
|
|
29
|
+
@apply text-sm;
|
|
30
|
+
}
|
|
29
31
|
}
|
|
30
|
-
}
|
|
31
32
|
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
33
|
+
&.is-float {
|
|
34
|
+
&.is-sm {
|
|
35
|
+
@apply pt-5 pb-2;
|
|
36
|
+
}
|
|
35
37
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
38
|
+
&.is-md {
|
|
39
|
+
@apply pt-6 pb-2.5;
|
|
40
|
+
}
|
|
39
41
|
|
|
40
|
-
|
|
41
|
-
|
|
42
|
+
&.is-lg {
|
|
43
|
+
@apply pt-7 pb-3;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
42
46
|
}
|
|
43
47
|
|
|
44
|
-
.textarea-control.is-
|
|
45
|
-
@apply
|
|
46
|
-
}
|
|
48
|
+
.textarea-control.is-soft {
|
|
49
|
+
@apply rounded-ui;
|
|
47
50
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
+
&.is-primary {
|
|
52
|
+
@apply bg-soft-primary text-primary;
|
|
53
|
+
&.is-active {
|
|
54
|
+
@apply bg-soft-primary/90;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
51
57
|
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
58
|
+
&.is-secondary {
|
|
59
|
+
@apply bg-soft-secondary text-secondary;
|
|
60
|
+
&.is-active {
|
|
61
|
+
@apply bg-soft-secondary/90;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
55
64
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
65
|
+
&.is-muted {
|
|
66
|
+
@apply bg-soft-muted text-on-muted;
|
|
67
|
+
&.is-active {
|
|
68
|
+
@apply bg-soft-muted/90;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
59
71
|
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
72
|
+
&.is-success {
|
|
73
|
+
@apply bg-soft-success text-success;
|
|
74
|
+
&.is-active {
|
|
75
|
+
@apply bg-soft-success/90;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
63
78
|
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
79
|
+
&.is-info {
|
|
80
|
+
@apply bg-soft-info text-info;
|
|
81
|
+
&.is-active {
|
|
82
|
+
@apply bg-soft-info/90;
|
|
83
|
+
}
|
|
84
|
+
}
|
|
67
85
|
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
86
|
+
&.is-danger {
|
|
87
|
+
@apply bg-soft-danger text-danger;
|
|
88
|
+
&.is-active {
|
|
89
|
+
@apply bg-soft-danger/90;
|
|
90
|
+
}
|
|
91
|
+
}
|
|
71
92
|
|
|
72
|
-
|
|
73
|
-
|
|
93
|
+
&.is-warning {
|
|
94
|
+
@apply bg-soft-warning text-warning;
|
|
95
|
+
&.is-active {
|
|
96
|
+
@apply bg-soft-warning/90;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
74
99
|
}
|
|
75
100
|
|
|
76
|
-
.textarea-control.is-
|
|
77
|
-
@apply
|
|
78
|
-
}
|
|
101
|
+
.textarea-control.is-solid {
|
|
102
|
+
@apply rounded-ui;
|
|
79
103
|
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
104
|
+
&.is-primary {
|
|
105
|
+
@apply bg-primary text-on-primary;
|
|
106
|
+
&.is-active {
|
|
107
|
+
@apply bg-primary/90;
|
|
108
|
+
}
|
|
109
|
+
}
|
|
83
110
|
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
111
|
+
&.is-secondary {
|
|
112
|
+
@apply bg-secondary text-on-secondary;
|
|
113
|
+
&.is-active {
|
|
114
|
+
@apply bg-secondary/90;
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
&.is-muted {
|
|
119
|
+
@apply bg-on-muted text-muted;
|
|
120
|
+
&.is-active {
|
|
121
|
+
@apply bg-on-muted/90;
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
&.is-success {
|
|
126
|
+
@apply bg-success text-on-success;
|
|
127
|
+
&.is-active {
|
|
128
|
+
@apply bg-success/90;
|
|
129
|
+
}
|
|
130
|
+
}
|
|
87
131
|
|
|
88
|
-
|
|
89
|
-
|
|
132
|
+
&.is-info {
|
|
133
|
+
@apply bg-info text-on-info;
|
|
134
|
+
&.is-active {
|
|
135
|
+
@apply bg-info/90;
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
&.is-danger {
|
|
140
|
+
@apply bg-danger text-on-danger;
|
|
141
|
+
&.is-active {
|
|
142
|
+
@apply bg-danger/90;
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
&.is-warning {
|
|
147
|
+
@apply bg-warning text-on-warning;
|
|
148
|
+
&.is-active {
|
|
149
|
+
@apply bg-warning/90;
|
|
150
|
+
}
|
|
151
|
+
}
|
|
90
152
|
}
|
|
91
153
|
|
|
92
154
|
.textarea-control.is-outlined {
|
|
93
|
-
@apply
|
|
94
|
-
|
|
155
|
+
@apply rounded-ui inset-ring;
|
|
156
|
+
|
|
157
|
+
&.is-active {
|
|
158
|
+
@apply inset-ring-2;
|
|
159
|
+
}
|
|
95
160
|
|
|
96
|
-
|
|
97
|
-
|
|
161
|
+
&.is-primary {
|
|
162
|
+
@apply inset-ring-primary;
|
|
163
|
+
}
|
|
164
|
+
&.is-secondary {
|
|
165
|
+
@apply inset-ring-secondary;
|
|
166
|
+
}
|
|
167
|
+
&.is-muted {
|
|
168
|
+
@apply inset-ring-muted;
|
|
169
|
+
}
|
|
170
|
+
&.is-success {
|
|
171
|
+
@apply inset-ring-success;
|
|
172
|
+
}
|
|
173
|
+
&.is-info {
|
|
174
|
+
@apply inset-ring-info;
|
|
175
|
+
}
|
|
176
|
+
&.is-danger {
|
|
177
|
+
@apply inset-ring-danger;
|
|
178
|
+
}
|
|
179
|
+
&.is-warning {
|
|
180
|
+
@apply inset-ring-warning;
|
|
181
|
+
}
|
|
98
182
|
}
|
|
99
183
|
|
|
100
184
|
.textarea-control.is-line {
|
|
101
|
-
@apply box-border border-b
|
|
185
|
+
@apply box-border border-b px-0;
|
|
102
186
|
|
|
103
187
|
.textarea-control-label {
|
|
104
188
|
@apply left-0!;
|
|
105
189
|
}
|
|
106
|
-
}
|
|
107
190
|
|
|
108
|
-
|
|
109
|
-
|
|
191
|
+
&.is-active {
|
|
192
|
+
@apply border-b-2;
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
&.is-primary {
|
|
196
|
+
@apply border-primary text-primary;
|
|
197
|
+
}
|
|
198
|
+
&.is-secondary {
|
|
199
|
+
@apply border-secondary text-secondary;
|
|
200
|
+
}
|
|
201
|
+
&.is-muted {
|
|
202
|
+
@apply border-on-muted text-on-muted;
|
|
203
|
+
}
|
|
204
|
+
&.is-success {
|
|
205
|
+
@apply border-success text-success;
|
|
206
|
+
}
|
|
207
|
+
&.is-info {
|
|
208
|
+
@apply border-info text-info;
|
|
209
|
+
}
|
|
210
|
+
&.is-danger {
|
|
211
|
+
@apply border-danger text-danger;
|
|
212
|
+
}
|
|
213
|
+
&.is-warning {
|
|
214
|
+
@apply border-warning text-warning;
|
|
215
|
+
}
|
|
110
216
|
}
|
|
111
217
|
|
|
112
218
|
.textarea-control-input {
|
|
113
219
|
@apply appearance-none flex-1 w-full border-none outline-none;
|
|
114
|
-
@apply placeholder:transition-opacity placeholder:duration-
|
|
220
|
+
@apply placeholder:transition-opacity placeholder:duration-300;
|
|
115
221
|
@apply bg-transparent;
|
|
116
222
|
@apply min-h-12;
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
.textarea-control-input.invisible {
|
|
120
|
-
@apply opacity-0;
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
.textarea-control-input {
|
|
124
223
|
resize: none;
|
|
125
|
-
}
|
|
126
224
|
|
|
127
|
-
|
|
128
|
-
|
|
225
|
+
&.invisible {
|
|
226
|
+
@apply opacity-0;
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
&.is-resizable {
|
|
230
|
+
resize: both;
|
|
231
|
+
}
|
|
129
232
|
}
|
|
130
233
|
}
|
package/dist/form/css/toggle.css
CHANGED
|
@@ -4,11 +4,11 @@
|
|
|
4
4
|
|
|
5
5
|
.toggle-input {
|
|
6
6
|
@apply relative appearance-none w-10 h-6 rounded-full;
|
|
7
|
-
@apply bg-muted transition-colors duration-
|
|
7
|
+
@apply bg-muted transition-colors duration-300 ease-in-out;
|
|
8
8
|
@apply focus:outline-none;
|
|
9
9
|
@apply before:content-[''] before:absolute before:h-4 before:w-4 before:left-1 before:top-1;
|
|
10
10
|
@apply before:bg-white before:rounded-full before:shadow;
|
|
11
|
-
@apply before:transition-transform before:duration-
|
|
11
|
+
@apply before:transition-transform before:duration-300 before:ease-in-out;
|
|
12
12
|
@apply checked:before:translate-x-4;
|
|
13
13
|
}
|
|
14
14
|
|
|
@@ -22,11 +22,23 @@
|
|
|
22
22
|
&.is-muted {
|
|
23
23
|
@apply bg-on-muted;
|
|
24
24
|
}
|
|
25
|
+
&.is-success {
|
|
26
|
+
@apply bg-success;
|
|
27
|
+
}
|
|
28
|
+
&.is-info {
|
|
29
|
+
@apply bg-info;
|
|
30
|
+
}
|
|
31
|
+
&.is-danger {
|
|
32
|
+
@apply bg-danger;
|
|
33
|
+
}
|
|
34
|
+
&.is-warning {
|
|
35
|
+
@apply bg-warning;
|
|
36
|
+
}
|
|
25
37
|
}
|
|
26
38
|
|
|
27
39
|
.toggle-label-left,
|
|
28
40
|
.toggle-label-right {
|
|
29
|
-
@apply text-muted transition-colors duration-
|
|
41
|
+
@apply text-muted transition-colors duration-300;
|
|
30
42
|
|
|
31
43
|
&.is-active {
|
|
32
44
|
@apply text-on-muted;
|
|
@@ -35,7 +35,7 @@ export const useChat = (config) => {
|
|
|
35
35
|
const loadedMessages = config.transformMessage
|
|
36
36
|
? data.messages.map(config.transformMessage)
|
|
37
37
|
: data.messages;
|
|
38
|
-
messages = loadedMessages.reverse();
|
|
38
|
+
messages = loadedMessages.reverse();
|
|
39
39
|
hasMore = data.hasMore ?? false;
|
|
40
40
|
if (messages.length > 0) {
|
|
41
41
|
oldestMessageId = messages[0].id;
|
|
@@ -36,7 +36,7 @@ export const useForm = (config) => {
|
|
|
36
36
|
toast.show({
|
|
37
37
|
title: config.errorTitle || 'Error',
|
|
38
38
|
description: config.errorDescription || 'An error occurred while submitting the form.',
|
|
39
|
-
|
|
39
|
+
color: 'danger',
|
|
40
40
|
duration: 3000
|
|
41
41
|
});
|
|
42
42
|
}
|
|
@@ -48,7 +48,7 @@ export const useForm = (config) => {
|
|
|
48
48
|
toast.show({
|
|
49
49
|
title: config.successTitle || 'Success',
|
|
50
50
|
description: config.successDescription || 'Form submitted successfully.',
|
|
51
|
-
|
|
51
|
+
color: 'success',
|
|
52
52
|
duration: 3000
|
|
53
53
|
});
|
|
54
54
|
}
|
|
@@ -63,7 +63,7 @@ export const useForm = (config) => {
|
|
|
63
63
|
toast.show({
|
|
64
64
|
title: config.errorTitle || 'Error',
|
|
65
65
|
description: config.errorDescription || 'An error occurred while submitting the form.',
|
|
66
|
-
|
|
66
|
+
color: 'danger',
|
|
67
67
|
duration: 3000
|
|
68
68
|
});
|
|
69
69
|
}
|
|
@@ -45,7 +45,6 @@ export const useSearch = (config) => {
|
|
|
45
45
|
(option.description && option.description.toLowerCase().includes(lowerSearch)));
|
|
46
46
|
});
|
|
47
47
|
}
|
|
48
|
-
// Client-side pagination
|
|
49
48
|
if (enablePagination) {
|
|
50
49
|
const start = 0;
|
|
51
50
|
const end = (currentPage + 1) * pageSize;
|
|
@@ -96,7 +95,6 @@ export const useSearch = (config) => {
|
|
|
96
95
|
else {
|
|
97
96
|
options = searchResponse.options;
|
|
98
97
|
}
|
|
99
|
-
// Determinar si hay más resultados
|
|
100
98
|
if (searchResponse.hasMore !== undefined) {
|
|
101
99
|
hasMore = searchResponse.hasMore;
|
|
102
100
|
}
|
|
@@ -105,7 +103,6 @@ export const useSearch = (config) => {
|
|
|
105
103
|
hasMore = options.length < searchResponse.total;
|
|
106
104
|
}
|
|
107
105
|
else {
|
|
108
|
-
// Si no hay info de total, asumimos que hay más si recibimos pageSize resultados
|
|
109
106
|
hasMore = searchResponse.options.length >= pageSize;
|
|
110
107
|
}
|
|
111
108
|
config.onSuccess?.(searchResponse);
|
|
@@ -9,6 +9,7 @@ export const useTable = (config) => {
|
|
|
9
9
|
let sortOrder = $state(config.initialSortOrder ?? 'ASC');
|
|
10
10
|
let search = $state(config.initialSearch ?? '');
|
|
11
11
|
let isLoading = $state(false);
|
|
12
|
+
let hasInitialized = $state(false);
|
|
12
13
|
let error = $state(null);
|
|
13
14
|
const selectable = config.selectable ?? false;
|
|
14
15
|
const rowKey = config.rowKey ?? 'id';
|
|
@@ -82,6 +83,7 @@ export const useTable = (config) => {
|
|
|
82
83
|
const startIndex = (page - 1) * pageSize;
|
|
83
84
|
const endIndex = startIndex + pageSize;
|
|
84
85
|
data = processedData.slice(startIndex, endIndex);
|
|
86
|
+
hasInitialized = true;
|
|
85
87
|
};
|
|
86
88
|
const fetchData = async () => {
|
|
87
89
|
if (isManualMode) {
|
|
@@ -125,6 +127,7 @@ export const useTable = (config) => {
|
|
|
125
127
|
catch (err) {
|
|
126
128
|
error = err;
|
|
127
129
|
config.onError?.(err);
|
|
130
|
+
hasInitialized = true;
|
|
128
131
|
}
|
|
129
132
|
finally {
|
|
130
133
|
isLoading = false;
|
|
@@ -307,6 +310,9 @@ export const useTable = (config) => {
|
|
|
307
310
|
get isLoading() {
|
|
308
311
|
return isLoading;
|
|
309
312
|
},
|
|
313
|
+
get hasInitialized() {
|
|
314
|
+
return hasInitialized;
|
|
315
|
+
},
|
|
310
316
|
get error() {
|
|
311
317
|
return error;
|
|
312
318
|
},
|
package/dist/icons/index.d.ts
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
export declare const Add24RegularIcon: {
|
|
2
|
+
body: string;
|
|
3
|
+
viewbox: string;
|
|
4
|
+
};
|
|
1
5
|
export declare const ArrowDown24RegularIcon: {
|
|
2
6
|
body: string;
|
|
3
7
|
viewbox: string;
|
|
@@ -90,7 +94,7 @@ export declare const SpeakerMute24RegularIcon: {
|
|
|
90
94
|
body: string;
|
|
91
95
|
viewbox: string;
|
|
92
96
|
};
|
|
93
|
-
export declare const
|
|
97
|
+
export declare const PauseFilledIcon: {
|
|
94
98
|
body: string;
|
|
95
99
|
viewbox: string;
|
|
96
100
|
};
|
|
@@ -98,7 +102,7 @@ export declare const PictureInPicture24RegularIcon: {
|
|
|
98
102
|
body: string;
|
|
99
103
|
viewbox: string;
|
|
100
104
|
};
|
|
101
|
-
export declare const
|
|
105
|
+
export declare const PlayFilledIcon: {
|
|
102
106
|
body: string;
|
|
103
107
|
viewbox: string;
|
|
104
108
|
};
|
|
@@ -138,3 +142,31 @@ export declare const EyeOffRegularIcon: {
|
|
|
138
142
|
body: string;
|
|
139
143
|
viewbox: string;
|
|
140
144
|
};
|
|
145
|
+
export declare const ArrowLeftRegularIcon: {
|
|
146
|
+
body: string;
|
|
147
|
+
viewbox: string;
|
|
148
|
+
};
|
|
149
|
+
export declare const ArrowRightRegularIcon: {
|
|
150
|
+
body: string;
|
|
151
|
+
viewbox: string;
|
|
152
|
+
};
|
|
153
|
+
export declare const ArrowDownloadRegularIcon: {
|
|
154
|
+
body: string;
|
|
155
|
+
viewbox: string;
|
|
156
|
+
};
|
|
157
|
+
export declare const ArrowUploadRegularIcon: {
|
|
158
|
+
body: string;
|
|
159
|
+
viewbox: string;
|
|
160
|
+
};
|
|
161
|
+
export declare const ImageAddRegularIcon: {
|
|
162
|
+
body: string;
|
|
163
|
+
viewbox: string;
|
|
164
|
+
};
|
|
165
|
+
export declare const ArrowResetRegularIcon: {
|
|
166
|
+
body: string;
|
|
167
|
+
viewbox: string;
|
|
168
|
+
};
|
|
169
|
+
export declare const CropRegularIcon: {
|
|
170
|
+
body: string;
|
|
171
|
+
viewbox: string;
|
|
172
|
+
};
|
package/dist/icons/index.js
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
export const Add24RegularIcon = {
|
|
2
|
+
body: '<path fill="currentColor" d="M11.75 3a.75.75 0 0 1 .75.75v7.5h7.5a.75.75 0 0 1 0 1.5h-7.5v7.5a.75.75 0 0 1-1.5 0v-7.5h-7.5a.75.75 0 0 1 0-1.5h7.5v-7.5a.75.75 0 0 1 .75-.75"/>',
|
|
3
|
+
viewbox: '0 0 24 24'
|
|
4
|
+
};
|
|
1
5
|
export const ArrowDown24RegularIcon = {
|
|
2
6
|
body: '<path fill="currentColor" d="M19.79 13.267a.75.75 0 0 0-1.086-1.034l-5.954 6.251V3.75a.75.75 0 1 0-1.5 0v14.734l-5.955-6.251a.75.75 0 1 0-1.086 1.034l7.067 7.42c.16.168.366.268.58.3a.8.8 0 0 0 .29-.001a1 1 0 0 0 .578-.3z"/>',
|
|
3
7
|
viewbox: '0 0 24 24'
|
|
@@ -90,16 +94,16 @@ export const SpeakerMute24RegularIcon = {
|
|
|
90
94
|
body: '<path fill="currentColor" d="M12.92 3.315C13.726 2.6 15 3.171 15 4.25v15.495c0 1.079-1.274 1.651-2.08.934l-4.492-3.993a.75.75 0 0 0-.498-.19H4.25A2.25 2.25 0 0 1 2 14.246V9.748a2.25 2.25 0 0 1 2.25-2.25h3.68a.75.75 0 0 0 .498-.19zm.58 1.491L9.425 8.43a2.25 2.25 0 0 1-1.495.568H4.25a.75.75 0 0 0-.75.75v4.498c0 .414.336.75.75.75h3.68a2.25 2.25 0 0 1 1.495.569l4.075 3.623zm2.72 4.413a.75.75 0 0 1 1.06 0L19 10.94l1.72-1.72a.75.75 0 1 1 1.06 1.06L20.06 12l1.72 1.72a.75.75 0 0 1-1.06 1.06L19 13.06l-1.72 1.72a.75.75 0 1 1-1.06-1.06L17.94 12l-1.72-1.72a.75.75 0 0 1 0-1.06"/>',
|
|
91
95
|
viewbox: '0 0 24 24'
|
|
92
96
|
};
|
|
93
|
-
export const
|
|
94
|
-
body: '<path fill="currentColor" d="
|
|
97
|
+
export const PauseFilledIcon = {
|
|
98
|
+
body: '<path fill="currentColor" d="M5.746 3a1.75 1.75 0 0 0-1.75 1.75v14.5c0 .966.784 1.75 1.75 1.75h3.5a1.75 1.75 0 0 0 1.75-1.75V4.75A1.75 1.75 0 0 0 9.246 3zm9 0a1.75 1.75 0 0 0-1.75 1.75v14.5c0 .966.784 1.75 1.75 1.75h3.5a1.75 1.75 0 0 0 1.75-1.75V4.75A1.75 1.75 0 0 0 18.246 3z"/>',
|
|
95
99
|
viewbox: '0 0 24 24'
|
|
96
100
|
};
|
|
97
101
|
export const PictureInPicture24RegularIcon = {
|
|
98
102
|
body: '<path fill="currentColor" d="M2 6.25A3.25 3.25 0 0 1 5.25 3h13.5A3.25 3.25 0 0 1 22 6.25V12h-1.5V6.25a1.75 1.75 0 0 0-1.75-1.75H5.25A1.75 1.75 0 0 0 3.5 6.25v9.5c0 .966.784 1.75 1.75 1.75H11V19H5.25A3.25 3.25 0 0 1 2 15.75zM14 13a2 2 0 0 0-2 2v5a2 2 0 0 0 2 2h7a2 2 0 0 0 2-2v-5a2 2 0 0 0-2-2z"/>',
|
|
99
103
|
viewbox: '0 0 24 24'
|
|
100
104
|
};
|
|
101
|
-
export const
|
|
102
|
-
body: '<path fill="currentColor" d="
|
|
105
|
+
export const PlayFilledIcon = {
|
|
106
|
+
body: '<path fill="currentColor" d="M5 5.274c0-1.707 1.826-2.792 3.325-1.977l12.362 6.727c1.566.852 1.566 3.1 0 3.952L8.325 20.702C6.826 21.518 5 20.432 5 18.726z"/>',
|
|
103
107
|
viewbox: '0 0 24 24'
|
|
104
108
|
};
|
|
105
109
|
export const Record24RegularIcon = {
|
|
@@ -138,3 +142,31 @@ export const EyeOffRegularIcon = {
|
|
|
138
142
|
body: '<path fill="currentColor" d="M2.22 2.22a.75.75 0 0 0-.073.976l.073.084l4.034 4.035a10 10 0 0 0-3.955 5.75a.75.75 0 0 0 1.455.364a8.5 8.5 0 0 1 3.58-5.034l1.81 1.81A4 4 0 0 0 14.8 15.86l5.919 5.92a.75.75 0 0 0 1.133-.977l-.073-.084l-6.113-6.114l.001-.002l-1.2-1.198l-2.87-2.87h.002l-2.88-2.877l.001-.002l-1.133-1.13L3.28 2.22a.75.75 0 0 0-1.06 0m7.984 9.045l3.535 3.536a2.5 2.5 0 0 1-3.535-3.535M12 5.5c-1 0-1.97.148-2.889.425l1.237 1.236a8.503 8.503 0 0 1 9.899 6.272a.75.75 0 0 0 1.455-.363A10 10 0 0 0 12 5.5m.195 3.51l3.801 3.8a4.003 4.003 0 0 0-3.801-3.8"/>',
|
|
139
143
|
viewbox: '0 0 24 24'
|
|
140
144
|
};
|
|
145
|
+
export const ArrowLeftRegularIcon = {
|
|
146
|
+
body: '<path fill="currentColor" d="M10.733 19.79a.75.75 0 0 0 1.034-1.086L5.516 12.75H20.25a.75.75 0 0 0 0-1.5H5.516l6.251-5.955a.75.75 0 0 0-1.034-1.086l-7.42 7.067a1 1 0 0 0-.3.58a.8.8 0 0 0 .001.289a1 1 0 0 0 .3.579z"/>',
|
|
147
|
+
viewbox: '0 0 24 24'
|
|
148
|
+
};
|
|
149
|
+
export const ArrowRightRegularIcon = {
|
|
150
|
+
body: '<path fill="currentColor" d="M13.267 4.209a.75.75 0 0 0-1.034 1.086l6.251 5.955H3.75a.75.75 0 0 0 0 1.5h14.734l-6.251 5.954a.75.75 0 0 0 1.034 1.087l7.42-7.067a1 1 0 0 0 .3-.58a.8.8 0 0 0-.001-.29a1 1 0 0 0-.3-.578z"/>',
|
|
151
|
+
viewbox: '0 0 24 24'
|
|
152
|
+
};
|
|
153
|
+
export const ArrowDownloadRegularIcon = {
|
|
154
|
+
body: '<path fill="currentColor" d="M18.25 20.5a.75.75 0 1 1 0 1.5l-13 .005a.75.75 0 1 1 0-1.5zM11.648 2.014l.102-.007a.75.75 0 0 1 .743.648l.007.102l-.001 13.685l3.722-3.72a.75.75 0 0 1 .976-.073l.085.073a.75.75 0 0 1 .072.976l-.073.084l-4.997 4.997a.75.75 0 0 1-.976.073l-.085-.073l-5.003-4.996a.75.75 0 0 1 .976-1.134l.084.072l3.719 3.714L11 2.756a.75.75 0 0 1 .648-.743l.102-.007z"/>',
|
|
155
|
+
viewbox: '0 0 24 24'
|
|
156
|
+
};
|
|
157
|
+
export const ArrowUploadRegularIcon = {
|
|
158
|
+
body: '<path fill="currentColor" d="M18.25 3.51a.75.75 0 1 0 0-1.5l-13-.004a.75.75 0 1 0 0 1.5zm-6.602 18.488l.102.007a.75.75 0 0 0 .743-.649l.007-.101l-.001-13.685l3.722 3.72a.75.75 0 0 0 .976.073l.085-.073a.75.75 0 0 0 .072-.977l-.073-.084l-4.997-4.996a.75.75 0 0 0-.976-.073l-.085.072L6.22 10.23a.75.75 0 0 0 .976 1.134l.084-.073l3.719-3.713L11 21.255c0 .38.282.693.648.743"/>',
|
|
159
|
+
viewbox: '0 0 24 24'
|
|
160
|
+
};
|
|
161
|
+
export const ImageAddRegularIcon = {
|
|
162
|
+
body: '<path fill="currentColor" d="M12 6.5a5.5 5.5 0 1 0-11 0a5.5 5.5 0 0 0 11 0M7 7l.001 2.504a.5.5 0 0 1-1 0V7H3.496a.5.5 0 0 1 0-1H6V3.5a.5.5 0 0 1 1 0V6h2.497a.5.5 0 0 1 0 1zm10.75-2.5h-5.063a6.5 6.5 0 0 0-.709-1.5h5.772A3.25 3.25 0 0 1 21 6.25v11.5A3.25 3.25 0 0 1 17.75 21H6.25A3.25 3.25 0 0 1 3 17.75v-5.772c.463.297.967.536 1.5.709v5.063q.001.313.103.594l5.823-5.701a2.25 2.25 0 0 1 3.02-.116l.128.116l5.822 5.702q.102-.28.104-.595V6.25a1.75 1.75 0 0 0-1.75-1.75m.58 14.901l-5.805-5.686a.75.75 0 0 0-.966-.071l-.084.07l-5.807 5.687q.274.097.582.099h11.5c.203 0 .399-.035.58-.099M15.253 6.5a2.252 2.252 0 1 1 0 4.504a2.252 2.252 0 0 1 0-4.504m0 1.5a.752.752 0 1 0 0 1.504a.752.752 0 0 0 0-1.504"/>',
|
|
163
|
+
viewbox: '0 0 24 24'
|
|
164
|
+
};
|
|
165
|
+
export const ArrowResetRegularIcon = {
|
|
166
|
+
body: '<path fill="currentColor" d="M6.78 2.72a.75.75 0 0 1 0 1.06L4.56 6h8.69a7.75 7.75 0 1 1-7.75 7.75a.75.75 0 0 1 1.5 0a6.25 6.25 0 1 0 6.25-6.25H4.56l2.22 2.22a.75.75 0 1 1-1.06 1.06l-3.5-3.5a.75.75 0 0 1 0-1.06l3.5-3.5a.75.75 0 0 1 1.06 0"/>',
|
|
167
|
+
viewbox: '0 0 24 24'
|
|
168
|
+
};
|
|
169
|
+
export const CropRegularIcon = {
|
|
170
|
+
body: '<path fill="currentColor" d="M21.25 17a.75.75 0 0 1 .102 1.493l-.102.007H18.5v2.75a.75.75 0 0 1-1.493.102L17 21.25V18.5H8.75a3.25 3.25 0 0 1-3.245-3.066L5.5 15.25L5.499 7H2.75a.75.75 0 0 1-.102-1.493L2.75 5.5h2.749L5.5 2.75a.75.75 0 0 1 1.493-.102L7 2.75L6.999 5.5H7V7h-.001L7 15.25a1.75 1.75 0 0 0 1.606 1.744L8.75 17zM8 5.5h7.25a3.25 3.25 0 0 1 3.245 3.066l.005.184V16H17V8.75a1.75 1.75 0 0 0-1.607-1.744L15.25 7H8z"/>',
|
|
171
|
+
viewbox: '0 0 24 24'
|
|
172
|
+
};
|