@auronui/styles 1.1.0 → 1.1.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.
@@ -5,3 +5,21 @@
5
5
  @apply mt-4;
6
6
  }
7
7
  }
8
+
9
+ .checkbox-group__label {
10
+ @apply text-sm font-medium text-foreground;
11
+ }
12
+
13
+ .checkbox-group[aria-invalid="true"] .checkbox-group__label {
14
+ color: var(--color-danger);
15
+ }
16
+
17
+ .checkbox-group__description {
18
+ @apply text-xs mt-1;
19
+ color: color-mix(in oklab, var(--color-foreground) 60%, transparent);
20
+ }
21
+
22
+ .checkbox-group__error-message {
23
+ @apply text-xs mt-1;
24
+ color: var(--color-danger);
25
+ }
@@ -17,12 +17,8 @@
17
17
  @apply items-start;
18
18
  }
19
19
 
20
- [data-slot="label"] {
21
- @apply select-none;
22
- }
23
-
24
- [data-slot="description"] {
25
- @apply text-wrap select-none;
20
+ .checkbox__content {
21
+ @apply text-sm select-none;
26
22
  }
27
23
 
28
24
  /* Disabled state */
@@ -55,6 +51,11 @@
55
51
  transition: stroke-dashoffset 300ms linear 300ms;
56
52
  }
57
53
 
54
+ /* Invalid: label color */
55
+ &[aria-invalid="true"] .checkbox__content {
56
+ color: var(--color-danger);
57
+ }
58
+
58
59
  /* Invalid + Selected: checkmark icon color */
59
60
  &[aria-invalid="true"][data-state="checked"] [data-slot="checkbox-default-indicator--checkmark"],
60
61
  &[aria-invalid="true"][aria-checked="true"] [data-slot="checkbox-default-indicator--checkmark"],
@@ -437,7 +437,7 @@
437
437
  }
438
438
 
439
439
  /* Invalid state — label color flips to danger */
440
- .date-input--label-inside[data-invalid="true"] .date-input__label {
440
+ .date-input--label-inside.date-input--invalid .date-input__label {
441
441
  color: var(--color-danger);
442
442
  }
443
443
 
@@ -270,6 +270,10 @@
270
270
  gap: 0.05rem;
271
271
  }
272
272
 
273
+ .date-range-field__segment-list[data-type="end"] {
274
+ flex: 1;
275
+ }
276
+
273
277
  .date-range-field__separator {
274
278
  @apply inline-flex items-center justify-center shrink-0 select-none px-1;
275
279
  color: var(--color-field-placeholder);
@@ -446,7 +450,7 @@
446
450
  }
447
451
 
448
452
  /* Invalid state — label color flips to danger */
449
- .date-range-field--label-inside[data-invalid="true"] .date-range-field__label {
453
+ .date-range-field--label-inside.date-range-field--invalid .date-range-field__label {
450
454
  color: var(--color-danger);
451
455
  }
452
456
 
@@ -305,7 +305,7 @@
305
305
  /* ─── Slots ──────────────────────────────────────────────────────────────────── */
306
306
 
307
307
  .input__input {
308
- @apply flex-1 bg-transparent outline-none border-0 text-inherit;
308
+ @apply flex-1 bg-transparent outline-none border-0 text-inherit !min-w-4;
309
309
  @apply placeholder:text-field-placeholder;
310
310
  align-self: stretch;
311
311
  padding: 0.5rem 0.75rem;
@@ -349,6 +349,11 @@
349
349
  @apply size-4;
350
350
  }
351
351
 
352
+ .input--sm .input__start-content svg,
353
+ .input--sm .input__end-content svg {
354
+ @apply size-3.5;
355
+ }
356
+
352
357
  /* ─── Label slot ─────────────────────────────────────────────────────────────── */
353
358
 
354
359
  .input__label {
@@ -482,7 +487,7 @@
482
487
  }
483
488
 
484
489
  /* Invalid state — label color flips to danger */
485
- .input--label-inside[data-invalid="true"] .input__label {
490
+ .input--label-inside.input--invalid .input__label {
486
491
  color: var(--color-danger);
487
492
  }
488
493
 
@@ -494,6 +499,10 @@
494
499
  gap: 0.375rem;
495
500
  }
496
501
 
502
+ .input-root--sm {
503
+ gap: 0.25rem;
504
+ }
505
+
497
506
  .input-root--full-width {
498
507
  @apply w-full;
499
508
  }
@@ -504,6 +513,10 @@
504
513
  gap: 0.75rem;
505
514
  }
506
515
 
516
+ .input-root--sm.input-root--label-outside-left {
517
+ gap: 0.5rem;
518
+ }
519
+
507
520
  .input__main-wrapper {
508
521
  display: flex;
509
522
  flex-direction: column;
@@ -525,6 +538,17 @@
525
538
  color: var(--color-foreground);
526
539
  }
527
540
 
541
+ /* Scale outside label font with size variant */
542
+ .input-root--sm.input-root--label-outside > .input__label,
543
+ .input-root--sm.input-root--label-outside-left > .input__label {
544
+ font-size: var(--text-xs);
545
+ }
546
+
547
+ .input-root--lg.input-root--label-outside > .input__label,
548
+ .input-root--lg.input-root--label-outside-left > .input__label {
549
+ font-size: var(--text-base);
550
+ }
551
+
528
552
  /* Align outside-left label with input text baseline; defaults tuned for md. */
529
553
  .input-root--label-outside-left > .input__label {
530
554
  padding-top: 0.5rem;
@@ -532,6 +556,15 @@
532
556
  flex-shrink: 0;
533
557
  }
534
558
 
559
+ /* Adjust outside-left label vertical alignment for sm/lg input heights */
560
+ .input-root--sm.input-root--label-outside-left > .input__label {
561
+ padding-top: 0.3rem;
562
+ }
563
+
564
+ .input-root--lg.input-root--label-outside-left > .input__label {
565
+ padding-top: 0.7rem;
566
+ }
567
+
535
568
  .input-root--label-outside[data-invalid="true"] > .input__label,
536
569
  .input-root--label-outside-left[data-invalid="true"] > .input__label {
537
570
  color: var(--color-danger);
@@ -10,20 +10,20 @@
10
10
  &[data-state="open"] {
11
11
  @apply animate-in duration-300 ease-smooth fade-in-0 zoom-in-90;
12
12
 
13
- /* Placement-specific translations */
14
- &[data-placement="top"] {
13
+ /* Placement-specific translations (Reka sets data-side, not data-placement) */
14
+ &[data-side="top"] {
15
15
  @apply slide-in-from-bottom-1;
16
16
  }
17
17
 
18
- &[data-placement="bottom"] {
18
+ &[data-side="bottom"] {
19
19
  @apply slide-in-from-top-1;
20
20
  }
21
21
 
22
- &[data-placement="left"] {
22
+ &[data-side="left"] {
23
23
  @apply slide-in-from-right-1;
24
24
  }
25
25
 
26
- &[data-placement="right"] {
26
+ &[data-side="right"] {
27
27
  @apply slide-in-from-left-1;
28
28
  }
29
29
  }
@@ -43,16 +43,16 @@
43
43
  fill: var(--overlay);
44
44
  }
45
45
 
46
- /* Arrow rotation based on placement */
47
- &[data-placement="bottom"] [data-slot="popover-overlay-arrow"] {
46
+ /* Arrow rotation based on placement (Reka sets data-side, not data-placement) */
47
+ &[data-side="bottom"] [data-slot="popover-overlay-arrow"] {
48
48
  rotate: 180deg;
49
49
  }
50
50
 
51
- &[data-placement="left"] [data-slot="popover-overlay-arrow"] {
51
+ &[data-side="left"] [data-slot="popover-overlay-arrow"] {
52
52
  rotate: -90deg;
53
53
  }
54
54
 
55
- &[data-placement="right"] [data-slot="popover-overlay-arrow"] {
55
+ &[data-side="right"] [data-slot="popover-overlay-arrow"] {
56
56
  rotate: 90deg;
57
57
  }
58
58
  }
@@ -1,3 +1,21 @@
1
+ .radio-group__label {
2
+ @apply text-sm font-medium text-foreground;
3
+ }
4
+
5
+ .radio-group[aria-invalid="true"] .radio-group__label {
6
+ color: var(--color-danger);
7
+ }
8
+
9
+ .radio-group__description {
10
+ @apply text-xs mt-1;
11
+ color: color-mix(in oklab, var(--color-foreground) 60%, transparent);
12
+ }
13
+
14
+ .radio-group__error-message {
15
+ @apply text-xs mt-1;
16
+ color: var(--color-danger);
17
+ }
18
+
1
19
  /* Radio Group base styles */
2
20
  .radio-group {
3
21
  @apply flex flex-col;
@@ -7,12 +7,8 @@
7
7
 
8
8
  cursor: var(--cursor-interactive);
9
9
 
10
- [data-slot="label"] {
11
- @apply select-none;
12
- }
13
-
14
- [data-slot="description"] {
15
- @apply text-wrap select-none;
10
+ .radio__content {
11
+ @apply text-sm select-none;
16
12
  }
17
13
 
18
14
  /* Disabled state */
@@ -21,6 +17,11 @@
21
17
  &[aria-disabled="true"] {
22
18
  @apply status-disabled;
23
19
  }
20
+
21
+ /* Invalid: label color */
22
+ &[aria-invalid="true"] .radio__content {
23
+ color: var(--color-danger);
24
+ }
24
25
  }
25
26
 
26
27
  /* ==========================================================================
@@ -3,6 +3,23 @@
3
3
  @apply flex flex-col gap-6;
4
4
  }
5
5
 
6
+ .switch-group__label {
7
+ @apply text-sm font-medium text-foreground;
8
+ }
9
+
10
+ .switch-group[aria-invalid="true"] .switch-group__label {
11
+ color: var(--color-danger);
12
+ }
13
+
14
+ .switch-group__description {
15
+ @apply text-xs text-muted mt-1;
16
+ }
17
+
18
+ .switch-group__error-message {
19
+ @apply text-xs mt-1;
20
+ color: var(--color-danger);
21
+ }
22
+
6
23
  .switch-group__items {
7
24
  @apply flex gap-4;
8
25
  }
@@ -190,5 +190,16 @@
190
190
 
191
191
  /* Switch content */
192
192
  .switch__content {
193
- @apply flex flex-col gap-0;
193
+ @apply flex flex-col gap-0 text-sm select-none;
194
+ }
195
+
196
+ /* Invalid: label color */
197
+ .switch[aria-invalid="true"] .switch__content {
198
+ color: var(--color-danger);
199
+ }
200
+
201
+ /* Invalid: red outline on unchecked track only; checked track stays accent */
202
+ .switch[aria-invalid="true"]:not([data-state="checked"]):not([aria-checked="true"]) .switch__control {
203
+ outline: 2px solid var(--color-danger);
204
+ outline-offset: 1px;
194
205
  }
@@ -439,7 +439,7 @@
439
439
 
440
440
  /* Invalid state — label color flips to danger */
441
441
  .textarea--label-inside:has(> textarea:invalid) .textarea__label,
442
- .textarea--label-inside[data-invalid="true"] .textarea__label {
442
+ .textarea--label-inside.textarea--invalid .textarea__label {
443
443
  color: var(--color-danger);
444
444
  }
445
445
 
@@ -438,7 +438,7 @@
438
438
  }
439
439
 
440
440
  /* Invalid state — label color flips to danger */
441
- .time-field--label-inside[data-invalid="true"] .time-field__label {
441
+ .time-field--label-inside.time-field--invalid .time-field__label {
442
442
  color: var(--color-danger);
443
443
  }
444
444
 
@@ -7,22 +7,38 @@
7
7
  /* box-shadow: var(--shadow-overlay); */
8
8
  will-change: opacity, transform;
9
9
 
10
+ /* Entering animations */
11
+ &[data-state="delayed-open"],
12
+ &[data-state="instant-open"] {
13
+ @apply animate-in duration-150 ease-smooth fade-in-0 zoom-in-95;
14
+
15
+ &[data-side="top"] { @apply slide-in-from-bottom-1; }
16
+ &[data-side="bottom"] { @apply slide-in-from-top-1; }
17
+ &[data-side="left"] { @apply slide-in-from-right-1; }
18
+ &[data-side="right"] { @apply slide-in-from-left-1; }
19
+ }
20
+
21
+ /* Exiting animation */
22
+ &[data-state="closed"] {
23
+ @apply animate-out duration-100 ease-smooth fade-out zoom-out-95;
24
+ }
25
+
10
26
  /* Arrow styling */
11
27
  & [data-slot="overlay-arrow"] {
12
28
  @apply stroke-border/40;
13
29
  fill: var(--overlay);
14
30
  }
15
31
 
16
- /* Arrow rotation based on placement */
17
- &[data-placement="bottom"] [data-slot="overlay-arrow"] {
32
+ /* Arrow rotation based on placement (Reka sets data-side, not data-placement) */
33
+ &[data-side="bottom"] [data-slot="overlay-arrow"] {
18
34
  rotate: 180deg;
19
35
  }
20
36
 
21
- &[data-placement="left"] [data-slot="overlay-arrow"] {
37
+ &[data-side="left"] [data-slot="overlay-arrow"] {
22
38
  rotate: -90deg;
23
39
  }
24
40
 
25
- &[data-placement="right"] [data-slot="overlay-arrow"] {
41
+ &[data-side="right"] [data-slot="overlay-arrow"] {
26
42
  rotate: 90deg;
27
43
  }
28
44
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@auronui/styles",
3
- "version": "1.1.0",
3
+ "version": "1.1.1",
4
4
  "description": "Auron core styles — adapted for Reka UI",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -37,9 +37,9 @@ export const inputVariants = tv({
37
37
  raised: { inputWrapper: "input--raised" },
38
38
  },
39
39
  size: {
40
- sm: { inputWrapper: "input--sm" },
40
+ sm: { base: "input-root--sm", inputWrapper: "input--sm" },
41
41
  md: {},
42
- lg: { inputWrapper: "input--lg" },
42
+ lg: { base: "input-root--lg", inputWrapper: "input--lg" },
43
43
  },
44
44
  color: {
45
45
  default: { inputWrapper: "input--default" },