@oslokommune/punkt-css 17.0.8 → 17.1.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 +36 -0
- package/dist/css/components/combobox.css +16 -21
- package/dist/css/components/combobox.min.css +1 -1
- package/dist/css/components/datepicker.css +31 -5
- package/dist/css/components/datepicker.min.css +1 -1
- package/dist/css/components/fileupload.css +24 -158
- package/dist/css/components/fileupload.min.css +1 -1
- package/dist/css/components/inputwrapper.css +8 -1
- package/dist/css/components/inputwrapper.min.css +1 -1
- package/dist/css/components/textarea.css +2 -10
- package/dist/css/components/textarea.min.css +1 -1
- package/dist/css/components/timepicker.css +54 -132
- package/dist/css/components/timepicker.min.css +1 -1
- package/dist/css/elements/button.css +0 -6
- package/dist/css/elements/button.min.css +1 -1
- package/dist/css/elements/checkbox-radio.css +5 -4
- package/dist/css/elements/checkbox-radio.min.css +1 -1
- package/dist/css/elements/input.css +38 -10
- package/dist/css/elements/input.min.css +1 -1
- package/dist/css/pkt-base.css +106 -107
- package/dist/css/pkt-base.min.css +1 -1
- package/dist/css/pkt-components.css +135 -327
- package/dist/css/pkt-components.min.css +1 -1
- package/dist/css/pkt-docs.css +285 -454
- package/dist/css/pkt-docs.min.css +1 -1
- package/dist/css/pkt-elements.css +44 -20
- package/dist/css/pkt-elements.min.css +1 -1
- package/dist/css/pkt.css +285 -454
- package/dist/css/pkt.layer.css +269 -443
- package/dist/css/pkt.layer.min.css +1 -1
- package/dist/css/pkt.min.css +1 -1
- package/dist/scss/abstracts/variables/_index.scss +1 -1
- package/dist/scss/base/_defaults.scss +5 -0
- package/dist/scss/base/_index.scss +1 -0
- package/dist/scss/base/_link.scss +136 -0
- package/dist/scss/base/_typography.scss +0 -139
- package/dist/scss/components/_combobox.scss +45 -43
- package/dist/scss/components/_datepicker.scss +30 -5
- package/dist/scss/components/_fileupload.scss +9 -3
- package/dist/scss/components/_inputwrapper.scss +8 -2
- package/dist/scss/components/_textarea.scss +2 -13
- package/dist/scss/components/_timepicker.scss +3 -3
- package/dist/scss/elements/_button.scss +0 -6
- package/dist/scss/elements/_checkbox-radio.scss +2 -1
- package/dist/scss/elements/_input.scss +40 -18
- package/package.json +2 -2
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Link
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
@use '../abstracts/variables';
|
|
6
|
+
|
|
7
|
+
a,
|
|
8
|
+
.pkt-link-button {
|
|
9
|
+
// Order of pseudoclasses is important for specificity:
|
|
10
|
+
// link, visited, hover, focus, active
|
|
11
|
+
// but we don't use visited, so we can skip :link
|
|
12
|
+
|
|
13
|
+
color: var(--pkt-color-text-action-normal);
|
|
14
|
+
text-decoration: underline;
|
|
15
|
+
word-wrap: break-word;
|
|
16
|
+
cursor: pointer;
|
|
17
|
+
|
|
18
|
+
span {
|
|
19
|
+
color: inherit;
|
|
20
|
+
text-decoration: inherit;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
// visited
|
|
24
|
+
&:visited:not(.pkt-linkcard, .pkt-btn, .pkt-tabs__link):not(:hover) {
|
|
25
|
+
color: inherit;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
// hover
|
|
29
|
+
&:hover,
|
|
30
|
+
&.pkt-link--hover {
|
|
31
|
+
color: var(--pkt-color-text-action-active);
|
|
32
|
+
text-decoration: underline;
|
|
33
|
+
svg {
|
|
34
|
+
--fg-color: currentColor;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
// focus
|
|
39
|
+
&:focus-visible,
|
|
40
|
+
&.pkt-link--focus {
|
|
41
|
+
box-shadow:
|
|
42
|
+
0px 0px 0px 0.125rem var(--pkt-color-text-action-active),
|
|
43
|
+
0px 0px 0px 0.375rem var(--pkt-color-border-states-focus);
|
|
44
|
+
outline: none;
|
|
45
|
+
color: var(--pkt-color-text-action-active);
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
&:focus:not(:focus-visible) {
|
|
49
|
+
box-shadow: none;
|
|
50
|
+
outline: 0.125rem solid var(--pkt-color-text-action-active);
|
|
51
|
+
color: var(--pkt-color-text-action-active);
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
// active
|
|
55
|
+
&:active,
|
|
56
|
+
&.pkt-link--active {
|
|
57
|
+
color: var(--pkt-color-text-action-active);
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.pkt-link {
|
|
62
|
+
display: inline;
|
|
63
|
+
text-align: left;
|
|
64
|
+
align-items: baseline;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
.pkt-link {
|
|
68
|
+
&__icon {
|
|
69
|
+
--fg-color: currentColor;
|
|
70
|
+
width: 1.5rem;
|
|
71
|
+
height: 1.5rem;
|
|
72
|
+
flex-shrink: 0;
|
|
73
|
+
margin-inline: 0.25rem;
|
|
74
|
+
align-self: center;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
&--icon-left,
|
|
78
|
+
&--icon-right {
|
|
79
|
+
display: inline-flex;
|
|
80
|
+
text-decoration: none;
|
|
81
|
+
align-items: baseline;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
&--icon-left {
|
|
85
|
+
flex-direction: row;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
&--icon-right {
|
|
89
|
+
flex-direction: row-reverse;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
&--external::after {
|
|
93
|
+
display: inline-block;
|
|
94
|
+
content: ' ';
|
|
95
|
+
--svg: url(#{variables.$icon-path}/new-window-small.svg);
|
|
96
|
+
background-image: var(--svg);
|
|
97
|
+
background-repeat: no-repeat;
|
|
98
|
+
background-size: 18px 18px;
|
|
99
|
+
width: 1.125rem;
|
|
100
|
+
height: 1.125rem;
|
|
101
|
+
vertical-align: middle;
|
|
102
|
+
align-self: center;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
&--external:hover::after {
|
|
106
|
+
// #1f42aa
|
|
107
|
+
filter: brightness(0) saturate(100%) invert(16%) sepia(99%) saturate(2420%) hue-rotate(222deg) brightness(93%)
|
|
108
|
+
contrast(90%);
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
button.pkt-link {
|
|
113
|
+
background: none;
|
|
114
|
+
border: none;
|
|
115
|
+
padding: 0;
|
|
116
|
+
font-family: inherit;
|
|
117
|
+
cursor: pointer;
|
|
118
|
+
font-weight: inherit;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
@at-root [data-mode='dark'] {
|
|
122
|
+
.pkt-link {
|
|
123
|
+
&--external::after {
|
|
124
|
+
// white
|
|
125
|
+
filter: brightness(0) saturate(100%) invert(100%);
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
&--external:hover::after,
|
|
129
|
+
&:hover:not(.pkt-btn) pkt-icon,
|
|
130
|
+
&:hover:not(.pkt-btn) .pkt-icon {
|
|
131
|
+
// #b3f5ff
|
|
132
|
+
filter: brightness(0) saturate(100%) invert(80%) sepia(54%) saturate(502%) hue-rotate(173deg) brightness(109%)
|
|
133
|
+
contrast(105%);
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
}
|
|
@@ -36,137 +36,6 @@ strong {
|
|
|
36
36
|
font-weight: map.get(variables.$font-weight, 'medium');
|
|
37
37
|
}
|
|
38
38
|
|
|
39
|
-
a,
|
|
40
|
-
.pkt-link-button {
|
|
41
|
-
// Order of pseudoclasses is important for specificity:
|
|
42
|
-
// link, visited, hover, focus, active
|
|
43
|
-
// but we don't use visited, so we can skip :link
|
|
44
|
-
|
|
45
|
-
color: var(--pkt-color-text-action-normal);
|
|
46
|
-
text-decoration: underline;
|
|
47
|
-
word-wrap: break-word;
|
|
48
|
-
cursor: pointer;
|
|
49
|
-
|
|
50
|
-
span {
|
|
51
|
-
color: inherit;
|
|
52
|
-
text-decoration: inherit;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
// visited
|
|
56
|
-
&:visited:not(.pkt-linkcard, .pkt-btn, .pkt-tabs__link):not(:hover) {
|
|
57
|
-
color: inherit;
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
// hover
|
|
61
|
-
&:hover,
|
|
62
|
-
&.pkt-link--hover {
|
|
63
|
-
color: var(--pkt-color-text-action-active);
|
|
64
|
-
text-decoration: underline;
|
|
65
|
-
svg {
|
|
66
|
-
--fg-color: currentColor;
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
// focus
|
|
71
|
-
&:focus-visible,
|
|
72
|
-
&.pkt-link--focus {
|
|
73
|
-
box-shadow:
|
|
74
|
-
0px 0px 0px 0.125rem var(--pkt-color-text-action-active),
|
|
75
|
-
0px 0px 0px 0.375rem var(--pkt-color-border-states-focus);
|
|
76
|
-
outline: none;
|
|
77
|
-
color: var(--pkt-color-text-action-active);
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
&:focus:not(:focus-visible) {
|
|
81
|
-
box-shadow: none;
|
|
82
|
-
outline: 0.125rem solid var(--pkt-color-text-action-active);
|
|
83
|
-
color: var(--pkt-color-text-action-active);
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
// active
|
|
87
|
-
&:active,
|
|
88
|
-
&.pkt-link--active {
|
|
89
|
-
color: var(--pkt-color-text-action-active);
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
.pkt-link {
|
|
94
|
-
display: inline;
|
|
95
|
-
text-align: left;
|
|
96
|
-
align-items: baseline;
|
|
97
|
-
}
|
|
98
|
-
|
|
99
|
-
.pkt-link {
|
|
100
|
-
&__icon {
|
|
101
|
-
--fg-color: currentColor;
|
|
102
|
-
width: 1.5rem;
|
|
103
|
-
height: 1.5rem;
|
|
104
|
-
flex-shrink: 0;
|
|
105
|
-
margin-inline: 0.25rem;
|
|
106
|
-
align-self: center;
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
&--icon-left,
|
|
110
|
-
&--icon-right {
|
|
111
|
-
display: inline-flex;
|
|
112
|
-
text-decoration: none;
|
|
113
|
-
align-items: baseline;
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
&--icon-left {
|
|
117
|
-
flex-direction: row;
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
&--icon-right {
|
|
121
|
-
flex-direction: row-reverse;
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
&--external::after {
|
|
125
|
-
display: inline-block;
|
|
126
|
-
content: ' ';
|
|
127
|
-
--svg: url(#{variables.$icon-path}/new-window-small.svg);
|
|
128
|
-
background-image: var(--svg);
|
|
129
|
-
background-repeat: no-repeat;
|
|
130
|
-
background-size: 18px 18px;
|
|
131
|
-
width: 1.125rem;
|
|
132
|
-
height: 1.125rem;
|
|
133
|
-
vertical-align: middle;
|
|
134
|
-
align-self: center;
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
&--external:hover::after {
|
|
138
|
-
// #1f42aa
|
|
139
|
-
filter: brightness(0) saturate(100%) invert(16%) sepia(99%) saturate(2420%) hue-rotate(222deg) brightness(93%)
|
|
140
|
-
contrast(90%);
|
|
141
|
-
}
|
|
142
|
-
}
|
|
143
|
-
|
|
144
|
-
button.pkt-link {
|
|
145
|
-
background: none;
|
|
146
|
-
border: none;
|
|
147
|
-
padding: 0;
|
|
148
|
-
font-family: inherit;
|
|
149
|
-
cursor: pointer;
|
|
150
|
-
font-weight: inherit;
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
@at-root [data-mode='dark'] {
|
|
154
|
-
.pkt-link {
|
|
155
|
-
&--external::after {
|
|
156
|
-
// white
|
|
157
|
-
filter: brightness(0) saturate(100%) invert(100%);
|
|
158
|
-
}
|
|
159
|
-
|
|
160
|
-
&--external:hover::after,
|
|
161
|
-
&:hover:not(.pkt-btn) pkt-icon,
|
|
162
|
-
&:hover:not(.pkt-btn) .pkt-icon {
|
|
163
|
-
// #b3f5ff
|
|
164
|
-
filter: brightness(0) saturate(100%) invert(80%) sepia(54%) saturate(502%) hue-rotate(173deg) brightness(109%)
|
|
165
|
-
contrast(105%);
|
|
166
|
-
}
|
|
167
|
-
}
|
|
168
|
-
}
|
|
169
|
-
|
|
170
39
|
/*
|
|
171
40
|
* origo typography
|
|
172
41
|
* prefix pkt
|
|
@@ -213,11 +82,3 @@ button.pkt-link {
|
|
|
213
82
|
.pkt-truncate-text {
|
|
214
83
|
@include typography.truncate-text();
|
|
215
84
|
}
|
|
216
|
-
|
|
217
|
-
/*
|
|
218
|
-
* Display contents and disregard layout
|
|
219
|
-
*/
|
|
220
|
-
.pkt-display-contents,
|
|
221
|
-
.pkt-contents {
|
|
222
|
-
display: contents;
|
|
223
|
-
}
|
|
@@ -8,12 +8,15 @@
|
|
|
8
8
|
$-box-separator: map.get(variables.$spacing, 'size-8');
|
|
9
9
|
$-input-spacing: map.get(variables.$spacing, 'size-4');
|
|
10
10
|
|
|
11
|
-
pkt-combobox
|
|
11
|
+
pkt-combobox {
|
|
12
|
+
display: block;
|
|
13
|
+
}
|
|
14
|
+
|
|
12
15
|
.pkt-combobox-component {
|
|
13
16
|
display: block;
|
|
14
17
|
max-width: 31rem;
|
|
15
18
|
width: 100%;
|
|
16
|
-
|
|
19
|
+
|
|
17
20
|
&--fullwidth {
|
|
18
21
|
max-width: 100%;
|
|
19
22
|
}
|
|
@@ -228,56 +231,55 @@ pkt-combobox,
|
|
|
228
231
|
.pkt-listbox__open {
|
|
229
232
|
margin-block-start: $-box-separator;
|
|
230
233
|
}
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
outline: 4px solid var(--pkt-color-border-states-focus);
|
|
235
|
-
}
|
|
234
|
+
&.pkt-inputwrapper:not([data-navtype='pointer']) .pkt-combobox__input:focus-within {
|
|
235
|
+
outline: 4px solid var(--pkt-color-border-states-focus);
|
|
236
|
+
}
|
|
236
237
|
|
|
237
|
-
// Dropdown scale follows input wrapper size (small / xsmall combobox fields)
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
238
|
+
// Dropdown scale follows input wrapper size (small / xsmall combobox fields)
|
|
239
|
+
&.pkt-inputwrapper--small,
|
|
240
|
+
&.pkt-inputwrapper--xsmall {
|
|
241
|
+
.pkt-listbox {
|
|
242
|
+
.pkt-listbox__option:not(.pkt-listbox__search) {
|
|
243
|
+
padding: map.get(variables.$spacing, 'size-8') map.get(variables.$spacing, 'size-16');
|
|
244
|
+
@include typography.get-text('pkt-txt-16-light');
|
|
245
|
+
}
|
|
245
246
|
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
247
|
+
.pkt-listbox__empty,
|
|
248
|
+
.pkt-listbox__banner {
|
|
249
|
+
padding: map.get(variables.$spacing, 'size-8') map.get(variables.$spacing, 'size-16');
|
|
250
|
+
@include typography.get-text('pkt-txt-16-light');
|
|
251
|
+
}
|
|
251
252
|
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
253
|
+
.pkt-listbox__search input {
|
|
254
|
+
padding: map.get(variables.$spacing, 'size-8') map.get(variables.$spacing, 'size-12');
|
|
255
|
+
@include typography.get-text('pkt-txt-16-light');
|
|
256
|
+
}
|
|
255
257
|
}
|
|
256
258
|
}
|
|
257
|
-
}
|
|
258
259
|
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
260
|
+
&.pkt-inputwrapper--xsmall {
|
|
261
|
+
.pkt-listbox {
|
|
262
|
+
.pkt-listbox__option:not(.pkt-listbox__search) {
|
|
263
|
+
padding: map.get(variables.$spacing, 'size-6') map.get(variables.$spacing, 'size-12');
|
|
264
|
+
@include typography.get-text('pkt-txt-14-light');
|
|
265
|
+
}
|
|
265
266
|
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
267
|
+
.pkt-listbox__empty,
|
|
268
|
+
.pkt-listbox__banner {
|
|
269
|
+
padding: map.get(variables.$spacing, 'size-6') map.get(variables.$spacing, 'size-12');
|
|
270
|
+
@include typography.get-text('pkt-txt-14-light');
|
|
271
|
+
}
|
|
271
272
|
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
273
|
+
.pkt-listbox__banner-icon,
|
|
274
|
+
.pkt-listbox__search-icon .pkt-icon {
|
|
275
|
+
width: 1.125rem;
|
|
276
|
+
height: 1.125rem;
|
|
277
|
+
}
|
|
277
278
|
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
279
|
+
.pkt-listbox__search input {
|
|
280
|
+
padding: map.get(variables.$spacing, 'size-6') map.get(variables.$spacing, 'size-8');
|
|
281
|
+
@include typography.get-text('pkt-txt-14-light');
|
|
282
|
+
}
|
|
281
283
|
}
|
|
282
284
|
}
|
|
283
285
|
}
|
|
@@ -6,6 +6,10 @@ pkt-datepicker {
|
|
|
6
6
|
position: relative;
|
|
7
7
|
}
|
|
8
8
|
|
|
9
|
+
.pkt-datepicker--fullwidth {
|
|
10
|
+
width: 100%;
|
|
11
|
+
}
|
|
12
|
+
|
|
9
13
|
.pkt-datepicker__tags {
|
|
10
14
|
button.pkt-tag {
|
|
11
15
|
margin: 0 0.25rem 0.5rem 0;
|
|
@@ -21,12 +25,13 @@ pkt-datepicker-multiple {
|
|
|
21
25
|
display: block;
|
|
22
26
|
}
|
|
23
27
|
|
|
28
|
+
.pkt-datepicker__inputs .pkt-input__container:not(:has(.pkt-input--fullwidth)):not(:has(.pkt-datepicker--multiple)) {
|
|
29
|
+
width: fit-content;
|
|
30
|
+
}
|
|
31
|
+
|
|
24
32
|
.pkt-datepicker__inputs {
|
|
25
33
|
width: 100%;
|
|
26
34
|
position: relative;
|
|
27
|
-
.pkt-input__container:not(:has(.pkt-input--fullwidth)) {
|
|
28
|
-
width: fit-content;
|
|
29
|
-
}
|
|
30
35
|
.pkt-input__container {
|
|
31
36
|
border: 2px solid var(--pkt-color-input-border-normal);
|
|
32
37
|
background-color: var(--pkt-color-input-background-normal);
|
|
@@ -89,6 +94,8 @@ pkt-datepicker-multiple {
|
|
|
89
94
|
.pkt-datepicker__input {
|
|
90
95
|
padding-inline-end: 0;
|
|
91
96
|
background-image: none;
|
|
97
|
+
}
|
|
98
|
+
.pkt-datepicker__input:not(.pkt-datepicker--multiple) {
|
|
92
99
|
width: 8.3rem;
|
|
93
100
|
}
|
|
94
101
|
.pkt-input-separator ~ .pkt-datepicker--range {
|
|
@@ -110,9 +117,18 @@ pkt-datepicker-multiple {
|
|
|
110
117
|
width: 8.3rem;
|
|
111
118
|
max-width: calc(100% - 3rem);
|
|
112
119
|
}
|
|
113
|
-
.pkt-datepicker__input.pkt-input--fullwidth:not(.pkt-datepicker--multiple) {
|
|
120
|
+
.pkt-datepicker__input.pkt-input--fullwidth:not(.pkt-datepicker--multiple):not(.pkt-datepicker--range) {
|
|
114
121
|
flex: 1;
|
|
115
122
|
}
|
|
123
|
+
|
|
124
|
+
.pkt-datepicker__input.pkt-input--fullwidth.pkt-datepicker--range {
|
|
125
|
+
flex: 0 0 auto;
|
|
126
|
+
width: 8.3rem;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
.pkt-input__container:has(.pkt-datepicker--range.pkt-input--fullwidth) button.pkt-input-icon {
|
|
130
|
+
margin-inline-start: auto;
|
|
131
|
+
}
|
|
116
132
|
.pkt-datepicker__input::-webkit-inner-spin-button,
|
|
117
133
|
.pkt-datepicker__input::-webkit-calendar-picker-indicator {
|
|
118
134
|
display: none;
|
|
@@ -167,6 +183,10 @@ pkt-datepicker-multiple {
|
|
|
167
183
|
width: $input-width;
|
|
168
184
|
}
|
|
169
185
|
|
|
186
|
+
.pkt-datepicker__input.pkt-input--fullwidth.pkt-datepicker--range {
|
|
187
|
+
width: $input-width;
|
|
188
|
+
}
|
|
189
|
+
|
|
170
190
|
.pkt-datepicker__input:not(.pkt-datepicker--multiple):not(.pkt-datepicker--range) {
|
|
171
191
|
max-width: calc(100% - $button-width);
|
|
172
192
|
}
|
|
@@ -191,10 +211,15 @@ pkt-datepicker-multiple {
|
|
|
191
211
|
width: auto;
|
|
192
212
|
max-width: 100%;
|
|
193
213
|
}
|
|
194
|
-
.pkt-datepicker__input.pkt-input--fullwidth:not(.pkt-datepicker--multiple) {
|
|
214
|
+
.pkt-datepicker__input.pkt-input--fullwidth:not(.pkt-datepicker--multiple):not(.pkt-datepicker--range) {
|
|
195
215
|
width: auto;
|
|
196
216
|
flex: 1;
|
|
197
217
|
}
|
|
218
|
+
|
|
219
|
+
.pkt-datepicker__input.pkt-input--fullwidth.pkt-datepicker--range {
|
|
220
|
+
width: auto;
|
|
221
|
+
flex: 0 0 auto;
|
|
222
|
+
}
|
|
198
223
|
.pkt-input__container:has(.pkt-datepicker__input[type='date']) button.pkt-input-icon {
|
|
199
224
|
display: none;
|
|
200
225
|
}
|
|
@@ -6,7 +6,14 @@
|
|
|
6
6
|
|
|
7
7
|
$-module-name: 'pkt-fileupload';
|
|
8
8
|
|
|
9
|
-
pkt-fileupload
|
|
9
|
+
pkt-fileupload {
|
|
10
|
+
display: block;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
.pkt-fileupload-component {
|
|
14
|
+
display: block;
|
|
15
|
+
}
|
|
16
|
+
|
|
10
17
|
.pkt-fileupload {
|
|
11
18
|
display: block;
|
|
12
19
|
width: min(100%, 31rem);
|
|
@@ -29,8 +36,7 @@ pkt-fileupload,
|
|
|
29
36
|
// COMPONENT MODIFIERS
|
|
30
37
|
// ============================================
|
|
31
38
|
|
|
32
|
-
&--full-width
|
|
33
|
-
&[fullwidth] {
|
|
39
|
+
&--full-width {
|
|
34
40
|
width: 100%;
|
|
35
41
|
|
|
36
42
|
.pkt-fileupload__drop-zone,
|
|
@@ -6,6 +6,10 @@
|
|
|
6
6
|
|
|
7
7
|
pkt-input-wrapper {
|
|
8
8
|
display: block;
|
|
9
|
+
|
|
10
|
+
&[inline] {
|
|
11
|
+
display: inline-block;
|
|
12
|
+
}
|
|
9
13
|
}
|
|
10
14
|
@supports selector(:not(:has(*))) {
|
|
11
15
|
// Skjul helptext-container hvis den ikke har innhold.
|
|
@@ -23,6 +27,8 @@ pkt-input-wrapper {
|
|
|
23
27
|
}
|
|
24
28
|
}
|
|
25
29
|
.pkt-inputwrapper {
|
|
30
|
+
display: block;
|
|
31
|
+
|
|
26
32
|
&__label {
|
|
27
33
|
display: flex;
|
|
28
34
|
flex-direction: row;
|
|
@@ -135,8 +141,9 @@ pkt-input-wrapper {
|
|
|
135
141
|
|
|
136
142
|
&--inline {
|
|
137
143
|
display: inline-block;
|
|
144
|
+
width: fit-content;
|
|
138
145
|
vertical-align: middle;
|
|
139
|
-
margin-
|
|
146
|
+
margin-inline-end: 8px;
|
|
140
147
|
}
|
|
141
148
|
|
|
142
149
|
.pkt-alert {
|
|
@@ -144,7 +151,6 @@ pkt-input-wrapper {
|
|
|
144
151
|
margin: 0 0 0.5rem 0;
|
|
145
152
|
}
|
|
146
153
|
|
|
147
|
-
// Alert — stretch to match field width (fieldset uses align-items: flex-start)
|
|
148
154
|
&__alert-wrapper {
|
|
149
155
|
align-self: stretch;
|
|
150
156
|
max-width: min(100%, 31rem);
|
|
@@ -9,22 +9,11 @@
|
|
|
9
9
|
@use '../abstracts/variables';
|
|
10
10
|
@use '../abstracts/mixins/typography';
|
|
11
11
|
|
|
12
|
-
|
|
13
|
-
// React: .pkt-inputwrapper is the outer box. Elements: pkt-textarea is the flex child and
|
|
14
|
-
// shrink-wraps unless capped here — inner .pkt-inputwrapper width: 100% then resolves correctly.
|
|
15
|
-
pkt-textarea:not([fullwidth]):has(textarea.pkt-input:not([cols])) {
|
|
12
|
+
:where(.pkt-textarea:has(textarea.pkt-input:not(.pkt-input--fullwidth):not([cols]))) {
|
|
16
13
|
width: min(31rem, 100%);
|
|
17
14
|
}
|
|
18
15
|
|
|
19
|
-
pkt-textarea
|
|
20
|
-
width: 100%;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
.pkt-inputwrapper:has(textarea.pkt-input:not(.pkt-input--fullwidth):not([cols])) {
|
|
24
|
-
width: min(31rem, 100%);
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
.pkt-inputwrapper:has(textarea.pkt-input--fullwidth) {
|
|
16
|
+
.pkt-textarea:has(textarea.pkt-input--fullwidth) {
|
|
28
17
|
width: 100%;
|
|
29
18
|
}
|
|
30
19
|
|
|
@@ -6,7 +6,6 @@ pkt-timepicker {
|
|
|
6
6
|
display: block;
|
|
7
7
|
}
|
|
8
8
|
|
|
9
|
-
/// Size overrides for small / xsmall. Base .pkt-input__container styles use medium (48px).
|
|
10
9
|
@mixin timepicker-field-size($min-height, $text-style, $icon-size, $padding-inline: 0.5rem) {
|
|
11
10
|
.pkt-input__container {
|
|
12
11
|
min-height: $min-height;
|
|
@@ -34,8 +33,7 @@ pkt-timepicker {
|
|
|
34
33
|
}
|
|
35
34
|
}
|
|
36
35
|
|
|
37
|
-
.pkt-timepicker
|
|
38
|
-
pkt-timepicker {
|
|
36
|
+
.pkt-timepicker {
|
|
39
37
|
&__anchor {
|
|
40
38
|
position: relative;
|
|
41
39
|
}
|
|
@@ -155,6 +153,8 @@ pkt-timepicker {
|
|
|
155
153
|
}
|
|
156
154
|
|
|
157
155
|
&--fullwidth {
|
|
156
|
+
width: 100%;
|
|
157
|
+
|
|
158
158
|
.pkt-timepicker__anchor,
|
|
159
159
|
.pkt-input__container {
|
|
160
160
|
width: 100%;
|
|
@@ -343,12 +343,6 @@ $-skins: (
|
|
|
343
343
|
@include -skin($key, map.get($value, 'light'));
|
|
344
344
|
}
|
|
345
345
|
|
|
346
|
-
pkt-button[disabled],
|
|
347
|
-
pkt-button[data-disabled],
|
|
348
|
-
pkt-button[isLoading] {
|
|
349
|
-
pointer-events: none;
|
|
350
|
-
}
|
|
351
|
-
|
|
352
346
|
// Selve knappe-klassen
|
|
353
347
|
.pkt-btn {
|
|
354
348
|
border-radius: 0;
|
|
@@ -55,11 +55,13 @@ $-module-name: 'pkt-input-check';
|
|
|
55
55
|
}
|
|
56
56
|
|
|
57
57
|
&[type='checkbox'][role='switch'] {
|
|
58
|
+
transition: all 0.15s ease-in-out;
|
|
58
59
|
position: relative;
|
|
59
60
|
height: calc(1.5rem + 2px);
|
|
60
61
|
width: 2.5rem;
|
|
61
62
|
border-radius: calc(0.75rem + 2px);
|
|
62
63
|
&:after {
|
|
64
|
+
transition: all 0.15s ease-in-out;
|
|
63
65
|
display: block;
|
|
64
66
|
content: '';
|
|
65
67
|
border: 2px solid var(--pkt-color-input-check-border);
|
|
@@ -92,7 +94,6 @@ $-module-name: 'pkt-input-check';
|
|
|
92
94
|
|
|
93
95
|
&[type='checkbox']:active:not(:disabled) {
|
|
94
96
|
--pkt-color-input-check-border: var(--pkt-color-input-border-active);
|
|
95
|
-
outline: 6px solid var(--pkt-color-input-border-active);
|
|
96
97
|
}
|
|
97
98
|
|
|
98
99
|
&[type='checkbox']:focus-visible {
|