@dolanske/vui 1.0.1 → 1.0.3
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/LICENSE +673 -673
- package/README.md +42 -42
- package/dist/components/Accordion/Accordion.vue.d.ts +2 -3
- package/dist/components/Accordion/AccordionGroup.vue.d.ts +2 -5
- package/dist/components/Alert/Alert.vue.d.ts +2 -3
- package/dist/components/Avatar/Avatar.vue.d.ts +2 -3
- package/dist/components/Badge/Badge.vue.d.ts +2 -3
- package/dist/components/Breadcrumbs/BreadcrumbItem.vue.d.ts +2 -3
- package/dist/components/Breadcrumbs/Breadcrumbs.vue.d.ts +2 -3
- package/dist/components/Button/Button.vue.d.ts +2 -3
- package/dist/components/ButtonGroup/ButtonGroup.vue.d.ts +2 -3
- package/dist/components/Calendar/Calendar.vue.d.ts +6 -6
- package/dist/components/Card/Card.vue.d.ts +3 -4
- package/dist/components/Checkbox/Checkbox.vue.d.ts +6 -7
- package/dist/components/CopyClipboard/CopyClipboard.vue.d.ts +1 -2
- package/dist/components/Divider/Divider.vue.d.ts +2 -3
- package/dist/components/Drawer/Drawer.vue.d.ts +5 -6
- package/dist/components/Dropdown/Dropdown.vue.d.ts +3 -66
- package/dist/components/Dropdown/DropdownItem.vue.d.ts +2 -3
- package/dist/components/Dropdown/DropdownTitle.vue.d.ts +6 -6
- package/dist/components/Flex/Flex.vue.d.ts +2 -3
- package/dist/components/Grid/Grid.vue.d.ts +2 -3
- package/dist/components/Input/Color.vue.d.ts +5 -5
- package/dist/components/Input/Counter.vue.d.ts +5 -5
- package/dist/components/Input/Dropzone.vue.d.ts +10 -95
- package/dist/components/Input/File.vue.d.ts +3 -4
- package/dist/components/Input/Input.vue.d.ts +6 -7
- package/dist/components/Input/Password.vue.d.ts +1 -1
- package/dist/components/Input/Textarea.vue.d.ts +6 -7
- package/dist/components/Kbd/Kbd.vue.d.ts +1 -1
- package/dist/components/Kbd/KbdGroup.vue.d.ts +1 -2
- package/dist/components/Modal/Confirm.vue.d.ts +5 -6
- package/dist/components/Modal/Modal.vue.d.ts +5 -6
- package/dist/components/OTP/OTP.vue.d.ts +6 -7
- package/dist/components/OTP/OTPItem.vue.d.ts +1 -1
- package/dist/components/Pagination/Pagination.vue.d.ts +2 -3
- package/dist/components/Popout/Popout.vue.d.ts +2 -3
- package/dist/components/Progress/Progress.vue.d.ts +5 -5
- package/dist/components/Radio/Radio.vue.d.ts +6 -7
- package/dist/components/Radio/RadioGroup.vue.d.ts +6 -7
- package/dist/components/Select/Select.vue.d.ts +8 -4
- package/dist/components/Sheet/Sheet.vue.d.ts +5 -6
- package/dist/components/Sidebar/Sidebar.vue.d.ts +6 -7
- package/dist/components/Skeleton/Skeleton.vue.d.ts +1 -1
- package/dist/components/Spinner/Spinner.vue.d.ts +1 -1
- package/dist/components/Switch/Switch.vue.d.ts +6 -7
- package/dist/components/Table/Cell.vue.d.ts +2 -5
- package/dist/components/Table/Head.vue.d.ts +2 -3
- package/dist/components/Table/Root.vue.d.ts +2 -3
- package/dist/components/Table/table.d.ts +2 -2
- package/dist/components/Tabs/Tab.vue.d.ts +2 -3
- package/dist/components/Tabs/Tabs.vue.d.ts +6 -7
- package/dist/components/Toast/toast.d.ts +6 -6
- package/dist/components/Tooltip/Tooltip.vue.d.ts +1 -2
- package/dist/internal/Backdrop/Backdrop.vue.d.ts +2 -3
- package/dist/{vui.css → style.css} +1 -1
- package/dist/vui.js +5318 -5449
- package/package.json +72 -72
- package/src/App.vue +95 -95
- package/src/components/Accordion/Accordion.vue +91 -91
- package/src/components/Accordion/AccordionGroup.vue +43 -43
- package/src/components/Accordion/accordion.scss +82 -82
- package/src/components/Alert/Alert.vue +59 -59
- package/src/components/Alert/alert.scss +161 -161
- package/src/components/Avatar/Avatar.vue +53 -53
- package/src/components/Avatar/avatar.scss +52 -52
- package/src/components/Badge/Badge.vue +21 -21
- package/src/components/Badge/badge.scss +206 -206
- package/src/components/Breadcrumbs/BreadcrumbItem.vue +26 -26
- package/src/components/Breadcrumbs/Breadcrumbs.vue +30 -32
- package/src/components/Breadcrumbs/breadcrumbs.scss +31 -31
- package/src/components/Button/Button.vue +85 -85
- package/src/components/Button/button.scss +279 -279
- package/src/components/ButtonGroup/ButtonGroup.vue +28 -28
- package/src/components/ButtonGroup/button-group.scss +51 -51
- package/src/components/Calendar/Calendar.vue +66 -66
- package/src/components/Calendar/calendar.scss +83 -83
- package/src/components/Card/Card.vue +48 -48
- package/src/components/Card/card.scss +53 -53
- package/src/components/Checkbox/Checkbox.vue +54 -54
- package/src/components/Checkbox/checkbox.scss +80 -80
- package/src/components/CopyClipboard/CopyClipboard.vue +91 -91
- package/src/components/CopyClipboard/copy-clipboard.scss +25 -25
- package/src/components/Divider/Divider.vue +44 -44
- package/src/components/Divider/divider.scss +35 -35
- package/src/components/Drawer/Drawer.vue +97 -97
- package/src/components/Drawer/drawer.scss +37 -37
- package/src/components/Dropdown/Dropdown.vue +135 -135
- package/src/components/Dropdown/DropdownItem.vue +33 -33
- package/src/components/Dropdown/DropdownTitle.vue +14 -14
- package/src/components/Dropdown/dropdown-item.scss +84 -84
- package/src/components/Dropdown/dropdown.scss +53 -53
- package/src/components/Flex/Flex.vue +113 -113
- package/src/components/Grid/Grid.vue +80 -80
- package/src/components/Input/Color.vue +26 -26
- package/src/components/Input/Counter.vue +66 -66
- package/src/components/Input/Dropzone.vue +65 -65
- package/src/components/Input/File.vue +15 -15
- package/src/components/Input/Input.vue +123 -123
- package/src/components/Input/Password.vue +35 -35
- package/src/components/Input/Textarea.vue +78 -78
- package/src/components/Input/input.scss +302 -302
- package/src/components/Kbd/Kbd.vue +48 -48
- package/src/components/Kbd/KbdGroup.vue +27 -27
- package/src/components/Kbd/kbd.scss +19 -19
- package/src/components/Modal/Confirm.vue +56 -56
- package/src/components/Modal/Modal.vue +99 -99
- package/src/components/Modal/modal.scss +54 -54
- package/src/components/OTP/OTP.vue +133 -133
- package/src/components/OTP/OTPItem.vue +37 -37
- package/src/components/OTP/otp.scss +84 -84
- package/src/components/Pagination/Pagination.vue +77 -77
- package/src/components/Pagination/pagination.ts +78 -78
- package/src/components/Popout/Popout.vue +52 -52
- package/src/components/Popout/popout.scss +15 -15
- package/src/components/Progress/Progress.vue +103 -103
- package/src/components/Progress/progress.scss +47 -47
- package/src/components/Radio/Radio.vue +38 -38
- package/src/components/Radio/RadioGroup.vue +40 -40
- package/src/components/Radio/radio.scss +78 -78
- package/src/components/Select/Select.vue +211 -211
- package/src/components/Select/select.scss +77 -77
- package/src/components/Sheet/Sheet.vue +98 -98
- package/src/components/Sheet/sheet.scss +69 -69
- package/src/components/Sidebar/Sidebar.vue +115 -115
- package/src/components/Sidebar/sidebar.scss +124 -124
- package/src/components/Skeleton/Skeleton.vue +43 -43
- package/src/components/Skeleton/skeleton.scss +14 -14
- package/src/components/Spinner/Spinner.vue +42 -42
- package/src/components/Spinner/spinner.scss +47 -47
- package/src/components/Switch/Switch.vue +31 -31
- package/src/components/Switch/switch.scss +93 -93
- package/src/components/Table/Cell.vue +23 -23
- package/src/components/Table/Head.vue +59 -59
- package/src/components/Table/Root.vue +66 -66
- package/src/components/Table/SelectAll.vue +23 -23
- package/src/components/Table/SelectRow.vue +30 -30
- package/src/components/Table/index.ts +7 -7
- package/src/components/Table/table.scss +154 -154
- package/src/components/Table/table.ts +248 -248
- package/src/components/Tabs/Tab.vue +25 -25
- package/src/components/Tabs/Tabs.vue +89 -89
- package/src/components/Tabs/tabs.scss +87 -87
- package/src/components/Toast/Toasts.vue +52 -52
- package/src/components/Toast/toast.scss +45 -45
- package/src/components/Toast/toast.ts +75 -75
- package/src/components/Tooltip/Tooltip.vue +86 -86
- package/src/components/Tooltip/tooltip.scss +8 -8
- package/src/examples/ExampleAccordions.vue +58 -58
- package/src/examples/ExampleAlerts.vue +78 -78
- package/src/examples/ExampleAvatars.vue +44 -44
- package/src/examples/ExampleBadges.vue +48 -48
- package/src/examples/ExampleBreadcrumbs.vue +46 -46
- package/src/examples/ExampleButtons.vue +140 -140
- package/src/examples/ExampleCalendars.vue +40 -40
- package/src/examples/ExampleCards.vue +94 -94
- package/src/examples/ExampleCheckboxes.vue +123 -123
- package/src/examples/ExampleCopyClipboard.vue +47 -47
- package/src/examples/ExampleDividers.vue +39 -39
- package/src/examples/ExampleDrawers.vue +67 -67
- package/src/examples/ExampleDropdowns.vue +114 -114
- package/src/examples/ExampleFlexGrid.vue +122 -122
- package/src/examples/ExampleInputs.vue +234 -234
- package/src/examples/ExampleKBD.vue +65 -65
- package/src/examples/ExampleModals.vue +143 -143
- package/src/examples/ExamplePalette.vue +159 -159
- package/src/examples/ExamplePopouts.vue +41 -41
- package/src/examples/ExampleSheets.vue +77 -77
- package/src/examples/ExampleSidebars.vue +270 -270
- package/src/examples/ExampleSkeletons.vue +26 -26
- package/src/examples/ExampleSpinners.vue +78 -78
- package/src/examples/ExampleTables.vue +195 -195
- package/src/examples/ExampleTabs.vue +119 -119
- package/src/examples/ExampleToasts.vue +96 -96
- package/src/examples/ExampleTooltips.vue +70 -70
- package/src/examples/shared/ExampleColor.vue +28 -28
- package/src/index.scss +1 -1
- package/src/index.ts +116 -116
- package/src/internal/Backdrop/Backdrop.vue +22 -22
- package/src/internal/Backdrop/backdrop.scss +34 -34
- package/src/main.ts +5 -5
- package/src/shared/helpers.ts +117 -117
- package/src/shared/theme.ts +22 -22
- package/src/shared/types.ts +29 -29
- package/src/style/animation.scss +22 -22
- package/src/style/core.scss +125 -125
- package/src/style/layout.scss +233 -233
- package/src/style/media-query.scss +29 -29
- package/src/style/reset.scss +135 -135
- package/src/style/text.scss +124 -92
- package/src/style/theme.scss +195 -195
- package/src/style/tooltip.scss +146 -146
- package/src/style/typography.scss +415 -415
- package/src/style/utils.scss +36 -36
|
@@ -1,302 +1,302 @@
|
|
|
1
|
-
.vui-input-container {
|
|
2
|
-
// Each component should have its own specification as it allows more granual
|
|
3
|
-
// modification via CSS variables if needed
|
|
4
|
-
--input-color-text-red: var(--color-text-red);
|
|
5
|
-
--input-color-text: var(--color-text);
|
|
6
|
-
--input-color-text-light: var(--color-text-light);
|
|
7
|
-
--input-color-text-lighter: var(--color-text-lighter);
|
|
8
|
-
--input-color-border: var(--color-border);
|
|
9
|
-
--input-color-border-strong: var(--color-border-strong);
|
|
10
|
-
--input-color-border-weak: var(--color-border-weak);
|
|
11
|
-
|
|
12
|
-
--input-height: var(--interactive-el-height);
|
|
13
|
-
--input-padding: 8px;
|
|
14
|
-
--textarea-padding: 8px;
|
|
15
|
-
|
|
16
|
-
//
|
|
17
|
-
|
|
18
|
-
width: 224px;
|
|
19
|
-
|
|
20
|
-
&.disabled {
|
|
21
|
-
.vui-input label {
|
|
22
|
-
color: var(--input-color-text-lighter);
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
input,
|
|
26
|
-
textarea {
|
|
27
|
-
cursor: not-allowed;
|
|
28
|
-
resize: none !important;
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
&.expand {
|
|
33
|
-
width: 100%;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
&.required .vui-input > label:after {
|
|
37
|
-
content: '*';
|
|
38
|
-
padding-left: 2px;
|
|
39
|
-
color: var(--input-color-text-red);
|
|
40
|
-
font-size: var(--font-size-l);
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
&.readonly .vui-input {
|
|
44
|
-
input,
|
|
45
|
-
textarea,
|
|
46
|
-
.vui-input-style {
|
|
47
|
-
pointer-events: none;
|
|
48
|
-
color: var(--input-color-text-light);
|
|
49
|
-
border-color: var(--input-color-border-weak);
|
|
50
|
-
resize: none !important;
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
&.has-errors {
|
|
55
|
-
.vui-input {
|
|
56
|
-
.vui-input-style,
|
|
57
|
-
textarea {
|
|
58
|
-
outline: 1px solid var(--color-text-red) !important;
|
|
59
|
-
}
|
|
60
|
-
}
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
&.vui-input-color {
|
|
64
|
-
.vui-input-style {
|
|
65
|
-
padding-left: 0 !important;
|
|
66
|
-
outline: none !important;
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
.vui-input {
|
|
71
|
-
label {
|
|
72
|
-
display: block;
|
|
73
|
-
text-align: left;
|
|
74
|
-
margin-bottom: 8px;
|
|
75
|
-
font-size: var(--font-size-m);
|
|
76
|
-
color: var(--input-color-text);
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
svg {
|
|
80
|
-
min-width: 16px;
|
|
81
|
-
min-height: 16px;
|
|
82
|
-
// font-size: var(--font-size-l);
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
.vui-input-hint {
|
|
86
|
-
margin-bottom: 8px;
|
|
87
|
-
margin-top: -4px;
|
|
88
|
-
color: var(--input-color-text-lighter);
|
|
89
|
-
font-size: var(--font-size-s);
|
|
90
|
-
display: block;
|
|
91
|
-
text-align: left;
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
::placeholder {
|
|
95
|
-
font-weight: 400;
|
|
96
|
-
color: var(--color-text-lighter);
|
|
97
|
-
font-family: var(--global-font);
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
.vui-input-style,
|
|
101
|
-
textarea {
|
|
102
|
-
display: block;
|
|
103
|
-
border-radius: var(--border-radius-s);
|
|
104
|
-
border: 1px solid var(--input-color-border);
|
|
105
|
-
background: transparent;
|
|
106
|
-
height: var(--input-height);
|
|
107
|
-
line-height: var(--input-height);
|
|
108
|
-
color: var(--color-text-lighter);
|
|
109
|
-
outline: none;
|
|
110
|
-
font-size: var(--font-size-m);
|
|
111
|
-
width: 100%;
|
|
112
|
-
transition: var(--transition-fast);
|
|
113
|
-
padding-inline: var(--input-padding);
|
|
114
|
-
z-index: 1;
|
|
115
|
-
|
|
116
|
-
&:has(input:focus),
|
|
117
|
-
&:focus {
|
|
118
|
-
// Override error outline
|
|
119
|
-
outline: 2px solid var(--color-text) !important;
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
.vui-button {
|
|
123
|
-
border: 1px solid var(--color-border);
|
|
124
|
-
|
|
125
|
-
&:first-child {
|
|
126
|
-
border-top-right-radius: 0;
|
|
127
|
-
border-bottom-right-radius: 0;
|
|
128
|
-
margin-left: calc(calc(var(--input-padding) + 1px) * -1);
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
&:last-child {
|
|
132
|
-
border-top-left-radius: 0;
|
|
133
|
-
border-bottom-left-radius: 0;
|
|
134
|
-
margin-right: calc(calc(var(--input-padding) + 1px) * -1);
|
|
135
|
-
}
|
|
136
|
-
}
|
|
137
|
-
}
|
|
138
|
-
|
|
139
|
-
input,
|
|
140
|
-
textarea {
|
|
141
|
-
color: var(--color-text);
|
|
142
|
-
font-family: var(--global-font);
|
|
143
|
-
// padding-inline: 3px;
|
|
144
|
-
}
|
|
145
|
-
|
|
146
|
-
input[type='file']::file-selector-button {
|
|
147
|
-
background-color: var(--color-bg);
|
|
148
|
-
color: var(--color-text);
|
|
149
|
-
border: none;
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
input[type='range'] {
|
|
153
|
-
-webkit-appearance: none; /* Override default CSS styles */
|
|
154
|
-
appearance: none;
|
|
155
|
-
height: 4px;
|
|
156
|
-
border-radius: 2px;
|
|
157
|
-
background-color: var(--color-border);
|
|
158
|
-
}
|
|
159
|
-
|
|
160
|
-
input[type='color'] {
|
|
161
|
-
width: 1px;
|
|
162
|
-
height: 1px;
|
|
163
|
-
position: absolute;
|
|
164
|
-
overflow: hidden;
|
|
165
|
-
outline: none !important;
|
|
166
|
-
opacity: 0;
|
|
167
|
-
|
|
168
|
-
&:focus + label .vui-input-color-indicator {
|
|
169
|
-
outline: 2px solid var(--color-text);
|
|
170
|
-
}
|
|
171
|
-
|
|
172
|
-
& + label {
|
|
173
|
-
position: relative;
|
|
174
|
-
margin: 0;
|
|
175
|
-
padding-left: var(--input-height);
|
|
176
|
-
|
|
177
|
-
input {
|
|
178
|
-
padding-inline: var(--space-xs);
|
|
179
|
-
border-radius: var(--border-radius-s);
|
|
180
|
-
|
|
181
|
-
&:focus {
|
|
182
|
-
outline: 2px solid var(--color-text);
|
|
183
|
-
}
|
|
184
|
-
}
|
|
185
|
-
|
|
186
|
-
.vui-input-color-indicator {
|
|
187
|
-
position: absolute;
|
|
188
|
-
inset: 4px;
|
|
189
|
-
right: unset;
|
|
190
|
-
width: calc(var(--input-height) - 8px);
|
|
191
|
-
background-color: var(--color-border);
|
|
192
|
-
border-radius: var(--border-radius-s);
|
|
193
|
-
font-size: var(--font-size-l);
|
|
194
|
-
display: flex;
|
|
195
|
-
align-items: center;
|
|
196
|
-
justify-content: center;
|
|
197
|
-
|
|
198
|
-
&:hover {
|
|
199
|
-
opacity: 0.8;
|
|
200
|
-
}
|
|
201
|
-
}
|
|
202
|
-
}
|
|
203
|
-
}
|
|
204
|
-
|
|
205
|
-
::-moz-range-thumb,
|
|
206
|
-
::-webkit-slider-thumb {
|
|
207
|
-
width: 16px;
|
|
208
|
-
height: 16px;
|
|
209
|
-
background-color: var(--color-text-light);
|
|
210
|
-
border: none;
|
|
211
|
-
}
|
|
212
|
-
|
|
213
|
-
input {
|
|
214
|
-
display: block;
|
|
215
|
-
width: 100%;
|
|
216
|
-
border: none;
|
|
217
|
-
height: calc(var(--input-height) - 1px);
|
|
218
|
-
line-height: calc(var(--input-height) - 1px);
|
|
219
|
-
background: transparent;
|
|
220
|
-
outline: none;
|
|
221
|
-
font-size: var(--font-size-m);
|
|
222
|
-
color: var(--color-text);
|
|
223
|
-
|
|
224
|
-
&:-webkit-autofill {
|
|
225
|
-
box-shadow: 0 0 0px 1000px var(--color-bg) inset;
|
|
226
|
-
-webkit-text-fill-color: var(--color-text);
|
|
227
|
-
}
|
|
228
|
-
}
|
|
229
|
-
|
|
230
|
-
textarea {
|
|
231
|
-
line-height: 1.3em;
|
|
232
|
-
height: auto;
|
|
233
|
-
min-height: 5lh;
|
|
234
|
-
field-sizing: content;
|
|
235
|
-
padding: var(--textarea-padding);
|
|
236
|
-
transition: none;
|
|
237
|
-
}
|
|
238
|
-
}
|
|
239
|
-
|
|
240
|
-
.vui-input-limit {
|
|
241
|
-
display: block;
|
|
242
|
-
margin-top: 6px;
|
|
243
|
-
text-align: left;
|
|
244
|
-
font-size: var(--font-size-xs);
|
|
245
|
-
color: var(--input-color-text-lighter);
|
|
246
|
-
}
|
|
247
|
-
|
|
248
|
-
.vui-input-errors {
|
|
249
|
-
display: flex;
|
|
250
|
-
flex-direction: column;
|
|
251
|
-
gap: 6px;
|
|
252
|
-
padding-top: 6px;
|
|
253
|
-
|
|
254
|
-
li {
|
|
255
|
-
display: block;
|
|
256
|
-
font-size: var(--font-size-s);
|
|
257
|
-
color: var(--color-text-red);
|
|
258
|
-
}
|
|
259
|
-
}
|
|
260
|
-
|
|
261
|
-
&.vui-dropzone {
|
|
262
|
-
&.dragging .vui-input .vui-input-style {
|
|
263
|
-
border-color: var(--color-accent);
|
|
264
|
-
|
|
265
|
-
&:hover {
|
|
266
|
-
border-color: var(--color-border);
|
|
267
|
-
}
|
|
268
|
-
}
|
|
269
|
-
|
|
270
|
-
.vui-input {
|
|
271
|
-
.vui-input-style {
|
|
272
|
-
height: unset;
|
|
273
|
-
border-width: 2px;
|
|
274
|
-
border-style: dashed;
|
|
275
|
-
border-radius: var(--border-radius-m);
|
|
276
|
-
line-height: 1.2em;
|
|
277
|
-
|
|
278
|
-
&:hover {
|
|
279
|
-
border-color: var(--color-accent);
|
|
280
|
-
}
|
|
281
|
-
|
|
282
|
-
input {
|
|
283
|
-
width: 1px;
|
|
284
|
-
height: 1px;
|
|
285
|
-
position: absolute;
|
|
286
|
-
outline: 0 !important;
|
|
287
|
-
opacity: 0 !important;
|
|
288
|
-
|
|
289
|
-
& + label {
|
|
290
|
-
display: flex;
|
|
291
|
-
align-items: center;
|
|
292
|
-
justify-content: center;
|
|
293
|
-
width: 100%;
|
|
294
|
-
min-height: 96px;
|
|
295
|
-
margin: 0;
|
|
296
|
-
color: var(--color-text-light);
|
|
297
|
-
}
|
|
298
|
-
}
|
|
299
|
-
}
|
|
300
|
-
}
|
|
301
|
-
}
|
|
302
|
-
}
|
|
1
|
+
.vui-input-container {
|
|
2
|
+
// Each component should have its own specification as it allows more granual
|
|
3
|
+
// modification via CSS variables if needed
|
|
4
|
+
--input-color-text-red: var(--color-text-red);
|
|
5
|
+
--input-color-text: var(--color-text);
|
|
6
|
+
--input-color-text-light: var(--color-text-light);
|
|
7
|
+
--input-color-text-lighter: var(--color-text-lighter);
|
|
8
|
+
--input-color-border: var(--color-border);
|
|
9
|
+
--input-color-border-strong: var(--color-border-strong);
|
|
10
|
+
--input-color-border-weak: var(--color-border-weak);
|
|
11
|
+
|
|
12
|
+
--input-height: var(--interactive-el-height);
|
|
13
|
+
--input-padding: 8px;
|
|
14
|
+
--textarea-padding: 8px;
|
|
15
|
+
|
|
16
|
+
//
|
|
17
|
+
|
|
18
|
+
width: 224px;
|
|
19
|
+
|
|
20
|
+
&.disabled {
|
|
21
|
+
.vui-input label {
|
|
22
|
+
color: var(--input-color-text-lighter);
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
input,
|
|
26
|
+
textarea {
|
|
27
|
+
cursor: not-allowed;
|
|
28
|
+
resize: none !important;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
&.expand {
|
|
33
|
+
width: 100%;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
&.required .vui-input > label:after {
|
|
37
|
+
content: '*';
|
|
38
|
+
padding-left: 2px;
|
|
39
|
+
color: var(--input-color-text-red);
|
|
40
|
+
font-size: var(--font-size-l);
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
&.readonly .vui-input {
|
|
44
|
+
input,
|
|
45
|
+
textarea,
|
|
46
|
+
.vui-input-style {
|
|
47
|
+
pointer-events: none;
|
|
48
|
+
color: var(--input-color-text-light);
|
|
49
|
+
border-color: var(--input-color-border-weak);
|
|
50
|
+
resize: none !important;
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
&.has-errors {
|
|
55
|
+
.vui-input {
|
|
56
|
+
.vui-input-style,
|
|
57
|
+
textarea {
|
|
58
|
+
outline: 1px solid var(--color-text-red) !important;
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
&.vui-input-color {
|
|
64
|
+
.vui-input-style {
|
|
65
|
+
padding-left: 0 !important;
|
|
66
|
+
outline: none !important;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.vui-input {
|
|
71
|
+
label {
|
|
72
|
+
display: block;
|
|
73
|
+
text-align: left;
|
|
74
|
+
margin-bottom: 8px;
|
|
75
|
+
font-size: var(--font-size-m);
|
|
76
|
+
color: var(--input-color-text);
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
svg {
|
|
80
|
+
min-width: 16px;
|
|
81
|
+
min-height: 16px;
|
|
82
|
+
// font-size: var(--font-size-l);
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.vui-input-hint {
|
|
86
|
+
margin-bottom: 8px;
|
|
87
|
+
margin-top: -4px;
|
|
88
|
+
color: var(--input-color-text-lighter);
|
|
89
|
+
font-size: var(--font-size-s);
|
|
90
|
+
display: block;
|
|
91
|
+
text-align: left;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
::placeholder {
|
|
95
|
+
font-weight: 400;
|
|
96
|
+
color: var(--color-text-lighter);
|
|
97
|
+
font-family: var(--global-font);
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.vui-input-style,
|
|
101
|
+
textarea {
|
|
102
|
+
display: block;
|
|
103
|
+
border-radius: var(--border-radius-s);
|
|
104
|
+
border: 1px solid var(--input-color-border);
|
|
105
|
+
background: transparent;
|
|
106
|
+
height: var(--input-height);
|
|
107
|
+
line-height: var(--input-height);
|
|
108
|
+
color: var(--color-text-lighter);
|
|
109
|
+
outline: none;
|
|
110
|
+
font-size: var(--font-size-m);
|
|
111
|
+
width: 100%;
|
|
112
|
+
transition: var(--transition-fast);
|
|
113
|
+
padding-inline: var(--input-padding);
|
|
114
|
+
z-index: 1;
|
|
115
|
+
|
|
116
|
+
&:has(input:focus),
|
|
117
|
+
&:focus {
|
|
118
|
+
// Override error outline
|
|
119
|
+
outline: 2px solid var(--color-text) !important;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
.vui-button {
|
|
123
|
+
border: 1px solid var(--color-border);
|
|
124
|
+
|
|
125
|
+
&:first-child {
|
|
126
|
+
border-top-right-radius: 0;
|
|
127
|
+
border-bottom-right-radius: 0;
|
|
128
|
+
margin-left: calc(calc(var(--input-padding) + 1px) * -1);
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
&:last-child {
|
|
132
|
+
border-top-left-radius: 0;
|
|
133
|
+
border-bottom-left-radius: 0;
|
|
134
|
+
margin-right: calc(calc(var(--input-padding) + 1px) * -1);
|
|
135
|
+
}
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
input,
|
|
140
|
+
textarea {
|
|
141
|
+
color: var(--color-text);
|
|
142
|
+
font-family: var(--global-font);
|
|
143
|
+
// padding-inline: 3px;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
input[type='file']::file-selector-button {
|
|
147
|
+
background-color: var(--color-bg);
|
|
148
|
+
color: var(--color-text);
|
|
149
|
+
border: none;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
input[type='range'] {
|
|
153
|
+
-webkit-appearance: none; /* Override default CSS styles */
|
|
154
|
+
appearance: none;
|
|
155
|
+
height: 4px;
|
|
156
|
+
border-radius: 2px;
|
|
157
|
+
background-color: var(--color-border);
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
input[type='color'] {
|
|
161
|
+
width: 1px;
|
|
162
|
+
height: 1px;
|
|
163
|
+
position: absolute;
|
|
164
|
+
overflow: hidden;
|
|
165
|
+
outline: none !important;
|
|
166
|
+
opacity: 0;
|
|
167
|
+
|
|
168
|
+
&:focus + label .vui-input-color-indicator {
|
|
169
|
+
outline: 2px solid var(--color-text);
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
& + label {
|
|
173
|
+
position: relative;
|
|
174
|
+
margin: 0;
|
|
175
|
+
padding-left: var(--input-height);
|
|
176
|
+
|
|
177
|
+
input {
|
|
178
|
+
padding-inline: var(--space-xs);
|
|
179
|
+
border-radius: var(--border-radius-s);
|
|
180
|
+
|
|
181
|
+
&:focus {
|
|
182
|
+
outline: 2px solid var(--color-text);
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
.vui-input-color-indicator {
|
|
187
|
+
position: absolute;
|
|
188
|
+
inset: 4px;
|
|
189
|
+
right: unset;
|
|
190
|
+
width: calc(var(--input-height) - 8px);
|
|
191
|
+
background-color: var(--color-border);
|
|
192
|
+
border-radius: var(--border-radius-s);
|
|
193
|
+
font-size: var(--font-size-l);
|
|
194
|
+
display: flex;
|
|
195
|
+
align-items: center;
|
|
196
|
+
justify-content: center;
|
|
197
|
+
|
|
198
|
+
&:hover {
|
|
199
|
+
opacity: 0.8;
|
|
200
|
+
}
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
::-moz-range-thumb,
|
|
206
|
+
::-webkit-slider-thumb {
|
|
207
|
+
width: 16px;
|
|
208
|
+
height: 16px;
|
|
209
|
+
background-color: var(--color-text-light);
|
|
210
|
+
border: none;
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
input {
|
|
214
|
+
display: block;
|
|
215
|
+
width: 100%;
|
|
216
|
+
border: none;
|
|
217
|
+
height: calc(var(--input-height) - 1px);
|
|
218
|
+
line-height: calc(var(--input-height) - 1px);
|
|
219
|
+
background: transparent;
|
|
220
|
+
outline: none;
|
|
221
|
+
font-size: var(--font-size-m);
|
|
222
|
+
color: var(--color-text);
|
|
223
|
+
|
|
224
|
+
&:-webkit-autofill {
|
|
225
|
+
box-shadow: 0 0 0px 1000px var(--color-bg) inset;
|
|
226
|
+
-webkit-text-fill-color: var(--color-text);
|
|
227
|
+
}
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
textarea {
|
|
231
|
+
line-height: 1.3em;
|
|
232
|
+
height: auto;
|
|
233
|
+
min-height: 5lh;
|
|
234
|
+
field-sizing: content;
|
|
235
|
+
padding: var(--textarea-padding);
|
|
236
|
+
transition: none;
|
|
237
|
+
}
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
.vui-input-limit {
|
|
241
|
+
display: block;
|
|
242
|
+
margin-top: 6px;
|
|
243
|
+
text-align: left;
|
|
244
|
+
font-size: var(--font-size-xs);
|
|
245
|
+
color: var(--input-color-text-lighter);
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
.vui-input-errors {
|
|
249
|
+
display: flex;
|
|
250
|
+
flex-direction: column;
|
|
251
|
+
gap: 6px;
|
|
252
|
+
padding-top: 6px;
|
|
253
|
+
|
|
254
|
+
li {
|
|
255
|
+
display: block;
|
|
256
|
+
font-size: var(--font-size-s);
|
|
257
|
+
color: var(--color-text-red);
|
|
258
|
+
}
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
&.vui-dropzone {
|
|
262
|
+
&.dragging .vui-input .vui-input-style {
|
|
263
|
+
border-color: var(--color-accent);
|
|
264
|
+
|
|
265
|
+
&:hover {
|
|
266
|
+
border-color: var(--color-border);
|
|
267
|
+
}
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
.vui-input {
|
|
271
|
+
.vui-input-style {
|
|
272
|
+
height: unset;
|
|
273
|
+
border-width: 2px;
|
|
274
|
+
border-style: dashed;
|
|
275
|
+
border-radius: var(--border-radius-m);
|
|
276
|
+
line-height: 1.2em;
|
|
277
|
+
|
|
278
|
+
&:hover {
|
|
279
|
+
border-color: var(--color-accent);
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
input {
|
|
283
|
+
width: 1px;
|
|
284
|
+
height: 1px;
|
|
285
|
+
position: absolute;
|
|
286
|
+
outline: 0 !important;
|
|
287
|
+
opacity: 0 !important;
|
|
288
|
+
|
|
289
|
+
& + label {
|
|
290
|
+
display: flex;
|
|
291
|
+
align-items: center;
|
|
292
|
+
justify-content: center;
|
|
293
|
+
width: 100%;
|
|
294
|
+
min-height: 96px;
|
|
295
|
+
margin: 0;
|
|
296
|
+
color: var(--color-text-light);
|
|
297
|
+
}
|
|
298
|
+
}
|
|
299
|
+
}
|
|
300
|
+
}
|
|
301
|
+
}
|
|
302
|
+
}
|