@adamosuiteservices/ui 2.14.2 → 2.15.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/combobox-DGuQtXjP.js +608 -0
- package/dist/combobox-hTCtPMUL.cjs +40 -0
- package/dist/combobox.cjs +1 -1
- package/dist/combobox.js +1 -1
- package/dist/components/ui/combobox/combobox.d.ts +5 -1
- package/dist/components/ui/date-picker-selector/date-picker-selector.d.ts +5 -1
- package/dist/components/ui/file-upload/file-upload.d.ts +4 -1
- package/dist/components/ui/slider/slider.d.ts +1 -1
- package/dist/components/ui/switch/switch.d.ts +1 -1
- package/dist/date-picker-selector.cjs +1 -1
- package/dist/date-picker-selector.js +38 -28
- package/dist/field.cjs +2 -2
- package/dist/field.js +2 -2
- package/dist/file-upload.cjs +5 -3
- package/dist/file-upload.js +191 -150
- package/dist/slider.cjs +5 -5
- package/dist/slider.js +196 -177
- package/dist/styles.css +1 -1
- package/dist/switch.cjs +3 -3
- package/dist/switch.js +105 -85
- package/docs/components/ui/accordion-rounded.md +2 -6
- package/docs/components/ui/avatar.md +3 -1
- package/docs/components/ui/button.md +22 -16
- package/docs/components/ui/card.md +49 -31
- package/docs/components/ui/checkbox.md +44 -8
- package/docs/components/ui/combobox.md +62 -4
- package/docs/components/ui/date-picker-selector.md +90 -26
- package/docs/components/ui/file-upload.md +364 -95
- package/docs/components/ui/icon.md +1 -1
- package/docs/components/ui/input.md +4 -1
- package/docs/components/ui/radio-group.md +1 -1
- package/docs/components/ui/select.md +51 -34
- package/docs/components/ui/sheet.md +3 -9
- package/docs/components/ui/slider.md +120 -99
- package/docs/components/ui/switch.md +408 -408
- package/docs/components/ui/textarea.md +37 -22
- package/docs/components/ui/tooltip.md +5 -2
- package/docs/components/ui/typography.md +63 -39
- package/package.json +1 -1
- package/dist/combobox-CCJGIMFQ.cjs +0 -40
- package/dist/combobox-Cj-GEp-T.js +0 -604
|
@@ -510,7 +510,7 @@ El componente renderiza un `<span>` con las siguientes características:
|
|
|
510
510
|
<span
|
|
511
511
|
data-slot="icon"
|
|
512
512
|
className="material-symbols-outlined adm:inline-block adm:text-2xl"
|
|
513
|
-
style={{ fontVariationSettings:
|
|
513
|
+
style={{ fontVariationSettings: "..." }}
|
|
514
514
|
>
|
|
515
515
|
{symbol}
|
|
516
516
|
</span>
|
|
@@ -135,7 +135,10 @@ import { Input } from "@adamosuiteservices/ui/input";
|
|
|
135
135
|
{
|
|
136
136
|
/* Por defecto */
|
|
137
137
|
}
|
|
138
|
-
<Input type="text" placeholder="Default input" />;
|
|
138
|
+
<Input type="text" placeholder="Default input" />;
|
|
139
|
+
{
|
|
140
|
+
/* h-10 por defecto */
|
|
141
|
+
}
|
|
139
142
|
|
|
140
143
|
{
|
|
141
144
|
/* Grande */
|
|
@@ -283,7 +283,7 @@ function App() {
|
|
|
283
283
|
## Accesibilidad
|
|
284
284
|
|
|
285
285
|
- ✅ **Role**: `role="radio"` y `role="radiogroup"`
|
|
286
|
-
- ✅ **ARIA**: `aria-checked`, `aria-
|
|
286
|
+
- ✅ **ARIA**: `aria-checked`, `aria-invalid`
|
|
287
287
|
- ✅ **Keyboard**: Arrow keys para navegar, Space para seleccionar
|
|
288
288
|
- ✅ **Label**: Asociar con `htmlFor` e `id`
|
|
289
289
|
- ✅ **Focus**: Focus ring visible en navegación por teclado
|
|
@@ -137,21 +137,30 @@ function App() {
|
|
|
137
137
|
### Con Label
|
|
138
138
|
|
|
139
139
|
```tsx
|
|
140
|
-
import {
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
<
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
</
|
|
140
|
+
import {
|
|
141
|
+
Field,
|
|
142
|
+
FieldContent,
|
|
143
|
+
FieldGroup,
|
|
144
|
+
FieldLabel,
|
|
145
|
+
} from "@adamosuiteservices/ui/field";
|
|
146
|
+
|
|
147
|
+
<FieldGroup className="max-w-sm">
|
|
148
|
+
<Field>
|
|
149
|
+
<FieldLabel htmlFor="email-provider">Email provider</FieldLabel>
|
|
150
|
+
<FieldContent>
|
|
151
|
+
<Select>
|
|
152
|
+
<SelectTrigger id="email-provider">
|
|
153
|
+
<SelectValue placeholder="Select a provider" />
|
|
154
|
+
</SelectTrigger>
|
|
155
|
+
<SelectContent>
|
|
156
|
+
<SelectItem value="gmail">Gmail</SelectItem>
|
|
157
|
+
<SelectItem value="outlook">Outlook</SelectItem>
|
|
158
|
+
<SelectItem value="yahoo">Yahoo</SelectItem>
|
|
159
|
+
</SelectContent>
|
|
160
|
+
</Select>
|
|
161
|
+
</FieldContent>
|
|
162
|
+
</Field>
|
|
163
|
+
</FieldGroup>;
|
|
155
164
|
```
|
|
156
165
|
|
|
157
166
|
### Con Grupos
|
|
@@ -244,6 +253,13 @@ import { Icon } from "@adamosuiteservices/ui/icon";
|
|
|
244
253
|
|
|
245
254
|
```tsx
|
|
246
255
|
import { Button } from "@adamosuiteservices/ui/button";
|
|
256
|
+
import {
|
|
257
|
+
Field,
|
|
258
|
+
FieldContent,
|
|
259
|
+
FieldError,
|
|
260
|
+
FieldGroup,
|
|
261
|
+
FieldLabel,
|
|
262
|
+
} from "@adamosuiteservices/ui/field";
|
|
247
263
|
|
|
248
264
|
function App() {
|
|
249
265
|
const [value, setValue] = useState("");
|
|
@@ -259,25 +275,26 @@ function App() {
|
|
|
259
275
|
|
|
260
276
|
return (
|
|
261
277
|
<div className="space-y-4">
|
|
262
|
-
<
|
|
263
|
-
<
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
<
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
278
|
+
<FieldGroup className="max-w-sm">
|
|
279
|
+
<Field>
|
|
280
|
+
<FieldLabel htmlFor="priority">
|
|
281
|
+
Priority level <span className="text-destructive">*</span>
|
|
282
|
+
</FieldLabel>
|
|
283
|
+
<FieldContent>
|
|
284
|
+
<Select value={value} onValueChange={setValue}>
|
|
285
|
+
<SelectTrigger id="priority" aria-invalid={!!error}>
|
|
286
|
+
<SelectValue placeholder="Select priority" />
|
|
287
|
+
</SelectTrigger>
|
|
288
|
+
<SelectContent>
|
|
289
|
+
<SelectItem value="low">Low</SelectItem>
|
|
290
|
+
<SelectItem value="medium">Medium</SelectItem>
|
|
291
|
+
<SelectItem value="high">High</SelectItem>
|
|
292
|
+
</SelectContent>
|
|
293
|
+
</Select>
|
|
294
|
+
</FieldContent>
|
|
295
|
+
{error && <FieldError>{error}</FieldError>}
|
|
296
|
+
</Field>
|
|
297
|
+
</FieldGroup>
|
|
281
298
|
<Button onClick={handleValidate} variant="outline">
|
|
282
299
|
Validate Selection
|
|
283
300
|
</Button>
|
|
@@ -32,9 +32,7 @@ import {
|
|
|
32
32
|
<SheetTitle>Are you sure?</SheetTitle>
|
|
33
33
|
<SheetDescription>This action cannot be undone.</SheetDescription>
|
|
34
34
|
</SheetHeader>
|
|
35
|
-
<SheetBody>
|
|
36
|
-
{/* Content */}
|
|
37
|
-
</SheetBody>
|
|
35
|
+
<SheetBody>{/* Content */}</SheetBody>
|
|
38
36
|
</SheetContent>
|
|
39
37
|
</Sheet>
|
|
40
38
|
```
|
|
@@ -74,9 +72,7 @@ Ancho: `w-11/12` en móvil, `max-w-sm` en desktop. Border radius: `rounded-2xl`.
|
|
|
74
72
|
<SheetTitle>Settings</SheetTitle>
|
|
75
73
|
<SheetDescription>Configure your preferences</SheetDescription>
|
|
76
74
|
</SheetHeader>
|
|
77
|
-
<SheetBody>
|
|
78
|
-
{/* Content with horizontal padding */}
|
|
79
|
-
</SheetBody>
|
|
75
|
+
<SheetBody>{/* Content with horizontal padding */}</SheetBody>
|
|
80
76
|
</SheetContent>
|
|
81
77
|
</Sheet>
|
|
82
78
|
```
|
|
@@ -126,9 +122,7 @@ Ancho: `w-11/12` en móvil, `max-w-sm` en desktop. Border radius: `rounded-2xl`.
|
|
|
126
122
|
<SheetTitle>Edit profile</SheetTitle>
|
|
127
123
|
<SheetDescription>Make changes to your profile here.</SheetDescription>
|
|
128
124
|
</SheetHeader>
|
|
129
|
-
<SheetBody>
|
|
130
|
-
{/* Form fields */}
|
|
131
|
-
</SheetBody>
|
|
125
|
+
<SheetBody>{/* Form fields */}</SheetBody>
|
|
132
126
|
<SheetFooter>
|
|
133
127
|
<SheetClose asChild>
|
|
134
128
|
<Button variant="outline">Cancel</Button>
|
|
@@ -22,19 +22,19 @@ import { Slider } from "@adamosuiteservices/ui/slider";
|
|
|
22
22
|
|
|
23
23
|
## Props
|
|
24
24
|
|
|
25
|
-
| Prop | Tipo
|
|
26
|
-
| --------------- |
|
|
27
|
-
| `defaultValue` | `number[]`
|
|
28
|
-
| `value` | `number[]`
|
|
29
|
-
| `onValueChange` | `(value: number[]) => void`
|
|
30
|
-
| `min` | `number`
|
|
31
|
-
| `max` | `number`
|
|
32
|
-
| `step` | `number`
|
|
33
|
-
| `disabled` | `boolean`
|
|
34
|
-
| `orientation` | `"horizontal" \| "vertical"`
|
|
35
|
-
| `colorSlide` | `"full" \| [string, string]`
|
|
36
|
-
| `theme` | `Theme`
|
|
37
|
-
| `className` | `string`
|
|
25
|
+
| Prop | Tipo | Descripción |
|
|
26
|
+
| --------------- | ---------------------------- | ----------------------------------- |
|
|
27
|
+
| `defaultValue` | `number[]` | Valor inicial (uncontrolled) |
|
|
28
|
+
| `value` | `number[]` | Valor controlado (array de números) |
|
|
29
|
+
| `onValueChange` | `(value: number[]) => void` | Callback al cambiar valor |
|
|
30
|
+
| `min` | `number` | Valor mínimo (default: 0) |
|
|
31
|
+
| `max` | `number` | Valor máximo (default: 100) |
|
|
32
|
+
| `step` | `number` | Incremento (default: 1) |
|
|
33
|
+
| `disabled` | `boolean` | Deshabilita el slider |
|
|
34
|
+
| `orientation` | `"horizontal" \| "vertical"` | Orientación (default: horizontal) |
|
|
35
|
+
| `colorSlide` | `"full" \| [string, string]` | Gradiente de colores personalizado |
|
|
36
|
+
| `theme` | `Theme` | Tema personalizado |
|
|
37
|
+
| `className` | `string` | Clases CSS adicionales |
|
|
38
38
|
|
|
39
39
|
**Nota**: `value` y `defaultValue` siempre son arrays. Single value = `[50]`, range = `[20, 80]`
|
|
40
40
|
|
|
@@ -51,24 +51,33 @@ import { Slider } from "@adamosuiteservices/ui/slider";
|
|
|
51
51
|
### Con Label
|
|
52
52
|
|
|
53
53
|
```tsx
|
|
54
|
-
import {
|
|
54
|
+
import {
|
|
55
|
+
Field,
|
|
56
|
+
FieldContent,
|
|
57
|
+
FieldGroup,
|
|
58
|
+
FieldLabel,
|
|
59
|
+
} from "@adamosuiteservices/ui/field";
|
|
55
60
|
import { useState } from "react";
|
|
56
61
|
|
|
57
62
|
function App() {
|
|
58
63
|
const [value, setValue] = useState([50]);
|
|
59
64
|
|
|
60
65
|
return (
|
|
61
|
-
<
|
|
62
|
-
<
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
66
|
+
<FieldGroup className="max-w-sm">
|
|
67
|
+
<Field>
|
|
68
|
+
<FieldLabel htmlFor="volume">Volume: {value[0]}%</FieldLabel>
|
|
69
|
+
<FieldContent>
|
|
70
|
+
<Slider
|
|
71
|
+
id="volume"
|
|
72
|
+
max={100}
|
|
73
|
+
step={1}
|
|
74
|
+
value={value}
|
|
75
|
+
onValueChange={setValue}
|
|
76
|
+
className="w-full"
|
|
77
|
+
/>
|
|
78
|
+
</FieldContent>
|
|
79
|
+
</Field>
|
|
80
|
+
</FieldGroup>
|
|
72
81
|
);
|
|
73
82
|
}
|
|
74
83
|
```
|
|
@@ -80,18 +89,22 @@ function App() {
|
|
|
80
89
|
const [value, setValue] = useState([20, 80]);
|
|
81
90
|
|
|
82
91
|
return (
|
|
83
|
-
<
|
|
84
|
-
<
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
92
|
+
<FieldGroup className="max-w-sm">
|
|
93
|
+
<Field>
|
|
94
|
+
<FieldLabel>
|
|
95
|
+
Price Range: ${value[0]} - ${value[1]}
|
|
96
|
+
</FieldLabel>
|
|
97
|
+
<FieldContent>
|
|
98
|
+
<Slider
|
|
99
|
+
max={100}
|
|
100
|
+
step={1}
|
|
101
|
+
value={value}
|
|
102
|
+
onValueChange={setValue}
|
|
103
|
+
className="w-full"
|
|
104
|
+
/>
|
|
105
|
+
</FieldContent>
|
|
106
|
+
</Field>
|
|
107
|
+
</FieldGroup>
|
|
95
108
|
);
|
|
96
109
|
}
|
|
97
110
|
```
|
|
@@ -104,20 +117,24 @@ function App() {
|
|
|
104
117
|
const stepSize = 25;
|
|
105
118
|
|
|
106
119
|
return (
|
|
107
|
-
<
|
|
108
|
-
<
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
<
|
|
120
|
-
|
|
120
|
+
<FieldGroup className="max-w-sm">
|
|
121
|
+
<Field>
|
|
122
|
+
<FieldLabel>Progress: {value[0]}%</FieldLabel>
|
|
123
|
+
<FieldContent>
|
|
124
|
+
<Slider
|
|
125
|
+
max={100}
|
|
126
|
+
step={stepSize}
|
|
127
|
+
value={value}
|
|
128
|
+
onValueChange={setValue}
|
|
129
|
+
className="w-full"
|
|
130
|
+
/>
|
|
131
|
+
</FieldContent>
|
|
132
|
+
<FieldDescription>
|
|
133
|
+
<div className="flex justify-between text-xs">
|
|
134
|
+
<span>0%</span>
|
|
135
|
+
<span>25%</span>
|
|
136
|
+
<span>50%</span>
|
|
137
|
+
<span>75%</span>
|
|
121
138
|
<span>100%</span>
|
|
122
139
|
</div>
|
|
123
140
|
</div>
|
|
@@ -134,7 +151,7 @@ function App() {
|
|
|
134
151
|
return (
|
|
135
152
|
<div className="flex h-64 items-center space-x-6">
|
|
136
153
|
<div className="flex flex-col items-center space-y-2">
|
|
137
|
-
<
|
|
154
|
+
<FieldLabel>Volume</FieldLabel>
|
|
138
155
|
<Slider
|
|
139
156
|
orientation="vertical"
|
|
140
157
|
max={100}
|
|
@@ -162,34 +179,38 @@ function App() {
|
|
|
162
179
|
const increase = () => setValue([Math.min(100, value[0] + 10)]);
|
|
163
180
|
|
|
164
181
|
return (
|
|
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
|
-
|
|
182
|
+
<FieldGroup className="max-w-sm">
|
|
183
|
+
<Field>
|
|
184
|
+
<FieldLabel>Volume: {value[0]}%</FieldLabel>
|
|
185
|
+
<FieldContent>
|
|
186
|
+
<div className="flex items-center space-x-2">
|
|
187
|
+
<Button
|
|
188
|
+
variant="outline"
|
|
189
|
+
size="sm"
|
|
190
|
+
onClick={decrease}
|
|
191
|
+
disabled={value[0] === 0}
|
|
192
|
+
>
|
|
193
|
+
-
|
|
194
|
+
</Button>
|
|
195
|
+
<Slider
|
|
196
|
+
value={value}
|
|
197
|
+
onValueChange={setValue}
|
|
198
|
+
max={100}
|
|
199
|
+
step={1}
|
|
200
|
+
className="flex-1"
|
|
201
|
+
/>
|
|
202
|
+
<Button
|
|
203
|
+
variant="outline"
|
|
204
|
+
size="sm"
|
|
205
|
+
onClick={increase}
|
|
206
|
+
disabled={value[0] === 100}
|
|
207
|
+
>
|
|
208
|
+
+
|
|
209
|
+
</Button>
|
|
210
|
+
</div>
|
|
211
|
+
</FieldContent>
|
|
212
|
+
</Field>
|
|
213
|
+
</FieldGroup>
|
|
193
214
|
);
|
|
194
215
|
}
|
|
195
216
|
```
|
|
@@ -215,7 +236,7 @@ function PriceFilter() {
|
|
|
215
236
|
</CardHeader>
|
|
216
237
|
<CardContent className="space-y-4">
|
|
217
238
|
<div className="space-y-2">
|
|
218
|
-
<
|
|
239
|
+
<FieldLabel>Price Range</FieldLabel>
|
|
219
240
|
<Slider
|
|
220
241
|
value={priceRange}
|
|
221
242
|
onValueChange={setPriceRange}
|
|
@@ -259,7 +280,7 @@ function ColorPicker() {
|
|
|
259
280
|
<div className="space-y-4">
|
|
260
281
|
<div className="space-y-2">
|
|
261
282
|
<div className="flex justify-between">
|
|
262
|
-
<
|
|
283
|
+
<FieldLabel>Red</FieldLabel>
|
|
263
284
|
<span className="text-sm text-muted-foreground">{red[0]}</span>
|
|
264
285
|
</div>
|
|
265
286
|
<Slider value={red} onValueChange={setRed} max={255} step={1} />
|
|
@@ -267,7 +288,7 @@ function ColorPicker() {
|
|
|
267
288
|
|
|
268
289
|
<div className="space-y-2">
|
|
269
290
|
<div className="flex justify-between">
|
|
270
|
-
<
|
|
291
|
+
<FieldLabel>Green</FieldLabel>
|
|
271
292
|
<span className="text-sm text-muted-foreground">{green[0]}</span>
|
|
272
293
|
</div>
|
|
273
294
|
<Slider value={green} onValueChange={setGreen} max={255} step={1} />
|
|
@@ -275,7 +296,7 @@ function ColorPicker() {
|
|
|
275
296
|
|
|
276
297
|
<div className="space-y-2">
|
|
277
298
|
<div className="flex justify-between">
|
|
278
|
-
<
|
|
299
|
+
<FieldLabel>Blue</FieldLabel>
|
|
279
300
|
<span className="text-sm text-muted-foreground">{blue[0]}</span>
|
|
280
301
|
</div>
|
|
281
302
|
<Slider value={blue} onValueChange={setBlue} max={255} step={1} />
|
|
@@ -289,18 +310,18 @@ function ColorPicker() {
|
|
|
289
310
|
|
|
290
311
|
### Con Gradiente Arcoíris
|
|
291
312
|
|
|
292
|
-
|
|
313
|
+
````tsx
|
|
293
314
|
function RainbowSlider() {
|
|
294
315
|
const [value, setValue] = useState([50]);
|
|
295
316
|
|
|
296
317
|
## Casos de Uso
|
|
297
318
|
|
|
298
|
-
**Volume control**: Audio, música, efectos de sonido
|
|
299
|
-
**Price filters**: Rango de precios en e-commerce
|
|
300
|
-
**Color pickers**: RGB, HSL sliders con gradientes personalizados
|
|
301
|
-
**Brightness/Contrast**: Ajustes de imagen
|
|
302
|
-
**Temperature**: Termostatos, controles de clima con gradientes frío-calor
|
|
303
|
-
**Range selection**: Filtros de fecha, edad, tamaño
|
|
319
|
+
**Volume control**: Audio, música, efectos de sonido
|
|
320
|
+
**Price filters**: Rango de precios en e-commerce
|
|
321
|
+
**Color pickers**: RGB, HSL sliders con gradientes personalizados
|
|
322
|
+
**Brightness/Contrast**: Ajustes de imagen
|
|
323
|
+
**Temperature**: Termostatos, controles de clima con gradientes frío-calor
|
|
324
|
+
**Range selection**: Filtros de fecha, edad, tamaño
|
|
304
325
|
**Hue selection**: Selectores de tono con gradiente arcoíris
|
|
305
326
|
## Estilos Base
|
|
306
327
|
|
|
@@ -329,13 +350,13 @@ function CustomColorSlider() {
|
|
|
329
350
|
onValueChange={setValue}
|
|
330
351
|
## Troubleshooting
|
|
331
352
|
|
|
332
|
-
**Thumb no se mueve**: Verifica `max`, `min` y `step` son números válidos
|
|
333
|
-
**Value no actualiza**: En modo controlado usa `value` + `onValueChange`, no `defaultValue`
|
|
334
|
-
**Range invertido**: Asegura `value[0] < value[1]` en ranges
|
|
335
|
-
**Vertical no funciona**: Agrega `className="h-[Xpx]"` para altura explícita
|
|
336
|
-
**Step no funciona**: `step` debe ser divisor válido del rango (max - min)
|
|
337
|
-
**Multiple thumbs**: `value={[10, 50, 90]}` crea 3 thumbs
|
|
338
|
-
**Color no se aplica**: Prop `colorSlide` acepta `"full"` o array de 2 strings `["#color1", "#color2"]`
|
|
353
|
+
**Thumb no se mueve**: Verifica `max`, `min` y `step` son números válidos
|
|
354
|
+
**Value no actualiza**: En modo controlado usa `value` + `onValueChange`, no `defaultValue`
|
|
355
|
+
**Range invertido**: Asegura `value[0] < value[1]` en ranges
|
|
356
|
+
**Vertical no funciona**: Agrega `className="h-[Xpx]"` para altura explícita
|
|
357
|
+
**Step no funciona**: `step` debe ser divisor válido del rango (max - min)
|
|
358
|
+
**Multiple thumbs**: `value={[10, 50, 90]}` crea 3 thumbs
|
|
359
|
+
**Color no se aplica**: Prop `colorSlide` acepta `"full"` o array de 2 strings `["#color1", "#color2"]`
|
|
339
360
|
**Gradiente no visible**: Asegura que los colores sean válidos (hex, rgb, hsl, etc.)
|
|
340
361
|
<Label>Blue to Green</Label>
|
|
341
362
|
<Slider
|
|
@@ -361,7 +382,7 @@ function CustomColorSlider() {
|
|
|
361
382
|
</div>
|
|
362
383
|
);
|
|
363
384
|
}
|
|
364
|
-
|
|
385
|
+
````
|
|
365
386
|
|
|
366
387
|
### Control de Temperatura con Colores
|
|
367
388
|
|