astrum-ui 0.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.
- package/dist/Avatar/Avatar.css +148 -0
- package/dist/Button/Button.css +170 -0
- package/dist/Checkbox/Checkbox.css +112 -0
- package/dist/Chips/Chips.css +63 -0
- package/dist/ColorPicker/ColorPicker.css +50 -0
- package/dist/FileUpload/FileUpload.css +191 -0
- package/dist/Input/Input.css +230 -0
- package/dist/InputCode/InputCode.css +98 -0
- package/dist/Radio/Radio.css +106 -0
- package/dist/Select/Select.css +210 -0
- package/dist/Toggler/Toggler.css +83 -0
- package/dist/index.css +221 -0
- package/dist/index.css.map +1 -0
- package/dist/index.d.mts +136 -0
- package/dist/index.d.ts +136 -0
- package/dist/index.js +1264 -0
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +1216 -0
- package/dist/index.mjs.map +1 -0
- package/dist/styles.css +11 -0
- package/package.json +53 -0
|
@@ -0,0 +1,230 @@
|
|
|
1
|
+
.astrum-input {
|
|
2
|
+
--astrum-input-primary: #2653F2;
|
|
3
|
+
--astrum-input-border: #D5D5D5;
|
|
4
|
+
--astrum-input-border-hover: #ABABAB;
|
|
5
|
+
--astrum-input-placeholder: #ABABAB;
|
|
6
|
+
--astrum-input-placeholder-focus: #D5D5D5;
|
|
7
|
+
--astrum-input-text: #575757;
|
|
8
|
+
--astrum-input-error: #EA3B3D;
|
|
9
|
+
--astrum-input-bg: #FFFFFF;
|
|
10
|
+
|
|
11
|
+
display: inline-flex;
|
|
12
|
+
flex-direction: column;
|
|
13
|
+
gap: 0;
|
|
14
|
+
min-width: 0;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.astrum-input__wrap {
|
|
18
|
+
position: relative;
|
|
19
|
+
display: flex;
|
|
20
|
+
align-items: center;
|
|
21
|
+
background: var(--astrum-input-bg);
|
|
22
|
+
border: 1px solid var(--astrum-input-border);
|
|
23
|
+
border-radius: 4px;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
@media (hover: hover) {
|
|
27
|
+
.astrum-input__wrap:hover:not(:has(.astrum-input__field:disabled)) {
|
|
28
|
+
border-color: var(--astrum-input-border-hover);
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
.astrum-input__wrap:focus-within {
|
|
33
|
+
outline: 1px solid var(--astrum-input-primary);
|
|
34
|
+
outline-offset: -1px;
|
|
35
|
+
border-color: var(--astrum-input-primary);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.astrum-input--error .astrum-input__wrap {
|
|
39
|
+
border-color: var(--astrum-input-error);
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.astrum-input--error .astrum-input__wrap:focus-within {
|
|
43
|
+
outline-color: var(--astrum-input-error);
|
|
44
|
+
border-color: var(--astrum-input-error);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.astrum-input__label {
|
|
48
|
+
display: block;
|
|
49
|
+
margin-bottom: 8px;
|
|
50
|
+
font-weight: 500;
|
|
51
|
+
font-size: 14px;
|
|
52
|
+
line-height: 120%;
|
|
53
|
+
color: var(--astrum-input-text);
|
|
54
|
+
cursor: pointer;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
.astrum-input--s .astrum-input__label {
|
|
58
|
+
margin-bottom: 6px;
|
|
59
|
+
font-size: 12px;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.astrum-input__required-icon {
|
|
63
|
+
display: flex;
|
|
64
|
+
width: 7px;
|
|
65
|
+
height: 6px;
|
|
66
|
+
position: absolute;
|
|
67
|
+
top: 8px;
|
|
68
|
+
right: 8px;
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
.astrum-input--s .astrum-input__required-icon {
|
|
72
|
+
top: 6px;
|
|
73
|
+
right: 6px;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.astrum-input__wrap--search .astrum-input__field {
|
|
77
|
+
padding-right: 36px;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
.astrum-input--s .astrum-input__wrap--search .astrum-input__field {
|
|
81
|
+
padding-right: 32px;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.astrum-input__wrap--password .astrum-input__field {
|
|
85
|
+
padding-right: 36px;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.astrum-input--s .astrum-input__wrap--password .astrum-input__field {
|
|
89
|
+
padding-right: 32px;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.astrum-input__search-icon {
|
|
93
|
+
position: absolute;
|
|
94
|
+
top: 50%;
|
|
95
|
+
right: 16px;
|
|
96
|
+
transform: translateY(-50%);
|
|
97
|
+
display: flex;
|
|
98
|
+
align-items: center;
|
|
99
|
+
justify-content: center;
|
|
100
|
+
padding: 0;
|
|
101
|
+
margin: 0;
|
|
102
|
+
border: none;
|
|
103
|
+
background: transparent;
|
|
104
|
+
color: var(--astrum-input-placeholder);
|
|
105
|
+
cursor: pointer;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.astrum-input--s .astrum-input__search-icon {
|
|
109
|
+
right: 8px;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
.astrum-input--s .astrum-input__search-icon svg {
|
|
113
|
+
width: 24px;
|
|
114
|
+
height: 24px;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
.astrum-input__clear-icon {
|
|
118
|
+
position: absolute;
|
|
119
|
+
top: 50%;
|
|
120
|
+
right: 16px;
|
|
121
|
+
transform: translateY(-50%);
|
|
122
|
+
display: flex;
|
|
123
|
+
align-items: center;
|
|
124
|
+
justify-content: center;
|
|
125
|
+
padding: 0;
|
|
126
|
+
margin: 0;
|
|
127
|
+
border: none;
|
|
128
|
+
background: transparent;
|
|
129
|
+
color: var(--astrum-input-placeholder);
|
|
130
|
+
cursor: pointer;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
.astrum-input--s .astrum-input__clear-icon {
|
|
134
|
+
right: 6px;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
.astrum-input--s .astrum-input__clear-icon svg {
|
|
138
|
+
width: 20px;
|
|
139
|
+
height: 20px;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
.astrum-input__password-toggle {
|
|
143
|
+
position: absolute;
|
|
144
|
+
top: 50%;
|
|
145
|
+
right: 16px;
|
|
146
|
+
transform: translateY(-50%);
|
|
147
|
+
display: flex;
|
|
148
|
+
align-items: center;
|
|
149
|
+
justify-content: center;
|
|
150
|
+
padding: 0;
|
|
151
|
+
margin: 0;
|
|
152
|
+
border: none;
|
|
153
|
+
background: transparent;
|
|
154
|
+
color: var(--astrum-input-border-hover);
|
|
155
|
+
cursor: pointer;
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
.astrum-input--s .astrum-input__password-toggle {
|
|
159
|
+
right: 6px;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
.astrum-input--s .astrum-input__password-toggle svg {
|
|
163
|
+
width: 24px;
|
|
164
|
+
height: 24px;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
.astrum-input__field {
|
|
168
|
+
box-sizing: border-box;
|
|
169
|
+
flex: 1;
|
|
170
|
+
min-width: 0;
|
|
171
|
+
width: 100%;
|
|
172
|
+
height: 54px;
|
|
173
|
+
padding: 16px 8px 16px 24px;
|
|
174
|
+
border: none;
|
|
175
|
+
border-radius: 8px;
|
|
176
|
+
background: transparent;
|
|
177
|
+
font-family: inherit;
|
|
178
|
+
font-weight: 500;
|
|
179
|
+
font-size: 16px;
|
|
180
|
+
line-height: 1.5;
|
|
181
|
+
color: var(--astrum-input-text);
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
.astrum-input__field[type="search"]::-webkit-search-cancel-button {
|
|
185
|
+
display: none;
|
|
186
|
+
-webkit-appearance: none;
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
.astrum-input--s .astrum-input__field {
|
|
190
|
+
height: 43px;
|
|
191
|
+
padding: 12px 8px 12px 20px;
|
|
192
|
+
font-size: 14px;
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
.astrum-input__field::placeholder {
|
|
196
|
+
color: var(--astrum-input-placeholder);
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
.astrum-input__field:focus::placeholder {
|
|
200
|
+
color: var(--astrum-input-placeholder-focus);
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
.astrum-input__field:focus-visible {
|
|
204
|
+
border-color: transparent;
|
|
205
|
+
outline: 1px solid transparent;
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
.astrum-input__field:disabled {
|
|
209
|
+
opacity: 0.4;
|
|
210
|
+
cursor: not-allowed;
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
.astrum-input__wrap:has(.astrum-input__field:disabled) {
|
|
214
|
+
cursor: not-allowed;
|
|
215
|
+
border-style: dotted;
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
.astrum-input__error {
|
|
219
|
+
display: block;
|
|
220
|
+
margin-top: 8px;
|
|
221
|
+
font-weight: 500;
|
|
222
|
+
font-size: 12px;
|
|
223
|
+
line-height: 1.4;
|
|
224
|
+
color: var(--astrum-input-error);
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
.astrum-input--s .astrum-input__error {
|
|
228
|
+
margin-top: 6px;
|
|
229
|
+
font-size: 11px;
|
|
230
|
+
}
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
.astrum-input-code {
|
|
2
|
+
--astrum-input-code-primary: #2653F2;
|
|
3
|
+
--astrum-input-code-border: #D5D5D5;
|
|
4
|
+
--astrum-input-code-text: #575757;
|
|
5
|
+
--astrum-input-code-placeholder: #ABABAB;
|
|
6
|
+
--astrum-input-code-error: #EA3B3D;
|
|
7
|
+
--astrum-input-code-error-bg: #FEE8E8;
|
|
8
|
+
--astrum-input-code-bg: #FFFFFF;
|
|
9
|
+
|
|
10
|
+
display: inline-flex;
|
|
11
|
+
flex-direction: column;
|
|
12
|
+
gap: 0;
|
|
13
|
+
min-width: 0;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.astrum-input-code__wrap {
|
|
17
|
+
box-sizing: border-box;
|
|
18
|
+
position: relative;
|
|
19
|
+
display: flex;
|
|
20
|
+
gap: 8px;
|
|
21
|
+
align-items: center;
|
|
22
|
+
justify-content: center;
|
|
23
|
+
width: 100%;
|
|
24
|
+
min-width: 301px;
|
|
25
|
+
padding: 16px 24px;
|
|
26
|
+
border: 1px solid var(--astrum-input-code-border);
|
|
27
|
+
border-radius: 8px;
|
|
28
|
+
background: var(--astrum-input-code-bg);
|
|
29
|
+
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
|
|
30
|
+
transition: border-color 0.2s, box-shadow 0.2s;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
.astrum-input-code__wrap:focus-within {
|
|
34
|
+
border-color: var(--astrum-input-code-primary);
|
|
35
|
+
box-shadow: 0 0 0 2px rgba(38, 83, 242, 0.1);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.astrum-input-code--error .astrum-input-code__wrap {
|
|
39
|
+
border-color: var(--astrum-input-code-error);
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.astrum-input-code__cell {
|
|
43
|
+
width: 18px;
|
|
44
|
+
height: 36px;
|
|
45
|
+
padding: 0;
|
|
46
|
+
margin: 0;
|
|
47
|
+
border: none;
|
|
48
|
+
border-bottom: 2px solid var(--astrum-input-code-placeholder);
|
|
49
|
+
border-radius: 0;
|
|
50
|
+
background: transparent;
|
|
51
|
+
font-family: inherit;
|
|
52
|
+
font-size: 28px;
|
|
53
|
+
font-weight: 700;
|
|
54
|
+
line-height: 1.2;
|
|
55
|
+
color: var(--astrum-input-code-text);
|
|
56
|
+
text-align: center;
|
|
57
|
+
outline: none;
|
|
58
|
+
transition: border-color 0.2s, color 0.2s;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.astrum-input-code__cell::placeholder {
|
|
62
|
+
color: transparent;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
.astrum-input-code__cell:focus {
|
|
66
|
+
border-bottom-color: var(--astrum-input-code-primary);
|
|
67
|
+
color: var(--astrum-input-code-primary);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.astrum-input-code__cell--spaced {
|
|
71
|
+
margin-left: 10px;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.astrum-input-code__cell:disabled {
|
|
75
|
+
cursor: not-allowed;
|
|
76
|
+
opacity: 0.4;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
.astrum-input-code__wrap:has(.astrum-input-code__cell:disabled) {
|
|
80
|
+
background-color: #F4F4F4;
|
|
81
|
+
border-style: dashed;
|
|
82
|
+
cursor: not-allowed;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.astrum-input-code__footer {
|
|
86
|
+
margin-top: 8px;
|
|
87
|
+
padding: 8px 12px;
|
|
88
|
+
border-radius: 4px;
|
|
89
|
+
background-color: var(--astrum-input-code-error-bg);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.astrum-input-code__error {
|
|
93
|
+
display: block;
|
|
94
|
+
font-weight: 500;
|
|
95
|
+
font-size: 12px;
|
|
96
|
+
line-height: 1.4;
|
|
97
|
+
color: var(--astrum-input-code-error);
|
|
98
|
+
}
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
.astrum-radio {
|
|
2
|
+
--astrum-primary: #2653f2;
|
|
3
|
+
--astrum-hover-blue: #0431d0;
|
|
4
|
+
--astrum-gray-20: #d5d5d5;
|
|
5
|
+
--astrum-gray-40: #ababab;
|
|
6
|
+
--astrum-gray-5: #f4f4f4;
|
|
7
|
+
|
|
8
|
+
display: inline-flex;
|
|
9
|
+
align-items: center;
|
|
10
|
+
gap: 8px;
|
|
11
|
+
cursor: pointer;
|
|
12
|
+
user-select: none;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.astrum-radio__input {
|
|
16
|
+
position: absolute;
|
|
17
|
+
width: 1px;
|
|
18
|
+
height: 1px;
|
|
19
|
+
padding: 0;
|
|
20
|
+
margin: -1px;
|
|
21
|
+
overflow: hidden;
|
|
22
|
+
clip: rect(0, 0, 0, 0);
|
|
23
|
+
white-space: nowrap;
|
|
24
|
+
border: 0;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.astrum-radio__circle {
|
|
28
|
+
flex-shrink: 0;
|
|
29
|
+
width: 24px;
|
|
30
|
+
height: 24px;
|
|
31
|
+
border-radius: 50%;
|
|
32
|
+
border: 2px solid var(--astrum-gray-20);
|
|
33
|
+
background-color: transparent;
|
|
34
|
+
transition:
|
|
35
|
+
border-color 0.15s,
|
|
36
|
+
background-color 0.15s,
|
|
37
|
+
box-shadow 0.15s;
|
|
38
|
+
position: relative;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.astrum-radio__circle::after {
|
|
42
|
+
content: "";
|
|
43
|
+
position: absolute;
|
|
44
|
+
inset: 4px;
|
|
45
|
+
border-radius: 50%;
|
|
46
|
+
background-color: var(--astrum-primary);
|
|
47
|
+
transform: scale(0);
|
|
48
|
+
transition: transform 0.15s ease;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.astrum-radio:hover:not(:has(.astrum-radio__input:disabled)) .astrum-radio__circle {
|
|
52
|
+
border-color: var(--astrum-gray-40);
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.astrum-radio__input:checked + .astrum-radio__circle {
|
|
56
|
+
border-color: var(--astrum-primary);
|
|
57
|
+
border-width: 2px;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
.astrum-radio__input:checked + .astrum-radio__circle::after {
|
|
61
|
+
transform: scale(1);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
.astrum-radio:hover:not(:has(.astrum-radio__input:disabled))
|
|
65
|
+
.astrum-radio__input:checked
|
|
66
|
+
+ .astrum-radio__circle {
|
|
67
|
+
border-color: var(--astrum-hover-blue);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.astrum-radio:hover:not(:has(.astrum-radio__input:disabled))
|
|
71
|
+
.astrum-radio__input:checked
|
|
72
|
+
+ .astrum-radio__circle::after {
|
|
73
|
+
background-color: var(--astrum-hover-blue);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.astrum-radio__input:disabled + .astrum-radio__circle {
|
|
77
|
+
border-color: var(--astrum-primary);
|
|
78
|
+
cursor: not-allowed;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
.astrum-radio__input:disabled:checked + .astrum-radio__circle {
|
|
82
|
+
border-color: var(--astrum-primary);
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.astrum-radio__input:disabled:checked + .astrum-radio__circle::after {
|
|
86
|
+
background-color: var(--astrum-primary);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.astrum-radio:has(.astrum-radio__input:disabled) {
|
|
90
|
+
cursor: not-allowed;
|
|
91
|
+
opacity: 0.4;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.astrum-radio-group {
|
|
95
|
+
border: none;
|
|
96
|
+
padding: 0;
|
|
97
|
+
margin: 0;
|
|
98
|
+
display: flex;
|
|
99
|
+
flex-direction: column;
|
|
100
|
+
gap: 12px;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.astrum-radio-group[data-inline] {
|
|
104
|
+
flex-direction: row;
|
|
105
|
+
flex-wrap: wrap;
|
|
106
|
+
}
|
|
@@ -0,0 +1,210 @@
|
|
|
1
|
+
.astrum-select {
|
|
2
|
+
--astrum-primary: #2653f2;
|
|
3
|
+
--astrum-gray-20: #d5d5d5;
|
|
4
|
+
--astrum-gray-40: #ababab;
|
|
5
|
+
--astrum-gray-80: #575757;
|
|
6
|
+
--astrum-gray-5: #f4f4f4;
|
|
7
|
+
--astrum-error: #ea3b3d;
|
|
8
|
+
|
|
9
|
+
position: relative;
|
|
10
|
+
display: inline-flex;
|
|
11
|
+
flex-direction: column;
|
|
12
|
+
gap: 6px;
|
|
13
|
+
font-family: "Involve", sans-serif;
|
|
14
|
+
min-width: 0;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.astrum-select__label {
|
|
18
|
+
font-size: 14px;
|
|
19
|
+
font-weight: 500;
|
|
20
|
+
line-height: 1.4;
|
|
21
|
+
color: var(--astrum-gray-80);
|
|
22
|
+
cursor: pointer;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.astrum-select__required {
|
|
26
|
+
color: var(--astrum-error);
|
|
27
|
+
margin-left: 2px;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.astrum-select__wrap {
|
|
31
|
+
position: relative;
|
|
32
|
+
display: flex;
|
|
33
|
+
align-items: center;
|
|
34
|
+
border: 1px solid var(--astrum-gray-20);
|
|
35
|
+
border-radius: 8px;
|
|
36
|
+
background-color: #ffffff;
|
|
37
|
+
transition: border-color 0.15s, box-shadow 0.15s;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
.astrum-select--open .astrum-select__wrap {
|
|
41
|
+
border-color: var(--astrum-primary);
|
|
42
|
+
box-shadow: 0 0 0 1px var(--astrum-primary);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.astrum-select--error .astrum-select__wrap {
|
|
46
|
+
border-color: var(--astrum-error);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.astrum-select--error .astrum-select__wrap:focus-within,
|
|
50
|
+
.astrum-select--error.astrum-select--open .astrum-select__wrap {
|
|
51
|
+
border-color: var(--astrum-error);
|
|
52
|
+
box-shadow: 0 0 0 1px var(--astrum-error);
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.astrum-select__field {
|
|
56
|
+
position: absolute;
|
|
57
|
+
width: 1px;
|
|
58
|
+
height: 1px;
|
|
59
|
+
padding: 0;
|
|
60
|
+
margin: -1px;
|
|
61
|
+
overflow: hidden;
|
|
62
|
+
clip: rect(0, 0, 0, 0);
|
|
63
|
+
white-space: nowrap;
|
|
64
|
+
border: 0;
|
|
65
|
+
opacity: 0;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.astrum-select__trigger {
|
|
69
|
+
flex: 1;
|
|
70
|
+
min-width: 0;
|
|
71
|
+
width: 100%;
|
|
72
|
+
display: flex;
|
|
73
|
+
align-items: center;
|
|
74
|
+
justify-content: space-between;
|
|
75
|
+
gap: 8px;
|
|
76
|
+
padding: 10px 12px;
|
|
77
|
+
border: none;
|
|
78
|
+
border-radius: 8px;
|
|
79
|
+
background: transparent;
|
|
80
|
+
font-family: inherit;
|
|
81
|
+
font-size: 16px;
|
|
82
|
+
font-weight: 400;
|
|
83
|
+
line-height: 1.5;
|
|
84
|
+
color: var(--astrum-gray-80);
|
|
85
|
+
cursor: pointer;
|
|
86
|
+
text-align: left;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.astrum-select__trigger:disabled {
|
|
90
|
+
cursor: not-allowed;
|
|
91
|
+
color: var(--astrum-gray-40);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.astrum-select__value {
|
|
95
|
+
flex: 1;
|
|
96
|
+
min-width: 0;
|
|
97
|
+
overflow: hidden;
|
|
98
|
+
text-overflow: ellipsis;
|
|
99
|
+
white-space: nowrap;
|
|
100
|
+
color: inherit;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.astrum-select__value--placeholder {
|
|
104
|
+
color: var(--astrum-gray-40);
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
.astrum-select__chevron {
|
|
108
|
+
flex-shrink: 0;
|
|
109
|
+
display: flex;
|
|
110
|
+
align-items: center;
|
|
111
|
+
justify-content: center;
|
|
112
|
+
color: var(--astrum-gray-40);
|
|
113
|
+
transition: transform 0.2s ease;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.astrum-select__chevron--open {
|
|
117
|
+
transform: rotate(180deg);
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
.astrum-select__wrap:has(.astrum-select__trigger:disabled) {
|
|
121
|
+
background-color: var(--astrum-gray-5);
|
|
122
|
+
border-color: var(--astrum-gray-20);
|
|
123
|
+
cursor: not-allowed;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
.astrum-select__footer {
|
|
127
|
+
display: flex;
|
|
128
|
+
align-items: center;
|
|
129
|
+
justify-content: space-between;
|
|
130
|
+
gap: 8px;
|
|
131
|
+
min-height: 18px;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
.astrum-select__error {
|
|
135
|
+
font-size: 12px;
|
|
136
|
+
font-weight: 500;
|
|
137
|
+
line-height: 1.4;
|
|
138
|
+
color: var(--astrum-error);
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
.astrum-select__dropdown {
|
|
142
|
+
position: absolute;
|
|
143
|
+
top: calc(100% + 4px);
|
|
144
|
+
left: 0;
|
|
145
|
+
right: 0;
|
|
146
|
+
z-index: 1000;
|
|
147
|
+
max-height: 240px;
|
|
148
|
+
overflow-y: auto;
|
|
149
|
+
border: 1px solid var(--astrum-gray-20);
|
|
150
|
+
border-radius: 8px;
|
|
151
|
+
background-color: #ffffff;
|
|
152
|
+
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
|
|
153
|
+
display: flex;
|
|
154
|
+
flex-direction: column;
|
|
155
|
+
min-width: 0;
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
.astrum-select__option {
|
|
159
|
+
padding: 10px 12px;
|
|
160
|
+
border: none;
|
|
161
|
+
background: transparent;
|
|
162
|
+
font-family: inherit;
|
|
163
|
+
font-size: 16px;
|
|
164
|
+
font-weight: 400;
|
|
165
|
+
line-height: 1.5;
|
|
166
|
+
color: var(--astrum-gray-80);
|
|
167
|
+
text-align: left;
|
|
168
|
+
cursor: pointer;
|
|
169
|
+
transition: background-color 0.15s;
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
.astrum-select__option:hover:not(:disabled) {
|
|
173
|
+
background-color: var(--astrum-gray-5);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.astrum-select__option--selected {
|
|
177
|
+
background-color: var(--astrum-gray-5);
|
|
178
|
+
color: var(--astrum-primary);
|
|
179
|
+
font-weight: 500;
|
|
180
|
+
}
|
|
181
|
+
|
|
182
|
+
.astrum-select__option--disabled {
|
|
183
|
+
color: var(--astrum-gray-40);
|
|
184
|
+
cursor: not-allowed;
|
|
185
|
+
opacity: 0.6;
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
.astrum-select--s .astrum-select__label {
|
|
189
|
+
font-size: 12px;
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
.astrum-select--s .astrum-select__trigger {
|
|
193
|
+
padding: 8px 10px;
|
|
194
|
+
font-size: 14px;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
.astrum-select--s .astrum-select__option {
|
|
198
|
+
padding: 8px 10px;
|
|
199
|
+
font-size: 14px;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
.astrum-select--l .astrum-select__trigger {
|
|
203
|
+
padding: 12px 16px;
|
|
204
|
+
font-size: 18px;
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
.astrum-select--l .astrum-select__option {
|
|
208
|
+
padding: 12px 16px;
|
|
209
|
+
font-size: 18px;
|
|
210
|
+
}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
.astrum-toggler {
|
|
2
|
+
--astrum-toggler-primary: #2653F2;
|
|
3
|
+
--astrum-toggler-hover-blue: #0431D0;
|
|
4
|
+
--astrum-toggler-gray-200: #D5D5D5;
|
|
5
|
+
--astrum-toggler-gray-400: #ABABAB;
|
|
6
|
+
--astrum-toggler-gray-600: #818181;
|
|
7
|
+
--astrum-toggler-white: #FFFFFF;
|
|
8
|
+
|
|
9
|
+
display: inline-flex;
|
|
10
|
+
align-items: center;
|
|
11
|
+
cursor: pointer;
|
|
12
|
+
position: relative;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.astrum-toggler__input {
|
|
16
|
+
position: absolute;
|
|
17
|
+
opacity: 0;
|
|
18
|
+
width: 0;
|
|
19
|
+
height: 0;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.astrum-toggler__track {
|
|
23
|
+
box-sizing: border-box;
|
|
24
|
+
position: relative;
|
|
25
|
+
display: flex;
|
|
26
|
+
align-items: center;
|
|
27
|
+
width: 36px;
|
|
28
|
+
height: 18px;
|
|
29
|
+
border-radius: 32px;
|
|
30
|
+
transition: background-color 0.2s ease-out, border-color 0.2s ease-out;
|
|
31
|
+
flex-shrink: 0;
|
|
32
|
+
overflow: hidden;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.astrum-toggler__thumb {
|
|
36
|
+
box-sizing: border-box;
|
|
37
|
+
position: absolute;
|
|
38
|
+
top: 50%;
|
|
39
|
+
left: 3px;
|
|
40
|
+
transform: translateY(-50%);
|
|
41
|
+
width: 10px;
|
|
42
|
+
height: 10px;
|
|
43
|
+
border-radius: 32px;
|
|
44
|
+
background: var(--astrum-toggler-gray-400);
|
|
45
|
+
flex-shrink: 0;
|
|
46
|
+
transition: transform 0.2s ease-out, left 0.2s ease-out;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.astrum-toggler:not(.astrum-toggler--checked) .astrum-toggler__track {
|
|
50
|
+
background: transparent;
|
|
51
|
+
border: 1px solid var(--astrum-toggler-gray-400);
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.astrum-toggler:not(.astrum-toggler--checked) .astrum-toggler__thumb {
|
|
55
|
+
transform: translateY(-50%);
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
@media (hover: hover) {
|
|
59
|
+
.astrum-toggler:hover:not(.astrum-toggler--disabled):not(.astrum-toggler--checked) .astrum-toggler__track {
|
|
60
|
+
border-color: var(--astrum-toggler-gray-600);
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
.astrum-toggler--checked .astrum-toggler__track {
|
|
65
|
+
border: 1px solid var(--astrum-toggler-primary);
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.astrum-toggler--checked .astrum-toggler__thumb {
|
|
69
|
+
transform: translateY(-50%);
|
|
70
|
+
background: var(--astrum-toggler-primary);
|
|
71
|
+
left: calc(100% - 13px);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
@media (hover: hover) {
|
|
75
|
+
.astrum-toggler:hover:not(.astrum-toggler--disabled).astrum-toggler--checked .astrum-toggler__track {
|
|
76
|
+
border-color: var(--astrum-toggler-hover-blue);
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
.astrum-toggler--disabled {
|
|
81
|
+
cursor: not-allowed;
|
|
82
|
+
opacity: 0.4;
|
|
83
|
+
}
|