@oslokommune/punkt-css 11.14.1 → 11.15.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 +129 -0
- package/dist/css/components/stepper.css +158 -0
- package/dist/css/components/stepper.min.css +1 -0
- package/dist/css/components/textinput.css +1 -1
- package/dist/css/components/textinput.min.css +1 -1
- package/dist/css/pkt-base.css +1 -1
- package/dist/css/pkt-base.min.css +1 -1
- package/dist/css/pkt-components.css +811 -652
- package/dist/css/pkt-components.min.css +1 -1
- package/dist/css/pkt-elements.css +3 -3
- package/dist/css/pkt-elements.min.css +1 -1
- package/dist/css/pkt.css +684 -524
- package/dist/css/pkt.min.css +1 -1
- package/dist/scss/abstracts/variables/_index.scss +1 -1
- package/dist/scss/components/_index.scss +7 -6
- package/dist/scss/components/_stepper.scss +212 -0
- package/package.json +3 -3
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
@forward 'accordion';
|
|
2
2
|
@forward 'alert';
|
|
3
|
-
@forward 'tag';
|
|
4
3
|
@forward 'backlink';
|
|
5
4
|
@forward 'badge';
|
|
6
5
|
@forward 'breadcrumbs';
|
|
@@ -9,12 +8,14 @@
|
|
|
9
8
|
@forward 'header';
|
|
10
9
|
@forward 'icon';
|
|
11
10
|
@forward 'inputwrapper';
|
|
12
|
-
@forward 'tabs';
|
|
13
|
-
@forward 'teaserlist';
|
|
14
|
-
@forward 'messagebox';
|
|
15
11
|
@forward 'linkcard';
|
|
16
12
|
@forward 'loader';
|
|
13
|
+
@forward 'messagebox';
|
|
14
|
+
@forward 'progressbar';
|
|
15
|
+
@forward 'searchinput';
|
|
16
|
+
@forward 'stepper';
|
|
17
|
+
@forward 'tabs';
|
|
18
|
+
@forward 'tag';
|
|
17
19
|
@forward 'tag';
|
|
20
|
+
@forward 'teaserlist';
|
|
18
21
|
@forward 'textinput';
|
|
19
|
-
@forward 'searchinput';
|
|
20
|
-
@forward 'progressbar';
|
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Stepper component
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
@use 'sass:map';
|
|
6
|
+
@use '../abstracts/variables';
|
|
7
|
+
@use '../abstracts/mixins/breakpoints' as *;
|
|
8
|
+
@use '../abstracts/' as *;
|
|
9
|
+
|
|
10
|
+
// GENERELL STEPPER OG STEP
|
|
11
|
+
.pkt-stepper {
|
|
12
|
+
--pkt-steps-indicator-width: 24px;
|
|
13
|
+
--pkt-steps-indicator-height: 24px;
|
|
14
|
+
--pkt-steps-indicator-color: var(--pkt-color-brand-dark-blue-1000);
|
|
15
|
+
--pkt-steps-border-width: 2.5px;
|
|
16
|
+
--pkt-steps-line-length: 1.5rem;
|
|
17
|
+
|
|
18
|
+
color: var(--pkt-color-brand-dark-blue-1000);
|
|
19
|
+
font-size: map.get(variables.$font-size, 'size-18');
|
|
20
|
+
font-weight: map.get(variables.$font-weight, 'medium');
|
|
21
|
+
letter-spacing: map.get(variables.$letter-spacing, 'tight');
|
|
22
|
+
list-style: none;
|
|
23
|
+
margin: 0;
|
|
24
|
+
padding: 0;
|
|
25
|
+
|
|
26
|
+
.pkt-step {
|
|
27
|
+
display: grid;
|
|
28
|
+
|
|
29
|
+
&__wrapper {
|
|
30
|
+
grid-column: title / content;
|
|
31
|
+
grid-row: title / content;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
&__title {
|
|
35
|
+
font-weight: map.get(variables.$font-weight, 'medium');
|
|
36
|
+
width: max-content;
|
|
37
|
+
width: 100%;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
&__content {
|
|
41
|
+
font-weight: map.get(variables.$font-weight, 'light');
|
|
42
|
+
padding-bottom: map.get(variables.$spacing, 'size-24');
|
|
43
|
+
width: 100%;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
&__indicator {
|
|
47
|
+
z-index: 2;
|
|
48
|
+
grid-area: indicator;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
&__line {
|
|
52
|
+
background-color: var(--pkt-color-brand-dark-blue-1000);
|
|
53
|
+
|
|
54
|
+
&--1 {
|
|
55
|
+
grid-area: indicator;
|
|
56
|
+
}
|
|
57
|
+
&--2 {
|
|
58
|
+
grid-area: indicator;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
&--3 {
|
|
62
|
+
grid-area: line;
|
|
63
|
+
height: fit-content;
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
// VERTICAL STEPPER (default)
|
|
70
|
+
.pkt-stepper--vertical {
|
|
71
|
+
display: grid;
|
|
72
|
+
grid-template-columns: 1fr;
|
|
73
|
+
|
|
74
|
+
.pkt-step {
|
|
75
|
+
grid-template-areas: 'indicator title' 'line content';
|
|
76
|
+
grid-template-columns: var(--pkt-steps-indicator-width) auto;
|
|
77
|
+
grid-template-rows: var(--pkt-steps-indicator-height) minmax(min-content, max-content);
|
|
78
|
+
grid-gap: 0 1rem;
|
|
79
|
+
justify-items: flex-start;
|
|
80
|
+
|
|
81
|
+
&--current {
|
|
82
|
+
.pkt-step__title,
|
|
83
|
+
.pkt-step__content {
|
|
84
|
+
padding: map-get(variables.$spacing, 'size-16') map-get(variables.$spacing, 'size-24');
|
|
85
|
+
background-color: var(--pkt-color-surface-subtle-pale-blue);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.pkt-step__wrapper {
|
|
89
|
+
margin-bottom: map-get(variables.$spacing, 'size-24');
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
&__indicator {
|
|
94
|
+
& > svg {
|
|
95
|
+
vertical-align: baseline;
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
&__line {
|
|
100
|
+
min-height: min-content;
|
|
101
|
+
height: 100%;
|
|
102
|
+
margin: auto;
|
|
103
|
+
width: var(--pkt-steps-border-width);
|
|
104
|
+
|
|
105
|
+
&--1 {
|
|
106
|
+
height: 50%;
|
|
107
|
+
transform: translateY(-55%);
|
|
108
|
+
}
|
|
109
|
+
&--2 {
|
|
110
|
+
height: 50%;
|
|
111
|
+
transform: translateY(55%);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
&--3 {
|
|
115
|
+
min-height: map.get(variables.$spacing, 'size-64');
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
// HORIZONTAL STEPPER
|
|
122
|
+
.pkt-stepper--horizontal {
|
|
123
|
+
display: flex;
|
|
124
|
+
|
|
125
|
+
.pkt-step {
|
|
126
|
+
grid-template-areas: 'indicator line' 'title title' 'content content';
|
|
127
|
+
grid-template-columns: var(--pkt-steps-indicator-width) auto;
|
|
128
|
+
grid-template-rows: var(--pkt-steps-indicator-width) min-content min-content;
|
|
129
|
+
justify-items: flex-start;
|
|
130
|
+
|
|
131
|
+
&__wrapper {
|
|
132
|
+
min-width: fit-content;
|
|
133
|
+
}
|
|
134
|
+
&__title {
|
|
135
|
+
padding: map-get(variables.$spacing, 'size-24') map-get(variables.$spacing, 'size-16')
|
|
136
|
+
map-get(variables.$spacing, 'size-24') 0;
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
&__content {
|
|
140
|
+
padding: 0 map-get(variables.$spacing, 'size-16') map-get(variables.$spacing, 'size-16') 0;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
&__indicator > svg {
|
|
144
|
+
vertical-align: baseline;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
&__line {
|
|
148
|
+
min-width: min-content;
|
|
149
|
+
width: 100%;
|
|
150
|
+
margin: auto;
|
|
151
|
+
|
|
152
|
+
height: var(--pkt-steps-border-width);
|
|
153
|
+
|
|
154
|
+
&--1 {
|
|
155
|
+
width: 50%;
|
|
156
|
+
transform: translateX(-55%);
|
|
157
|
+
}
|
|
158
|
+
&--2 {
|
|
159
|
+
width: 50%;
|
|
160
|
+
transform: translateX(55%);
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
&--3 {
|
|
164
|
+
min-width: map.get(variables.$spacing, 'size-80');
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
// FIRST STEP
|
|
171
|
+
.pkt-step:first-of-type {
|
|
172
|
+
.pkt-step__line--1 {
|
|
173
|
+
display: none;
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
// INCOMPLETE STEP
|
|
178
|
+
.pkt-step--incomplete {
|
|
179
|
+
.pkt-step__line {
|
|
180
|
+
background-color: var(--pkt-color-grays-gray-200);
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
.pkt-step__title,
|
|
184
|
+
.pkt-step__content {
|
|
185
|
+
color: var(--pkt-color-grays-gray-600);
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
// FIRST INCOMPLETE STEP
|
|
190
|
+
.pkt-step--current + .pkt-step--incomplete {
|
|
191
|
+
.pkt-step__line--1 {
|
|
192
|
+
background-color: var(--pkt-color-brand-dark-blue-1000);
|
|
193
|
+
}
|
|
194
|
+
.pkt-step__line--2 {
|
|
195
|
+
background-color: var(--pkt-color-grays-gray-200);
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
// LAST STEP
|
|
200
|
+
.pkt-step:last-of-type {
|
|
201
|
+
.pkt-step__line--3,
|
|
202
|
+
.pkt-step__line--2 {
|
|
203
|
+
display: none;
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
// ALL STEP CONTENT EXCEPT CURRENT
|
|
208
|
+
.pkt-step--hidden:not(.pkt-step--current) {
|
|
209
|
+
.pkt-step__content {
|
|
210
|
+
display: none;
|
|
211
|
+
}
|
|
212
|
+
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@oslokommune/punkt-css",
|
|
3
|
-
"version": "11.
|
|
3
|
+
"version": "11.15.0",
|
|
4
4
|
"description": "CSS-rammeverket til Punkt, et designsystem laget av Oslo Origo",
|
|
5
5
|
"homepage": "https://punkt.oslo.kommune.no",
|
|
6
6
|
"author": "Team Designsystem, Oslo Origo",
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"preview": "astro preview"
|
|
21
21
|
},
|
|
22
22
|
"devDependencies": {
|
|
23
|
-
"@oslokommune/punkt-assets": "^11.
|
|
23
|
+
"@oslokommune/punkt-assets": "^11.15.0",
|
|
24
24
|
"astro": "^2.8.1",
|
|
25
25
|
"edit-json-file": "^1.7.0",
|
|
26
26
|
"fs-extra": "^11.1.0",
|
|
@@ -55,5 +55,5 @@
|
|
|
55
55
|
"url": "https://github.com/oslokommune/punkt/issues"
|
|
56
56
|
},
|
|
57
57
|
"license": "MIT",
|
|
58
|
-
"gitHead": "
|
|
58
|
+
"gitHead": "edc5dbab79e9fc84f66aad1e36047afa22627e60"
|
|
59
59
|
}
|