@navikt/ds-css 7.5.3 → 7.7.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.
- package/CHANGELOG.md +20 -0
- package/darkside/action-menu.darkside.css +1 -6
- package/darkside/alert.darkside.css +2 -2
- package/darkside/button.darkside.css +134 -149
- package/darkside/chat.darkside.css +2 -2
- package/darkside/date.darkside.css +171 -232
- package/darkside/expansioncard.darkside.css +3 -9
- package/darkside/form/combobox.darkside.css +12 -20
- package/darkside/form/error-summary.darkside.css +2 -2
- package/darkside/form/file-upload.darkside.css +12 -13
- package/darkside/form/form-progress.darkside.css +1 -1
- package/darkside/form/form-summary.darkside.css +3 -2
- package/darkside/form/index.css +14 -16
- package/darkside/form/search.darkside.css +82 -160
- package/darkside/form/select.darkside.css +74 -68
- package/darkside/form/switch.darkside.css +125 -132
- package/darkside/form/text-field.darkside.css +2 -2
- package/darkside/form/textarea.darkside.css +36 -78
- package/darkside/help-text.darkside.css +0 -6
- package/darkside/index.css +23 -14
- package/darkside/internalheader.darkside.css +45 -49
- package/darkside/modal.darkside.css +7 -10
- package/darkside/popover.darkside.css +2 -5
- package/darkside/primitives/base.darkside.css +350 -350
- package/darkside/primitives/bleed.darkside.css +52 -52
- package/darkside/primitives/box.darkside.css +21 -21
- package/darkside/primitives/hgrid.darkside.css +28 -28
- package/darkside/primitives/index.css +7 -36
- package/darkside/primitives/page.darkside.css +6 -9
- package/darkside/primitives/stack.darkside.css +58 -58
- package/darkside/read-more.darkside.css +68 -57
- package/darkside/skeleton.darkside.css +21 -24
- package/darkside/stepper.darkside.css +181 -221
- package/darkside/tabs.darkside.css +67 -74
- package/darkside/toggle-group.darkside.css +52 -120
- package/dist/component/form.css +22 -18
- package/dist/component/form.min.css +2 -2
- package/dist/component/index.css +40 -22
- package/dist/component/index.min.css +3 -3
- package/dist/component/modal.css +8 -0
- package/dist/component/modal.min.css +1 -1
- package/dist/component/readmore.css +4 -0
- package/dist/component/readmore.min.css +1 -1
- package/dist/components.css +40 -22
- package/dist/components.min.css +3 -3
- package/dist/global/tokens.css +1 -1
- package/dist/global/tokens.min.css +1 -1
- package/dist/index.css +40 -22
- package/dist/index.min.css +3 -3
- package/form/combobox.css +9 -2
- package/form/file-upload.css +7 -9
- package/form/select.css +2 -9
- package/form/switch.css +8 -0
- package/modal.css +8 -0
- package/package.json +2 -2
- package/read-more.css +4 -0
|
@@ -4,16 +4,11 @@
|
|
|
4
4
|
width: fit-content;
|
|
5
5
|
}
|
|
6
6
|
|
|
7
|
-
.navds-switch--right {
|
|
8
|
-
width: auto;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
7
|
.navds-switch--small {
|
|
12
|
-
position: relative;
|
|
13
8
|
min-height: 2rem;
|
|
14
9
|
}
|
|
15
10
|
|
|
16
|
-
/* Input */
|
|
11
|
+
/* ------------------------------ Switch Input ------------------------------ */
|
|
17
12
|
.navds-switch__input {
|
|
18
13
|
cursor: pointer;
|
|
19
14
|
position: absolute;
|
|
@@ -22,17 +17,17 @@
|
|
|
22
17
|
height: 3rem;
|
|
23
18
|
opacity: 0;
|
|
24
19
|
top: 0;
|
|
25
|
-
}
|
|
26
20
|
|
|
27
|
-
.navds-switch--small >
|
|
28
|
-
|
|
29
|
-
|
|
21
|
+
.navds-switch--small > & {
|
|
22
|
+
height: 2rem;
|
|
23
|
+
top: 0;
|
|
24
|
+
}
|
|
30
25
|
}
|
|
31
26
|
|
|
32
|
-
/*
|
|
27
|
+
/* -------------------------- Switch content/label -------------------------- */
|
|
33
28
|
.navds-switch__label-wrapper {
|
|
34
29
|
cursor: pointer;
|
|
35
|
-
color: var(--
|
|
30
|
+
color: var(--ax-text-default);
|
|
36
31
|
}
|
|
37
32
|
|
|
38
33
|
.navds-switch__content {
|
|
@@ -40,134 +35,135 @@
|
|
|
40
35
|
flex-direction: column;
|
|
41
36
|
gap: 0.125rem;
|
|
42
37
|
padding: 0.75rem 0 0.75rem 3.25rem;
|
|
43
|
-
}
|
|
44
38
|
|
|
45
|
-
.navds-switch--right
|
|
46
|
-
|
|
47
|
-
}
|
|
39
|
+
.navds-switch--right & {
|
|
40
|
+
padding: 0.75rem 3.25rem 0.75rem 0;
|
|
41
|
+
}
|
|
48
42
|
|
|
49
|
-
.navds-switch--small
|
|
50
|
-
|
|
51
|
-
}
|
|
43
|
+
.navds-switch--small & {
|
|
44
|
+
padding: calc(var(--ax-spacing-2) - var(--ax-spacing-05)) 0 calc(var(--ax-spacing-2) - var(--ax-spacing-05)) 3.25rem;
|
|
45
|
+
}
|
|
52
46
|
|
|
53
|
-
.navds-switch--right.navds-switch--small
|
|
54
|
-
|
|
47
|
+
.navds-switch--right.navds-switch--small & {
|
|
48
|
+
padding: calc(var(--ax-spacing-2) - var(--ax-spacing-05)) 3.25rem calc(var(--ax-spacing-2) - var(--ax-spacing-05)) 0;
|
|
49
|
+
}
|
|
55
50
|
}
|
|
56
51
|
|
|
57
|
-
.navds-switch--with-description
|
|
58
|
-
.navds-switch--small > .navds-switch__label-wrapper > .navds-switch--with-description {
|
|
52
|
+
.navds-switch--with-description {
|
|
59
53
|
padding-bottom: 0;
|
|
60
54
|
}
|
|
61
55
|
|
|
62
56
|
.navds-switch__input:hover ~ .navds-switch__label-wrapper,
|
|
63
57
|
.navds-switch__label-wrapper:hover {
|
|
64
|
-
color: var(--
|
|
58
|
+
color: var(--ax-text-accent-strong);
|
|
65
59
|
}
|
|
66
60
|
|
|
67
61
|
.navds-switch__input:disabled:hover ~ .navds-switch__label-wrapper {
|
|
68
62
|
color: inherit;
|
|
69
63
|
}
|
|
70
64
|
|
|
71
|
-
/* Track */
|
|
65
|
+
/* ------------------------------ Switch Track ------------------------------ */
|
|
72
66
|
.navds-switch__track {
|
|
73
67
|
width: 2.75rem;
|
|
74
68
|
height: 1.5rem;
|
|
75
|
-
background-color: var(--
|
|
69
|
+
background-color: var(--ax-bg-input);
|
|
76
70
|
position: absolute;
|
|
77
|
-
top: var(--
|
|
71
|
+
top: var(--ax-spacing-3);
|
|
78
72
|
left: 0;
|
|
79
|
-
border-radius: var(--
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
.navds-switch--right > .navds-switch__track {
|
|
89
|
-
right: 0;
|
|
90
|
-
left: auto;
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
.navds-switch__input:checked ~ .navds-switch__track {
|
|
94
|
-
background-color: var(--ac-switch-checked-bg, var(--a-surface-action-selected));
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
.navds-switch__input:hover ~ .navds-switch__track {
|
|
98
|
-
background-color: var(--ac-switch-hover-bg, var(--a-surface-neutral-hover));
|
|
99
|
-
}
|
|
73
|
+
border-radius: var(--ax-border-radius-full);
|
|
74
|
+
border: 2px solid var(--ax-border-default);
|
|
75
|
+
transition-property: background-color, border-color;
|
|
76
|
+
transition-duration: 100ms;
|
|
77
|
+
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
|
78
|
+
|
|
79
|
+
.navds-switch--small > & {
|
|
80
|
+
top: var(--ax-spacing-1);
|
|
81
|
+
}
|
|
100
82
|
|
|
101
|
-
.navds-switch__input:
|
|
102
|
-
|
|
103
|
-
|
|
83
|
+
.navds-switch__input:checked ~ & {
|
|
84
|
+
background-color: var(--ax-bg-accent-strong-pressed);
|
|
85
|
+
border-color: var(--ax-bg-accent-strong-pressed);
|
|
86
|
+
}
|
|
104
87
|
|
|
105
|
-
.navds-switch__input:
|
|
106
|
-
|
|
107
|
-
|
|
88
|
+
.navds-switch__input:hover:checked ~ & {
|
|
89
|
+
background-color: var(--ax-bg-accent-strong-hover);
|
|
90
|
+
border-color: var(--ax-bg-accent-strong-hover);
|
|
91
|
+
}
|
|
108
92
|
|
|
109
|
-
.navds-switch__input:
|
|
110
|
-
|
|
111
|
-
|
|
93
|
+
.navds-switch__input:disabled ~ & {
|
|
94
|
+
background-color: var(--ax-bg-input);
|
|
95
|
+
border-color: var(--ax-border-default);
|
|
96
|
+
}
|
|
112
97
|
|
|
113
|
-
.navds-switch__input:
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
0 0 0 1px var(--a-surface-default),
|
|
118
|
-
var(--a-shadow-focus);
|
|
119
|
-
}
|
|
98
|
+
.navds-switch__input:checked:disabled ~ & {
|
|
99
|
+
background-color: var(--ax-bg-accent-strong-pressed);
|
|
100
|
+
border-color: var(--ax-bg-accent-strong-pressed);
|
|
101
|
+
}
|
|
120
102
|
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
outline: 2px
|
|
124
|
-
box-shadow:
|
|
125
|
-
0 0 0 1px var(--a-surface-default),
|
|
126
|
-
var(--a-shadow-focus);
|
|
103
|
+
.navds-switch__input:focus-visible ~ & {
|
|
104
|
+
outline: 2px solid var(--ax-border-focus);
|
|
105
|
+
outline-offset: 2px;
|
|
127
106
|
}
|
|
128
107
|
}
|
|
129
108
|
|
|
130
|
-
/* Thumb */
|
|
109
|
+
/* ------------------------------ Switch Thumb ------------------------------ */
|
|
131
110
|
.navds-switch__thumb {
|
|
132
|
-
background-color: var(--
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
height: 1.25rem;
|
|
111
|
+
background-color: var(--ax-bg-neutral-strong);
|
|
112
|
+
border-radius: var(--ax-border-radius-full);
|
|
113
|
+
width: 1.125rem;
|
|
114
|
+
height: 1.125rem;
|
|
137
115
|
position: absolute;
|
|
138
116
|
transform: translateX(0);
|
|
139
|
-
|
|
140
|
-
top: var(--a-spacing-05);
|
|
141
|
-
transition: transform 250ms cubic-bezier(0.4, 0, 0.2, 1);
|
|
117
|
+
transition: transform 150ms cubic-bezier(0.4, 0, 0.2, 1);
|
|
142
118
|
display: flex;
|
|
143
119
|
align-items: center;
|
|
144
120
|
justify-content: center;
|
|
121
|
+
left: 0.0625rem;
|
|
122
|
+
top: 0.0625rem;
|
|
123
|
+
|
|
124
|
+
.navds-switch__input:checked ~ .navds-switch__track > & {
|
|
125
|
+
background-color: var(--ax-bg-raised);
|
|
126
|
+
transform: translateX(1.25rem);
|
|
127
|
+
color: var(--ax-text-accent-strong);
|
|
128
|
+
width: 1.25rem;
|
|
129
|
+
height: 1.25rem;
|
|
130
|
+
left: 0;
|
|
131
|
+
top: 0;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
.navds-switch__input:checked ~ .navds-switch__track > & > .navds-switch__checkmark {
|
|
135
|
+
visibility: visible;
|
|
136
|
+
opacity: 1;
|
|
137
|
+
}
|
|
145
138
|
}
|
|
146
139
|
|
|
147
|
-
.navds-
|
|
148
|
-
|
|
149
|
-
|
|
140
|
+
.navds-switch__checkmark {
|
|
141
|
+
visibility: hidden;
|
|
142
|
+
opacity: 0;
|
|
143
|
+
transition: opacity 150ms cubic-bezier(0.4, 0, 0.2, 1);
|
|
150
144
|
}
|
|
151
145
|
|
|
152
146
|
@media (hover: hover) and (pointer: fine) {
|
|
153
|
-
.navds-switch__input:hover ~ .navds-switch__track > .navds-switch__thumb {
|
|
154
|
-
transform: translateX(0.
|
|
147
|
+
.navds-switch__input:hover:not(:disabled) ~ .navds-switch__track > .navds-switch__thumb {
|
|
148
|
+
transform: translateX(0.0625rem);
|
|
155
149
|
}
|
|
156
150
|
|
|
157
|
-
.navds-switch__input:checked:hover ~ .navds-switch__track > .navds-switch__thumb {
|
|
158
|
-
transform: translateX(1.
|
|
151
|
+
.navds-switch__input:checked:hover:not(:disabled) ~ .navds-switch__track > .navds-switch__thumb {
|
|
152
|
+
transform: translateX(1.19rem);
|
|
159
153
|
}
|
|
160
154
|
}
|
|
161
155
|
|
|
162
|
-
.navds-
|
|
163
|
-
|
|
164
|
-
}
|
|
156
|
+
.navds-switch--right {
|
|
157
|
+
width: auto;
|
|
165
158
|
|
|
166
|
-
.navds-switch__input
|
|
167
|
-
|
|
159
|
+
& .navds-switch__input,
|
|
160
|
+
& .navds-switch__track {
|
|
161
|
+
right: 0;
|
|
162
|
+
left: auto;
|
|
163
|
+
}
|
|
168
164
|
}
|
|
169
165
|
|
|
170
|
-
/* Disabled */
|
|
166
|
+
/* -------------------------- Switch Disabled-state ------------------------- */
|
|
171
167
|
.navds-switch__input:disabled {
|
|
172
168
|
appearance: none;
|
|
173
169
|
}
|
|
@@ -181,47 +177,51 @@
|
|
|
181
177
|
cursor: not-allowed;
|
|
182
178
|
}
|
|
183
179
|
|
|
184
|
-
/* Readonly */
|
|
185
|
-
.navds-switch--readonly
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
.navds-switch--readonly > .navds-switch__input {
|
|
194
|
-
cursor: default;
|
|
195
|
-
}
|
|
180
|
+
/* -------------------------- Switch Readonly state ------------------------- */
|
|
181
|
+
.navds-switch--readonly {
|
|
182
|
+
& > .navds-switch__track,
|
|
183
|
+
& > .navds-switch__input:hover ~ .navds-switch__track,
|
|
184
|
+
& > .navds-switch__input:checked ~ .navds-switch__track,
|
|
185
|
+
& > .navds-switch__input:checked:hover ~ .navds-switch__track {
|
|
186
|
+
background-color: var(--ax-bg-neutral-moderate);
|
|
187
|
+
border-color: var(--ax-border-neutral-subtleA);
|
|
188
|
+
}
|
|
196
189
|
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
}
|
|
190
|
+
& > .navds-switch__label-wrapper,
|
|
191
|
+
& > .navds-switch__input {
|
|
192
|
+
cursor: default;
|
|
193
|
+
}
|
|
201
194
|
|
|
202
|
-
.navds-
|
|
203
|
-
|
|
204
|
-
|
|
195
|
+
& > .navds-switch__input:hover ~ .navds-switch__label-wrapper,
|
|
196
|
+
& .navds-switch__label-wrapper:hover {
|
|
197
|
+
color: var(--ax-text-default);
|
|
198
|
+
}
|
|
205
199
|
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
}
|
|
200
|
+
& .navds-switch__label {
|
|
201
|
+
display: inline-flex;
|
|
202
|
+
}
|
|
210
203
|
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
}
|
|
204
|
+
& .navds-switch__thumb {
|
|
205
|
+
background-color: var(--ax-bg-neutral-strong);
|
|
206
|
+
}
|
|
214
207
|
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
208
|
+
& > .navds-switch__input:checked ~ .navds-switch__track > .navds-switch__thumb {
|
|
209
|
+
background-color: var(--ax-bg-neutral-strong);
|
|
210
|
+
color: var(--ax-text-neutral-contrast);
|
|
218
211
|
}
|
|
219
212
|
|
|
220
|
-
|
|
221
|
-
|
|
213
|
+
@media (hover: hover) and (pointer: fine) {
|
|
214
|
+
& > .navds-switch__input:hover ~ .navds-switch__track > .navds-switch__thumb {
|
|
215
|
+
transform: translateX(0);
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
& > .navds-switch__input:checked:hover ~ .navds-switch__track > .navds-switch__thumb {
|
|
219
|
+
transform: translateX(1.25rem);
|
|
220
|
+
}
|
|
222
221
|
}
|
|
223
222
|
}
|
|
224
223
|
|
|
224
|
+
/* ------------------------ Switch Forced colors mode ----------------------- */
|
|
225
225
|
@media (forced-colors: active) {
|
|
226
226
|
.navds-switch__input:hover ~ .navds-switch__label-wrapper,
|
|
227
227
|
.navds-switch__label-wrapper:hover {
|
|
@@ -230,7 +230,7 @@
|
|
|
230
230
|
|
|
231
231
|
.navds-switch__thumb,
|
|
232
232
|
.navds-switch--readonly .navds-switch__thumb {
|
|
233
|
-
background-color: fieldtext;
|
|
233
|
+
background-color: fieldtext !important;
|
|
234
234
|
}
|
|
235
235
|
|
|
236
236
|
.navds-switch__input:checked ~ .navds-switch__track > .navds-switch__thumb,
|
|
@@ -238,13 +238,6 @@
|
|
|
238
238
|
color: field;
|
|
239
239
|
}
|
|
240
240
|
|
|
241
|
-
.navds-switch__track {
|
|
242
|
-
width: calc(2.75rem + 4px);
|
|
243
|
-
height: calc(1.5rem + 4px);
|
|
244
|
-
top: var(--a-spacing-3);
|
|
245
|
-
border: 2px solid fieldtext;
|
|
246
|
-
}
|
|
247
|
-
|
|
248
241
|
.navds-switch__input:focus-visible ~ .navds-switch__track {
|
|
249
242
|
outline: 2px solid highlight;
|
|
250
243
|
outline-offset: 2px;
|
|
@@ -259,7 +252,7 @@
|
|
|
259
252
|
}
|
|
260
253
|
|
|
261
254
|
.navds-switch--disabled:not(.navds-switch--loading) .navds-switch__track {
|
|
262
|
-
border-color: graytext;
|
|
255
|
+
border-color: graytext !important;
|
|
263
256
|
}
|
|
264
257
|
|
|
265
258
|
.navds-switch--disabled:not(.navds-switch--loading) .navds-switch__label-wrapper,
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
}
|
|
26
26
|
|
|
27
27
|
&::placeholder {
|
|
28
|
-
color: var(--ax-text-
|
|
28
|
+
color: var(--ax-text-neutral);
|
|
29
29
|
}
|
|
30
30
|
|
|
31
31
|
&[size] {
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
min-height: 2rem;
|
|
39
39
|
}
|
|
40
40
|
|
|
41
|
-
.navds-text-field--error
|
|
41
|
+
.navds-text-field--error .navds-text-field__input:not(:disabled) {
|
|
42
42
|
border-color: var(--ax-border-danger);
|
|
43
43
|
box-shadow: 0 0 0 1px var(--ax-border-danger);
|
|
44
44
|
}
|
|
@@ -1,73 +1,54 @@
|
|
|
1
|
-
[data-theme="dark"] {
|
|
2
|
-
--__ac-textarea-text: var(--a-text-on-inverted);
|
|
3
|
-
--__ac-textarea-bg: var(--a-transparent);
|
|
4
|
-
--__ac-textarea-border: var(--a-border-on-inverted);
|
|
5
|
-
--__ac-textarea-hover-border: var(--a-blue-200);
|
|
6
|
-
--__ac-textarea-placeholder: var(--a-gray-500);
|
|
7
|
-
--__ac-textarea-error-border: var(--a-red-300);
|
|
8
|
-
--__ac-textarea-counter-text: var(--a-gray-300);
|
|
9
|
-
--__ac-textarea-counter-error-text: var(--a-red-300);
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
[data-theme="light"] {
|
|
13
|
-
--__ac-textarea-text: initial;
|
|
14
|
-
--__ac-textarea-bg: initial;
|
|
15
|
-
--__ac-textarea-border: initial;
|
|
16
|
-
--__ac-textarea-hover-border: initial;
|
|
17
|
-
--__ac-textarea-placeholder: initial;
|
|
18
|
-
--__ac-textarea-error-border: initial;
|
|
19
|
-
--__ac-textarea-counter-text: initial;
|
|
20
|
-
--__ac-textarea-counter-error-text: initial;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
1
|
.navds-textarea__input {
|
|
24
2
|
/* stylelint-disable-next-line csstools/value-no-unknown-custom-properties */
|
|
25
|
-
height: var(--
|
|
3
|
+
height: var(--__axc-textarea-height);
|
|
26
4
|
appearance: none;
|
|
27
|
-
padding: var(--
|
|
28
|
-
background-color: var(--
|
|
29
|
-
border-radius: var(--
|
|
30
|
-
border: 1px solid var(--
|
|
5
|
+
padding: var(--ax-spacing-2);
|
|
6
|
+
background-color: var(--ax-bg-input);
|
|
7
|
+
border-radius: var(--ax-border-radius-medium);
|
|
8
|
+
border: 1px solid var(--ax-border-default);
|
|
31
9
|
resize: none;
|
|
32
10
|
width: 100%;
|
|
33
11
|
display: block;
|
|
34
|
-
color: var(--
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
.navds-textarea__input::placeholder {
|
|
38
|
-
color: var(--ac-textarea-placeholder, var(--__ac-textarea-placeholder, var(--a-text-subtle)));
|
|
39
|
-
}
|
|
12
|
+
color: var(--ax-text-default);
|
|
40
13
|
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
}
|
|
14
|
+
&::placeholder {
|
|
15
|
+
color: var(--ax-text-subtle);
|
|
16
|
+
}
|
|
44
17
|
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
box-shadow: var(--a-shadow-focus);
|
|
49
|
-
border-color: var(--ac-textarea-active-border, var(--a-border-action-selected));
|
|
50
|
-
}
|
|
18
|
+
&:hover {
|
|
19
|
+
border-color: var(--ax-border-accent-strong);
|
|
20
|
+
}
|
|
51
21
|
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
outline: 2px solid transparent;
|
|
22
|
+
&:focus-visible {
|
|
23
|
+
outline: 2px solid var(--ax-border-focus);
|
|
55
24
|
outline-offset: 2px;
|
|
56
|
-
|
|
25
|
+
border-color: var(--ax-border-accent-strong);
|
|
57
26
|
}
|
|
58
|
-
}
|
|
59
27
|
|
|
60
|
-
|
|
61
|
-
|
|
28
|
+
&:disabled {
|
|
29
|
+
background-color: var(--ax-bg-input);
|
|
30
|
+
border-color: var(--ax-border-default);
|
|
31
|
+
cursor: not-allowed;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.navds-form-field--small & {
|
|
35
|
+
padding: var(--ax-spacing-1-alt);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.navds-textarea--readonly & {
|
|
39
|
+
background-color: var(--ax-bg-neutral-moderate);
|
|
40
|
+
border-color: var(--ax-border-neutral-subtleA);
|
|
41
|
+
cursor: default;
|
|
42
|
+
}
|
|
62
43
|
}
|
|
63
44
|
|
|
64
45
|
.navds-textarea__counter {
|
|
65
|
-
margin-top: -0.
|
|
66
|
-
color: var(--
|
|
46
|
+
margin-top: -0.25rem;
|
|
47
|
+
color: var(--ax-text-subtle);
|
|
67
48
|
}
|
|
68
49
|
|
|
69
50
|
.navds-textarea__counter--error {
|
|
70
|
-
color: var(--
|
|
51
|
+
color: var(--ax-text-danger);
|
|
71
52
|
}
|
|
72
53
|
|
|
73
54
|
.navds-textarea__sr-counter {
|
|
@@ -108,32 +89,9 @@
|
|
|
108
89
|
scrollbar-gutter: stable; /* Needed to prevent scrollbar from appearing too early */
|
|
109
90
|
}
|
|
110
91
|
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
.navds-textarea--error .navds-textarea__input:not(:hover, :focus-visible, :disabled) {
|
|
115
|
-
box-shadow: 0 0 0 1px var(--ac-textarea-error-border, var(--__ac-textarea-error-border, var(--a-border-danger)));
|
|
116
|
-
border-color: var(--ac-textarea-error-border, var(--__ac-textarea-error-border, var(--a-border-danger)));
|
|
117
|
-
}
|
|
118
|
-
|
|
119
|
-
@supports not selector(:focus-visible) {
|
|
120
|
-
.navds-textarea--error .navds-textarea__input:not(:hover, :focus, :disabled) {
|
|
121
|
-
box-shadow: 0 0 0 1px var(--ac-textarea-error-border, var(--__ac-textarea-error-border, var(--a-border-danger)));
|
|
122
|
-
border-color: var(--ac-textarea-error-border, var(--__ac-textarea-error-border, var(--a-border-danger)));
|
|
123
|
-
}
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
.navds-textarea__input:disabled {
|
|
127
|
-
background-color: var(--ac-textarea-bg, var(--__ac-textarea-bg, var(--a-surface-default)));
|
|
128
|
-
border-color: var(--ac-textarea-border, var(--__ac-textarea-border, var(--a-border-default)));
|
|
129
|
-
box-shadow: none;
|
|
130
|
-
cursor: not-allowed;
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
.navds-textarea--readonly .navds-textarea__input {
|
|
134
|
-
background-color: var(--a-surface-subtle);
|
|
135
|
-
border-color: var(--a-border-subtle);
|
|
136
|
-
cursor: default;
|
|
92
|
+
.navds-textarea--error .navds-textarea__input:not(:disabled) {
|
|
93
|
+
box-shadow: 0 0 0 1px var(--ax-border-danger);
|
|
94
|
+
border-color: var(--ax-border-danger);
|
|
137
95
|
}
|
|
138
96
|
|
|
139
97
|
@media (forced-colors: active) {
|
|
@@ -21,12 +21,6 @@
|
|
|
21
21
|
max-width: min(65ch, calc(100vw - var(--ax-spacing-6)));
|
|
22
22
|
border-radius: var(--ax-border-radius-large);
|
|
23
23
|
border: 1px solid var(--ax-border-info);
|
|
24
|
-
box-shadow:
|
|
25
|
-
0 0 1px 0 rgba(7 9 13/ 0.15),
|
|
26
|
-
0 1px 3px 0 rgba(7 9 13/ 0.1),
|
|
27
|
-
0 5px 12px 0 rgba(7 9 13/ 0.13),
|
|
28
|
-
0 0.5px 0 0 rgba(255 255 255/ 0) inset,
|
|
29
|
-
0 0 1px 0 rgba(255 255 255/ 0) inset;
|
|
30
24
|
}
|
|
31
25
|
|
|
32
26
|
.navds-help-text__icon--filled {
|
package/darkside/index.css
CHANGED
|
@@ -1,30 +1,34 @@
|
|
|
1
1
|
@charset "UTF-8";
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
/* CSS is ordered by specificity, so that browsers without layers fall backs to good defaults */
|
|
4
|
+
@layer aksel.reset, aksel.typography, aksel.theme, aksel.components, aksel.layout, aksel.utilities;
|
|
4
5
|
|
|
5
|
-
/* CSS foundations */
|
|
6
|
+
/* ----------------------------- CSS foundations ---------------------------- */
|
|
6
7
|
@import "./baseline/reset.darkside.css" layer(aksel.reset);
|
|
7
8
|
@import "./baseline/print.darkside.css" layer(aksel.reset);
|
|
8
9
|
@import "./baseline/fonts.darkside.css" layer(aksel.typography);
|
|
9
|
-
@import "./baseline/theme.darkside.css" layer(aksel.theme);
|
|
10
10
|
@import "./typography.darkside.css" layer(aksel.typography);
|
|
11
|
-
@import "./baseline/utilities.darkside.css" layer(aksel.utilities);
|
|
12
11
|
|
|
13
|
-
/*
|
|
14
|
-
@import "./form/index.css";
|
|
15
|
-
@import "./primitives/index.css";
|
|
16
|
-
|
|
17
|
-
/* Theming */
|
|
12
|
+
/* --------------------------------- Theming -------------------------------- */
|
|
18
13
|
@import "@navikt/ds-tokens/dist/darkside/tokens.css" layer(aksel.theme);
|
|
14
|
+
@import "./baseline/theme.darkside.css" layer(aksel.theme);
|
|
19
15
|
|
|
20
|
-
/* Components */
|
|
21
|
-
@import "../primitives/stack.css" layer(aksel.components);
|
|
22
|
-
@import "./accordion.darkside.css" layer(aksel.components);
|
|
16
|
+
/* ------------------------------- Components ------------------------------- */
|
|
23
17
|
@import "./button.darkside.css" layer(aksel.components);
|
|
18
|
+
@import "./chips.darkside.css" layer(aksel.components);
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* `./form/index.css` edits the following components:
|
|
22
|
+
* - Button
|
|
23
|
+
* - Chips
|
|
24
|
+
* To avoid specificity conflicts, we import those components before form.
|
|
25
|
+
*/
|
|
26
|
+
@import "./form/index.css" layer(aksel.components);
|
|
27
|
+
@import "./accordion.darkside.css" layer(aksel.components);
|
|
24
28
|
@import "./alert.darkside.css" layer(aksel.components);
|
|
25
29
|
@import "./chat.darkside.css" layer(aksel.components);
|
|
26
|
-
@import "./chips.darkside.css" layer(aksel.components);
|
|
27
30
|
@import "./copybutton.darkside.css" layer(aksel.components);
|
|
31
|
+
@import "./date.darkside.css" layer(aksel.components);
|
|
28
32
|
@import "./dropdown.darkside.css" layer(aksel.components);
|
|
29
33
|
@import "./action-menu.darkside.css" layer(aksel.components);
|
|
30
34
|
@import "./expansioncard.darkside.css" layer(aksel.components);
|
|
@@ -36,7 +40,6 @@
|
|
|
36
40
|
@import "./modal.darkside.css" layer(aksel.components);
|
|
37
41
|
@import "./pagination.darkside.css" layer(aksel.components);
|
|
38
42
|
@import "./popover.darkside.css" layer(aksel.components);
|
|
39
|
-
@import "./date.darkside.css" layer(aksel.components);
|
|
40
43
|
@import "./tag.darkside.css" layer(aksel.components);
|
|
41
44
|
@import "./timeline.darkside.css" layer(aksel.components);
|
|
42
45
|
@import "./tooltip.darkside.css" layer(aksel.components);
|
|
@@ -50,3 +53,9 @@
|
|
|
50
53
|
@import "./table.darkside.css" layer(aksel.components);
|
|
51
54
|
@import "./tabs.darkside.css" layer(aksel.components);
|
|
52
55
|
@import "./list.darkside.css" layer(aksel.components);
|
|
56
|
+
|
|
57
|
+
/* --------------------------------- Layout --------------------------------- */
|
|
58
|
+
@import "./primitives/index.css" layer(aksel.layout);
|
|
59
|
+
|
|
60
|
+
/* --------------------------------- Utility -------------------------------- */
|
|
61
|
+
@import "./baseline/utilities.darkside.css" layer(aksel.utilities);
|