@danske/sapphire-css 40.2.1 → 42.0.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/components/accordion/accordion.module.css +15 -36
- package/components/accordion/accordion.module.css.d.ts +1 -4
- package/components/alert/alert.module.css +68 -0
- package/components/alert/alert.module.css.d.ts +11 -0
- package/components/dateField/dateField.module.css +1 -1
- package/components/dialog/dialog.module.css +8 -1
- package/components/dialog/dialog.module.css.d.ts +1 -0
- package/components/feedbackMessage/feedbackMessage.module.css +14 -4
- package/components/feedbackMessage/feedbackMessage.module.css.d.ts +2 -0
- package/components/filterDropdown/filterDropdown.module.css +0 -2
- package/components/progressIndicator/progressIndicator.module.css +45 -0
- package/components/progressIndicator/progressIndicator.module.css.d.ts +7 -0
- package/components/table/table.module.css +0 -3
- package/components/tag/tag.module.css +16 -10
- package/components/text/text.module.css +4 -0
- package/components/text/text.module.css.d.ts +1 -0
- package/package.json +3 -3
|
@@ -61,8 +61,10 @@
|
|
|
61
61
|
display: flex;
|
|
62
62
|
justify-content: space-between;
|
|
63
63
|
align-items: center;
|
|
64
|
-
padding: var(--sapphire-semantic-size-spacing-
|
|
65
|
-
var(--sapphire-semantic-size-spacing-md)
|
|
64
|
+
padding: var(--sapphire-semantic-size-spacing-md)
|
|
65
|
+
var(--sapphire-semantic-size-spacing-md)
|
|
66
|
+
var(--sapphire-semantic-size-spacing-md)
|
|
67
|
+
var(--sapphire-semantic-size-spacing-lg);
|
|
66
68
|
border: none;
|
|
67
69
|
background: inherit;
|
|
68
70
|
font-family: inherit;
|
|
@@ -72,28 +74,6 @@
|
|
|
72
74
|
background: var(--sapphire-semantic-color-background-action-tertiary-default);
|
|
73
75
|
}
|
|
74
76
|
|
|
75
|
-
/* Hover header */
|
|
76
|
-
|
|
77
|
-
.sapphire-accordion__item:not(.is-disabled)
|
|
78
|
-
.sapphire-accordion__item-header:not(:active):not(.is-active):not(
|
|
79
|
-
.js-hover
|
|
80
|
-
):hover,
|
|
81
|
-
.sapphire-accordion__item:not(.is-disabled)
|
|
82
|
-
.sapphire-accordion__item-header:not(:active):not(.is-active).is-hover {
|
|
83
|
-
background: var(--sapphire-semantic-color-background-action-tertiary-hover);
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
/* Active header */
|
|
87
|
-
|
|
88
|
-
.sapphire-accordion__item:not(.is-disabled)
|
|
89
|
-
.sapphire-accordion__item-header.is-active,
|
|
90
|
-
.sapphire-accordion__item:not(.is-disabled)
|
|
91
|
-
.sapphire-accordion__item-header:active,
|
|
92
|
-
.sapphire-accordion__item:not(.is-disabled)
|
|
93
|
-
.sapphire-accordion__item-header:not(.js-focus):focus-visible:active {
|
|
94
|
-
background: var(--sapphire-semantic-color-background-action-tertiary-active);
|
|
95
|
-
}
|
|
96
|
-
|
|
97
77
|
/* Focus header */
|
|
98
78
|
|
|
99
79
|
.sapphire-accordion__item-header:focus {
|
|
@@ -141,8 +121,6 @@
|
|
|
141
121
|
}
|
|
142
122
|
|
|
143
123
|
.sapphire-accordion__item-heading {
|
|
144
|
-
font-size: var(--sapphire-semantic-size-font-body-md);
|
|
145
|
-
font-weight: var(--sapphire-semantic-font-weight-default-medium);
|
|
146
124
|
text-align: left;
|
|
147
125
|
flex: 1;
|
|
148
126
|
/* Wrap if title is long */
|
|
@@ -154,8 +132,8 @@
|
|
|
154
132
|
display: flex;
|
|
155
133
|
justify-content: center;
|
|
156
134
|
align-items: center;
|
|
157
|
-
width: var(--sapphire-semantic-size-height-control-
|
|
158
|
-
height: var(--sapphire-semantic-size-height-control-
|
|
135
|
+
width: var(--sapphire-semantic-size-height-control-xs);
|
|
136
|
+
height: var(--sapphire-semantic-size-height-control-xs);
|
|
159
137
|
transition: transform var(--sapphire-semantic-time-motion-quick)
|
|
160
138
|
var(--sapphire-semantic-transitions-dynamic);
|
|
161
139
|
}
|
|
@@ -177,12 +155,13 @@
|
|
|
177
155
|
font-weight: var(--sapphire-semantic-font-weight-default-regular);
|
|
178
156
|
overflow: hidden;
|
|
179
157
|
visibility: hidden;
|
|
180
|
-
|
|
181
|
-
|
|
158
|
+
opacity: 0;
|
|
159
|
+
transition: opacity var(--sapphire-semantic-time-fade-default)
|
|
160
|
+
var(--sapphire-semantic-transitions-fade),
|
|
182
161
|
padding-bottom var(--sapphire-semantic-time-motion-quick)
|
|
183
162
|
var(--sapphire-semantic-transitions-fade);
|
|
184
|
-
padding-right: var(--sapphire-semantic-size-spacing-
|
|
185
|
-
padding-left: var(--sapphire-semantic-size-spacing-
|
|
163
|
+
padding-right: var(--sapphire-semantic-size-spacing-lg);
|
|
164
|
+
padding-left: var(--sapphire-semantic-size-spacing-lg);
|
|
186
165
|
}
|
|
187
166
|
|
|
188
167
|
.sapphire-accordion__item--open > .sapphire-accordion__item-content-wrapper {
|
|
@@ -192,12 +171,12 @@
|
|
|
192
171
|
.sapphire-accordion__item--open
|
|
193
172
|
> .sapphire-accordion__item-content-wrapper
|
|
194
173
|
> .sapphire-accordion__item-content {
|
|
195
|
-
|
|
196
|
-
padding-bottom: var(--sapphire-semantic-size-spacing-
|
|
174
|
+
opacity: 1;
|
|
175
|
+
padding-bottom: var(--sapphire-semantic-size-spacing-lg);
|
|
197
176
|
visibility: visible;
|
|
198
177
|
}
|
|
199
178
|
|
|
200
179
|
.sapphire-accordion--negative-margin-self {
|
|
201
|
-
margin-left: calc(var(--sapphire-semantic-size-spacing-
|
|
202
|
-
width: calc(100% + (var(--sapphire-semantic-size-spacing-
|
|
180
|
+
margin-left: calc(var(--sapphire-semantic-size-spacing-lg) * -1);
|
|
181
|
+
width: calc(100% + (var(--sapphire-semantic-size-spacing-lg) * 2));
|
|
203
182
|
}
|
|
@@ -5,11 +5,8 @@ declare const styles: {
|
|
|
5
5
|
readonly "is-disabled": string;
|
|
6
6
|
readonly "sapphire-accordion__item-header": string;
|
|
7
7
|
readonly "sapphire-accordion__item-content-wrapper": string;
|
|
8
|
-
readonly "is-active": string;
|
|
9
|
-
readonly "js-hover": string;
|
|
10
|
-
readonly "is-hover": string;
|
|
11
|
-
readonly "js-focus": string;
|
|
12
8
|
readonly "is-focus": string;
|
|
9
|
+
readonly "js-focus": string;
|
|
13
10
|
readonly "sapphire-accordion__item--open": string;
|
|
14
11
|
readonly "sapphire-accordion__item-heading": string;
|
|
15
12
|
readonly "sapphire-accordion__item-arrow": string;
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
.sapphire-alert {
|
|
2
|
+
box-sizing: border-box;
|
|
3
|
+
margin: 0;
|
|
4
|
+
display: grid;
|
|
5
|
+
column-gap: var(--sapphire-semantic-size-spacing-2xs);
|
|
6
|
+
row-gap: var(--sapphire-semantic-size-spacing-sm);
|
|
7
|
+
grid-template-columns: var(--sapphire-semantic-size-icon-sm) 1fr;
|
|
8
|
+
padding: var(--sapphire-semantic-size-spacing-md);
|
|
9
|
+
border-radius: var(--sapphire-semantic-size-radius-lg);
|
|
10
|
+
|
|
11
|
+
color: var(--sapphire-semantic-color-foreground-primary);
|
|
12
|
+
|
|
13
|
+
/* Default variant "info" */
|
|
14
|
+
background-color: var(--sapphire-semantic-color-background-accent-subtle);
|
|
15
|
+
|
|
16
|
+
/* The below is meant to address a font rendering quirk in OSX where the text
|
|
17
|
+
* looks bolder than intended due to subpixel rendering. This quirk generally
|
|
18
|
+
* occurs for bold fonts on dark backgrounds but depending on the font, it
|
|
19
|
+
* can happen in other contexts as well.
|
|
20
|
+
*
|
|
21
|
+
* These do not do anything except in webkit browsers & firefox on OSX.
|
|
22
|
+
*
|
|
23
|
+
* For more details see:
|
|
24
|
+
* - https://azuredevops/Main/WCCJ/_git/sapphire/pullRequest/212710?path=%2Fpackages%2Fcss%2Fcomponents%2Fbutton%2Fbutton.module.css&discussionId=1507702&_a=files
|
|
25
|
+
* - https://usabilitypost.com/2012/11/05/stop-fixing-font-smoothing/
|
|
26
|
+
*/
|
|
27
|
+
-webkit-font-smoothing: antialiased;
|
|
28
|
+
-moz-osx-font-smoothing: grayscale;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.sapphire-alert__icon {
|
|
32
|
+
grid-row: 1;
|
|
33
|
+
grid-column: 1;
|
|
34
|
+
color: var(--sapphire-semantic-color-foreground-on-accent-subtle);
|
|
35
|
+
line-height: 0;
|
|
36
|
+
padding-top: var(--sapphire-semantic-size-spacing-4xs);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.sapphire-alert .sapphire-alert__title {
|
|
40
|
+
grid-row: 1 / 2;
|
|
41
|
+
grid-column: 2 / 3;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.sapphire-alert__content {
|
|
45
|
+
grid-row: 2 / 3;
|
|
46
|
+
grid-column: 1 / 3;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.sapphire-alert--warning {
|
|
50
|
+
background-color: var(--sapphire-semantic-color-background-warning-subtle);
|
|
51
|
+
}
|
|
52
|
+
.sapphire-alert--warning .sapphire-alert__icon {
|
|
53
|
+
color: var(--sapphire-semantic-color-foreground-on-warning-subtle);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.sapphire-alert--negative {
|
|
57
|
+
background-color: var(--sapphire-semantic-color-background-negative-subtle);
|
|
58
|
+
}
|
|
59
|
+
.sapphire-alert--negative .sapphire-alert__icon {
|
|
60
|
+
color: var(--sapphire-semantic-color-foreground-on-negative-subtle);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.sapphire-alert--positive {
|
|
64
|
+
background-color: var(--sapphire-semantic-color-background-positive-subtle);
|
|
65
|
+
}
|
|
66
|
+
.sapphire-alert--positive .sapphire-alert__icon {
|
|
67
|
+
color: var(--sapphire-semantic-color-foreground-on-positive-subtle);
|
|
68
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
declare const styles: {
|
|
2
|
+
readonly "sapphire-alert": string;
|
|
3
|
+
readonly "sapphire-alert__icon": string;
|
|
4
|
+
readonly "sapphire-alert__title": string;
|
|
5
|
+
readonly "sapphire-alert__content": string;
|
|
6
|
+
readonly "sapphire-alert--warning": string;
|
|
7
|
+
readonly "sapphire-alert--negative": string;
|
|
8
|
+
readonly "sapphire-alert--positive": string;
|
|
9
|
+
};
|
|
10
|
+
export = styles;
|
|
11
|
+
|
|
@@ -123,7 +123,7 @@
|
|
|
123
123
|
.sapphire-date-field__segment:not(:disabled):not(.is-disabled).is-focus {
|
|
124
124
|
color: var(--sapphire-semantic-color-foreground-primary);
|
|
125
125
|
background: var(
|
|
126
|
-
--sapphire-semantic-color-background-action-secondary-default
|
|
126
|
+
--sapphire-semantic-color-background-action-select-secondary-default
|
|
127
127
|
);
|
|
128
128
|
outline: none;
|
|
129
129
|
}
|
|
@@ -39,12 +39,19 @@
|
|
|
39
39
|
animation-fill-mode: forwards;
|
|
40
40
|
}
|
|
41
41
|
|
|
42
|
+
.sapphire-dialog--padded {
|
|
43
|
+
padding: var(--sapphire-semantic-size-spacing-3xl)
|
|
44
|
+
var(--sapphire-semantic-size-spacing-3xl)
|
|
45
|
+
var(--sapphire-semantic-size-spacing-2xl)
|
|
46
|
+
var(--sapphire-semantic-size-spacing-3xl);
|
|
47
|
+
}
|
|
48
|
+
|
|
42
49
|
.sapphire-dialog--exiting {
|
|
43
50
|
animation-name: fade-out;
|
|
44
51
|
}
|
|
45
52
|
|
|
46
53
|
.sapphire-dialog--xs {
|
|
47
|
-
width: var(--sapphire-global-size-generic-
|
|
54
|
+
width: var(--sapphire-global-size-generic-900);
|
|
48
55
|
}
|
|
49
56
|
|
|
50
57
|
.sapphire-dialog--sm {
|
|
@@ -1,11 +1,15 @@
|
|
|
1
1
|
.sapphire-feedback-message {
|
|
2
2
|
display: flex;
|
|
3
3
|
flex-direction: column;
|
|
4
|
-
align-items:
|
|
5
|
-
justify-content: center;
|
|
4
|
+
align-items: stretch;
|
|
6
5
|
margin: auto;
|
|
7
6
|
max-width: var(--sapphire-global-size-generic-1000);
|
|
8
|
-
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.sapphire-feedback-message__header {
|
|
10
|
+
display: flex;
|
|
11
|
+
justify-content: center;
|
|
12
|
+
margin-bottom: var(--sapphire-semantic-size-spacing-xl);
|
|
9
13
|
}
|
|
10
14
|
|
|
11
15
|
.sapphire-feedback-message__content {
|
|
@@ -13,5 +17,11 @@
|
|
|
13
17
|
flex-direction: column;
|
|
14
18
|
align-items: center;
|
|
15
19
|
text-align: center;
|
|
16
|
-
gap: var(--sapphire-semantic-size-spacing-
|
|
20
|
+
gap: var(--sapphire-semantic-size-spacing-sm);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.sapphire-feedback-message__footer {
|
|
24
|
+
display: flex;
|
|
25
|
+
justify-content: center;
|
|
26
|
+
margin-top: var(--sapphire-semantic-size-spacing-2xl);
|
|
17
27
|
}
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
declare const styles: {
|
|
2
2
|
readonly "sapphire-feedback-message": string;
|
|
3
|
+
readonly "sapphire-feedback-message__header": string;
|
|
3
4
|
readonly "sapphire-feedback-message__content": string;
|
|
5
|
+
readonly "sapphire-feedback-message__footer": string;
|
|
4
6
|
};
|
|
5
7
|
export = styles;
|
|
6
8
|
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/* Progress bar Track styles */
|
|
2
|
+
.sapphire-progress {
|
|
3
|
+
height: 3px;
|
|
4
|
+
width: 100%;
|
|
5
|
+
overflow: hidden;
|
|
6
|
+
background: var(--sapphire-semantic-color-background-accent-subtle);
|
|
7
|
+
position: relative;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.sapphire-progress:has(.sapphire-progress--segments) {
|
|
11
|
+
display: flex;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
/* Progress bar Progress styles */
|
|
15
|
+
.sapphire-progress--indicator {
|
|
16
|
+
height: 100%;
|
|
17
|
+
background: var(--sapphire-semantic-color-background-accent);
|
|
18
|
+
transition: width var(--sapphire-semantic-time-motion-default)
|
|
19
|
+
var(--sapphire-semantic-transitions-dynamic);
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
/* Progress bar Segmented styles */
|
|
23
|
+
.sapphire-progress--segments {
|
|
24
|
+
position: absolute;
|
|
25
|
+
width: 100%;
|
|
26
|
+
height: 100%;
|
|
27
|
+
margin: 0;
|
|
28
|
+
padding: 0;
|
|
29
|
+
display: flex;
|
|
30
|
+
pointer-events: none;
|
|
31
|
+
z-index: 1;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.sapphire-progress--segments span {
|
|
35
|
+
flex: 1;
|
|
36
|
+
position: relative;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.sapphire-progress--segments span:not(:first-child)::before {
|
|
40
|
+
background: var(--sapphire-semantic-color-background-surface);
|
|
41
|
+
content: '';
|
|
42
|
+
display: block;
|
|
43
|
+
height: 100%;
|
|
44
|
+
width: 4px;
|
|
45
|
+
}
|
|
@@ -167,9 +167,6 @@
|
|
|
167
167
|
.js-hover
|
|
168
168
|
):hover
|
|
169
169
|
.sapphire-table__headCell_container {
|
|
170
|
-
--sapphire-table-row-bg: var(
|
|
171
|
-
--sapphire-semantic-color-background-action-tertiary-hover
|
|
172
|
-
);
|
|
173
170
|
color: var(--sapphire-semantic-color-foreground-action-on-tertiary-hover);
|
|
174
171
|
border-radius: var(--sapphire-semantic-size-radius-sm);
|
|
175
172
|
}
|
|
@@ -8,9 +8,11 @@
|
|
|
8
8
|
.sapphire-tag {
|
|
9
9
|
display: inline-flex;
|
|
10
10
|
height: var(--sapphire-semantic-size-height-control-sm);
|
|
11
|
-
padding: 0 var(--sapphire-semantic-size-spacing-
|
|
11
|
+
padding: 0 var(--sapphire-semantic-size-spacing-md);
|
|
12
12
|
align-items: center;
|
|
13
13
|
border-radius: var(--sapphire-semantic-size-height-control-sm);
|
|
14
|
+
border: var(--sapphire-semantic-size-border-sm) solid
|
|
15
|
+
var(--sapphire-semantic-color-border-primary);
|
|
14
16
|
|
|
15
17
|
/* typography */
|
|
16
18
|
font-size: var(--sapphire-semantic-size-font-control-md);
|
|
@@ -19,11 +21,8 @@
|
|
|
19
21
|
font-style: normal;
|
|
20
22
|
text-decoration: none;
|
|
21
23
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
--sapphire-semantic-color-background-action-secondary-default
|
|
25
|
-
);
|
|
26
|
-
color: var(--sapphire-semantic-color-foreground-primary);
|
|
24
|
+
background: var(--sapphire-semantic-color-background-action-tertiary-default);
|
|
25
|
+
color: var(--sapphire-semantic-color-foreground-action-on-tertiary-default);
|
|
27
26
|
outline: none;
|
|
28
27
|
|
|
29
28
|
/* transition */
|
|
@@ -69,12 +68,14 @@
|
|
|
69
68
|
.sapphire-tag--actionable:not(:disabled):not(.is-disabled):not(:active):not(
|
|
70
69
|
.is-active
|
|
71
70
|
).is-hover {
|
|
72
|
-
background: var(--sapphire-semantic-color-background-action-
|
|
71
|
+
background: var(--sapphire-semantic-color-background-action-tertiary-hover);
|
|
72
|
+
color: var(--sapphire-semantic-color-foreground-action-on-tertiary-hover);
|
|
73
73
|
cursor: pointer;
|
|
74
74
|
}
|
|
75
75
|
|
|
76
76
|
.sapphire-tag--actionable.is-active {
|
|
77
|
-
background: var(--sapphire-semantic-color-background-action-
|
|
77
|
+
background: var(--sapphire-semantic-color-background-action-tertiary-active);
|
|
78
|
+
color: var(--sapphire-semantic-color-foreground-action-on-tertiary-active);
|
|
78
79
|
cursor: pointer;
|
|
79
80
|
}
|
|
80
81
|
|
|
@@ -95,12 +96,17 @@
|
|
|
95
96
|
.sapphire-tag__error-icon {
|
|
96
97
|
display: flex;
|
|
97
98
|
align-items: center;
|
|
98
|
-
color: var(--sapphire-semantic-color-foreground-
|
|
99
|
+
color: var(--sapphire-semantic-color-foreground-negative);
|
|
99
100
|
}
|
|
100
101
|
|
|
101
102
|
/**
|
|
102
103
|
* Button
|
|
103
104
|
*/
|
|
105
|
+
|
|
106
|
+
.sapphire-tag:has(.sapphire-tag__button) {
|
|
107
|
+
padding-right: var(--sapphire-semantic-size-spacing-sm);
|
|
108
|
+
}
|
|
109
|
+
|
|
104
110
|
.sapphire-tag__button {
|
|
105
111
|
box-sizing: border-box;
|
|
106
112
|
display: inline-flex;
|
|
@@ -120,7 +126,7 @@
|
|
|
120
126
|
|
|
121
127
|
/* style */
|
|
122
128
|
background: transparent;
|
|
123
|
-
color: var(--sapphire-semantic-color-foreground-on-
|
|
129
|
+
color: var(--sapphire-semantic-color-foreground-action-on-tertiary-default);
|
|
124
130
|
}
|
|
125
131
|
|
|
126
132
|
.sapphire-tag__button:focus {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
declare const styles: {
|
|
2
2
|
readonly "sapphire-text": string;
|
|
3
3
|
readonly "sapphire-text--strong": string;
|
|
4
|
+
readonly "sapphire-text--semibold": string;
|
|
4
5
|
readonly "sapphire-text--underlined": string;
|
|
5
6
|
readonly "sapphire-text--secondary": string;
|
|
6
7
|
readonly "sapphire-text--informative": string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@danske/sapphire-css",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "42.0.0",
|
|
4
4
|
"description": "CSS implementation of the Sapphire Design System from Danske Bank A/S",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
"typescript": "~4.6.4"
|
|
68
68
|
},
|
|
69
69
|
"dependencies": {
|
|
70
|
-
"@danske/sapphire-design-tokens": "^42.1.
|
|
70
|
+
"@danske/sapphire-design-tokens": "^42.1.1"
|
|
71
71
|
},
|
|
72
|
-
"gitHead": "
|
|
72
|
+
"gitHead": "afb5a25463f39012c3599e6242c8d308786d11e1"
|
|
73
73
|
}
|