@t007/input 0.0.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.
@@ -0,0 +1,779 @@
1
+ :where(:root) {
2
+ --t007-input-dark-error-color: #f44336;
3
+ --t007-input-font-family: inherit;
4
+ --t007-input-width: 100%;
5
+ --t007-input-height: 3rem;
6
+ --t007-input-font-size: 1rem;
7
+ --t007-input-floating-label-scale: 0.75;
8
+ --t007-input-border-width: 1px;
9
+ --t007-input-focused-border-width: 2px;
10
+ --t007-input-border-style: solid;
11
+ --t007-input-focused-border-style: var(--t007-input-border-style);
12
+ --t007-input-icon-width: unset;
13
+ --t007-input-icon-height: unset;
14
+ --t007-input-disabled-opacity: 0.6;
15
+ --t007-input-p-meter-border-radius: unset;
16
+ --t007-input-p-meter-color-weak: #b81a0a;
17
+ --t007-input-p-meter-color-fair: #f68b1e;
18
+ --t007-input-p-meter-color-strong: #0a8b1e;
19
+ --t007-input-p-meter-color-very-strong: #39ff14;
20
+ --t007-input-ripple-size: 250%;
21
+ --t007-input-ripple-color: rgb(from var(--t007-input-checkbox-checked-background) r g b/0.15);
22
+ }
23
+
24
+ /* general input state variables */
25
+ :where(:root, .t007-input-field) {
26
+ --t007-input-color: black;
27
+ /* borders */
28
+ --t007-input-base-color: rgb(from var(--t007-input-color) r g b / 0.45);
29
+ --t007-input-hover-color: rgb(from var(--t007-input-color) r g b / 1);
30
+ --t007-input-focused-color: rgb(from var(--t007-input-color) r g b / 1);
31
+ --t007-input-filled-color: var(--t007-input-base-color);
32
+ --t007-input-error-color: #d32f2f;
33
+ --t007-input-disabled-color: gray;
34
+ /* label */
35
+ --t007-input-base-label-color: rgb(from var(--t007-input-base-color) r g b / 0.95);
36
+ --t007-input-hover-label-color: var(--t007-input-base-label-color);
37
+ --t007-input-focused-label-color: var(--t007-input-focused-color);
38
+ --t007-input-filled-label-color: var(--t007-input-base-label-color);
39
+ --t007-input-error-label-color: var(--t007-input-error-color);
40
+ --t007-input-disabled-label-color: var(--t007-input-disabled-color);
41
+ /* value */
42
+ --t007-input-base-value-color: rgb(from var(--t007-input-color) r g b / 1);
43
+ --t007-input-hover-value-color: var(--t007-input-base-value-color);
44
+ --t007-input-focused-value-color: var(--t007-input-base-value-color);
45
+ --t007-input-filled-value-color: var(--t007-input-base-value-color);
46
+ --t007-input-error-value-color: var(--t007-input-base-value-color);
47
+ --t007-input-disabled-value-color: var(--t007-input-disabled-color);
48
+ /* helper */
49
+ --t007-input-base-helper-color: rgb(from var(--t007-input-color) r g b / 0.8);
50
+ --t007-input-hover-helper-color: var(--t007-input-base-helper-color);
51
+ --t007-input-focused-helper-color: rgb(from var(--t007-input-color) r g b / 0.9);
52
+ --t007-input-filled-helper-color: var(--t007-input-filled-color);
53
+ --t007-input-error-helper-color: var(--t007-input-error-color);
54
+ --t007-input-disabled-helper-color: var(--t007-input-disabled-color);
55
+ /* background */
56
+ --t007-input-base-background-color: transparent;
57
+ --t007-input-hover-background-color: var(--t007-input-base-background-color);
58
+ --t007-input-focused-background-color: var(--t007-input-base-background-color);
59
+ --t007-input-filled-background-color: var(--t007-input-base-background-color);
60
+ --t007-input-error-background-color: var(--t007-input-base-background-color);
61
+ --t007-input-disabled-background-color: var(--t007-input-base-background-color);
62
+ --t007-input-autofill-background-color: var(--t007-input-base-background-color);
63
+ /* icon */
64
+ --t007-input-icon-fill: var(--t007-input-color);
65
+ --t007-input-icon-stroke: unset;
66
+ /* derived */
67
+ --t007-input-padding: calc(var(--t007-input-height) / 4);
68
+ --t007-input-floating-label-font-size: calc(var(--t007-input-font-size) * var(--t007-input-floating-label-scale));
69
+ --t007-input-helper-font-size: calc(var(--t007-input-font-size) * 0.7);
70
+ --t007-input-border-radius: calc(var(--t007-input-height) / 12);
71
+ --t007-input-p-meter-font-size: calc(var(--t007-input-font-size) * 0.75);
72
+ --t007-input-p-meter-gap: calc(var(--t007-input-font-size) * 0.25);
73
+ --t007-input-p-meter-height: calc(var(--t007-input-font-size) * 0.25);
74
+ --t007-input-checkbox-font-size: calc(var(--t007-input-font-size) * 0.9);
75
+ --t007-input-checkbox-gap: calc(var(--t007-input-font-size) * 0.5);
76
+ --t007-input-checkbox-size: calc(var(--t007-input-font-size) * 0.85);
77
+ --t007-input-radio-font-size: calc(var(--t007-input-font-size) * 0.9);
78
+ --t007-input-radio-gap: calc(var(--t007-input-font-size) * 0.5);
79
+ --t007-input-radio-size: calc(var(--t007-input-font-size) * 0.85);
80
+ }
81
+
82
+ /* checkbox input state variables */
83
+ :where(:root) {
84
+ --t007-input-checkmark-color: white;
85
+ --t007-input-checkmark-width: 2px;
86
+ --t007-input-checkbox-background: whitesmoke;
87
+ --t007-input-checkbox-checked-background: dodgerblue;
88
+ --t007-input-checkbox-border-color: #707070;
89
+ --t007-input-checkbox-checked-border-color: black;
90
+ --t007-input-checkbox-border-width: 1px;
91
+ --t007-input-checkbox-border-radius: 0.2rem;
92
+ }
93
+
94
+ /* radio input state variables */
95
+ :where(:root) {
96
+ --t007-input-radio-color: dodgerblue;
97
+ --t007-input-radio-background: whitesmoke;
98
+ --t007-input-radio-border-color: #707070;
99
+ --t007-input-radio-checked-border-color: dodgerblue;
100
+ --t007-input-radio-checked-background: whitesmoke;
101
+ --t007-input-radio-border-width: 1px;
102
+ }
103
+
104
+ .t007-input-field,
105
+ .t007-input-field *[class^="t007-input"],
106
+ .t007-input-field *[class^="t007-input"]::after,
107
+ .t007-input-field *[class^="t007-input"]::before {
108
+ box-sizing: border-box;
109
+ font-family: var(--t007-input-font-family);
110
+ transition-property: transform, filter, background-color, color, border, right, left, top, bottom, width, height, font-size, scale;
111
+ transition-duration: 150ms;
112
+ transition-timing-function: ease;
113
+ }
114
+
115
+ :where(.t007-input-field) *,
116
+ :where(.t007-input-field) *::after,
117
+ :where(.t007-input-field) *::before {
118
+ padding: 0;
119
+ margin: 0;
120
+ }
121
+
122
+ .t007-input-field {
123
+ --t007-input-current-color: var(--t007-input-base-color);
124
+ --t007-input-current-label-color: var(--t007-input-base-label-color);
125
+ --t007-input-current-value-color: var(--t007-input-base-value-color);
126
+ --t007-input-current-helper-color: var(--t007-input-base-helper-color);
127
+ --t007-input-current-background-color: var(--t007-input-base-background-color);
128
+ width: var(--t007-input-width);
129
+ max-width: 100%;
130
+ padding-top: calc((var(--t007-input-floating-label-font-size) * 1.3) * 0.5);
131
+ isolation: isolate;
132
+ -webkit-font-smoothing: antialiased;
133
+ }
134
+
135
+ .t007-input-field:where(.t007-input-is-wrapper):where(:has([contenteditable="true"]:not(:empty)):not(:has([contenteditable="true"] > br:only-child)):not(:has([contenteditable="true"] > :only-child > br:only-child))),
136
+ .t007-input-field:where(.t007-input-is-wrapper):where(:has([data-wrapper-filled], [contenteditable="true"][data-filled])),
137
+ .t007-input-field:where(:has(.t007-input:is([data-filled], :-webkit-autofill, :not(:placeholder-shown):where(:not(select):not([type="date"]):not([type="time"]):not([type="datetime-local"]):not([type="month"]):not([type="week"]):not([type="color"]):not([type="range"]):not([type="file"]))))) {
138
+ --t007-input-current-color: var(--t007-input-filled-color);
139
+ --t007-input-current-label-color: var(--t007-input-filled-label-color);
140
+ --t007-input-current-value-color: var(--t007-input-filled-value-color);
141
+ --t007-input-current-helper-color: var(--t007-input-filled-helper-color);
142
+ --t007-input-current-background-color: var(--t007-input-filled-background-color);
143
+ }
144
+
145
+ .t007-input-field:where(:hover) {
146
+ --t007-input-current-color: var(--t007-input-hover-color);
147
+ --t007-input-current-label-color: var(--t007-input-hover-label-color);
148
+ --t007-input-current-value-color: var(--t007-input-hover-value-color);
149
+ --t007-input-current-helper-color: var(--t007-input-hover-helper-color);
150
+ --t007-input-current-background-color: var(--t007-input-hover-background-color);
151
+ }
152
+
153
+ .t007-input-field:where(.t007-input-is-wrapper):where(:has([data-wrapper-focused], [contenteditable="true"]:focus)),
154
+ .t007-input-field:where(:has(.t007-input:focus)) {
155
+ --t007-input-current-color: var(--t007-input-focused-color);
156
+ --t007-input-current-label-color: var(--t007-input-focused-label-color);
157
+ --t007-input-current-value-color: var(--t007-input-focused-value-color);
158
+ --t007-input-current-helper-color: var(--t007-input-focused-helper-color);
159
+ --t007-input-current-background-color: var(--t007-input-focused-background-color);
160
+ }
161
+
162
+ .t007-input-field:where(.t007-input-is-wrapper):where(:has([data-wrapper-error], [contenteditable="true"][data-error])),
163
+ .t007-input-field:where(:has(.t007-input[data-error])) {
164
+ --t007-input-current-color: var(--t007-input-error-color);
165
+ --t007-input-current-label-color: var(--t007-input-error-label-color);
166
+ --t007-input-current-value-color: var(--t007-input-error-value-color);
167
+ --t007-input-current-helper-color: var(--t007-input-error-helper-color);
168
+ --t007-input-current-background-color: var(--t007-input-error-background-color);
169
+ }
170
+
171
+ .t007-input-field:has(.t007-input:disabled) {
172
+ --t007-input-current-color: var(--t007-input-disabled-color);
173
+ --t007-input-current-label-color: var(--t007-input-disabled-label-color);
174
+ --t007-input-current-value-color: var(--t007-input-disabled-value-color);
175
+ --t007-input-current-helper-color: var(--t007-input-disabled-helper-color);
176
+ --t007-input-current-background-color: var(--t007-input-disabled-background-color);
177
+ opacity: var(--t007-input-disabled-opacity);
178
+ cursor: not-allowed;
179
+ }
180
+
181
+ .t007-input-field:has(.t007-input:-webkit-autofill) {
182
+ --t007-input-current-background-color: var(--t007-input-autofill-background-color);
183
+ }
184
+
185
+ .t007-input-field:where(.t007-input-no-helper:has(.t007-input[type="checkbox"], .t007-input[type="radio"])) {
186
+ display: contents;
187
+ }
188
+
189
+ .t007-input-field:has(.t007-input[hidden]) {
190
+ display: none;
191
+ }
192
+
193
+ .t007-input-wrapper {
194
+ position: relative;
195
+ width: 100%;
196
+ height: var(--t007-input-height);
197
+ display: inline-flex;
198
+ align-items: baseline;
199
+ padding: var(--t007-input-padding);
200
+ border-radius: var(--t007-input-border-radius);
201
+ }
202
+
203
+ .t007-input-field.t007-input-is-wrapper .t007-input-wrapper {
204
+ min-height: fit-content;
205
+ padding: var(--t007-input-border-width);
206
+ }
207
+
208
+ .t007-input-wrapper:has(textarea) {
209
+ min-height: fit-content;
210
+ }
211
+
212
+ .t007-input-wrapper:has(.t007-input-icon) {
213
+ padding-right: 0;
214
+ }
215
+
216
+ .t007-input-field.t007-input-icon-override .t007-input-wrapper {
217
+ padding-right: 12px;
218
+ }
219
+
220
+ .t007-input-outline {
221
+ position: absolute;
222
+ inset: 0;
223
+ display: flex;
224
+ width: 100%;
225
+ max-width: 100%;
226
+ height: 100%;
227
+ pointer-events: none;
228
+ text-align: left;
229
+ border-radius: inherit;
230
+ }
231
+
232
+ .t007-input-outline > * {
233
+ height: 100%;
234
+ background-color: var(--t007-input-current-background-color);
235
+ border-color: var(--t007-input-current-color);
236
+ border-width: var(--t007-input-border-width);
237
+ border-style: var(--t007-input-border-style);
238
+ pointer-events: none;
239
+ }
240
+
241
+ .t007-input-field.t007-input-is-wrapper:has([data-wrapper-focused], [contenteditable="true"]:focus) .t007-input-outline > *,
242
+ .t007-input-field:has(.t007-input:focus) .t007-input-outline > * {
243
+ border-width: var(--t007-input-focused-border-width);
244
+ border-style: var(--t007-input-focused-border-style);
245
+ }
246
+
247
+ .t007-input-outline-leading {
248
+ width: max(0.75rem, var(--t007-input-border-radius));
249
+ border-top-left-radius: inherit;
250
+ border-top-right-radius: 0;
251
+ border-bottom-left-radius: inherit;
252
+ border-bottom-right-radius: 0;
253
+ border-right: none !important;
254
+ }
255
+
256
+ .t007-input-outline-trailing {
257
+ flex: 1;
258
+ min-width: var(--t007-input-border-radius);
259
+ border-top-left-radius: 0;
260
+ border-top-right-radius: inherit;
261
+ border-bottom-left-radius: 0;
262
+ border-bottom-right-radius: inherit;
263
+ border-left: none !important;
264
+ }
265
+
266
+ .t007-input-outline-notch {
267
+ flex: 0 0 auto;
268
+ position: relative;
269
+ width: fit-content;
270
+ max-width: calc(100% - 0.75rem);
271
+ border-left: none !important;
272
+ border-right: none !important;
273
+ transition-property: border-bottom, transform, filter, background-color, color, right, left, top, bottom, width, height, font-size, scale;
274
+ }
275
+
276
+ .t007-input-field:has(.t007-input-icon) .t007-input-outline-notch {
277
+ max-width: calc(100% - 3.75rem);
278
+ }
279
+
280
+ .t007-input-field.t007-input-is-wrapper .t007-input-outline-notch,
281
+ .t007-input-field:has(.t007-input:is([data-filled], :focus, :-webkit-autofill, :not(:placeholder-shown):where(:not(select):not([type="date"]):not([type="time"]):not([type="datetime-local"]):not([type="month"]):not([type="week"]):not([type="color"]):not([type="range"]):not([type="file"])))) .t007-input-outline-notch,
282
+ .t007-input-field:has(.t007-input:is(select, :not([placeholder=""]), [type="date"], [type="time"], [type="datetime-local"], [type="month"], [type="week"], [type="color"], [type="range"], [type="file"])) .t007-input-outline-notch {
283
+ border-top: none !important;
284
+ }
285
+
286
+ .t007-input-floating-label {
287
+ position: relative;
288
+ top: calc(var(--t007-input-height) / 2);
289
+ display: block;
290
+ max-width: 100%;
291
+ transform: translateY(-50%);
292
+ color: var(--t007-input-current-label-color);
293
+ opacity: 0.85;
294
+ font-weight: 400;
295
+ font-size: var(--t007-input-font-size);
296
+ line-height: 1.3;
297
+ overflow: hidden;
298
+ text-overflow: ellipsis;
299
+ transform-origin: left top;
300
+ white-space: nowrap;
301
+ will-change: transform;
302
+ }
303
+
304
+ .t007-input-floating-label:not(:empty) {
305
+ margin-inline: 0.25rem;
306
+ }
307
+
308
+ .t007-input-field.t007-input-is-wrapper .t007-input-floating-label,
309
+ .t007-input-field:has(.t007-input:is([data-filled], :focus, :-webkit-autofill, :not(:placeholder-shown):where(:not(select):not([type="date"]):not([type="time"]):not([type="datetime-local"]):not([type="month"]):not([type="week"]):not([type="color"]):not([type="range"]):not([type="file"])))) .t007-input-floating-label,
310
+ .t007-input-field:has(.t007-input:is(select, :not([placeholder=""]), [type="date"], [type="time"], [type="datetime-local"], [type="month"], [type="week"], [type="color"], [type="range"], [type="file"])) .t007-input-floating-label {
311
+ transform: translateY(calc(-1 * ((var(--t007-input-height) / 2) + (var(--t007-input-font-size) / 2))));
312
+ font-size: var(--t007-input-floating-label-font-size);
313
+ opacity: 1;
314
+ right: auto;
315
+ max-width: 133%;
316
+ }
317
+
318
+ .t007-input-field.t007-input-is-wrapper .t007-input-floating-label.t007-input-shake,
319
+ .t007-input-field:has(.t007-input:is([data-filled], :focus, :-webkit-autofill, :not(:placeholder-shown):where(:not(select):not([type="date"]):not([type="time"]):not([type="datetime-local"]):not([type="month"]):not([type="week"]):not([type="color"]):not([type="range"]):not([type="file"])))) .t007-input-floating-label.t007-input-shake,
320
+ .t007-input-field:has(.t007-input:is(select, :not([placeholder=""]), [type="date"], [type="time"], [type="datetime-local"], [type="month"], [type="week"], [type="color"], [type="range"], [type="file"])) .t007-input-floating-label.t007-input-shake {
321
+ transform: translateY(calc(-1 * ((var(--t007-input-height) / 2) + (var(--t007-input-font-size) / 2)))) translateX(0.25rem);
322
+ }
323
+
324
+ .t007-input {
325
+ border: none;
326
+ background: none;
327
+ color: var(--t007-input-current-value-color);
328
+ caret-color: var(--t007-input-current-value-color);
329
+ border-radius: 0;
330
+ font-size: var(--t007-input-font-size);
331
+ height: 100%;
332
+ width: 100%;
333
+ min-width: 0;
334
+ min-height: 0;
335
+ padding: 0;
336
+ font-family: inherit;
337
+ outline: none !important;
338
+ }
339
+
340
+ .t007-input[type="file"] {
341
+ height: unset;
342
+ }
343
+
344
+ .t007-input:is([type="checkbox"], [type="radio"]) {
345
+ opacity: 0;
346
+ position: absolute;
347
+ pointer-events: none;
348
+ }
349
+
350
+ .t007-input:not(select) {
351
+ appearance: none;
352
+ }
353
+
354
+ .t007-input:where(textarea) {
355
+ min-height: 100%;
356
+ height: auto;
357
+ resize: none;
358
+ }
359
+
360
+ :where(select.t007-input::picker(select)) {
361
+ color: black;
362
+ }
363
+
364
+ .t007-input::placeholder {
365
+ color: currentColor;
366
+ opacity: 0.55;
367
+ }
368
+
369
+ .t007-input-field:has(.t007-input[type="file"]) {
370
+ /* computed values for the selector button */
371
+ --t007-input-sb-active-margin: calc((var(--t007-input-floating-label-font-size) * 1.3) / 2);
372
+ --t007-input-sb-padding-inline: calc(var(--t007-input-font-size) / 3.5);
373
+ --t007-input-sb-padding-block: calc(((var(--t007-input-height) / 2) - ((var(--t007-input-font-size) / 1.25) / 2)) - ((var(--t007-input-floating-label-font-size) * 1.3) / 2) - 1px);
374
+ }
375
+
376
+ .t007-input-wrapper:has(.t007-input[type="file"]) {
377
+ padding-block: var(--t007-input-sb-active-margin);
378
+ padding-left: var(--t007-input-sb-active-margin);
379
+ }
380
+
381
+ :where(.t007-input[type="file"])::file-selector-button {
382
+ font-family: inherit;
383
+ font-weight: bold;
384
+ font-size: calc(var(--t007-input-font-size) / 1.25);
385
+ margin-right: calc(var(--t007-input-font-size) / 2.5);
386
+ border-top: none;
387
+ padding-inline: var(--t007-input-sb-padding-inline);
388
+ padding-block: calc(var(--t007-input-sb-padding-block) - 1px);
389
+ border-right: none;
390
+ border-width: 2px;
391
+ border-radius: calc(var(--t007-input-border-radius) / 1.25);
392
+ background: dodgerblue;
393
+ color: whitesmoke;
394
+ cursor: pointer;
395
+ transition: filter 200ms ease;
396
+ }
397
+
398
+ :where(.t007-input[type="file"])::file-selector-button:where(:active) {
399
+ border-width: 1px;
400
+ }
401
+
402
+ :where(.t007-input[type="file"])::file-selector-button:where(:hover, :focus-visible) {
403
+ filter: brightness(80%);
404
+ }
405
+
406
+ :where(.t007-input[type="file"].t007-input-image-selected)::file-selector-button {
407
+ background:
408
+ center/contain no-repeat var(--t007-input-image-src),
409
+ linear-gradient(black, black),
410
+ black;
411
+ color: transparent;
412
+ padding-block: var(--t007-input-sb-padding-block);
413
+ border: none;
414
+ }
415
+
416
+ .t007-input:-webkit-autofill {
417
+ transition: background-color 50000000s ease-in-out 0s !important;
418
+ -webkit-text-fill-color: var(--t007-input-current-value-color) !important;
419
+ }
420
+
421
+ .t007-input-field.t007-input-icon-override input::-webkit-calendar-picker-indicator {
422
+ opacity: 0;
423
+ }
424
+
425
+ .t007-input-icon {
426
+ background: none;
427
+ border: none;
428
+ border-radius: 50%;
429
+ padding: 0.5rem;
430
+ align-self: center;
431
+ cursor: pointer;
432
+ display: flex;
433
+ align-items: center;
434
+ justify-content: center;
435
+ pointer-events: none;
436
+ }
437
+
438
+ .t007-input-icon:is(.t007-input-password-hidden-icon, .t007-input-password-visible-icon) {
439
+ pointer-events: all;
440
+ }
441
+
442
+ .t007-input-icon:hover {
443
+ background-color: rgba(0, 0, 0, 0.02);
444
+ }
445
+
446
+ .t007-input-field.t007-input-icon-override .t007-input-icon {
447
+ position: absolute;
448
+ right: 0;
449
+ }
450
+
451
+ .t007-input-field.t007-input-icon-override svg,
452
+ .t007-input-icon svg {
453
+ width: var(--t007-input-icon-width);
454
+ height: var(--t007-input-icon-height);
455
+ }
456
+
457
+ .t007-input-icon svg path {
458
+ fill: var(--t007-input-icon-fill);
459
+ stroke: var(--t007-input-icon-stroke);
460
+ }
461
+
462
+ .t007-input-field:has(input[type="password"]) .t007-input-password-visible-icon,
463
+ .t007-input-field:has(input[type="text"]) .t007-input-password-hidden-icon {
464
+ display: none;
465
+ }
466
+
467
+ .t007-input-helper-line {
468
+ position: relative;
469
+ margin-inline: 1rem;
470
+ height: calc(var(--t007-input-helper-font-size) * 1.4);
471
+ color: var(--t007-input-current-helper-color);
472
+ }
473
+
474
+ .t007-input-helper-text-wrapper {
475
+ position: relative;
476
+ width: 100%;
477
+ height: 100%;
478
+ overflow-x: auto;
479
+ overflow-y: hidden;
480
+ scrollbar-width: none;
481
+ }
482
+
483
+ .t007-input-helper-text-wrapper::-webkit-scrollbar {
484
+ display: none;
485
+ }
486
+
487
+ .t007-input-scroll-assist {
488
+ position: absolute;
489
+ top: 1px;
490
+ min-width: 2rem;
491
+ height: 100%;
492
+ opacity: 0.075;
493
+ background: linear-gradient(var(--gradient-dir), transparent 0, currentColor 30%, transparent);
494
+ z-index: 2;
495
+ }
496
+
497
+ .t007-input-scroll-assist[data-scroll-direction="left"] {
498
+ left: -0.25rem;
499
+ --gradient-dir: to right;
500
+ }
501
+
502
+ .t007-input-scroll-assist[data-scroll-direction="right"] {
503
+ right: -0.25rem;
504
+ --gradient-dir: to left;
505
+ }
506
+
507
+ .t007-input-helper-text {
508
+ position: absolute;
509
+ top: 2px;
510
+ font-size: var(--t007-input-helper-font-size);
511
+ opacity: 0;
512
+ line-height: 1.2;
513
+ white-space: nowrap;
514
+ }
515
+
516
+ .t007-input-helper-text[data-violation="none"],
517
+ .t007-input-helper-text.t007-input-show {
518
+ opacity: 1;
519
+ }
520
+
521
+ .t007-input-helper-line:has(.t007-input-show) [data-violation="none"],
522
+ .t007-input-helper-line:not(:has(.t007-input-show, [data-violation="none"])) .t007-input-scroll-assist {
523
+ opacity: 0;
524
+ }
525
+
526
+ .t007-input-password-meter {
527
+ --t007-input-p-meter-current-color: var(--t007-input-p-meter-color-weak);
528
+ display: none;
529
+ margin-top: 0.75rem;
530
+ }
531
+
532
+ .t007-input-field:has(.t007-input:is([type="password"], [type="text"]):is([data-filled], :-webkit-autofill, :not(:placeholder-shown))) .t007-input-password-meter {
533
+ display: block;
534
+ }
535
+
536
+ .t007-input-password-meter[data-strength-level="2"] {
537
+ --t007-input-p-meter-current-color: var(--t007-input-p-meter-color-fair);
538
+ }
539
+
540
+ .t007-input-password-meter[data-strength-level="3"] {
541
+ --t007-input-p-meter-current-color: var(--t007-input-p-meter-color-strong);
542
+ }
543
+
544
+ .t007-input-password-meter[data-strength-level="4"] {
545
+ --t007-input-p-meter-current-color: var(--t007-input-p-meter-color-very-strong);
546
+ }
547
+
548
+ .t007-input-password-meter::after {
549
+ content: "";
550
+ position: relative;
551
+ bottom: 0;
552
+ display: block;
553
+ text-align: right;
554
+ font-size: var(--t007-input-p-meter-font-size);
555
+ margin-top: 0.75rem;
556
+ color: var(--t007-input-p-meter-current-color);
557
+ line-height: normal;
558
+ }
559
+
560
+ .t007-input-password-meter[data-strength-level="1"]::after {
561
+ content: "Weak";
562
+ }
563
+
564
+ .t007-input-password-meter[data-strength-level="2"]::after {
565
+ content: "Fair";
566
+ }
567
+
568
+ .t007-input-password-meter[data-strength-level="3"]::after {
569
+ content: "Strong";
570
+ }
571
+
572
+ .t007-input-password-meter[data-strength-level="4"]::after {
573
+ content: "Very Strong";
574
+ }
575
+
576
+ .t007-input-password-strength-meter {
577
+ display: flex;
578
+ }
579
+
580
+ .t007-input-password-strength-meter > div {
581
+ flex: 1;
582
+ margin-right: var(--t007-input-p-meter-gap);
583
+ height: var(--t007-input-p-meter-height);
584
+ border-radius: var(--t007-input-p-meter-border-radius);
585
+ }
586
+
587
+ .t007-input-password-meter[data-strength-level="1"] .t007-input-p-weak,
588
+ .t007-input-password-meter[data-strength-level="2"] :is(.t007-input-p-weak, .t007-input-p-fair),
589
+ .t007-input-password-meter[data-strength-level="3"] :is(.t007-input-p-weak, .t007-input-p-fair, .t007-input-p-strong),
590
+ .t007-input-password-meter[data-strength-level="4"] :is(.t007-input-p-weak, .t007-input-p-fair, .t007-input-p-strong, .t007-input-p-very-strong) {
591
+ background-color: var(--t007-input-p-meter-current-color);
592
+ }
593
+
594
+ .t007-input-checkbox-wrapper,
595
+ .t007-input-radio-wrapper {
596
+ position: relative;
597
+ display: inline-flex;
598
+ align-items: center;
599
+ }
600
+
601
+ .t007-input-checkbox-wrapper {
602
+ font-size: var(--t007-input-checkbox-font-size);
603
+ }
604
+
605
+ .t007-input-radio-wrapper {
606
+ font-size: var(--t007-input-radio-font-size);
607
+ }
608
+
609
+ .t007-input-checkbox-label,
610
+ .t007-input-radio-label {
611
+ color: var(--t007-input-current-label-color);
612
+ }
613
+
614
+ .t007-input-checkbox-label:not(:empty) {
615
+ margin-left: var(--t007-input-checkbox-gap);
616
+ }
617
+
618
+ .t007-input-radio-label:not(:empty) {
619
+ margin-left: var(--t007-input-radio-gap);
620
+ }
621
+
622
+ :is(.t007-input-checkbox-wrapper, .t007-input-radio-wrapper):hover {
623
+ filter: brightness(95%);
624
+ }
625
+
626
+ .t007-input-checkbox-box,
627
+ .t007-input-radio-box {
628
+ position: relative;
629
+ border-style: solid;
630
+ }
631
+
632
+ .t007-input-checkbox-box {
633
+ width: var(--t007-input-checkbox-size);
634
+ height: var(--t007-input-checkbox-size);
635
+ border-width: var(--t007-input-checkbox-border-width);
636
+ }
637
+
638
+ .t007-input-radio-box {
639
+ width: var(--t007-input-radio-size);
640
+ height: var(--t007-input-radio-size);
641
+ border-width: var(--t007-input-radio-border-width);
642
+ }
643
+
644
+ .t007-input-checkbox-box {
645
+ background: var(--t007-input-checkbox-background);
646
+ border-color: var(--t007-input-checkbox-border-color);
647
+ }
648
+
649
+ .t007-input-radio-box {
650
+ background: var(--t007-input-radio-background);
651
+ border-color: var(--t007-input-radio-border-color);
652
+ }
653
+
654
+ .t007-input-checkbox-box {
655
+ border-radius: var(--t007-input-checkbox-border-radius);
656
+ }
657
+
658
+ .t007-input-radio-box {
659
+ border-radius: 50%;
660
+ }
661
+
662
+ .t007-input-field:has(.t007-input[type="checkbox"]:checked) .t007-input-checkbox-box {
663
+ background: var(--t007-input-checkbox-checked-background);
664
+ border-color: var(--t007-input-checkbox-checked-border-color);
665
+ }
666
+
667
+ .t007-input-field:has(.t007-input[type="radio"]:checked) .t007-input-radio-box {
668
+ background: var(--t007-input-radio-checked-background);
669
+ border-color: var(--t007-input-radio-checked-border-color);
670
+ }
671
+
672
+ .t007-input-field:has(.t007-input:is([type="checkbox"], [type="radio"])[data-error]) :is(.t007-input-checkbox-box, .t007-input-radio-box) {
673
+ border-color: var(--t007-input-error-color);
674
+ }
675
+
676
+ .t007-input-checkbox-tag,
677
+ .t007-input-radio-tag {
678
+ content: "";
679
+ opacity: 0;
680
+ position: absolute;
681
+ inset: 0;
682
+ left: 2.6%;
683
+ margin: auto;
684
+ }
685
+
686
+ .t007-input-checkbox-tag {
687
+ top: -14.25%;
688
+ width: 35%;
689
+ height: 70%;
690
+ border: solid var(--t007-input-checkmark-color);
691
+ border-width: 0 var(--t007-input-checkmark-width) var(--t007-input-checkmark-width) 0;
692
+ transform: rotate(45deg);
693
+ }
694
+
695
+ .t007-input-field.t007-input-indeterminate .t007-input-checkbox-tag {
696
+ top: 50%;
697
+ left: 50.5%;
698
+ width: 60%;
699
+ height: var(--t007-input-checkmark-width);
700
+ margin: 0;
701
+ transform: translate(-50%, -50%);
702
+ background-color: var(--t007-input-checkmark-color);
703
+ border: none;
704
+ }
705
+
706
+ .t007-input-radio-tag {
707
+ width: 70%;
708
+ height: 72.5%;
709
+ left: -1%;
710
+ border-radius: inherit;
711
+ background: var(--t007-input-radio-color);
712
+ scale: 0;
713
+ transition-timing-function: cubic-bezier(0.34, 1.64, 0.64, 1);
714
+ }
715
+
716
+ .t007-input-field:has(.t007-input:is([type="radio"], [type="checkbox"]):checked) :is(.t007-input-checkbox-tag, .t007-input-radio-tag) {
717
+ opacity: 1;
718
+ scale: 1;
719
+ }
720
+
721
+ /* Base styles to enable pointer effects */
722
+ :where(.t007-input-rippler),
723
+ .t007-input-checkbox-box,
724
+ .t007-input-radio-box {
725
+ position: relative;
726
+ outline: none !important;
727
+ }
728
+
729
+ /* Pulse bubble effect on click */
730
+ .t007-input-rippler::before,
731
+ .t007-input-checkbox-box::before,
732
+ .t007-input-radio-box::before {
733
+ content: "";
734
+ position: absolute;
735
+ top: 50%;
736
+ left: 50%;
737
+ width: 0;
738
+ height: 0;
739
+ background: var(--t007-input-ripple-color);
740
+ border-radius: 50%;
741
+ transform: translate(-50%, -50%);
742
+ transition-property: width, height, opacity;
743
+ transition-duration: 300ms;
744
+ transition-timing-function: cubic-bezier(0.68, -0.55, 0.27, 1.55);
745
+ opacity: 0;
746
+ pointer-events: none;
747
+ }
748
+
749
+ .t007-input-rippler:is(:hover, :focus-visible, :has(:focus-visible), :has(~ :focus-visible))::before,
750
+ .t007-input-field:is(:hover, :has(.t007-input[type="checkbox"]:focus-visible)) .t007-input-checkbox-box::before,
751
+ .t007-input-field:is(:hover, :has(.t007-input[type="radio"]:focus-visible)) .t007-input-radio-box::before {
752
+ width: var(--t007-input-ripple-size);
753
+ height: var(--t007-input-ripple-size);
754
+ opacity: 1;
755
+ }
756
+
757
+ .t007-input-rippler:is(:checked, :has(:checked), :has(~ :checked))::before,
758
+ .t007-input-field:has(.t007-input[type="checkbox"]:checked) .t007-input-checkbox-box::before,
759
+ .t007-input-field:has(.t007-input[type="radio"]:checked) .t007-input-radio-box::before {
760
+ animation: t007-ripple-pulse 350ms ease-out;
761
+ }
762
+
763
+ @keyframes t007-ripple-pulse {
764
+ 0% {
765
+ width: 0;
766
+ height: 0;
767
+ opacity: 0.5;
768
+ }
769
+ 85% {
770
+ width: var(--t007-input-ripple-size);
771
+ height: var(--t007-input-ripple-size);
772
+ opacity: 1;
773
+ }
774
+ 100% {
775
+ width: var(--t007-input-ripple-size);
776
+ height: var(--t007-input-ripple-size);
777
+ opacity: 0;
778
+ }
779
+ }