@danske/sapphire-css 50.2.1 → 52.2.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/build/themes/cjs/default-dark.js +4 -1
- package/build/themes/cjs/default.js +4 -1
- package/build/themes/cjs/index.d.ts +3 -0
- package/build/themes/cjs/realkredit.js +4 -1
- package/build/themes/esm/default-dark.js +4 -1
- package/build/themes/esm/default.js +4 -1
- package/build/themes/esm/index.d.ts +3 -0
- package/build/themes/esm/realkredit.js +4 -1
- package/components/alert/alert.module.css +3 -2
- package/components/avatar/avatar.module.css +1 -0
- package/components/button/button.module.css +1 -1
- package/components/calendar/calendar.module.css +46 -4
- package/components/calendar/calendar.module.css.d.ts +1 -0
- package/components/checkbox/checkbox.module.css +48 -3
- package/components/checkbox/checkbox.module.css.d.ts +5 -0
- package/components/danskeProgressBar/danskeProgressBar.module.css +178 -0
- package/components/danskeProgressBar/danskeProgressBar.module.css.d.ts +9 -0
- package/components/dateField/dateField.module.css +30 -1
- package/components/dateField/dateField.module.css.d.ts +1 -0
- package/components/dropzone/dropzone.module.css +12 -49
- package/components/field/field.module.css +180 -15
- package/components/field/field.module.css.d.ts +9 -2
- package/components/fieldGroup/fieldGroup.module.css +4 -0
- package/components/fieldGroup/fieldGroup.module.css.d.ts +1 -0
- package/components/label/label.module.css +5 -0
- package/components/label/label.module.css.d.ts +1 -0
- package/components/link/link.module.css +0 -1
- package/components/listbox/listbox.module.css +6 -0
- package/components/modalLayout/modalLayout.module.css +2 -1
- package/components/radio/radio.module.css +79 -18
- package/components/radio/radio.module.css.d.ts +5 -0
- package/components/searchField/searchField.module.css +31 -6
- package/components/searchField/searchField.module.css.d.ts +1 -0
- package/components/select/select.module.css +61 -16
- package/components/select/select.module.css.d.ts +2 -0
- package/components/slider/slider.module.css +2 -3
- package/components/switch/switch.module.css +42 -8
- package/components/switch/switch.module.css.d.ts +2 -0
- package/components/table/table.module.css +108 -10
- package/components/table/table.module.css.d.ts +5 -1
- package/components/textField/textField.module.css +43 -10
- package/components/textField/textField.module.css.d.ts +1 -0
- package/components/toast/toast.module.css +1 -0
- package/components/truncate-overflow/truncate-overflow.module.css +7 -0
- package/components/truncate-overflow/truncate-overflow.module.css.d.ts +5 -0
- package/package.json +19 -22
- package/themes/default-dark.js +4 -1
- package/themes/default.js +4 -1
- package/themes/index.d.ts +3 -0
- package/themes/realkredit.js +4 -1
|
@@ -34,12 +34,18 @@
|
|
|
34
34
|
font-size: var(--sapphire-semantic-size-font-control-md);
|
|
35
35
|
}
|
|
36
36
|
|
|
37
|
+
.sapphire-text-field--sm {
|
|
38
|
+
border-radius: var(--sapphire-semantic-size-radius-sm);
|
|
39
|
+
height: var(--sapphire-semantic-size-height-control-sm);
|
|
40
|
+
font-size: var(--sapphire-semantic-size-font-control-md);
|
|
41
|
+
}
|
|
42
|
+
|
|
37
43
|
.sapphire-text-field__input {
|
|
38
44
|
box-sizing: border-box;
|
|
39
45
|
width: 100%;
|
|
40
46
|
height: 100%;
|
|
41
47
|
margin: 0;
|
|
42
|
-
padding: 0 var(--sapphire-semantic-size-spacing-control-horizontal-
|
|
48
|
+
padding: 0 var(--sapphire-semantic-size-spacing-control-horizontal-md);
|
|
43
49
|
line-height: var(--sapphire-semantic-size-line-height-md);
|
|
44
50
|
|
|
45
51
|
font-family: inherit;
|
|
@@ -53,10 +59,6 @@
|
|
|
53
59
|
outline: none;
|
|
54
60
|
}
|
|
55
61
|
|
|
56
|
-
.sapphire-text-field--md .sapphire-text-field__input {
|
|
57
|
-
padding: 0 var(--sapphire-semantic-size-spacing-control-horizontal-md);
|
|
58
|
-
}
|
|
59
|
-
|
|
60
62
|
/**
|
|
61
63
|
* Placeholder
|
|
62
64
|
*/
|
|
@@ -82,6 +84,9 @@
|
|
|
82
84
|
.sapphire-text-field--md:not(.sapphire-text-field--multiline) {
|
|
83
85
|
gap: var(--sapphire-semantic-size-spacing-xs);
|
|
84
86
|
}
|
|
87
|
+
.sapphire-text-field--sm:not(.sapphire-text-field--multiline) {
|
|
88
|
+
gap: var(--sapphire-semantic-size-spacing-2xs);
|
|
89
|
+
}
|
|
85
90
|
|
|
86
91
|
/**
|
|
87
92
|
* Prefix/postfix
|
|
@@ -100,8 +105,8 @@
|
|
|
100
105
|
margin-left: var(--sapphire-semantic-size-spacing-control-horizontal-md);
|
|
101
106
|
}
|
|
102
107
|
|
|
103
|
-
.sapphire-text-field--
|
|
104
|
-
margin-left: var(--sapphire-semantic-size-spacing-control-horizontal-
|
|
108
|
+
.sapphire-text-field--sm .sapphire-text-field__prefix {
|
|
109
|
+
margin-left: var(--sapphire-semantic-size-spacing-control-horizontal-sm);
|
|
105
110
|
}
|
|
106
111
|
|
|
107
112
|
/**
|
|
@@ -121,8 +126,8 @@
|
|
|
121
126
|
margin-right: var(--sapphire-semantic-size-spacing-control-horizontal-md);
|
|
122
127
|
}
|
|
123
128
|
|
|
124
|
-
.sapphire-text-field--
|
|
125
|
-
margin-right: var(--sapphire-semantic-size-spacing-control-horizontal-
|
|
129
|
+
.sapphire-text-field--sm .sapphire-text-field__postfix {
|
|
130
|
+
margin-right: var(--sapphire-semantic-size-spacing-control-horizontal-sm);
|
|
126
131
|
}
|
|
127
132
|
|
|
128
133
|
/**
|
|
@@ -141,6 +146,12 @@
|
|
|
141
146
|
height: var(--sapphire-semantic-size-icon-sm);
|
|
142
147
|
}
|
|
143
148
|
|
|
149
|
+
.sapphire-text-field--sm .sapphire-text-field__prefix--icon,
|
|
150
|
+
.sapphire-text-field--sm .sapphire-text-field__postfix--icon {
|
|
151
|
+
width: var(--sapphire-semantic-size-icon-sm);
|
|
152
|
+
height: var(--sapphire-semantic-size-icon-sm);
|
|
153
|
+
}
|
|
154
|
+
|
|
144
155
|
/**
|
|
145
156
|
* Multiline
|
|
146
157
|
* (this does not support a prefix/postfix)
|
|
@@ -156,7 +167,7 @@
|
|
|
156
167
|
resize: none;
|
|
157
168
|
width: 100%;
|
|
158
169
|
padding: var(--sapphire-semantic-size-spacing-control-vertical-lg)
|
|
159
|
-
var(--sapphire-semantic-size-spacing-control-horizontal-
|
|
170
|
+
var(--sapphire-semantic-size-spacing-control-horizontal-md);
|
|
160
171
|
scroll-padding-bottom: var(
|
|
161
172
|
--sapphire-semantic-size-spacing-control-vertical-lg
|
|
162
173
|
);
|
|
@@ -171,6 +182,15 @@
|
|
|
171
182
|
);
|
|
172
183
|
}
|
|
173
184
|
|
|
185
|
+
.sapphire-text-field--sm.sapphire-text-field--multiline
|
|
186
|
+
.sapphire-text-field__input {
|
|
187
|
+
padding: var(--sapphire-semantic-size-spacing-control-vertical-sm)
|
|
188
|
+
var(--sapphire-semantic-size-spacing-control-horizontal-sm);
|
|
189
|
+
scroll-padding-bottom: var(
|
|
190
|
+
--sapphire-semantic-size-spacing-control-vertical-sm
|
|
191
|
+
);
|
|
192
|
+
}
|
|
193
|
+
|
|
174
194
|
/**
|
|
175
195
|
* Resizable
|
|
176
196
|
*/
|
|
@@ -276,6 +296,15 @@
|
|
|
276
296
|
gap: var(--sapphire-semantic-size-spacing-sm);
|
|
277
297
|
}
|
|
278
298
|
|
|
299
|
+
.sapphire-text-field--sm .sapphire-text-field__stepper {
|
|
300
|
+
padding: var(--sapphire-semantic-size-spacing-2xs)
|
|
301
|
+
calc(
|
|
302
|
+
var(--sapphire-semantic-size-spacing-2xs) +
|
|
303
|
+
var(--sapphire-semantic-size-border-sm)
|
|
304
|
+
);
|
|
305
|
+
gap: var(--sapphire-semantic-size-spacing-2xs);
|
|
306
|
+
}
|
|
307
|
+
|
|
279
308
|
.sapphire-text-field:has(.sapphire-text-field__stepper)
|
|
280
309
|
.sapphire-text-field__postfix {
|
|
281
310
|
margin-right: 0;
|
|
@@ -331,3 +360,7 @@
|
|
|
331
360
|
.sapphire-text-field--md.sapphire-text-field__stepper-button {
|
|
332
361
|
width: var(--sapphire-semantic-size-icon-sm);
|
|
333
362
|
}
|
|
363
|
+
|
|
364
|
+
.sapphire-text-field--sm.sapphire-text-field__stepper-button {
|
|
365
|
+
width: var(--sapphire-semantic-size-icon-sm);
|
|
366
|
+
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
declare const styles: {
|
|
2
2
|
readonly "sapphire-text-field": string;
|
|
3
3
|
readonly "sapphire-text-field--md": string;
|
|
4
|
+
readonly "sapphire-text-field--sm": string;
|
|
4
5
|
readonly "sapphire-text-field__input": string;
|
|
5
6
|
readonly "sapphire-text-field__input--align-right": string;
|
|
6
7
|
readonly "sapphire-text-field--multiline": string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@danske/sapphire-css",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "52.2.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,
|
|
@@ -32,8 +32,8 @@
|
|
|
32
32
|
"test:stylelint": "stylelint components/**/*.module.css",
|
|
33
33
|
"test:findUnusedTokens": "stylelint components/**/*.module.css",
|
|
34
34
|
"watch:types": "yarn run types -- -w",
|
|
35
|
-
"storybook": "
|
|
36
|
-
"build:storybook": "
|
|
35
|
+
"storybook": "storybook dev -p 6007",
|
|
36
|
+
"build:storybook": "storybook build --docs -o dist",
|
|
37
37
|
"build:types": "tcm -p /**/*.module.css",
|
|
38
38
|
"build:themes": "yarn build:themes:esm && yarn build:themes:cjs",
|
|
39
39
|
"build:themes:esm": "tsc -p tsconfig.themes.json --module ES2020 --outDir build/themes/esm && tsc -p tsconfig.themes.json --module ES2020 --outDir themes",
|
|
@@ -42,33 +42,30 @@
|
|
|
42
42
|
"postpublish": "node ../../../scripts/append-release-notes.js"
|
|
43
43
|
},
|
|
44
44
|
"devDependencies": {
|
|
45
|
-
"@babel/core": "^7.20.12",
|
|
46
|
-
"@babel/preset-env": "^7.20.2",
|
|
47
|
-
"@babel/preset-react": "^7.18.6",
|
|
48
|
-
"@babel/preset-typescript": "^7.18.6",
|
|
49
45
|
"@danske/sapphire-icons": "^3.1.0",
|
|
50
|
-
"@danske/sapphire-react": "^5.
|
|
51
|
-
"@
|
|
52
|
-
"@storybook/addon-
|
|
53
|
-
"@storybook/addon-
|
|
54
|
-
"@storybook/
|
|
55
|
-
"@storybook/html": "
|
|
56
|
-
"@storybook/
|
|
57
|
-
"
|
|
46
|
+
"@danske/sapphire-react": "^5.17.3",
|
|
47
|
+
"@storybook/addon-docs": "8.6.14",
|
|
48
|
+
"@storybook/addon-links": "8.6.14",
|
|
49
|
+
"@storybook/addon-toolbars": "8.6.14",
|
|
50
|
+
"@storybook/blocks": "8.6.14",
|
|
51
|
+
"@storybook/html": "8.6.14",
|
|
52
|
+
"@storybook/html-vite": "8.6.14",
|
|
53
|
+
"@storybook/manager-api": "8.6.14",
|
|
54
|
+
"@storybook/theming": "8.6.14",
|
|
58
55
|
"cross-env": "^7.0.3",
|
|
59
|
-
"
|
|
56
|
+
"html-webpack-plugin": "^4.5.2",
|
|
60
57
|
"identity-obj-proxy": "^3.0.0",
|
|
61
58
|
"react": "^18.3.1",
|
|
62
|
-
"
|
|
63
|
-
"storybook
|
|
64
|
-
"style-loader": "^2.0.0",
|
|
59
|
+
"react-dom": "^18.3.1",
|
|
60
|
+
"storybook": "8.6.14",
|
|
65
61
|
"stylelint": "15.2.0",
|
|
66
62
|
"stylelint-value-no-unknown-custom-properties": "4.0.0",
|
|
67
63
|
"typed-css-modules": "0.6.5",
|
|
68
|
-
"typescript": "~4.6.4"
|
|
64
|
+
"typescript": "~4.6.4",
|
|
65
|
+
"vite": "^5.4.19"
|
|
69
66
|
},
|
|
70
67
|
"dependencies": {
|
|
71
|
-
"@danske/sapphire-design-tokens": "^
|
|
68
|
+
"@danske/sapphire-design-tokens": "^43.1.0"
|
|
72
69
|
},
|
|
73
|
-
"gitHead": "
|
|
70
|
+
"gitHead": "c659e1463951455fb38f07b7b429083261776798"
|
|
74
71
|
}
|
package/themes/default-dark.js
CHANGED
|
@@ -8,6 +8,9 @@ var tokens_module_css_1 = __importDefault(require("@danske/sapphire-design-token
|
|
|
8
8
|
var theme = {
|
|
9
9
|
themeClassName: tokens_module_css_1["default"]['sapphire-theme-default-dark'],
|
|
10
10
|
themeSecondaryModifierClassName: tokens_module_css_1["default"]['sapphire-theme--secondary'],
|
|
11
|
-
themeContrastModifierClassName: tokens_module_css_1["default"]['sapphire-theme--contrast']
|
|
11
|
+
themeContrastModifierClassName: tokens_module_css_1["default"]['sapphire-theme--contrast'],
|
|
12
|
+
themeScaleSmModifierClassName: tokens_module_css_1["default"]['sapphire-theme--scale-sm'],
|
|
13
|
+
themeScaleMdModifierClassName: tokens_module_css_1["default"]['sapphire-theme--scale-md'],
|
|
14
|
+
themeScaleAutoModifierClassName: tokens_module_css_1["default"]['sapphire-theme--scale-auto']
|
|
12
15
|
};
|
|
13
16
|
exports["default"] = theme;
|
package/themes/default.js
CHANGED
|
@@ -9,6 +9,9 @@ var theme = {
|
|
|
9
9
|
themeClassName: tokens_module_css_1["default"]['sapphire-theme-default'],
|
|
10
10
|
themeSecondaryModifierClassName: tokens_module_css_1["default"]['sapphire-theme--secondary'],
|
|
11
11
|
themeTertiaryModifierClassName: tokens_module_css_1["default"]['sapphire-theme--tertiary'],
|
|
12
|
-
themeContrastModifierClassName: tokens_module_css_1["default"]['sapphire-theme--contrast']
|
|
12
|
+
themeContrastModifierClassName: tokens_module_css_1["default"]['sapphire-theme--contrast'],
|
|
13
|
+
themeScaleSmModifierClassName: tokens_module_css_1["default"]['sapphire-theme--scale-sm'],
|
|
14
|
+
themeScaleMdModifierClassName: tokens_module_css_1["default"]['sapphire-theme--scale-md'],
|
|
15
|
+
themeScaleAutoModifierClassName: tokens_module_css_1["default"]['sapphire-theme--scale-auto']
|
|
13
16
|
};
|
|
14
17
|
exports["default"] = theme;
|
package/themes/index.d.ts
CHANGED
|
@@ -4,4 +4,7 @@ export interface Theme {
|
|
|
4
4
|
themeSecondaryModifierClassName?: string;
|
|
5
5
|
themeTertiaryModifierClassName?: string;
|
|
6
6
|
themeContrastModifierClassName?: string;
|
|
7
|
+
themeScaleSmModifierClassName?: string;
|
|
8
|
+
themeScaleMdModifierClassName?: string;
|
|
9
|
+
themeScaleAutoModifierClassName?: string;
|
|
7
10
|
}
|
package/themes/realkredit.js
CHANGED
|
@@ -6,6 +6,9 @@ exports.__esModule = true;
|
|
|
6
6
|
require("@danske/sapphire-design-tokens/build/themes/realkredit/assets/fonts/realkredit/fontFace.css");
|
|
7
7
|
var tokens_module_css_1 = __importDefault(require("@danske/sapphire-design-tokens/build/themes/realkredit/css/tokens.module.css"));
|
|
8
8
|
var theme = {
|
|
9
|
-
themeClassName: tokens_module_css_1["default"]['sapphire-theme-realkredit']
|
|
9
|
+
themeClassName: tokens_module_css_1["default"]['sapphire-theme-realkredit'],
|
|
10
|
+
themeScaleSmModifierClassName: tokens_module_css_1["default"]['sapphire-theme--scale-sm'],
|
|
11
|
+
themeScaleMdModifierClassName: tokens_module_css_1["default"]['sapphire-theme--scale-md'],
|
|
12
|
+
themeScaleAutoModifierClassName: tokens_module_css_1["default"]['sapphire-theme--scale-auto']
|
|
10
13
|
};
|
|
11
14
|
exports["default"] = theme;
|