@auronui/styles 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (268) hide show
  1. package/DATA_ATTRIBUTES.md +163 -0
  2. package/LICENSE +21 -0
  3. package/README.md +54 -0
  4. package/base/base.css +40 -0
  5. package/components/accordion.css +201 -0
  6. package/components/alert-dialog.css +307 -0
  7. package/components/alert.css +143 -0
  8. package/components/aspect-ratio.css +8 -0
  9. package/components/autocomplete.css +685 -0
  10. package/components/avatar.css +78 -0
  11. package/components/badge.css +186 -0
  12. package/components/breadcrumbs.css +76 -0
  13. package/components/button-group.css +126 -0
  14. package/components/button.css +282 -0
  15. package/components/calendar-year-picker.css +193 -0
  16. package/components/calendar.css +332 -0
  17. package/components/card.css +225 -0
  18. package/components/checkbox-group.css +7 -0
  19. package/components/checkbox.css +268 -0
  20. package/components/chip.css +227 -0
  21. package/components/close-button.css +65 -0
  22. package/components/collapsible-group.css +7 -0
  23. package/components/collapsible.css +74 -0
  24. package/components/color-area.css +81 -0
  25. package/components/color-field.css +99 -0
  26. package/components/color-input-group.css +153 -0
  27. package/components/color-picker.css +121 -0
  28. package/components/color-slider.css +266 -0
  29. package/components/color-swatch-picker.css +247 -0
  30. package/components/color-swatch.css +42 -0
  31. package/components/combo-box.css +203 -0
  32. package/components/date-input-group.css +125 -0
  33. package/components/date-input.css +529 -0
  34. package/components/date-picker.css +86 -0
  35. package/components/date-range-field.css +538 -0
  36. package/components/date-range-picker.css +93 -0
  37. package/components/description.css +4 -0
  38. package/components/drawer.css +222 -0
  39. package/components/dropdown.css +67 -0
  40. package/components/empty-state.css +4 -0
  41. package/components/error-message.css +13 -0
  42. package/components/field-error.css +19 -0
  43. package/components/fieldset.css +39 -0
  44. package/components/header.css +7 -0
  45. package/components/index.css +164 -0
  46. package/components/input-otp.css +124 -0
  47. package/components/input.css +603 -0
  48. package/components/kbd.css +27 -0
  49. package/components/label.css +28 -0
  50. package/components/link.css +144 -0
  51. package/components/list-box-item.css +29 -0
  52. package/components/list-box-section.css +13 -0
  53. package/components/list-box.css +11 -0
  54. package/components/menu-item.css +68 -0
  55. package/components/menu-section.css +18 -0
  56. package/components/menu.css +7 -0
  57. package/components/meter.css +104 -0
  58. package/components/modal.css +335 -0
  59. package/components/number-field.css +395 -0
  60. package/components/pagination.css +157 -0
  61. package/components/popover.css +96 -0
  62. package/components/progress-bar.css +126 -0
  63. package/components/progress-circle.css +82 -0
  64. package/components/radio-group.css +47 -0
  65. package/components/radio.css +157 -0
  66. package/components/range-calendar.css +402 -0
  67. package/components/scroll-area.css +70 -0
  68. package/components/scroll-shadow.css +77 -0
  69. package/components/select.css +649 -0
  70. package/components/separator.css +59 -0
  71. package/components/skeleton.css +48 -0
  72. package/components/slider.css +155 -0
  73. package/components/spinner.css +42 -0
  74. package/components/splitter.css +74 -0
  75. package/components/stepper.css +160 -0
  76. package/components/surface.css +23 -0
  77. package/components/switch-group.css +17 -0
  78. package/components/switch.css +194 -0
  79. package/components/table.css +341 -0
  80. package/components/tabs.css +262 -0
  81. package/components/tag-group.css +66 -0
  82. package/components/tag.css +99 -0
  83. package/components/textarea.css +536 -0
  84. package/components/time-field.css +530 -0
  85. package/components/toast.css +267 -0
  86. package/components/toggle-button-group.css +174 -0
  87. package/components/toggle-button.css +149 -0
  88. package/components/toolbar.css +32 -0
  89. package/components/tooltip.css +47 -0
  90. package/components/tree.css +81 -0
  91. package/index.css +29 -0
  92. package/package.json +415 -0
  93. package/src/components/accordion/accordion.styles.ts +46 -0
  94. package/src/components/accordion/index.ts +1 -0
  95. package/src/components/alert/alert.styles.ts +37 -0
  96. package/src/components/alert/index.ts +1 -0
  97. package/src/components/alert-dialog/alert-dialog.styles.ts +72 -0
  98. package/src/components/alert-dialog/index.ts +1 -0
  99. package/src/components/aspect-ratio/aspect-ratio.styles.ts +10 -0
  100. package/src/components/aspect-ratio/index.ts +1 -0
  101. package/src/components/autocomplete/autocomplete.styles.ts +86 -0
  102. package/src/components/autocomplete/index.ts +1 -0
  103. package/src/components/avatar/avatar.styles.ts +53 -0
  104. package/src/components/avatar/index.ts +1 -0
  105. package/src/components/badge/badge.styles.ts +77 -0
  106. package/src/components/badge/index.ts +1 -0
  107. package/src/components/breadcrumbs/breadcrumbs.styles.ts +14 -0
  108. package/src/components/breadcrumbs/index.ts +1 -0
  109. package/src/components/button/__tests__/button.styles.test.ts +79 -0
  110. package/src/components/button/button.styles.ts +65 -0
  111. package/src/components/button/index.ts +1 -0
  112. package/src/components/button-group/button-group.styles.ts +32 -0
  113. package/src/components/button-group/index.ts +1 -0
  114. package/src/components/calendar/calendar.styles.ts +60 -0
  115. package/src/components/calendar/index.ts +1 -0
  116. package/src/components/calendar-year-picker/calendar-year-picker.styles.ts +15 -0
  117. package/src/components/calendar-year-picker/index.ts +1 -0
  118. package/src/components/card/card.styles.ts +65 -0
  119. package/src/components/card/index.ts +1 -0
  120. package/src/components/checkbox/checkbox.styles.ts +27 -0
  121. package/src/components/checkbox/index.ts +1 -0
  122. package/src/components/checkbox-group/checkbox-group.styles.ts +18 -0
  123. package/src/components/checkbox-group/index.ts +1 -0
  124. package/src/components/chip/chip.styles.ts +65 -0
  125. package/src/components/chip/index.ts +1 -0
  126. package/src/components/close-button/close-button.styles.ts +17 -0
  127. package/src/components/close-button/index.ts +1 -0
  128. package/src/components/collapsible/collapsible.styles.ts +25 -0
  129. package/src/components/collapsible/index.ts +1 -0
  130. package/src/components/collapsible-group/collapsible-group.styles.ts +13 -0
  131. package/src/components/collapsible-group/index.ts +1 -0
  132. package/src/components/color-area/color-area.styles.ts +23 -0
  133. package/src/components/color-area/index.ts +1 -0
  134. package/src/components/color-field/color-field.styles.ts +18 -0
  135. package/src/components/color-field/index.ts +1 -0
  136. package/src/components/color-input-group/color-input-group.styles.ts +34 -0
  137. package/src/components/color-input-group/index.ts +1 -0
  138. package/src/components/color-picker/color-picker.styles.ts +13 -0
  139. package/src/components/color-picker/index.ts +1 -0
  140. package/src/components/color-slider/color-slider.styles.ts +14 -0
  141. package/src/components/color-slider/index.ts +1 -0
  142. package/src/components/color-swatch/color-swatch.styles.ts +26 -0
  143. package/src/components/color-swatch/index.ts +1 -0
  144. package/src/components/color-swatch-picker/color-swatch-picker.styles.ts +54 -0
  145. package/src/components/color-swatch-picker/index.ts +1 -0
  146. package/src/components/combo-box/combo-box.styles.ts +26 -0
  147. package/src/components/combo-box/index.ts +1 -0
  148. package/src/components/date-input/date-input.styles.ts +86 -0
  149. package/src/components/date-input/index.ts +1 -0
  150. package/src/components/date-picker/date-picker.styles.ts +14 -0
  151. package/src/components/date-picker/index.ts +1 -0
  152. package/src/components/date-range-field/date-range-field.styles.ts +87 -0
  153. package/src/components/date-range-field/index.ts +1 -0
  154. package/src/components/date-range-picker/date-range-picker.styles.ts +14 -0
  155. package/src/components/date-range-picker/index.ts +1 -0
  156. package/src/components/description/description.styles.ts +9 -0
  157. package/src/components/description/index.ts +1 -0
  158. package/src/components/drawer/drawer.styles.ts +55 -0
  159. package/src/components/drawer/index.ts +1 -0
  160. package/src/components/dropdown/dropdown.styles.ts +14 -0
  161. package/src/components/dropdown/index.ts +1 -0
  162. package/src/components/empty-state/empty-state.styles.ts +9 -0
  163. package/src/components/empty-state/index.ts +1 -0
  164. package/src/components/error-message/error-message.styles.ts +9 -0
  165. package/src/components/error-message/index.ts +1 -0
  166. package/src/components/fieldset/fieldset.styles.ts +29 -0
  167. package/src/components/fieldset/index.ts +1 -0
  168. package/src/components/header/header.styles.ts +5 -0
  169. package/src/components/header/index.ts +1 -0
  170. package/src/components/index.ts +84 -0
  171. package/src/components/input/index.ts +1 -0
  172. package/src/components/input/input.styles.ts +87 -0
  173. package/src/components/input-otp/index.ts +1 -0
  174. package/src/components/input-otp/input-otp.styles.ts +30 -0
  175. package/src/components/kbd/index.ts +1 -0
  176. package/src/components/kbd/kbd.styles.ts +20 -0
  177. package/src/components/label/index.ts +1 -0
  178. package/src/components/label/label.styles.ts +25 -0
  179. package/src/components/link/index.ts +1 -0
  180. package/src/components/link/link.styles.ts +38 -0
  181. package/src/components/list-box/index.ts +1 -0
  182. package/src/components/list-box/list-box.styles.ts +18 -0
  183. package/src/components/list-box-item/index.ts +1 -0
  184. package/src/components/list-box-item/list-box-item.styles.ts +25 -0
  185. package/src/components/list-box-section/index.ts +1 -0
  186. package/src/components/list-box-section/list-box-section.styles.ts +13 -0
  187. package/src/components/menu/index.ts +1 -0
  188. package/src/components/menu/menu.styles.ts +9 -0
  189. package/src/components/menu-item/index.ts +1 -0
  190. package/src/components/menu-item/menu-item.styles.ts +26 -0
  191. package/src/components/menu-section/index.ts +1 -0
  192. package/src/components/menu-section/menu-section.styles.ts +14 -0
  193. package/src/components/meter/index.ts +1 -0
  194. package/src/components/meter/meter.styles.ts +48 -0
  195. package/src/components/modal/index.ts +1 -0
  196. package/src/components/modal/modal.styles.ts +70 -0
  197. package/src/components/number-field/index.ts +1 -0
  198. package/src/components/number-field/number-field.styles.ts +80 -0
  199. package/src/components/pagination/index.ts +1 -0
  200. package/src/components/pagination/pagination.styles.ts +32 -0
  201. package/src/components/popover/index.ts +1 -0
  202. package/src/components/popover/popover.styles.ts +14 -0
  203. package/src/components/progress-bar/index.ts +1 -0
  204. package/src/components/progress-bar/progress-bar.styles.ts +97 -0
  205. package/src/components/progress-circle/index.ts +1 -0
  206. package/src/components/progress-circle/progress-circle.styles.ts +74 -0
  207. package/src/components/radio/index.ts +1 -0
  208. package/src/components/radio/radio.styles.ts +14 -0
  209. package/src/components/radio-group/index.ts +1 -0
  210. package/src/components/radio-group/radio-group.styles.ts +18 -0
  211. package/src/components/range-calendar/index.ts +1 -0
  212. package/src/components/range-calendar/range-calendar.styles.ts +60 -0
  213. package/src/components/scroll-shadow/index.ts +1 -0
  214. package/src/components/scroll-shadow/scroll-shadow.styles.ts +37 -0
  215. package/src/components/select/index.ts +1 -0
  216. package/src/components/select/select.styles.ts +86 -0
  217. package/src/components/separator/index.ts +1 -0
  218. package/src/components/separator/separator.styles.ts +25 -0
  219. package/src/components/skeleton/index.ts +1 -0
  220. package/src/components/skeleton/skeleton.styles.ts +21 -0
  221. package/src/components/slider/index.ts +1 -0
  222. package/src/components/slider/slider.styles.ts +40 -0
  223. package/src/components/spinner/index.ts +1 -0
  224. package/src/components/spinner/spinner.styles.ts +28 -0
  225. package/src/components/splitter/index.ts +1 -0
  226. package/src/components/splitter/splitter.styles.ts +28 -0
  227. package/src/components/stepper/index.ts +1 -0
  228. package/src/components/stepper/stepper.styles.ts +57 -0
  229. package/src/components/surface/index.ts +1 -0
  230. package/src/components/surface/surface.styles.ts +20 -0
  231. package/src/components/switch/index.ts +1 -0
  232. package/src/components/switch/switch.styles.ts +31 -0
  233. package/src/components/switch-group/index.ts +1 -0
  234. package/src/components/switch-group/switch-group.styles.ts +25 -0
  235. package/src/components/table/index.ts +1 -0
  236. package/src/components/table/table.styles.ts +47 -0
  237. package/src/components/tabs/index.ts +1 -0
  238. package/src/components/tabs/tabs.styles.ts +31 -0
  239. package/src/components/tag/index.ts +1 -0
  240. package/src/components/tag/tag.styles.ts +37 -0
  241. package/src/components/tag-group/index.ts +1 -0
  242. package/src/components/tag-group/tag-group.styles.ts +12 -0
  243. package/src/components/text/index.ts +1 -0
  244. package/src/components/text/text.styles.ts +29 -0
  245. package/src/components/textarea/index.ts +1 -0
  246. package/src/components/textarea/textarea.styles.ts +86 -0
  247. package/src/components/time-field/index.ts +1 -0
  248. package/src/components/time-field/time-field.styles.ts +86 -0
  249. package/src/components/toast/index.ts +1 -0
  250. package/src/components/toast/toast.styles.ts +67 -0
  251. package/src/components/toggle-button/index.ts +1 -0
  252. package/src/components/toggle-button/toggle-button.styles.ts +28 -0
  253. package/src/components/toggle-button-group/index.ts +1 -0
  254. package/src/components/toggle-button-group/toggle-button-group.styles.ts +39 -0
  255. package/src/components/toolbar/index.ts +1 -0
  256. package/src/components/toolbar/toolbar.styles.ts +23 -0
  257. package/src/components/tooltip/index.ts +1 -0
  258. package/src/components/tooltip/tooltip.styles.ts +12 -0
  259. package/src/components/tree/index.ts +1 -0
  260. package/src/components/tree/tree.styles.ts +33 -0
  261. package/src/index.ts +5 -0
  262. package/src/utils/index.ts +15 -0
  263. package/themes/default/components/index.css +6 -0
  264. package/themes/default/index.css +8 -0
  265. package/themes/default/variables.css +168 -0
  266. package/themes/shared/theme.css +196 -0
  267. package/utilities/index.css +244 -0
  268. package/variants/index.css +106 -0
@@ -0,0 +1,603 @@
1
+ .input {
2
+ @apply flex items-center gap-2 rounded-field border bg-field px-3 py-2 text-sm text-field-foreground shadow-field outline-none sm:text-xs;
3
+
4
+ /* Default size - matches input--md (height equivalent to h-9) */
5
+ height: 2.25rem;
6
+
7
+ border-width: var(--border-width-field);
8
+ border-color: var(--color-field-border);
9
+
10
+ /**
11
+ * Transitions
12
+ * CRITICAL: motion-reduce must be AFTER transition for correct override specificity
13
+ */
14
+ transition:
15
+ background-color 300ms var(--ease-smooth),
16
+ border-color 300ms var(--ease-smooth),
17
+ box-shadow 300ms var(--ease-out);
18
+ @apply motion-reduce:transition-none;
19
+
20
+ @media (hover: hover) {
21
+ &:has(> input:hover):not(:focus-within),
22
+ &[data-hovered="true"]:not([data-focused="true"]):not([data-focus-visible="true"]) {
23
+ @apply bg-field-hover;
24
+ border-color: var(--color-field-border-hover);
25
+ }
26
+ }
27
+
28
+ &.input--sm {
29
+ @apply gap-[0.40rem];
30
+ }
31
+
32
+ &.input--lg {
33
+ @apply gap-4;
34
+ }
35
+
36
+ /* Focus state */
37
+ &:focus-within,
38
+ &[data-focused="true"] {
39
+ @apply status-focused-field;
40
+ border-color: var(--color-field-border-focus);
41
+ background-color: var(--color-field-focus);
42
+ }
43
+
44
+ /* Focus visible state */
45
+ &:has(> input:focus-visible):not(:focus-within),
46
+ &[data-focus-visible="true"] {
47
+ }
48
+
49
+ /* Invalid state */
50
+ &:has(> input:invalid),
51
+ &[data-invalid="true"] {
52
+ @apply status-invalid-field;
53
+ background-color: var(--color-field-focus);
54
+ border-color: var(--color-field-border-invalid);
55
+ }
56
+
57
+ /* Disabled state */
58
+ &:has(> input:disabled),
59
+ &[data-disabled="true"] {
60
+ @apply status-disabled;
61
+ }
62
+
63
+ /* Readonly state */
64
+ &:has(> input:read-only),
65
+ &[data-readonly="true"] {
66
+ background-color: var(--color-default-100);
67
+ cursor: default;
68
+ }
69
+ }
70
+
71
+ /* ─── Variant modifiers ─────────────────────────────────────────────────────── */
72
+
73
+ .input--flat {
74
+ /* Transparent background across all states, no border, no shadow */
75
+ @apply shadow-none bg-transparent;
76
+ border-color: transparent;
77
+
78
+ @media (hover: hover) {
79
+ &:has(> input:hover):not(:focus-within),
80
+ &[data-hovered="true"]:not([data-focused="true"]):not([data-focus-visible="true"]) {
81
+ @apply bg-transparent;
82
+ }
83
+ }
84
+
85
+ &:focus-within,
86
+ &[data-focused="true"] {
87
+ @apply bg-transparent;
88
+ border-color: var(--color-field-border-focus);
89
+ }
90
+ }
91
+
92
+ .input--bordered {
93
+ /* Transparent background + light border */
94
+ @apply shadow-none;
95
+ background-color: transparent;
96
+ border-width: var(--border-width);
97
+ border-color: var(--border);
98
+
99
+ @media (hover: hover) {
100
+ &:has(> input:hover):not(:focus-within),
101
+ &[data-hovered="true"]:not([data-focused="true"]):not([data-focus-visible="true"]) {
102
+ background-color: transparent;
103
+ border-color: color-mix(in oklab, var(--border) 80%, var(--foreground) 20%);
104
+ }
105
+ }
106
+
107
+ &:focus-within,
108
+ &[data-focused="true"] {
109
+ background-color: transparent;
110
+ border-color: var(--color-field-border-focus);
111
+ }
112
+ }
113
+
114
+ .input--faded {
115
+ /* Muted background + visible border */
116
+ @apply shadow-none;
117
+ background-color: var(--color-background-tertiary);
118
+ border-color: var(--color-border);
119
+
120
+ &:focus-within,
121
+ &[data-focused="true"] {
122
+ background-color: var(--color-background-tertiary);
123
+ border-color: var(--color-field-border-focus);
124
+ }
125
+ }
126
+
127
+ .input--underlined {
128
+ /* Bottom border only — always-visible underline */
129
+ @apply rounded-none shadow-none bg-transparent !px-0;
130
+ border-top: none;
131
+ border-left: none;
132
+ border-right: none;
133
+ border-bottom-width: var(--border-width);
134
+ border-bottom-color: var(--border);
135
+
136
+ @media (hover: hover) {
137
+ &:has(> input:hover):not(:focus-within),
138
+ &[data-hovered="true"]:not([data-focused="true"]):not([data-focus-visible="true"]) {
139
+ background-color: transparent;
140
+ border-bottom-color: color-mix(in oklab, var(--border) 80%, var(--foreground) 20%);
141
+ }
142
+ }
143
+
144
+ &:focus-within,
145
+ &[data-focused="true"] {
146
+ @apply bg-transparent;
147
+ border-bottom-color: var(--color-field-border-focus);
148
+ --tw-ring-color: var(--focus);
149
+ box-shadow: 0 1.2px 0 0 var(--tw-ring-color, var(--color-field-border-focus));
150
+ }
151
+ }
152
+
153
+ .input--raised {
154
+ /* Elevated look: white bg + shadow, transparent border */
155
+ @apply shadow-md;
156
+ background-color: var(--snow);
157
+ border-color: transparent;
158
+
159
+ @media (hover: hover) {
160
+ &:has(> input:hover):not(:focus-within),
161
+ &[data-hovered="true"]:not([data-focused="true"]):not([data-focus-visible="true"]) {
162
+ @apply shadow-lg;
163
+ background-color: var(--background);
164
+ border-color: transparent;
165
+ }
166
+ }
167
+
168
+ &:focus-within,
169
+ &[data-focused="true"] {
170
+ @apply shadow-lg;
171
+ background-color: var(--snow);
172
+ border-color: var(--color-field-border-focus);
173
+ }
174
+ }
175
+
176
+ /* ─── Size modifiers ─────────────────────────────────────────────────────────── */
177
+
178
+ .input--sm {
179
+ @apply text-xs px-2 py-1;
180
+ height: 1.75rem;
181
+ }
182
+
183
+ .input--md {
184
+ /* No styles — md is the default size defined on .input base */
185
+ }
186
+
187
+ .input--lg {
188
+ @apply text-base px-4 py-2.5;
189
+ height: 2.75rem;
190
+ }
191
+
192
+ /* ─── Color modifiers ────────────────────────────────────────────────────────── */
193
+
194
+ .input--default {
195
+ /* Default accent */
196
+ --input-accent: var(--color-default-foreground);
197
+ accent-color: var(--input-accent);
198
+ }
199
+
200
+ .input--primary {
201
+ --input-accent: var(--color-primary);
202
+ accent-color: var(--input-accent);
203
+
204
+ &:focus-within,
205
+ &[data-focused="true"] {
206
+ border-color: var(--color-primary);
207
+ --tw-ring-color: var(--color-secondary);
208
+ }
209
+ }
210
+
211
+ .input--secondary {
212
+ --input-accent: var(--color-secondary);
213
+ accent-color: var(--input-accent);
214
+
215
+ &:focus-within,
216
+ &[data-focused="true"] {
217
+ border-color: var(--color-secondary);
218
+ --tw-ring-color: var(--color-secondary);
219
+ }
220
+ }
221
+
222
+ .input--success {
223
+ --input-accent: var(--color-success);
224
+ accent-color: var(--input-accent);
225
+
226
+ &:focus-within,
227
+ &[data-focused="true"] {
228
+ border-color: var(--color-success);
229
+ --tw-ring-color: var(--color-success);
230
+ }
231
+ }
232
+
233
+ .input--warning {
234
+ --input-accent: var(--color-warning);
235
+ accent-color: var(--input-accent);
236
+
237
+ &:focus-within,
238
+ &[data-focused="true"] {
239
+ border-color: var(--color-warning);
240
+ --tw-ring-color: var(--color-warning);
241
+ }
242
+ }
243
+
244
+ .input--danger {
245
+ --input-accent: var(--color-danger);
246
+ accent-color: var(--input-accent);
247
+
248
+ &:focus-within,
249
+ &[data-focused="true"] {
250
+ border-color: var(--color-danger);
251
+ --tw-ring-color: var(--color-danger);
252
+ }
253
+ }
254
+
255
+ /* ─── Underlined + color variant overrides ─────────────────────────────────── */
256
+ /* When .input--underlined is combined with any color variant, enforce the
257
+ bottom-only underline silhouette on focus (no full-box border, no full-ring
258
+ shadow). Each rule overrides .input--{color}'s &:focus box-shadow. */
259
+
260
+ .input--underlined.input--primary,
261
+ .input--underlined.input--secondary,
262
+ .input--underlined.input--success,
263
+ .input--underlined.input--warning,
264
+ .input--underlined.input--danger {
265
+ /* Re-assert underline-only silhouette even when color variant is applied */
266
+ border-top: none;
267
+ border-left: none;
268
+ border-right: none;
269
+ border-bottom-width: var(--border-width);
270
+ }
271
+
272
+
273
+ /* ─── State modifiers ────────────────────────────────────────────────────────── */
274
+
275
+ .input--invalid {
276
+ /* Applied by tv() isInvalid variant — mirrors native :invalid */
277
+ border-color: var(--color-danger) !important;
278
+ @apply status-invalid-field;
279
+ }
280
+
281
+ .input--disabled {
282
+ /* Applied by tv() isDisabled variant — mirrors native :disabled */
283
+ @apply status-disabled opacity-60 cursor-not-allowed;
284
+ }
285
+
286
+ .input--readonly {
287
+ /* Applied by tv() isReadonly variant — mirrors native :read-only */
288
+ background-color: var(--color-default-100);
289
+ cursor: default;
290
+ }
291
+
292
+ /* ─── Layout modifiers ───────────────────────────────────────────────────────── */
293
+
294
+ .input--full-width {
295
+ @apply w-full;
296
+ }
297
+
298
+ /* ─── Slots ──────────────────────────────────────────────────────────────────── */
299
+
300
+ .input__input {
301
+ @apply flex-1 bg-transparent outline-none border-0 p-0 h-auto text-inherit;
302
+ @apply placeholder:text-field-placeholder;
303
+
304
+ &:focus,
305
+ &:focus-visible {
306
+ outline: none;
307
+ box-shadow: none;
308
+ }
309
+ }
310
+
311
+ .input__start-content,
312
+ .input__end-content {
313
+ @apply inline-flex items-center justify-center shrink-0;
314
+ color: var(--color-field-placeholder);
315
+ }
316
+
317
+ .input__start-content svg,
318
+ .input__end-content svg {
319
+ @apply size-4;
320
+ }
321
+
322
+ /* ─── Label slot ─────────────────────────────────────────────────────────────── */
323
+
324
+ .input__label {
325
+ @apply text-sm font-medium select-none;
326
+ color: var(--color-field-placeholder);
327
+ pointer-events: none;
328
+ transition:
329
+ transform 300ms var(--ease-smooth),
330
+ color 300ms var(--ease-smooth),
331
+ scale 300ms var(--ease-smooth);
332
+ @apply motion-reduce:transition-none;
333
+ }
334
+
335
+ /* ─── Floating label (inside the input) ──────────────────────────────────── */
336
+
337
+ /* When a label is present, the input wrapper is taller to make room for the
338
+ floated label above the caret. Heights override the base/size defaults. */
339
+ .input--label-inside {
340
+ position: relative;
341
+ height: 3.5rem; /* md: was 2.25rem; +0.75rem room for floated label */
342
+ padding-top: 0;
343
+ padding-bottom: 0;
344
+ }
345
+
346
+ .input--label-inside.input--sm {
347
+ height: 2.5rem; /* sm: was 1.75rem */
348
+ }
349
+
350
+ .input--label-inside.input--lg {
351
+ height: 4rem; /* lg: was 2.75rem */
352
+ }
353
+
354
+ .input--label-inside .input__label {
355
+ position: absolute;
356
+ left: 0.75rem; /* matches .input px-3 */
357
+ top: 50%;
358
+ transform: translateY(-50%);
359
+ transform-origin: left center;
360
+ font-size: var(--text-sm);
361
+ color: var(--color-field-placeholder);
362
+ }
363
+
364
+ .input--label-inside.input--underlined .input__label {
365
+ left: 0rem;
366
+ }
367
+
368
+ /* Push the input caret/text down so it doesn't sit under the floated label.
369
+ Applied statically (not only in up-state) to keep the input box stable. */
370
+ .input--label-inside .input__input {
371
+ padding-top: 1rem;
372
+ padding-bottom: 0;
373
+ }
374
+
375
+ /* Hide the native placeholder while the label occupies the resting position.
376
+ Placeholder reveals only once the label has floated up (focused or filled). */
377
+ .input--label-inside .input__input::placeholder {
378
+ color: transparent;
379
+ }
380
+
381
+ .input--label-inside.input--default:focus-within .input__label,
382
+ .input--label-inside.input--default[data-focused="true"] .input__label {
383
+ color: var(--color-foreground);
384
+ }
385
+
386
+ .input--label-inside:focus-within .input__input::placeholder,
387
+ .input--label-inside[data-focused="true"] .input__input::placeholder,
388
+ .input--label-inside[data-filled="true"] .input__input::placeholder {
389
+ color: var(--color-field-placeholder);
390
+ }
391
+
392
+ /* Up-state: focused OR filled. Paired pseudo-class + data-attribute per the
393
+ Reka UI selector pairing rule. */
394
+ .input--label-inside:focus-within .input__label,
395
+ .input--label-inside[data-focused="true"] .input__label,
396
+ .input--label-inside[data-filled="true"] .input__label {
397
+ transform: translateY(-110%) scale(0.85);
398
+ }
399
+
400
+ /* Start-content pushes the label's left anchor so it doesn't overlap the icon */
401
+ .input--label-inside:has(> .input__start-content) .input__label {
402
+ left: calc(0.75rem + 1rem + 0.5rem); /* px-3 + size-4 icon + gap-2 */
403
+ }
404
+ .input--label-inside.input--underlined:has(> .input__start-content) .input__label {
405
+ left: calc(1rem + 0.5rem); /* px-3 + size-4 icon + gap-2 */
406
+ }
407
+
408
+ /* Size-aware offsets for the inside variant */
409
+ .input--label-inside.input--sm .input__label {
410
+ font-size: var(--text-xs, 0.75rem);
411
+ left: 0.5rem; /* matches .input--sm px-2 */
412
+ }
413
+
414
+ .input--label-inside.input--sm:has(> .input__start-content) .input__label {
415
+ left: calc(0.5rem + 1rem + 0.4rem); /* px-3 + size-4 icon + gap-2 */
416
+ }
417
+
418
+ .input--label-inside.input--underlined.input--sm:has(> .input__start-content) .input__label {
419
+ left: calc(1rem + 0.4rem); /* px-3 + size-4 icon + gap-2 */
420
+ }
421
+
422
+ .input--label-inside.input--sm .input__input {
423
+ padding-top: 0.625rem;
424
+ }
425
+ .input--label-inside.input--sm:focus-within .input__label,
426
+ .input--label-inside.input--sm[data-focused="true"] .input__label,
427
+ .input--label-inside.input--sm[data-filled="true"] .input__label {
428
+ transform: translateY(-100%) scale(0.8);
429
+ }
430
+
431
+ .input--label-inside.input--lg .input__label {
432
+ font-size: var(--text-base, 1rem);
433
+ left: 1rem; /* matches .input--lg px-4 */
434
+ }
435
+ .input--label-inside.input--lg:has(> .input__start-content) .input__label {
436
+ left: calc(1rem + 1rem + 1rem); /* px-3 + size-4 icon + gap-2 */
437
+ }
438
+
439
+ .input--label-inside.input--underlined.input--lg:has(> .input__start-content) .input__label {
440
+ left: calc(1rem + 1rem); /* px-3 + size-4 icon + gap-2 */
441
+ }
442
+
443
+ .input--label-inside.input--lg .input__input {
444
+ padding-top: 1.125rem;
445
+ }
446
+
447
+
448
+ /* Underlined variant + inside label: ensure the input has enough top padding */
449
+ .input--underlined.input--label-inside .input__input {
450
+ padding-top: 1.125rem;
451
+ }
452
+
453
+ /* Invalid state — label color flips to danger */
454
+ .input--label-inside:has(> input:invalid) .input__label,
455
+ .input--label-inside[data-invalid="true"] .input__label {
456
+ color: var(--color-danger);
457
+ }
458
+
459
+ /* ─── Root wrapper (holds label + field + helper) ───────────────────────── */
460
+
461
+ .input-root {
462
+ display: flex;
463
+ flex-direction: column;
464
+ gap: 0.375rem;
465
+ }
466
+
467
+ .input-root--full-width {
468
+ @apply w-full;
469
+ }
470
+
471
+ .input-root--label-outside-left {
472
+ flex-direction: row;
473
+ align-items: flex-start;
474
+ gap: 0.75rem;
475
+ }
476
+
477
+ .input__main-wrapper {
478
+ display: flex;
479
+ flex-direction: column;
480
+ gap: 0.25rem;
481
+ flex: 1;
482
+ min-width: 0;
483
+ }
484
+
485
+ /* ─── Outside label ──────────────────────────────────────────────────────── */
486
+
487
+ .input-root--label-outside > .input__label,
488
+ .input-root--label-outside-left > .input__label {
489
+ position: static;
490
+ transform: none;
491
+ display: block;
492
+ pointer-events: auto;
493
+ font-size: var(--text-sm);
494
+ font-weight: 500;
495
+ color: var(--color-foreground);
496
+ }
497
+
498
+ /* Align outside-left label with input text baseline; defaults tuned for md. */
499
+ .input-root--label-outside-left > .input__label {
500
+ padding-top: 0.5rem;
501
+ min-width: 5rem;
502
+ flex-shrink: 0;
503
+ }
504
+
505
+ .input-root--label-outside[data-invalid="true"] > .input__label,
506
+ .input-root--label-outside-left[data-invalid="true"] > .input__label {
507
+ color: var(--color-danger);
508
+ }
509
+
510
+ /* ─── Helper text (description / error message) ─────────────────────────── */
511
+
512
+ .input__helper-wrapper {
513
+ display: flex;
514
+ flex-direction: column;
515
+ gap: 0.125rem;
516
+ padding: 0 0.25rem;
517
+ }
518
+
519
+ .input__description {
520
+ @apply text-xs;
521
+ color: color-mix(in oklab, var(--color-foreground) 60%, transparent);
522
+ }
523
+
524
+ .input__error-message {
525
+ @apply text-xs;
526
+ color: var(--color-danger);
527
+ }
528
+
529
+ /* ─── Clear button + password toggle ─────────────────────────────────── */
530
+
531
+ .input__clear-button,
532
+ .input__password-toggle {
533
+ @apply inline-flex items-center justify-center shrink-0;
534
+ @apply bg-transparent border-0 p-0 cursor-pointer outline-none;
535
+ color: var(--color-field-placeholder);
536
+ transition:
537
+ color 300ms var(--ease-smooth),
538
+ opacity 300ms var(--ease-smooth);
539
+ @apply motion-reduce:transition-none;
540
+ }
541
+
542
+ .input__clear-button svg,
543
+ .input__password-toggle svg {
544
+ @apply size-4;
545
+ }
546
+
547
+ .input--sm .input__clear-button svg,
548
+ .input--sm .input__password-toggle svg {
549
+ width: 0.875rem;
550
+ height: 0.875rem;
551
+ }
552
+
553
+ .input--lg .input__clear-button svg,
554
+ .input--lg .input__password-toggle svg {
555
+ @apply size-5;
556
+ }
557
+
558
+ @media (hover: hover) {
559
+ .input__clear-button:hover,
560
+ .input__password-toggle:hover,
561
+ .input__clear-button[data-hovered="true"],
562
+ .input__password-toggle[data-hovered="true"] {
563
+ color: var(--color-foreground);
564
+ }
565
+ }
566
+
567
+ .input__clear-button:focus-visible,
568
+ .input__password-toggle:focus-visible,
569
+ .input__clear-button[data-focus-visible="true"],
570
+ .input__password-toggle[data-focus-visible="true"] {
571
+ color: var(--color-foreground);
572
+ border-radius: 4px;
573
+ box-shadow: 0 0 0 2px var(--color-focus, var(--color-field-border-focus));
574
+ }
575
+
576
+ .input__clear-button:disabled,
577
+ .input__password-toggle:disabled,
578
+ .input__clear-button[data-disabled="true"],
579
+ .input__password-toggle[data-disabled="true"] {
580
+ @apply cursor-not-allowed opacity-50;
581
+ }
582
+
583
+ /* Color up-state — floated label picks up the focus accent per color variant */
584
+ .input--label-inside.input--primary:focus-within .input__label,
585
+ .input--label-inside.input--primary[data-focused="true"] .input__label {
586
+ color: var(--color-primary);
587
+ }
588
+ .input--label-inside.input--secondary:focus-within .input__label,
589
+ .input--label-inside.input--secondary[data-focused="true"] .input__label {
590
+ color: var(--color-secondary);
591
+ }
592
+ .input--label-inside.input--success:focus-within .input__label,
593
+ .input--label-inside.input--success[data-focused="true"] .input__label {
594
+ color: var(--color-success);
595
+ }
596
+ .input--label-inside.input--warning:focus-within .input__label,
597
+ .input--label-inside.input--warning[data-focused="true"] .input__label {
598
+ color: var(--color-warning);
599
+ }
600
+ .input--label-inside.input--danger:focus-within .input__label,
601
+ .input--label-inside.input--danger[data-focused="true"] .input__label {
602
+ color: var(--color-danger);
603
+ }
@@ -0,0 +1,27 @@
1
+ /* Base styles */
2
+ .kbd {
3
+ @apply inline-flex h-6 items-center space-x-0.5 rounded-lg bg-default px-2 text-center font-sans text-sm font-medium whitespace-nowrap text-muted rtl:space-x-reverse;
4
+ word-spacing: -0.25rem;
5
+ }
6
+
7
+ /* Key abbreviation styles */
8
+ .kbd__abbr {
9
+ display: flex;
10
+ justify-content: center;
11
+ align-items: center;
12
+ width: 100%;
13
+ height: 100%;
14
+ text-decoration: none;
15
+ }
16
+
17
+ /* Content wrapper */
18
+ .kbd__content {
19
+ display: flex;
20
+ justify-content: center;
21
+ align-items: center;
22
+ }
23
+
24
+ /* Variant styles */
25
+ .kbd--light {
26
+ @apply bg-transparent;
27
+ }
@@ -0,0 +1,28 @@
1
+ /* Base label styles */
2
+ .label {
3
+ /* Base styling */
4
+ @apply text-sm font-medium text-foreground;
5
+ }
6
+
7
+ /*
8
+ * Exclude group-level components (RadioGroup, CheckboxGroup) and radio/checkbox items
9
+ * to ensure asterisks only appear on atomic form field labels and group labels,
10
+ * not on individual options within those groups
11
+ */
12
+ .label--required,
13
+ [aria-required="true"]:not([role="group"]):not([role="radiogroup"]):not([role="checkboxgroup"])
14
+ > .label,
15
+ [aria-required="true"]:not([data-slot="radio"]):not([data-slot="checkbox"]) > .label {
16
+ @apply after:ml-0.5 after:text-danger after:content-['*'];
17
+ }
18
+
19
+ .label--disabled,
20
+ [data-disabled] .label {
21
+ @apply status-disabled;
22
+ }
23
+
24
+ .label--invalid,
25
+ [aria-invalid="true"] .label,
26
+ [aria-invalid="true"] .label {
27
+ @apply text-danger;
28
+ }