-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathSprintCodeInput.css.ts
More file actions
94 lines (84 loc) · 1.86 KB
/
SprintCodeInput.css.ts
File metadata and controls
94 lines (84 loc) · 1.86 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
import { style } from '@vanilla-extract/css';
import { colors } from '@sopt-makers/colors';
import { fontsObject } from '@sopt-makers/fonts';
export const root = style({
display: 'flex',
flexDirection: 'column',
gap: 12,
maxWidth: 320,
textAlign: 'left',
});
export const fieldLabel = style({
display: 'flex',
alignItems: 'center',
gap: 4,
});
export const fieldLabelText = style({
color: colors.white,
...fontsObject.LABEL_3_14_SB,
});
export const fieldLabelRequired = style({
color: colors.orange400,
...fontsObject.LABEL_4_12_SB,
});
export const codeField = style({
position: 'relative',
width: '100%',
});
export const hiddenInput = style({
position: 'absolute',
inset: 0,
width: '100%',
height: '100%',
opacity: 0,
cursor: 'text',
caretColor: 'transparent',
zIndex: 1,
});
export const codeBoxes = style({
display: 'flex',
gap: 12,
pointerEvents: 'none',
});
export const codeBox = style({
boxSizing: 'border-box',
display: 'flex',
alignItems: 'center',
justifyContent: 'center',
width: 42,
height: 60,
borderRadius: 8,
backgroundColor: colors.gray600,
border: '1px solid transparent',
selectors: {
'&[data-filled="true"]': {
backgroundColor: colors.gray800,
borderColor: colors.orange400,
},
'&[data-active="true"]:not([data-filled="true"])': {
backgroundColor: colors.gray800,
borderColor: colors.orange400,
},
'&[data-error="true"]': {
borderColor: colors.error,
},
},
});
export const codeDigit = style({
display: 'block',
minHeight: '1em',
textAlign: 'center',
color: colors.secondary,
...fontsObject.HEADING_7_16_B,
selectors: {
[`${codeBox}[data-error="true"] &`]: {
color: colors.error,
},
},
});
export const errorText = style({
margin: 0,
textAlign: 'left',
color: colors.error,
...fontsObject.BODY_3_14_M,
});