@navikt/ds-css 0.12.7 → 0.12.8
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/index.css +209 -2
- package/index.css +1 -0
- package/package.json +2 -2
- package/step-indicator.css +202 -0
package/index.css
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@navikt/ds-css",
|
|
3
|
-
"version": "0.12.
|
|
3
|
+
"version": "0.12.8",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "Css for NAV Designsystem components",
|
|
6
6
|
"author": "NAV Designsystem team",
|
|
@@ -27,5 +27,5 @@
|
|
|
27
27
|
"postcss-cli": "^8.3.1",
|
|
28
28
|
"postcss-import": "^14.0.2"
|
|
29
29
|
},
|
|
30
|
-
"gitHead": "
|
|
30
|
+
"gitHead": "3db81c9b79f8be93cb23f996002d0cbb38ca2348"
|
|
31
31
|
}
|
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
:root {
|
|
2
|
+
--navds-step-indicator-color-step-line: var(--navds-semantic-color-divider);
|
|
3
|
+
--navds-step-indicator-color-step-text: var(--navds-semantic-color-text);
|
|
4
|
+
--navds-step-indicator-color-step-label: var(
|
|
5
|
+
--navds-semantic-color-interaction-primary
|
|
6
|
+
);
|
|
7
|
+
--navds-step-indicator-color-step-number-background: var(
|
|
8
|
+
--navds-semantic-color-canvas-background-light
|
|
9
|
+
);
|
|
10
|
+
--navds-step-indicator-color-step-number-background-finished: var(
|
|
11
|
+
--navds-semantic-color-canvas-background
|
|
12
|
+
);
|
|
13
|
+
--navds-step-indicator-color-step-number-shadow: var(
|
|
14
|
+
--navds-semantic-color-border
|
|
15
|
+
);
|
|
16
|
+
--navds-step-indicator-color-step-number-shadow-active: var(
|
|
17
|
+
--navds-semantic-color-interaction-primary-selected
|
|
18
|
+
);
|
|
19
|
+
--navds-step-indicator-color-step-number-shadow-hover: var(
|
|
20
|
+
--navds-semantic-color-interaction-primary
|
|
21
|
+
);
|
|
22
|
+
--navds-step-indicator-color-step-number-background-active: var(
|
|
23
|
+
--navds-semantic-color-interaction-primary-selected
|
|
24
|
+
);
|
|
25
|
+
--navds-step-indicator-color-step-number-text-active: var(
|
|
26
|
+
--navds-semantic-color-text-inverted
|
|
27
|
+
);
|
|
28
|
+
--navds-step-indicator-color-step-number-shadow-inset: var(
|
|
29
|
+
--navds-semantic-color-component-background-light
|
|
30
|
+
);
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
/* StepIndicator */
|
|
34
|
+
.navds-step-indicator {
|
|
35
|
+
display: flex;
|
|
36
|
+
align-items: flex-start;
|
|
37
|
+
padding: 0;
|
|
38
|
+
margin: 0;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
/* Step */
|
|
42
|
+
.navds-step-indicator__step-wrapper {
|
|
43
|
+
padding: 0 var(--navds-spacing-2);
|
|
44
|
+
flex: 1;
|
|
45
|
+
position: relative;
|
|
46
|
+
list-style: none;
|
|
47
|
+
min-width: 10rem;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.navds-step-indicator__step-wrapper--hidelabel {
|
|
51
|
+
min-width: 5rem;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.navds-step-indicator__step {
|
|
55
|
+
display: flex;
|
|
56
|
+
align-items: center;
|
|
57
|
+
flex-direction: column;
|
|
58
|
+
padding: 0;
|
|
59
|
+
background: none;
|
|
60
|
+
border: none;
|
|
61
|
+
appearance: none;
|
|
62
|
+
width: 100%;
|
|
63
|
+
flex-shrink: 1;
|
|
64
|
+
color: var(--navds-step-indicator-color-step-text);
|
|
65
|
+
text-decoration: none;
|
|
66
|
+
cursor: pointer;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.navds-step-indicator__step-number {
|
|
70
|
+
flex-shrink: 0;
|
|
71
|
+
display: flex;
|
|
72
|
+
width: 2rem;
|
|
73
|
+
height: 2rem;
|
|
74
|
+
margin: 0.5rem;
|
|
75
|
+
border-radius: 50%;
|
|
76
|
+
align-items: center;
|
|
77
|
+
justify-content: center;
|
|
78
|
+
box-shadow: 0 0 0 1px var(--navds-step-indicator-color-step-number-shadow);
|
|
79
|
+
background-color: var(--navds-step-indicator-color-step-number-background);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
.navds-step-indicator__step-wrapper:first-child
|
|
83
|
+
> .navds-step-indicator__step
|
|
84
|
+
> .navds-step-indicator__step-number {
|
|
85
|
+
padding-right: 0;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.navds-step-indicator__step-wrapper:last-child
|
|
89
|
+
> .navds-step-indicator__step
|
|
90
|
+
> .navds-step-indicator__step-number {
|
|
91
|
+
padding-left: 0;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.navds-step-indicator__step-label {
|
|
95
|
+
width: 100%;
|
|
96
|
+
margin-top: var(--navds-spacing-4);
|
|
97
|
+
text-align: center;
|
|
98
|
+
color: var(--navds-step-indicator-color-step-label);
|
|
99
|
+
text-decoration: underline;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
.navds-step-indicator__step-line {
|
|
103
|
+
flex: 1 1 100%;
|
|
104
|
+
position: absolute;
|
|
105
|
+
top: 1.5rem;
|
|
106
|
+
right: calc(50% + 2rem);
|
|
107
|
+
left: calc(-50% + 2rem);
|
|
108
|
+
display: block;
|
|
109
|
+
border-top: 2px solid var(--navds-step-indicator-color-step-line);
|
|
110
|
+
border-radius: 4px;
|
|
111
|
+
pointer-events: none;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
.navds-step-indicator__step--active > .navds-step-indicator__step-label {
|
|
115
|
+
color: var(--navds-step-indicator-color-step-text);
|
|
116
|
+
font-weight: bold;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
.navds-step-indicator__step--active > .navds-step-indicator__step-number {
|
|
120
|
+
background-color: var(
|
|
121
|
+
--navds-step-indicator-color-step-number-background-active
|
|
122
|
+
);
|
|
123
|
+
color: var(--navds-step-indicator-color-step-number-text-active);
|
|
124
|
+
box-shadow: 0 0 0 1px
|
|
125
|
+
var(--navds-step-indicator-color-step-number-shadow-active);
|
|
126
|
+
width: 2.5rem;
|
|
127
|
+
height: 2.5rem;
|
|
128
|
+
margin: 0.25rem;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
.navds-step-indicator__step:focus {
|
|
132
|
+
outline: none;
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
.navds-step-indicator__step:hover > .navds-step-indicator__step-label {
|
|
136
|
+
text-decoration: none;
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
.navds-step-indicator__step.navds-step-indicator__step--disabled:hover
|
|
140
|
+
> .navds-step-indicator__step-label {
|
|
141
|
+
text-decoration: underline;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
.navds-step-indicator__step--active > .navds-step-indicator__step-label,
|
|
145
|
+
.navds-step-indicator__step--active.navds-step-indicator__step--disabled:hover
|
|
146
|
+
> .navds-step-indicator__step-label {
|
|
147
|
+
text-decoration: none;
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
.navds-step-indicator__step:hover > .navds-step-indicator__step-number {
|
|
151
|
+
background: var(--navds-step-indicator-color-step-number-background);
|
|
152
|
+
box-shadow: 0 0 0 2px
|
|
153
|
+
var(--navds-step-indicator-color-step-number-shadow-hover);
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.navds-step-indicator__step--active:hover > .navds-step-indicator__step-number {
|
|
157
|
+
background-color: var(
|
|
158
|
+
--navds-step-indicator-color-step-number-background-active
|
|
159
|
+
);
|
|
160
|
+
color: var(--navds-step-indicator-color-step-number-text-active);
|
|
161
|
+
box-shadow: 0 0 0 1px
|
|
162
|
+
var(--navds-step-indicator-color-step-number-shadow-active);
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
.navds-step-indicator__step:focus > .navds-step-indicator__step-number {
|
|
166
|
+
box-shadow: var(--navds-shadow-focus);
|
|
167
|
+
outline: none;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
.navds-step-indicator__step--active:focus > .navds-step-indicator__step-number {
|
|
171
|
+
box-shadow: 0 0 0 1px inset
|
|
172
|
+
var(--navds-step-indicator-color-step-number-shadow-inset),
|
|
173
|
+
var(--navds-shadow-focus);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.navds-step-indicator__step--disabled:hover
|
|
177
|
+
> .navds-step-indicator__step-number {
|
|
178
|
+
box-shadow: 0 0 0 1px var(--navds-step-indicator-color-step-number-shadow);
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
.navds-step-indicator__step--disabled.navds-step-indicator__step--active:disabled
|
|
182
|
+
> .navds-step-indicator__step-number {
|
|
183
|
+
box-shadow: 0 0 0 1px
|
|
184
|
+
var(--navds-step-indicator-color-step-number-shadow-active);
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
/* Finished state */
|
|
188
|
+
.navds-step-indicator__step--finished > .navds-step-indicator__step-number,
|
|
189
|
+
.navds-step-indicator__step--finished.navds-step-indicator__step--disabled
|
|
190
|
+
> .navds-step-indicator__step-number {
|
|
191
|
+
background: var(--navds-step-indicator-color-step-number-background-finished);
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
/* Disabled */
|
|
195
|
+
.navds-step-indicator__step--disabled > .navds-step-indicator__step-number,
|
|
196
|
+
.navds-step-indicator__step--disabled > .navds-step-indicator__step-label {
|
|
197
|
+
opacity: 0.3;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
.navds-step-indicator__step--disabled {
|
|
201
|
+
cursor: not-allowed;
|
|
202
|
+
}
|