@lmvz-ds/design-tokens 0.22.0 → 0.23.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 CHANGED
@@ -1,5 +1,17 @@
1
1
  # @lmvz-ds/design-tokens
2
2
 
3
+ ## 0.23.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 09e454c: Generierung von @custom-media Breakpoints aus Supernova Tokens hinzugefügt
8
+
9
+ ## 0.22.1
10
+
11
+ ### Patch Changes
12
+
13
+ - 96010ab: Design Tokens aktualisiert
14
+
3
15
  ## 0.22.0
4
16
 
5
17
  ## 0.21.0
package/README.md CHANGED
@@ -51,3 +51,62 @@ which will create CSS custom properties in the dist folder.
51
51
  ### Code Versioning
52
52
 
53
53
  Currently the changes have to be created and committed manually. As of October 2025, CI/CD-based sync is not possible due to our GitLab being hosted behind a VPN.
54
+
55
+ ## Responsive Breakpoint Custom Media
56
+
57
+ This package generates a `dist/css/custom-media.css` artifact containing CSS custom media queries sourced from Supernova `naming.spec-breakpoint-*` tokens. Components and applications consume these aliases via a PostCSS plugin chain during their CSS build.
58
+
59
+ The `@custom-media` artifact is a standard CSS custom media rule file that makes breakpoint values defined in Supernova available to component CSS. The file is generated automatically during the design-tokens build instead of manually maintained.
60
+
61
+ ### How to import as a consumer
62
+
63
+ If your build pipeline consumes custom media queries, import the artifact:
64
+
65
+ ```javascript
66
+ import '@lmvz-ds/design-tokens/css/custom-media.css';
67
+
68
+ // Or via CSS @import (less common in modern bundlers)
69
+ // @import '@lmvz-ds/design-tokens/css/custom-media';
70
+ ```
71
+
72
+ ### How to use in component CSS
73
+
74
+ Component CSS uses breakpoint aliases in media queries via a PostCSS plugin chain:
75
+
76
+ ```css
77
+ @media (--lmvz-bp-small) {
78
+ .my-component {
79
+ /* styles for small breakpoint and above */
80
+ }
81
+ }
82
+ ```
83
+
84
+ The PostCSS build resolves this to the concrete pixel value:
85
+
86
+ ```css
87
+ @media (min-width: 768px) {
88
+ .my-component {
89
+ /* styles for small breakpoint and above */
90
+ }
91
+ }
92
+ ```
93
+
94
+ See `packages/components/stencil.config.base.ts` for the reference PostCSS plugin chain configuration. The key plugins are:
95
+
96
+ 1. `postcss-import` — inlines `@import` statements so all CSS is available to subsequent plugins.
97
+ 2. `@csstools/postcss-global-data` — makes `@custom-media` declarations globally available without emitting them to output.
98
+ 3. `postcss-custom-media` — resolves `@media (--lmvz-bp-*)` aliases to concrete media queries.
99
+
100
+ Plugin order is load-bearing: reversing or skipping any step causes aliases to remain unresolved.
101
+
102
+ ### Naming convention
103
+
104
+ All breakpoint aliases follow the pattern `--lmvz-bp-<size>`, where `<size>` is the trailing segment of the `naming.spec-breakpoint-*` token name (e.g., `spec-breakpoint-small` → `--lmvz-bp-small`).
105
+
106
+ ### Sentinel value handling
107
+
108
+ Supernova currently defines `naming.spec-breakpoint-largest` as `"TV"` (a non-numeric placeholder for future expansion). The design-tokens build intentionally skips this value with a `console.warn` message. When Supernova provides a real pixel value, the alias appears automatically on the next build without code changes.
109
+
110
+ ### How to extend with new breakpoints
111
+
112
+ Add a new token to Supernova matching the naming pattern `naming.spec-breakpoint-<size>` with a numeric pixel value. On the next design-tokens build, a new `--lmvz-bp-<size>` alias is generated. No code changes are needed.
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Generated by @lmvz-ds/design-tokens — do not edit.
3
+ * Source: tokens.json `naming.spec-breakpoint-*`
4
+ *
5
+ * Skipped tokens:
6
+ * --lmvz-bp-largest (value "TV" is non-numeric)
7
+ */
8
+ @custom-media --lmvz-bp-large (min-width: 1920px);
9
+ @custom-media --lmvz-bp-medium (min-width: 1440px);
10
+ @custom-media --lmvz-bp-small (min-width: 768px);
11
+ @custom-media --lmvz-bp-smallest (min-width: 402px);
@@ -425,20 +425,20 @@
425
425
  --lmvz-component-component-typography-body-lg-padding-bottom: var(--lmvz-dimension-10-13);
426
426
  --lmvz-component-component-typography-body-md-padding-bottom: var(--lmvz-dimension-4-10);
427
427
  --lmvz-component-component-typography-body-sm-padding-bottom: var(--lmvz-dimension-2-8);
428
- --lmvz-component-box-padding-x: var(--lmvz-dimension-24-48);
429
- --lmvz-component-box-padding-y: var(--lmvz-dimension-36-40);
430
- --lmvz-component-form-wrapper-gap-x: var(--lmvz-dimension-4-10);
431
- --lmvz-component-form-wrapper-gap-y: var(--lmvz-dimension-18-28);
432
- --lmvz-component-form-wrapper-padding-y: var(--lmvz-dimension-6-10);
433
- --lmvz-component-buttongroup-wrapper-gap-x: var(--lmvz-dimension-4-10);
434
- --lmvz-component-buttongroup-wrapper-gap-y: var(--lmvz-dimension-18-28);
435
- --lmvz-component-buttongroup-wrapper-padding-y: var(--lmvz-dimension-6-10);
428
+ --lmvz-component-modal-padding-x: var(--lmvz-dimension-24-48);
429
+ --lmvz-component-modal-padding-y: var(--lmvz-dimension-36-40);
436
430
  --lmvz-component-table-cell-padding-y: var(--lmvz-dimension-4-10);
437
431
  --lmvz-component-table-cell-padding-x: var(--lmvz-dimension-4-10);
438
432
  --lmvz-component-table-row-height: var(--lmvz-dimension-4-10);
439
433
  --lmvz-component-table-border-color: var(--lmvz-semantic-color-border-default);
440
434
  --lmvz-component-table-bg: var(--lmvz-semantic-color-surface-primary);
441
435
  --lmvz-component-table-header-bg: var(--lmvz-semantic-color-surface-secondary);
436
+ --lmvz-component-form-wrapper-gap-x: var(--lmvz-dimension-4-10);
437
+ --lmvz-component-form-wrapper-gap-y: var(--lmvz-dimension-18-28);
438
+ --lmvz-component-form-wrapper-padding-y: var(--lmvz-dimension-6-10);
439
+ --lmvz-component-buttongroup-wrapper-gap-x: var(--lmvz-dimension-4-10);
440
+ --lmvz-component-buttongroup-wrapper-gap-y: var(--lmvz-dimension-18-28);
441
+ --lmvz-component-buttongroup-wrapper-padding-y: var(--lmvz-dimension-6-10);
442
442
  --lmvz-component-input-sm-padding-x: var(--lmvz-dimension-8-12);
443
443
  --lmvz-component-input-sm-padding-y: var(--lmvz-dimension-8-12);
444
444
  --lmvz-component-input-sm-gap-x: var(--lmvz-dimension-4-10);
@@ -448,9 +448,9 @@
448
448
  --lmvz-component-input-lg-padding-x: var(--lmvz-dimension-14-20);
449
449
  --lmvz-component-input-lg-padding-y: var(--lmvz-dimension-14-20);
450
450
  --lmvz-component-input-lg-gap-x: var(--lmvz-dimension-4-10);
451
- --lmvz-component-input-height-sm: var(--lmvz-dimension-36-40);
452
- --lmvz-component-input-height-md: var(--lmvz-dimension-40-44);
453
- --lmvz-component-input-height-lg: var(--lmvz-dimension-44-48);
451
+ --lmvz-component-input-size-sm: var(--lmvz-dimension-32-36);
452
+ --lmvz-component-input-size-md: var(--lmvz-dimension-40-44);
453
+ --lmvz-component-input-size-lg: var(--lmvz-dimension-44-48);
454
454
  --lmvz-component-input-padding-sm: var(--lmvz-dimension-12-14);
455
455
  --lmvz-component-input-padding-md: var(--lmvz-dimension-14-16);
456
456
  --lmvz-component-input-padding-lg: var(--lmvz-dimension-16-20);
@@ -470,7 +470,8 @@
470
470
  --lmvz-semantic-color-surface-input-primary: var(--lmvz-semantic-color-surface-primary);
471
471
  --lmvz-semantic-color-gradient-main-1: var(--lmvz-semantic-color-status-on-active);
472
472
  --lmvz-semantic-color-gradient-main-2: var(--lmvz-semantic-color-status-on-active);
473
- --lmvz-component-box-radius: var(--lmvz-semantic-border-radius-xl);
473
+ --lmvz-component-modal-border-radius: var(--lmvz-semantic-border-radius-xl);
474
+ --lmvz-component-card-border-radius: var(--lmvz-semantic-border-radius-xl);
474
475
  }
475
476
  /**
476
477
  * Fluid ramp tokens generated from our global dimension scale tokens.
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@lmvz-ds/design-tokens",
3
3
  "private": false,
4
4
  "type": "module",
5
- "version": "0.22.0",
5
+ "version": "0.23.0",
6
6
  "author": "Patrick Nemenz <patrick.nemenz@adesso.at>",
7
7
  "license": "UNLICENSED",
8
8
  "publishConfig": {