@db-ux/core-foundations 5.1.6 → 5.2.1

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.
Files changed (31) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/build/styles/bundle.css +5 -0
  3. package/build/styles/defaults/default-fonts.scss +1 -10
  4. package/build/styles/density/classes/all.css +5 -0
  5. package/build/styles/density/classes/expressive.css +5 -0
  6. package/build/styles/density/classes/functional.css +5 -0
  7. package/build/styles/density/classes/regular.css +5 -0
  8. package/build/styles/fonts/_headline-levels.scss +13 -0
  9. package/build/styles/fonts/_index.scss +1 -0
  10. package/build/styles/fonts/classes/all.css +6 -0
  11. package/build/styles/fonts/classes/body/2xl.css +6 -0
  12. package/build/styles/fonts/classes/body/2xs.css +6 -0
  13. package/build/styles/fonts/classes/body/3xl.css +6 -0
  14. package/build/styles/fonts/classes/body/3xs.css +6 -0
  15. package/build/styles/fonts/classes/body/all.css +6 -0
  16. package/build/styles/fonts/classes/body/lg.css +6 -0
  17. package/build/styles/fonts/classes/body/md.css +6 -0
  18. package/build/styles/fonts/classes/body/sm.css +6 -0
  19. package/build/styles/fonts/classes/body/xl.css +6 -0
  20. package/build/styles/fonts/classes/body/xs.css +6 -0
  21. package/build/styles/fonts/classes/headline/2xl.css +6 -0
  22. package/build/styles/fonts/classes/headline/2xs.css +6 -0
  23. package/build/styles/fonts/classes/headline/3xl.css +6 -0
  24. package/build/styles/fonts/classes/headline/3xs.css +6 -0
  25. package/build/styles/fonts/classes/headline/all.css +6 -0
  26. package/build/styles/fonts/classes/headline/lg.css +6 -0
  27. package/build/styles/fonts/classes/headline/md.css +6 -0
  28. package/build/styles/fonts/classes/headline/sm.css +6 -0
  29. package/build/styles/fonts/classes/headline/xl.css +6 -0
  30. package/build/styles/fonts/classes/headline/xs.css +6 -0
  31. package/package.json +2 -2
package/CHANGELOG.md CHANGED
@@ -1,5 +1,20 @@
1
1
  # @db-ux/core-foundations
2
2
 
3
+ ## 5.2.1
4
+
5
+ _version bump_
6
+
7
+ ## 5.2.0
8
+
9
+ ### Minor Changes
10
+
11
+ - refactor(SASS): expose the headline level mapping as `fonts.$headlines` - [see commit dfa8e2c](https://github.com/db-ux-design-system/core-web/commit/dfa8e2cf7c05d7bc42782a38b1eb3d65d971e156):
12
+
13
+ - The default visual size per semantic level moves from
14
+ - `defaults/default-fonts.scss` into the new non-emitting partial
15
+ - `fonts/_headline-levels.scss`, so `defaults/default-fonts.scss` and the Heading
16
+ - component styles share one source of truth. The emitted CSS is unchanged.
17
+
3
18
  ## 5.1.6
4
19
 
5
20
  _version bump_
@@ -202,6 +202,11 @@ code {
202
202
  --db-icon-font-size: var(--db-base-body-icon-font-size-sm);
203
203
  }
204
204
 
205
+ /* Single source of truth for the default visual headline size per semantic
206
+ * level. Kept in its own partial because it is consumed both by
207
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
208
+ * component styles in `@db-ux/core-components`. Those must not pull in the
209
+ * emitted default-fonts CSS just to read the mapping. */
205
210
  :root,
206
211
  :host {
207
212
  --db-sizing-3xs: var(--db-sizing-regular-3xs);
@@ -8,16 +8,7 @@ code {
8
8
  @extend %db-overwrite-font-size-sm;
9
9
  }
10
10
 
11
- $headlines: (
12
- "h1": "xl",
13
- "h2": "lg",
14
- "h3": "md",
15
- "h4": "sm",
16
- "h5": "xs",
17
- "h6": "2xs"
18
- );
19
-
20
- @each $headline, $size in $headlines {
11
+ @each $headline, $size in fonts.$headlines {
21
12
  #{string.unquote($headline)} {
22
13
  /* stylelint-disable custom-property-pattern */
23
14
  font: var(--db-type-headline-#{string.unquote($size)});
@@ -18,6 +18,11 @@
18
18
  --db-icon-font-size: var(--db-base-body-icon-font-size-md);
19
19
  }
20
20
 
21
+ /* Single source of truth for the default visual headline size per semantic
22
+ * level. Kept in its own partial because it is consumed both by
23
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
24
+ * component styles in `@db-ux/core-components`. Those must not pull in the
25
+ * emitted default-fonts CSS just to read the mapping. */
21
26
  .db-density-expressive,
22
27
  [data-density=expressive] {
23
28
  --db-sizing-3xs: var(--db-sizing-expressive-3xs);
@@ -14,6 +14,11 @@
14
14
  --db-icon-font-size: var(--db-base-body-icon-font-size-md);
15
15
  }
16
16
 
17
+ /* Single source of truth for the default visual headline size per semantic
18
+ * level. Kept in its own partial because it is consumed both by
19
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
20
+ * component styles in `@db-ux/core-components`. Those must not pull in the
21
+ * emitted default-fonts CSS just to read the mapping. */
17
22
  .db-density-expressive,
18
23
  [data-density=expressive] {
19
24
  --db-sizing-3xs: var(--db-sizing-expressive-3xs);
@@ -14,6 +14,11 @@
14
14
  --db-icon-font-size: var(--db-base-body-icon-font-size-md);
15
15
  }
16
16
 
17
+ /* Single source of truth for the default visual headline size per semantic
18
+ * level. Kept in its own partial because it is consumed both by
19
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
20
+ * component styles in `@db-ux/core-components`. Those must not pull in the
21
+ * emitted default-fonts CSS just to read the mapping. */
17
22
  .db-density-functional,
18
23
  [data-density=functional] {
19
24
  --db-sizing-3xs: var(--db-sizing-functional-3xs);
@@ -14,6 +14,11 @@
14
14
  --db-icon-font-size: var(--db-base-body-icon-font-size-md);
15
15
  }
16
16
 
17
+ /* Single source of truth for the default visual headline size per semantic
18
+ * level. Kept in its own partial because it is consumed both by
19
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
20
+ * component styles in `@db-ux/core-components`. Those must not pull in the
21
+ * emitted default-fonts CSS just to read the mapping. */
17
22
  .db-density-regular,
18
23
  [data-density=regular] {
19
24
  --db-sizing-3xs: var(--db-sizing-regular-3xs);
@@ -0,0 +1,13 @@
1
+ /* Single source of truth for the default visual headline size per semantic
2
+ * level. Kept in its own partial because it is consumed both by
3
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
4
+ * component styles in `@db-ux/core-components`. Those must not pull in the
5
+ * emitted default-fonts CSS just to read the mapping. */
6
+ $headlines: (
7
+ "h1": "xl",
8
+ "h2": "lg",
9
+ "h3": "md",
10
+ "h4": "sm",
11
+ "h5": "xs",
12
+ "h6": "2xs"
13
+ );
@@ -1,2 +1,3 @@
1
1
  @forward "font-sizes";
2
+ @forward "headline-levels";
2
3
  @forward "variables";
@@ -144,3 +144,9 @@
144
144
  --db-icon-font-weight: var(--db-base-headline-icon-weight-3xs);
145
145
  --db-icon-font-size: var(--db-base-headline-icon-font-size-3xs);
146
146
  }
147
+
148
+ /* Single source of truth for the default visual headline size per semantic
149
+ * level. Kept in its own partial because it is consumed both by
150
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
151
+ * component styles in `@db-ux/core-components`. Those must not pull in the
152
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-body-icon-weight-2xl);
9
9
  --db-icon-font-size: var(--db-base-body-icon-font-size-2xl);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-body-icon-weight-2xs);
9
9
  --db-icon-font-size: var(--db-base-body-icon-font-size-2xs);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-body-icon-weight-3xl);
9
9
  --db-icon-font-size: var(--db-base-body-icon-font-size-3xl);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-body-icon-weight-3xs);
9
9
  --db-icon-font-size: var(--db-base-body-icon-font-size-3xs);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -72,3 +72,9 @@
72
72
  --db-icon-font-weight: var(--db-base-body-icon-weight-3xs);
73
73
  --db-icon-font-size: var(--db-base-body-icon-font-size-3xs);
74
74
  }
75
+
76
+ /* Single source of truth for the default visual headline size per semantic
77
+ * level. Kept in its own partial because it is consumed both by
78
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
79
+ * component styles in `@db-ux/core-components`. Those must not pull in the
80
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-body-icon-weight-lg);
9
9
  --db-icon-font-size: var(--db-base-body-icon-font-size-lg);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-body-icon-weight-md);
9
9
  --db-icon-font-size: var(--db-base-body-icon-font-size-md);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-body-icon-weight-sm);
9
9
  --db-icon-font-size: var(--db-base-body-icon-font-size-sm);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-body-icon-weight-xl);
9
9
  --db-icon-font-size: var(--db-base-body-icon-font-size-xl);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-body-icon-weight-xs);
9
9
  --db-icon-font-size: var(--db-base-body-icon-font-size-xs);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-headline-icon-weight-2xl);
9
9
  --db-icon-font-size: var(--db-base-headline-icon-font-size-2xl);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-headline-icon-weight-2xs);
9
9
  --db-icon-font-size: var(--db-base-headline-icon-font-size-2xs);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-headline-icon-weight-3xl);
9
9
  --db-icon-font-size: var(--db-base-headline-icon-font-size-3xl);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-headline-icon-weight-3xs);
9
9
  --db-icon-font-size: var(--db-base-headline-icon-font-size-3xs);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -72,3 +72,9 @@
72
72
  --db-icon-font-weight: var(--db-base-headline-icon-weight-3xs);
73
73
  --db-icon-font-size: var(--db-base-headline-icon-font-size-3xs);
74
74
  }
75
+
76
+ /* Single source of truth for the default visual headline size per semantic
77
+ * level. Kept in its own partial because it is consumed both by
78
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
79
+ * component styles in `@db-ux/core-components`. Those must not pull in the
80
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-headline-icon-weight-lg);
9
9
  --db-icon-font-size: var(--db-base-headline-icon-font-size-lg);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-headline-icon-weight-md);
9
9
  --db-icon-font-size: var(--db-base-headline-icon-font-size-md);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-headline-icon-weight-sm);
9
9
  --db-icon-font-size: var(--db-base-headline-icon-font-size-sm);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-headline-icon-weight-xl);
9
9
  --db-icon-font-size: var(--db-base-headline-icon-font-size-xl);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
@@ -8,3 +8,9 @@
8
8
  --db-icon-font-weight: var(--db-base-headline-icon-weight-xs);
9
9
  --db-icon-font-size: var(--db-base-headline-icon-font-size-xs);
10
10
  }
11
+
12
+ /* Single source of truth for the default visual headline size per semantic
13
+ * level. Kept in its own partial because it is consumed both by
14
+ * `defaults/default-fonts.scss`, which styles bare `h1`-`h6`, and by the Heading
15
+ * component styles in `@db-ux/core-components`. Those must not pull in the
16
+ * emitted default-fonts CSS just to read the mapping. */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@db-ux/core-foundations",
3
- "version": "5.1.6",
3
+ "version": "5.2.1",
4
4
  "type": "module",
5
5
  "description": "Provides basic tokens and assets based on DB UX Design System (Version 3).",
6
6
  "repository": {
@@ -22,7 +22,7 @@
22
22
  "@db-ux/icon-font-tools": "0.3.6",
23
23
  "@playwright/test": "1.62.1",
24
24
  "cpr": "3.0.1",
25
- "cssnano": "8.0.7",
25
+ "cssnano": "9.0.0",
26
26
  "glob": "13.0.6",
27
27
  "nodemon": "3.1.14",
28
28
  "postcss": "8.5.26",