svelte-multistyle-ui 0.0.3-alpha → 0.0.4-alpha
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/components/DatePicker.svelte +130 -44
- package/dist/components/Input.svelte +3 -2
- package/dist/components/MultiSelect.svelte +20 -2
- package/dist/components/Select.svelte +4 -2
- package/dist/components/Textarea.svelte +1 -1
- package/dist/components/datepicker-styles.css +26 -10
- package/dist/components/input-styles.css +14 -15
- package/dist/components/multiselect-styles.css +193 -30
- package/dist/components/select-styles.css +45 -3
- package/dist/components/textarea-styles.css +1 -1
- package/package.json +1 -1
|
@@ -28,8 +28,6 @@
|
|
|
28
28
|
const internalId = `dp-${uid}`;
|
|
29
29
|
const dispFormat = $derived(displayFormat ?? format);
|
|
30
30
|
|
|
31
|
-
|
|
32
|
-
|
|
33
31
|
// State
|
|
34
32
|
let open = $state(false);
|
|
35
33
|
let view = $state("date");
|
|
@@ -37,7 +35,6 @@
|
|
|
37
35
|
let selectedDate = $state(null);
|
|
38
36
|
let isMobile = $state(false);
|
|
39
37
|
|
|
40
|
-
|
|
41
38
|
// Format helpers — uses dayjs for full format support (MMM, MMMM, etc.)
|
|
42
39
|
function toDayjsFmt(f) {
|
|
43
40
|
return f.replace(/hh/g, "HH");
|
|
@@ -54,14 +51,21 @@
|
|
|
54
51
|
|
|
55
52
|
// Derived
|
|
56
53
|
const displayValue = $derived(
|
|
57
|
-
value ? fmt(parseDate(value, format) || new Date(), dispFormat) : ""
|
|
54
|
+
value ? fmt(parseDate(value, format) || new Date(), dispFormat) : "",
|
|
58
55
|
);
|
|
59
56
|
const inputPlaceholder = $derived(placeholder || dispFormat.toLowerCase());
|
|
60
57
|
|
|
61
58
|
// Floating-label support — mirrors Input.svelte so the label sits inside the
|
|
62
59
|
// border (floats up on focus/value) for outlined styles, and renders no
|
|
63
60
|
// in-field label for the non-floating styles, exactly like Input.
|
|
64
|
-
const floatingStyles = [
|
|
61
|
+
const floatingStyles = [
|
|
62
|
+
"material",
|
|
63
|
+
"material3",
|
|
64
|
+
"fluent",
|
|
65
|
+
"carbon",
|
|
66
|
+
"bootstrap",
|
|
67
|
+
"legacy-ios",
|
|
68
|
+
];
|
|
65
69
|
const hasFloatingLabel = $derived(floatingStyles.includes(style) && !!label);
|
|
66
70
|
const hasValue = $derived(!!value);
|
|
67
71
|
const floated = $derived(open || hasValue);
|
|
@@ -76,13 +80,13 @@
|
|
|
76
80
|
|
|
77
81
|
const months = $derived(
|
|
78
82
|
Array.from({ length: 12 }, (_, i) =>
|
|
79
|
-
new Date(2000, i, 1).toLocaleString(locale, { month: "short" })
|
|
80
|
-
)
|
|
83
|
+
new Date(2000, i, 1).toLocaleString(locale, { month: "short" }),
|
|
84
|
+
),
|
|
81
85
|
);
|
|
82
86
|
const weekdays = $derived(
|
|
83
87
|
Array.from({ length: 7 }, (_, i) =>
|
|
84
|
-
new Date(2000, 0, i + 2).toLocaleString(locale, { weekday: "short" })
|
|
85
|
-
)
|
|
88
|
+
new Date(2000, 0, i + 2).toLocaleString(locale, { weekday: "short" }),
|
|
89
|
+
),
|
|
86
90
|
);
|
|
87
91
|
|
|
88
92
|
function calendarDays(year, month) {
|
|
@@ -93,27 +97,41 @@
|
|
|
93
97
|
for (let i = fd - 1; i >= 0; i--) days.push({ d: pmd - i, o: true });
|
|
94
98
|
for (let i = 1; i <= dim; i++) days.push({ d: i, o: false });
|
|
95
99
|
let n = 1;
|
|
96
|
-
while (days.length < 42) {
|
|
100
|
+
while (days.length < 42) {
|
|
101
|
+
days.push({ d: n++, o: true });
|
|
102
|
+
}
|
|
97
103
|
return days;
|
|
98
104
|
}
|
|
99
105
|
|
|
100
106
|
const calDays = $derived(calendarDays(viewYear, viewMonth));
|
|
101
107
|
const yearList = $derived(
|
|
102
|
-
Array.from({ length: 12 }, (_, i) => decadeStart + i)
|
|
108
|
+
Array.from({ length: 12 }, (_, i) => decadeStart + i),
|
|
103
109
|
);
|
|
104
110
|
|
|
105
111
|
function isToday(d, o) {
|
|
106
112
|
if (o) return false;
|
|
107
113
|
const t = new Date();
|
|
108
|
-
return
|
|
114
|
+
return (
|
|
115
|
+
d === t.getDate() &&
|
|
116
|
+
viewMonth === t.getMonth() &&
|
|
117
|
+
viewYear === t.getFullYear()
|
|
118
|
+
);
|
|
109
119
|
}
|
|
110
120
|
|
|
111
121
|
function isDisabled(d, o) {
|
|
112
122
|
if (o) return true;
|
|
113
123
|
const dt = new Date(viewYear, viewMonth, d);
|
|
114
124
|
const day = new Date(dt.getFullYear(), dt.getMonth(), dt.getDate());
|
|
115
|
-
const minDay = minDate
|
|
116
|
-
|
|
125
|
+
const minDay = minDate
|
|
126
|
+
? new Date(minDate.getFullYear(), minDate.getMonth(), minDate.getDate())
|
|
127
|
+
: null;
|
|
128
|
+
const maxDay = maxDate
|
|
129
|
+
? new Date(
|
|
130
|
+
maxDate.getFullYear(),
|
|
131
|
+
maxDate.getMonth(),
|
|
132
|
+
maxDate.getDate() + 1,
|
|
133
|
+
)
|
|
134
|
+
: null;
|
|
117
135
|
if (minDay && day < minDay) return true;
|
|
118
136
|
if (maxDay && day >= maxDay) return true;
|
|
119
137
|
return false;
|
|
@@ -121,7 +139,11 @@
|
|
|
121
139
|
|
|
122
140
|
function isSelected(d, o) {
|
|
123
141
|
if (!selectedDate || o) return false;
|
|
124
|
-
return
|
|
142
|
+
return (
|
|
143
|
+
d === selectedDate.getDate() &&
|
|
144
|
+
viewMonth === selectedDate.getMonth() &&
|
|
145
|
+
viewYear === selectedDate.getFullYear()
|
|
146
|
+
);
|
|
125
147
|
}
|
|
126
148
|
|
|
127
149
|
// Navigation
|
|
@@ -141,7 +163,11 @@
|
|
|
141
163
|
if (o) return;
|
|
142
164
|
const dt = new Date(viewYear, viewMonth, d);
|
|
143
165
|
if (selectedDate) {
|
|
144
|
-
dt.setHours(
|
|
166
|
+
dt.setHours(
|
|
167
|
+
selectedDate.getHours(),
|
|
168
|
+
selectedDate.getMinutes(),
|
|
169
|
+
selectedDate.getSeconds(),
|
|
170
|
+
);
|
|
145
171
|
}
|
|
146
172
|
selectedDate = dt;
|
|
147
173
|
value = fmt(dt, format);
|
|
@@ -230,7 +256,7 @@
|
|
|
230
256
|
class="s-datepicker-wrapper {styleClass} {themeClass}"
|
|
231
257
|
class:s-datepicker-open={open}
|
|
232
258
|
class:focused={open}
|
|
233
|
-
class:floated
|
|
259
|
+
class:floated
|
|
234
260
|
class:has-value={hasValue}
|
|
235
261
|
class:disabled
|
|
236
262
|
bind:this={wrapperEl}
|
|
@@ -246,13 +272,19 @@
|
|
|
246
272
|
value={displayValue}
|
|
247
273
|
placeholder={hasFloatingLabel ? "" : inputPlaceholder}
|
|
248
274
|
{disabled}
|
|
249
|
-
onfocus={() => {
|
|
250
|
-
|
|
275
|
+
onfocus={() => {
|
|
276
|
+
if (!disabled) open = true;
|
|
277
|
+
}}
|
|
278
|
+
onclick={() => {
|
|
279
|
+
if (!disabled) open = true;
|
|
280
|
+
}}
|
|
251
281
|
role="combobox"
|
|
252
282
|
aria-expanded={open}
|
|
253
283
|
aria-haspopup="dialog"
|
|
254
284
|
/>
|
|
255
|
-
<span class="s-datepicker-trigger-icon {iconClass}" aria-hidden="true"
|
|
285
|
+
<span class="s-datepicker-trigger-icon {iconClass}" aria-hidden="true"
|
|
286
|
+
>calendar_today</span
|
|
287
|
+
>
|
|
256
288
|
|
|
257
289
|
{#if open}
|
|
258
290
|
<div
|
|
@@ -264,24 +296,50 @@
|
|
|
264
296
|
>
|
|
265
297
|
<!-- Header -->
|
|
266
298
|
<div class="s-dp-header">
|
|
267
|
-
<button
|
|
299
|
+
<button
|
|
300
|
+
type="button"
|
|
301
|
+
class="s-dp-nav-btn"
|
|
302
|
+
onclick={prev}
|
|
303
|
+
aria-label="Previous">‹</button
|
|
304
|
+
>
|
|
268
305
|
<div class="s-dp-header-labels">
|
|
269
306
|
{#if view === "date"}
|
|
270
|
-
<button
|
|
271
|
-
|
|
307
|
+
<button
|
|
308
|
+
type="button"
|
|
309
|
+
class="s-dp-header-label"
|
|
310
|
+
onclick={() => (view = "month")}
|
|
311
|
+
>
|
|
312
|
+
{new Date(2000, viewMonth, 1).toLocaleString(locale, {
|
|
313
|
+
month: "long",
|
|
314
|
+
})}
|
|
272
315
|
</button>
|
|
273
|
-
<button
|
|
316
|
+
<button
|
|
317
|
+
type="button"
|
|
318
|
+
class="s-dp-header-label"
|
|
319
|
+
onclick={() => (view = "year")}
|
|
320
|
+
>
|
|
274
321
|
{viewYear}
|
|
275
322
|
</button>
|
|
276
323
|
{:else if view === "month"}
|
|
277
|
-
<button
|
|
324
|
+
<button
|
|
325
|
+
type="button"
|
|
326
|
+
class="s-dp-header-label s-dp-header-label-active"
|
|
327
|
+
onclick={() => (view = "year")}
|
|
328
|
+
>
|
|
278
329
|
{viewYear}
|
|
279
330
|
</button>
|
|
280
331
|
{:else}
|
|
281
|
-
<span class="s-dp-header-label s-dp-header-label-active"
|
|
332
|
+
<span class="s-dp-header-label s-dp-header-label-active"
|
|
333
|
+
>{decadeStart} – {decadeEnd}</span
|
|
334
|
+
>
|
|
282
335
|
{/if}
|
|
283
336
|
</div>
|
|
284
|
-
<button
|
|
337
|
+
<button
|
|
338
|
+
type="button"
|
|
339
|
+
class="s-dp-nav-btn"
|
|
340
|
+
onclick={next}
|
|
341
|
+
aria-label="Next">›</button
|
|
342
|
+
>
|
|
285
343
|
</div>
|
|
286
344
|
|
|
287
345
|
<!-- Date view -->
|
|
@@ -301,34 +359,37 @@
|
|
|
301
359
|
class:s-dp-selected={isSelected(cd.d, cd.o)}
|
|
302
360
|
class:s-dp-day-disabled={isDisabled(cd.d, cd.o)}
|
|
303
361
|
onclick={() => selectDay(cd.d, cd.o)}
|
|
304
|
-
disabled={cd.o || isDisabled(cd.d, cd.o)}
|
|
305
|
-
>
|
|
362
|
+
disabled={cd.o || isDisabled(cd.d, cd.o)}>{cd.d}</button
|
|
363
|
+
>
|
|
306
364
|
{/each}
|
|
307
365
|
</div>
|
|
308
366
|
|
|
309
|
-
|
|
367
|
+
<!-- Month view -->
|
|
310
368
|
{:else if view === "month"}
|
|
311
369
|
<div class="s-dp-months-grid">
|
|
312
370
|
{#each months as m, i}
|
|
313
371
|
<button
|
|
314
372
|
type="button"
|
|
315
373
|
class="s-dp-month"
|
|
316
|
-
class:s-dp-selected={selectedDate &&
|
|
317
|
-
|
|
318
|
-
|
|
374
|
+
class:s-dp-selected={selectedDate &&
|
|
375
|
+
i === selectedDate.getMonth() &&
|
|
376
|
+
viewYear === selectedDate.getFullYear()}
|
|
377
|
+
onclick={() => selectMonth(i)}>{m}</button
|
|
378
|
+
>
|
|
319
379
|
{/each}
|
|
320
380
|
</div>
|
|
321
381
|
|
|
322
|
-
|
|
382
|
+
<!-- Year view (decade) -->
|
|
323
383
|
{:else}
|
|
324
384
|
<div class="s-dp-years-grid">
|
|
325
385
|
{#each yearList as y (y)}
|
|
326
386
|
<button
|
|
327
387
|
type="button"
|
|
328
388
|
class="s-dp-year"
|
|
329
|
-
class:s-dp-selected={selectedDate &&
|
|
330
|
-
|
|
331
|
-
|
|
389
|
+
class:s-dp-selected={selectedDate &&
|
|
390
|
+
y === selectedDate.getFullYear()}
|
|
391
|
+
onclick={() => selectYear(y)}>{y}</button
|
|
392
|
+
>
|
|
332
393
|
{/each}
|
|
333
394
|
</div>
|
|
334
395
|
{/if}
|
|
@@ -339,18 +400,39 @@
|
|
|
339
400
|
<span class="s-dp-time-label">Time</span>
|
|
340
401
|
<div class="s-dp-time-inputs">
|
|
341
402
|
{#if showHours}
|
|
342
|
-
<input
|
|
343
|
-
|
|
403
|
+
<input
|
|
404
|
+
type="number"
|
|
405
|
+
class="s-dp-time-input"
|
|
406
|
+
min={0}
|
|
407
|
+
max={23}
|
|
408
|
+
value={currentHour}
|
|
409
|
+
oninput={(e) => setHour(parseInt(e.target.value) || 0)}
|
|
410
|
+
aria-label="Hour"
|
|
411
|
+
/>
|
|
344
412
|
<span class="s-dp-time-sep">:</span>
|
|
345
413
|
{/if}
|
|
346
414
|
{#if showMinutes}
|
|
347
|
-
<input
|
|
348
|
-
|
|
415
|
+
<input
|
|
416
|
+
type="number"
|
|
417
|
+
class="s-dp-time-input"
|
|
418
|
+
min={0}
|
|
419
|
+
max={59}
|
|
420
|
+
value={currentMinute}
|
|
421
|
+
oninput={(e) => setMinute(parseInt(e.target.value) || 0)}
|
|
422
|
+
aria-label="Minute"
|
|
423
|
+
/>
|
|
349
424
|
{/if}
|
|
350
425
|
{#if showSeconds}
|
|
351
426
|
<span class="s-dp-time-sep">:</span>
|
|
352
|
-
<input
|
|
353
|
-
|
|
427
|
+
<input
|
|
428
|
+
type="number"
|
|
429
|
+
class="s-dp-time-input"
|
|
430
|
+
min={0}
|
|
431
|
+
max={59}
|
|
432
|
+
value={currentSecond}
|
|
433
|
+
oninput={(e) => setSecond(parseInt(e.target.value) || 0)}
|
|
434
|
+
aria-label="Second"
|
|
435
|
+
/>
|
|
354
436
|
{/if}
|
|
355
437
|
</div>
|
|
356
438
|
</div>
|
|
@@ -358,7 +440,11 @@
|
|
|
358
440
|
|
|
359
441
|
<!-- Mobile done button -->
|
|
360
442
|
{#if isMobile}
|
|
361
|
-
<button
|
|
443
|
+
<button
|
|
444
|
+
type="button"
|
|
445
|
+
class="s-dp-done-btn"
|
|
446
|
+
onclick={() => (open = false)}>Done</button
|
|
447
|
+
>
|
|
362
448
|
{/if}
|
|
363
449
|
</div>
|
|
364
450
|
{/if}
|
|
@@ -80,7 +80,8 @@
|
|
|
80
80
|
<span class="s-input-icon s-input-icon-start {iconClass}">{iconStart}</span>
|
|
81
81
|
{/if}
|
|
82
82
|
{#if hasFloatingLabel}
|
|
83
|
-
<label class="s-input-floating-label" for={internalId}>{displayLabel}</label
|
|
83
|
+
<label class="s-input-floating-label" for={internalId}>{displayLabel}</label
|
|
84
|
+
>
|
|
84
85
|
{/if}
|
|
85
86
|
<input
|
|
86
87
|
{type}
|
|
@@ -118,4 +119,4 @@
|
|
|
118
119
|
{#if style === "fluent"}
|
|
119
120
|
<span class="s-input-fluent-border-indicator"></span>
|
|
120
121
|
{/if}
|
|
121
|
-
</div>
|
|
122
|
+
</div>
|
|
@@ -19,10 +19,24 @@
|
|
|
19
19
|
let open = $state(false);
|
|
20
20
|
let focused = $state(false);
|
|
21
21
|
let hasValue = $derived(selected.length > 0);
|
|
22
|
+
let floated = $derived(focused || hasValue);
|
|
22
23
|
|
|
23
24
|
const styleClass = $derived(`s-mselect-${style}`);
|
|
24
25
|
const themeClass = $derived(`theme-${theme}`);
|
|
25
26
|
|
|
27
|
+
const floatingStyles = [
|
|
28
|
+
"material",
|
|
29
|
+
"material3",
|
|
30
|
+
"fluent",
|
|
31
|
+
"carbon",
|
|
32
|
+
"bootstrap",
|
|
33
|
+
"legacy-ios",
|
|
34
|
+
];
|
|
35
|
+
const hasFloatingLabel = $derived(
|
|
36
|
+
floatingStyles.includes(style) && (label || placeholder),
|
|
37
|
+
);
|
|
38
|
+
const displayLabel = $derived(label || placeholder);
|
|
39
|
+
|
|
26
40
|
function toggle(val) {
|
|
27
41
|
if (selected.includes(val)) {
|
|
28
42
|
selected = selected.filter((v) => v !== val);
|
|
@@ -54,13 +68,17 @@
|
|
|
54
68
|
class:focused
|
|
55
69
|
class:open
|
|
56
70
|
class:has-value={hasValue}
|
|
71
|
+
class:floated
|
|
57
72
|
tabindex="-1"
|
|
58
73
|
role="listbox"
|
|
59
|
-
aria-label={
|
|
74
|
+
aria-label={displayLabel}
|
|
60
75
|
onfocusin={() => (focused = true)}
|
|
61
76
|
onfocusout={handleBlur}
|
|
62
77
|
{...rest}
|
|
63
78
|
>
|
|
79
|
+
{#if hasFloatingLabel}
|
|
80
|
+
<label class="s-mselect-floating-label">{displayLabel}</label>
|
|
81
|
+
{/if}
|
|
64
82
|
<div
|
|
65
83
|
class="mselect-control"
|
|
66
84
|
role="button"
|
|
@@ -90,7 +108,7 @@
|
|
|
90
108
|
</span>
|
|
91
109
|
{/each}
|
|
92
110
|
</div>
|
|
93
|
-
{:else}
|
|
111
|
+
{:else if !hasFloatingLabel}
|
|
94
112
|
<span class="mselect-placeholder">{placeholder}</span>
|
|
95
113
|
{/if}
|
|
96
114
|
<span class="mselect-arrow">
|
|
@@ -49,7 +49,9 @@
|
|
|
49
49
|
class:floated
|
|
50
50
|
>
|
|
51
51
|
{#if hasFloatingLabel}
|
|
52
|
-
<label class="s-select-floating-label" for={internalId}
|
|
52
|
+
<label class="s-select-floating-label" for={internalId}
|
|
53
|
+
>{displayLabel}</label
|
|
54
|
+
>
|
|
53
55
|
{/if}
|
|
54
56
|
<select
|
|
55
57
|
bind:value
|
|
@@ -77,4 +79,4 @@
|
|
|
77
79
|
/>
|
|
78
80
|
</svg>
|
|
79
81
|
</span>
|
|
80
|
-
</div>
|
|
82
|
+
</div>
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
left: 14px;
|
|
44
44
|
top: 16px;
|
|
45
45
|
font-size: 15px;
|
|
46
|
-
color: var(--t-text
|
|
46
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
47
47
|
transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
|
|
48
48
|
transform-origin: left center;
|
|
49
49
|
white-space: nowrap;
|
|
@@ -380,19 +380,35 @@
|
|
|
380
380
|
* Material is the base look defined above; the other styles override from there.
|
|
381
381
|
*/
|
|
382
382
|
|
|
383
|
-
/* ----- Material
|
|
383
|
+
/* ----- Material ----- underline input, rounded top */
|
|
384
|
+
.s-datepicker-material input {
|
|
385
|
+
background: color-mix(in srgb, var(--t-primary) 4%, var(--t-surface));
|
|
386
|
+
border: none;
|
|
387
|
+
border-bottom: var(--t-border-width) solid var(--t-border);
|
|
388
|
+
border-radius: var(--t-card-radius) var(--t-card-radius) 0 0;
|
|
389
|
+
}
|
|
390
|
+
.s-datepicker-material input:hover {
|
|
391
|
+
background: color-mix(in srgb, var(--t-primary) 8%, var(--t-surface));
|
|
392
|
+
border-bottom-color: var(--t-text);
|
|
393
|
+
}
|
|
394
|
+
.s-datepicker-material.s-datepicker-open input,
|
|
395
|
+
.s-datepicker-material input:focus {
|
|
396
|
+
border-bottom-color: var(--t-primary);
|
|
397
|
+
background: color-mix(in srgb, var(--t-primary) 10%, var(--t-surface));
|
|
398
|
+
box-shadow: none;
|
|
399
|
+
}
|
|
384
400
|
.s-datepicker-material .s-dp-floating-label {
|
|
385
401
|
left: 14px;
|
|
386
402
|
top: 16px;
|
|
387
403
|
font-size: 15px;
|
|
388
|
-
color: var(--t-
|
|
404
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
389
405
|
}
|
|
390
406
|
.s-datepicker-material.floated .s-dp-floating-label {
|
|
391
407
|
transform: translateY(-12px) scale(0.75);
|
|
392
408
|
color: var(--t-primary);
|
|
393
409
|
}
|
|
394
410
|
.s-datepicker-material:not(.focused).has-value .s-dp-floating-label {
|
|
395
|
-
color: var(--t-
|
|
411
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
396
412
|
}
|
|
397
413
|
|
|
398
414
|
/* ----- Material 3 ----- pill cells, outlined today, larger radii */
|
|
@@ -441,7 +457,7 @@
|
|
|
441
457
|
left: 14px;
|
|
442
458
|
top: 16px;
|
|
443
459
|
font-size: 15px;
|
|
444
|
-
color: var(--t-
|
|
460
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
445
461
|
background: transparent;
|
|
446
462
|
padding: 0 4px;
|
|
447
463
|
}
|
|
@@ -451,7 +467,7 @@
|
|
|
451
467
|
background: var(--t-surface);
|
|
452
468
|
}
|
|
453
469
|
.s-datepicker-material3:not(.focused).has-value .s-dp-floating-label {
|
|
454
|
-
color: var(--t-
|
|
470
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
455
471
|
background: var(--t-surface);
|
|
456
472
|
transform: translateY(-24px) scale(0.75);
|
|
457
473
|
}
|
|
@@ -491,7 +507,7 @@
|
|
|
491
507
|
left: 12px;
|
|
492
508
|
top: 15px;
|
|
493
509
|
font-size: 14px;
|
|
494
|
-
color: var(--t-
|
|
510
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
495
511
|
}
|
|
496
512
|
.s-datepicker-fluent.floated .s-dp-floating-label {
|
|
497
513
|
transform: translateY(-9px) scale(0.78);
|
|
@@ -724,14 +740,14 @@
|
|
|
724
740
|
left: 12px;
|
|
725
741
|
top: 15px;
|
|
726
742
|
font-size: 15px;
|
|
727
|
-
color: var(--t-text
|
|
743
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
728
744
|
}
|
|
729
745
|
.s-datepicker-bootstrap.floated .s-dp-floating-label {
|
|
730
746
|
transform: translateY(-10px) scale(0.75);
|
|
731
747
|
color: var(--t-primary);
|
|
732
748
|
}
|
|
733
749
|
.s-datepicker-bootstrap:not(.focused).has-value .s-dp-floating-label {
|
|
734
|
-
color: var(--t-text
|
|
750
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
735
751
|
}
|
|
736
752
|
|
|
737
753
|
/* ----- Cartoon ----- big rounded corners, offset shadow, bouncy */
|
|
@@ -878,7 +894,7 @@
|
|
|
878
894
|
top: 8px;
|
|
879
895
|
font-size: 12px;
|
|
880
896
|
font-family: 'IBM Plex Sans', sans-serif;
|
|
881
|
-
color: var(--t-text
|
|
897
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
882
898
|
transform: none;
|
|
883
899
|
}
|
|
884
900
|
.s-datepicker-carbon.floated .s-dp-floating-label {
|
|
@@ -12,6 +12,9 @@
|
|
|
12
12
|
outline: none;
|
|
13
13
|
transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
|
|
14
14
|
}
|
|
15
|
+
.s-input-wrapper input::placeholder {
|
|
16
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
17
|
+
}
|
|
15
18
|
.s-input-wrapper.disabled {
|
|
16
19
|
opacity: 0.45;
|
|
17
20
|
pointer-events: none;
|
|
@@ -84,14 +87,14 @@
|
|
|
84
87
|
left: 16px;
|
|
85
88
|
top: 16px;
|
|
86
89
|
font-size: 16px;
|
|
87
|
-
color: var(--t-
|
|
90
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
88
91
|
}
|
|
89
92
|
.s-input-material.floated .s-input-floating-label {
|
|
90
93
|
transform: translateY(-12px) scale(0.75);
|
|
91
94
|
color: var(--t-primary);
|
|
92
95
|
}
|
|
93
96
|
.s-input-material:not(.focused).has-value .s-input-floating-label {
|
|
94
|
-
color: var(--t-
|
|
97
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
95
98
|
}
|
|
96
99
|
|
|
97
100
|
/* ===== MATERIAL 3 — outlined, label on border ===== */
|
|
@@ -116,7 +119,7 @@
|
|
|
116
119
|
left: 14px;
|
|
117
120
|
top: 16px;
|
|
118
121
|
font-size: 16px;
|
|
119
|
-
color: var(--t-
|
|
122
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
120
123
|
background: transparent;
|
|
121
124
|
padding: 0 4px;
|
|
122
125
|
}
|
|
@@ -126,7 +129,7 @@
|
|
|
126
129
|
background: var(--t-surface);
|
|
127
130
|
}
|
|
128
131
|
.s-input-material3:not(.focused).has-value .s-input-floating-label {
|
|
129
|
-
color: var(--t-
|
|
132
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
130
133
|
background: var(--t-surface);
|
|
131
134
|
transform: translateY(-24px) scale(0.75);
|
|
132
135
|
}
|
|
@@ -149,7 +152,7 @@
|
|
|
149
152
|
left: 12px;
|
|
150
153
|
top: 15px;
|
|
151
154
|
font-size: 14px;
|
|
152
|
-
color: var(--t-
|
|
155
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
153
156
|
}
|
|
154
157
|
.s-input-fluent.floated .s-input-floating-label {
|
|
155
158
|
transform: translateY(-9px) scale(0.78);
|
|
@@ -222,8 +225,6 @@
|
|
|
222
225
|
box-shadow: inset -3px -3px 0 rgba(0,0,0,0.25), inset 3px 3px 0 rgba(255,255,255,0.1), 0 0 0 3px var(--t-shadow);
|
|
223
226
|
color: var(--t-text);
|
|
224
227
|
}
|
|
225
|
-
.s-input-pixel input::placeholder { color: var(--t-text-muted); }
|
|
226
|
-
|
|
227
228
|
/* ===== NEON UI ===== */
|
|
228
229
|
.s-input-neon input {
|
|
229
230
|
padding: 12px 16px;
|
|
@@ -243,8 +244,6 @@
|
|
|
243
244
|
box-shadow: 0 0 10px var(--t-primary), 0 0 25px var(--t-primary), 0 0 50px var(--t-shadow), inset 0 0 10px rgba(0, 0, 0, 0.2);
|
|
244
245
|
animation: none;
|
|
245
246
|
}
|
|
246
|
-
.s-input-neon input::placeholder { color: var(--t-text-muted); }
|
|
247
|
-
|
|
248
247
|
@keyframes neonPulse {
|
|
249
248
|
0% { box-shadow: 0 0 4px var(--t-primary), inset 0 0 4px rgba(0, 0, 0, 0.5); }
|
|
250
249
|
100% { box-shadow: 0 0 8px var(--t-primary), 0 0 12px var(--t-shadow), inset 0 0 6px rgba(0, 0, 0, 0.4); }
|
|
@@ -289,11 +288,11 @@
|
|
|
289
288
|
left: 12px;
|
|
290
289
|
top: 15px;
|
|
291
290
|
font-size: 15px;
|
|
292
|
-
color: var(--t-text
|
|
291
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
293
292
|
}
|
|
294
293
|
.s-input-bootstrap.floated .s-input-floating-label {
|
|
295
294
|
transform: translateY(-10px) scale(0.75);
|
|
296
|
-
color: var(--t-
|
|
295
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
297
296
|
}
|
|
298
297
|
.s-input-bootstrap:not(.focused).has-value .s-input-floating-label {
|
|
299
298
|
color: var(--t-text-hint);
|
|
@@ -364,12 +363,12 @@
|
|
|
364
363
|
top: 8px;
|
|
365
364
|
font-size: 12px;
|
|
366
365
|
font-family: 'IBM Plex Sans', sans-serif;
|
|
367
|
-
color: var(--t-text
|
|
366
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
368
367
|
transform: none;
|
|
369
368
|
}
|
|
370
369
|
.s-input-carbon.floated .s-input-floating-label {
|
|
371
370
|
transform: none;
|
|
372
|
-
color: var(--t-text
|
|
371
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
373
372
|
}
|
|
374
373
|
.s-input-carbon.focused .s-input-floating-label {
|
|
375
374
|
color: var(--t-primary);
|
|
@@ -425,12 +424,12 @@
|
|
|
425
424
|
left: 16px;
|
|
426
425
|
top: 16px;
|
|
427
426
|
font-size: 16px;
|
|
428
|
-
color: var(--t-text
|
|
427
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
429
428
|
}
|
|
430
429
|
.s-input-legacy-ios.floated .s-input-floating-label {
|
|
431
430
|
transform: translateY(-10px) scale(0.75);
|
|
432
431
|
color: var(--t-primary);
|
|
433
432
|
}
|
|
434
433
|
.s-input-legacy-ios:not(.focused).has-value .s-input-floating-label {
|
|
435
|
-
color: var(--t-text
|
|
434
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
436
435
|
}
|
|
@@ -11,8 +11,8 @@
|
|
|
11
11
|
align-items: center;
|
|
12
12
|
flex-wrap: wrap;
|
|
13
13
|
gap: 4px;
|
|
14
|
-
min-height:
|
|
15
|
-
padding:
|
|
14
|
+
min-height: 56px;
|
|
15
|
+
padding: 14px 36px 14px 12px;
|
|
16
16
|
background: var(--t-surface);
|
|
17
17
|
color: var(--t-text);
|
|
18
18
|
border: var(--t-border-width) solid var(--t-border);
|
|
@@ -106,8 +106,198 @@
|
|
|
106
106
|
transform: translateY(-50%) rotate(180deg);
|
|
107
107
|
}
|
|
108
108
|
|
|
109
|
+
/* ===== FLOATING LABEL ===== */
|
|
110
|
+
.s-mselect-floating-label {
|
|
111
|
+
position: absolute;
|
|
112
|
+
pointer-events: none;
|
|
113
|
+
left: 12px;
|
|
114
|
+
top: 12px;
|
|
115
|
+
font-size: 15px;
|
|
116
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
117
|
+
transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
|
|
118
|
+
transform-origin: left center;
|
|
119
|
+
z-index: 1;
|
|
120
|
+
}
|
|
121
|
+
.s-mselect-wrapper.floated .s-mselect-floating-label {
|
|
122
|
+
transform: translateY(-10px) scale(0.75);
|
|
123
|
+
color: var(--t-primary);
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
/* ===== FLOATING LABEL PADDING ===== */
|
|
127
|
+
.s-mselect-material .mselect-control,
|
|
128
|
+
.s-mselect-material3 .mselect-control,
|
|
129
|
+
.s-mselect-fluent .mselect-control,
|
|
130
|
+
.s-mselect-carbon .mselect-control,
|
|
131
|
+
.s-mselect-bootstrap .mselect-control,
|
|
132
|
+
.s-mselect-legacy-ios .mselect-control {
|
|
133
|
+
padding-top: 27px;
|
|
134
|
+
padding-bottom: 9px;
|
|
135
|
+
}
|
|
136
|
+
|
|
109
137
|
/* ===== STYLE OVERRIDES ===== */
|
|
110
138
|
|
|
139
|
+
/* Material */
|
|
140
|
+
.s-mselect-material .mselect-control {
|
|
141
|
+
background: color-mix(in srgb, var(--t-primary) 4%, var(--t-surface));
|
|
142
|
+
border: none;
|
|
143
|
+
border-bottom: var(--t-border-width) solid var(--t-border);
|
|
144
|
+
border-radius: var(--t-card-radius) var(--t-card-radius) 0 0;
|
|
145
|
+
}
|
|
146
|
+
.s-mselect-material .mselect-control:hover {
|
|
147
|
+
background: color-mix(in srgb, var(--t-primary) 8%, var(--t-surface));
|
|
148
|
+
border-bottom-color: var(--t-text);
|
|
149
|
+
}
|
|
150
|
+
.s-mselect-material.focused .mselect-control {
|
|
151
|
+
border-bottom-color: var(--t-primary);
|
|
152
|
+
background: color-mix(in srgb, var(--t-primary) 10%, var(--t-surface));
|
|
153
|
+
box-shadow: none;
|
|
154
|
+
}
|
|
155
|
+
.s-mselect-material .s-mselect-floating-label {
|
|
156
|
+
left: 12px;
|
|
157
|
+
top: 14px;
|
|
158
|
+
font-size: 16px;
|
|
159
|
+
}
|
|
160
|
+
.s-mselect-material.floated .s-mselect-floating-label {
|
|
161
|
+
transform: translateY(-12px) scale(0.75);
|
|
162
|
+
color: var(--t-primary);
|
|
163
|
+
}
|
|
164
|
+
.s-mselect-material:not(.focused).has-value .s-mselect-floating-label {
|
|
165
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
/* Material 3 */
|
|
169
|
+
.s-mselect-material3 .mselect-control {
|
|
170
|
+
background: var(--t-surface);
|
|
171
|
+
border: var(--t-border-width) solid var(--t-border);
|
|
172
|
+
border-radius: var(--t-card-radius);
|
|
173
|
+
}
|
|
174
|
+
.s-mselect-material3 .mselect-control:hover {
|
|
175
|
+
border-color: var(--t-text);
|
|
176
|
+
}
|
|
177
|
+
.s-mselect-material3.focused .mselect-control {
|
|
178
|
+
border-color: var(--t-primary);
|
|
179
|
+
border-width: calc(var(--t-border-width) + 0.5px);
|
|
180
|
+
}
|
|
181
|
+
.s-mselect-material3 .s-mselect-floating-label {
|
|
182
|
+
left: 12px;
|
|
183
|
+
top: 14px;
|
|
184
|
+
font-size: 16px;
|
|
185
|
+
background: transparent;
|
|
186
|
+
padding: 0 4px;
|
|
187
|
+
}
|
|
188
|
+
.s-mselect-material3.floated .s-mselect-floating-label {
|
|
189
|
+
transform: translateY(-22px) scale(0.75);
|
|
190
|
+
color: var(--t-primary);
|
|
191
|
+
background: var(--t-surface);
|
|
192
|
+
}
|
|
193
|
+
.s-mselect-material3:not(.focused).has-value .s-mselect-floating-label {
|
|
194
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
195
|
+
background: var(--t-surface);
|
|
196
|
+
transform: translateY(-22px) scale(0.75);
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
/* Fluent */
|
|
200
|
+
.s-mselect-fluent .mselect-control {
|
|
201
|
+
background: var(--t-surface);
|
|
202
|
+
border: var(--t-border-width) solid var(--t-border);
|
|
203
|
+
border-radius: var(--t-card-radius);
|
|
204
|
+
border-bottom: 2px solid var(--t-border);
|
|
205
|
+
}
|
|
206
|
+
.s-mselect-fluent .mselect-control:hover {
|
|
207
|
+
border-color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
208
|
+
border-bottom-color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
209
|
+
}
|
|
210
|
+
.s-mselect-fluent .s-mselect-floating-label {
|
|
211
|
+
left: 12px;
|
|
212
|
+
top: 13px;
|
|
213
|
+
font-size: 14px;
|
|
214
|
+
}
|
|
215
|
+
.s-mselect-fluent.floated .s-mselect-floating-label {
|
|
216
|
+
transform: translateY(-9px) scale(0.78);
|
|
217
|
+
color: var(--t-primary);
|
|
218
|
+
font-weight: 600;
|
|
219
|
+
}
|
|
220
|
+
.s-mselect-fluent:not(.focused).has-value .s-mselect-floating-label {
|
|
221
|
+
color: var(--t-text);
|
|
222
|
+
font-weight: 400;
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
/* Bootstrap */
|
|
226
|
+
.s-mselect-bootstrap .mselect-control {
|
|
227
|
+
border-radius: 6px;
|
|
228
|
+
border: var(--t-border-width) solid var(--t-border);
|
|
229
|
+
box-shadow: var(--t-shadow-xs);
|
|
230
|
+
}
|
|
231
|
+
.s-mselect-bootstrap.focused .mselect-control {
|
|
232
|
+
box-shadow: 0 0 0 3px var(--t-shadow);
|
|
233
|
+
border-color: var(--t-primary);
|
|
234
|
+
}
|
|
235
|
+
.s-mselect-bootstrap .mselect-dropdown { border-radius: 6px; }
|
|
236
|
+
.s-mselect-bootstrap .s-mselect-floating-label {
|
|
237
|
+
left: 12px;
|
|
238
|
+
top: 13px;
|
|
239
|
+
font-size: 15px;
|
|
240
|
+
}
|
|
241
|
+
.s-mselect-bootstrap.floated .s-mselect-floating-label {
|
|
242
|
+
transform: translateY(-10px) scale(0.75);
|
|
243
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
244
|
+
}
|
|
245
|
+
.s-mselect-bootstrap:not(.focused).has-value .s-mselect-floating-label {
|
|
246
|
+
color: var(--t-text-hint);
|
|
247
|
+
}
|
|
248
|
+
|
|
249
|
+
/* Carbon */
|
|
250
|
+
.s-mselect-carbon .mselect-control {
|
|
251
|
+
border-radius: 0;
|
|
252
|
+
border: var(--t-border-width) solid var(--t-border);
|
|
253
|
+
border-bottom-width: 2px;
|
|
254
|
+
box-shadow: none;
|
|
255
|
+
}
|
|
256
|
+
.s-mselect-carbon.focused .mselect-control {
|
|
257
|
+
border-bottom-color: var(--t-primary);
|
|
258
|
+
box-shadow: none;
|
|
259
|
+
}
|
|
260
|
+
.s-mselect-carbon .mselect-dropdown { border-radius: 0; }
|
|
261
|
+
.s-mselect-carbon .s-mselect-floating-label {
|
|
262
|
+
left: 12px;
|
|
263
|
+
top: 6px;
|
|
264
|
+
font-size: 12px;
|
|
265
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
266
|
+
transform: none;
|
|
267
|
+
}
|
|
268
|
+
.s-mselect-carbon.floated .s-mselect-floating-label {
|
|
269
|
+
transform: none;
|
|
270
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
271
|
+
}
|
|
272
|
+
.s-mselect-carbon.focused .s-mselect-floating-label {
|
|
273
|
+
color: var(--t-primary);
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
/* Legacy iOS */
|
|
277
|
+
.s-mselect-legacy-ios .mselect-control {
|
|
278
|
+
border-radius: 10px;
|
|
279
|
+
border: var(--t-border-width) solid var(--t-border);
|
|
280
|
+
background: linear-gradient(180deg, rgba(255,255,255,0.8) 0%, var(--t-surface) 100%);
|
|
281
|
+
box-shadow: inset 0 1px 0 rgba(255,255,255,0.8), var(--t-shadow-xs);
|
|
282
|
+
}
|
|
283
|
+
.s-mselect-legacy-ios.focused .mselect-control {
|
|
284
|
+
border-color: var(--t-primary);
|
|
285
|
+
box-shadow: inset 0 1px 0 rgba(255,255,255,0.8), 0 0 0 3px var(--t-shadow);
|
|
286
|
+
}
|
|
287
|
+
.s-mselect-legacy-ios .mselect-dropdown { border-radius: 10px; }
|
|
288
|
+
.s-mselect-legacy-ios .s-mselect-floating-label {
|
|
289
|
+
left: 12px;
|
|
290
|
+
top: 14px;
|
|
291
|
+
font-size: 16px;
|
|
292
|
+
}
|
|
293
|
+
.s-mselect-legacy-ios.floated .s-mselect-floating-label {
|
|
294
|
+
transform: translateY(-10px) scale(0.75);
|
|
295
|
+
color: var(--t-primary);
|
|
296
|
+
}
|
|
297
|
+
.s-mselect-legacy-ios:not(.focused).has-value .s-mselect-floating-label {
|
|
298
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
299
|
+
}
|
|
300
|
+
|
|
111
301
|
/* Brutalist */
|
|
112
302
|
.s-mselect-brutalist .mselect-control {
|
|
113
303
|
font-family: 'Courier New', monospace;
|
|
@@ -143,15 +333,6 @@
|
|
|
143
333
|
}
|
|
144
334
|
.s-mselect-metro .mselect-dropdown { border-radius: 0; border: var(--t-border-width) solid var(--t-primary); }
|
|
145
335
|
|
|
146
|
-
/* Bootstrap */
|
|
147
|
-
.s-mselect-bootstrap .mselect-control {
|
|
148
|
-
border-radius: 6px;
|
|
149
|
-
border: var(--t-border-width) solid var(--t-border);
|
|
150
|
-
box-shadow: var(--t-shadow-xs);
|
|
151
|
-
}
|
|
152
|
-
.s-mselect-bootstrap.focused .mselect-control { box-shadow: 0 0 0 3px var(--t-shadow); border-color: var(--t-primary); }
|
|
153
|
-
.s-mselect-bootstrap .mselect-dropdown { border-radius: 6px; }
|
|
154
|
-
|
|
155
336
|
/* Cartoon */
|
|
156
337
|
.s-mselect-cartoon .mselect-control {
|
|
157
338
|
border-radius: 16px;
|
|
@@ -170,17 +351,6 @@
|
|
|
170
351
|
}
|
|
171
352
|
.s-mselect-illustration .mselect-dropdown { border-radius: 8px; border: var(--t-border-width) solid var(--t-text); box-shadow: 3px 3px 0 var(--t-border); }
|
|
172
353
|
|
|
173
|
-
/* Carbon */
|
|
174
|
-
.s-mselect-carbon .mselect-control {
|
|
175
|
-
border-radius: 0;
|
|
176
|
-
border: var(--t-border-width) solid var(--t-border);
|
|
177
|
-
border-bottom-width: 2px;
|
|
178
|
-
font-family: 'IBM Plex Sans', sans-serif;
|
|
179
|
-
box-shadow: none;
|
|
180
|
-
}
|
|
181
|
-
.s-mselect-carbon.focused .mselect-control { border-bottom-color: var(--t-primary); box-shadow: none; }
|
|
182
|
-
.s-mselect-carbon .mselect-dropdown { border-radius: 0; }
|
|
183
|
-
|
|
184
354
|
/* Liquid Glass */
|
|
185
355
|
.s-mselect-liquid-glass .mselect-control {
|
|
186
356
|
border-radius: 16px;
|
|
@@ -192,11 +362,4 @@
|
|
|
192
362
|
}
|
|
193
363
|
.s-mselect-liquid-glass .mselect-dropdown { border-radius: 16px; backdrop-filter: blur(24px); background: rgba(255,255,255,0.1); border: 1px solid rgba(255,255,255,0.2); }
|
|
194
364
|
|
|
195
|
-
|
|
196
|
-
.s-mselect-legacy-ios .mselect-control {
|
|
197
|
-
border-radius: 10px;
|
|
198
|
-
border: var(--t-border-width) solid var(--t-border);
|
|
199
|
-
background: linear-gradient(180deg, rgba(255,255,255,0.8) 0%, var(--t-surface) 100%);
|
|
200
|
-
box-shadow: inset 0 1px 0 rgba(255,255,255,0.8), var(--t-shadow-xs);
|
|
201
|
-
}
|
|
202
|
-
.s-mselect-legacy-ios .mselect-dropdown { border-radius: 10px; }
|
|
365
|
+
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
left: 14px;
|
|
51
51
|
top: 14px;
|
|
52
52
|
font-size: 15px;
|
|
53
|
-
color: var(--t-
|
|
53
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
54
54
|
transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
|
|
55
55
|
transform-origin: left center;
|
|
56
56
|
}
|
|
@@ -66,8 +66,8 @@
|
|
|
66
66
|
.s-select-carbon select,
|
|
67
67
|
.s-select-bootstrap select,
|
|
68
68
|
.s-select-legacy-ios select {
|
|
69
|
-
padding-top:
|
|
70
|
-
padding-bottom:
|
|
69
|
+
padding-top: 24px;
|
|
70
|
+
padding-bottom: 8px;
|
|
71
71
|
}
|
|
72
72
|
|
|
73
73
|
/* ===== MATERIAL ===== */
|
|
@@ -77,10 +77,31 @@
|
|
|
77
77
|
border-bottom: var(--t-border-width) solid var(--t-border);
|
|
78
78
|
border-radius: var(--t-card-radius) var(--t-card-radius) 0 0;
|
|
79
79
|
}
|
|
80
|
+
.s-select-material select:hover {
|
|
81
|
+
background: color-mix(in srgb, var(--t-primary) 8%, var(--t-surface));
|
|
82
|
+
border-bottom-color: var(--t-text);
|
|
83
|
+
}
|
|
80
84
|
.s-select-material.focused select {
|
|
81
85
|
border-bottom-color: var(--t-primary);
|
|
86
|
+
background: color-mix(in srgb, var(--t-primary) 10%, var(--t-surface));
|
|
82
87
|
box-shadow: none;
|
|
83
88
|
}
|
|
89
|
+
.s-select-material .s-select-floating-label {
|
|
90
|
+
left: 16px;
|
|
91
|
+
top: 16px;
|
|
92
|
+
font-size: 16px;
|
|
93
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
94
|
+
}
|
|
95
|
+
.s-select-material.floated .s-select-floating-label {
|
|
96
|
+
transform: translateY(-12px) scale(0.75);
|
|
97
|
+
color: var(--t-primary);
|
|
98
|
+
}
|
|
99
|
+
.s-select-material:not(.focused).has-value .s-select-floating-label {
|
|
100
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
101
|
+
}
|
|
102
|
+
.s-select-material.focused .s-select-arrow {
|
|
103
|
+
color: var(--t-primary);
|
|
104
|
+
}
|
|
84
105
|
|
|
85
106
|
/* ===== MATERIAL 3 ===== */
|
|
86
107
|
.s-select-material3 select {
|
|
@@ -88,10 +109,31 @@
|
|
|
88
109
|
border: var(--t-border-width) solid var(--t-border);
|
|
89
110
|
border-radius: var(--t-card-radius);
|
|
90
111
|
}
|
|
112
|
+
.s-select-material3 select:hover {
|
|
113
|
+
border-color: var(--t-text);
|
|
114
|
+
}
|
|
91
115
|
.s-select-material3.focused select {
|
|
92
116
|
border-color: var(--t-primary);
|
|
93
117
|
border-width: calc(var(--t-border-width) + 0.5px);
|
|
94
118
|
}
|
|
119
|
+
.s-select-material3 .s-select-floating-label {
|
|
120
|
+
left: 14px;
|
|
121
|
+
top: 16px;
|
|
122
|
+
font-size: 16px;
|
|
123
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
124
|
+
background: transparent;
|
|
125
|
+
padding: 0 4px;
|
|
126
|
+
}
|
|
127
|
+
.s-select-material3.floated .s-select-floating-label {
|
|
128
|
+
transform: translateY(-24px) scale(0.75);
|
|
129
|
+
color: var(--t-primary);
|
|
130
|
+
background: var(--t-surface);
|
|
131
|
+
}
|
|
132
|
+
.s-select-material3:not(.focused).has-value .s-select-floating-label {
|
|
133
|
+
color: color-mix(in srgb, var(--t-text) 50%, transparent);
|
|
134
|
+
background: var(--t-surface);
|
|
135
|
+
transform: translateY(-24px) scale(0.75);
|
|
136
|
+
}
|
|
95
137
|
|
|
96
138
|
/* ===== STYLE OVERRIDES ===== */
|
|
97
139
|
|
package/package.json
CHANGED