@amsterdam/design-system-tokens 0.14.0 → 0.15.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 +65 -0
- package/README.md +14 -7
- package/build.js +39 -16
- package/dist/compact.css +18 -18
- package/dist/compact.d.ts +18 -12
- package/dist/compact.json +21 -15
- package/dist/compact.mjs +21 -22
- package/dist/compact.scss +18 -18
- package/dist/compact.theme.css +18 -18
- package/dist/index.css +779 -766
- package/dist/index.d.ts +286 -283
- package/dist/index.json +589 -586
- package/dist/index.mjs +533 -509
- package/dist/index.scss +779 -766
- package/dist/index.theme.css +779 -766
- package/package.json +4 -3
- package/src/brand/ams/aspect-ratio.tokens.json +6 -6
- package/src/brand/ams/border.tokens.json +3 -3
- package/src/brand/ams/color.tokens.json +34 -15
- package/src/brand/ams/cursor.tokens.json +8 -0
- package/src/brand/ams/space.compact.tokens.json +6 -15
- package/src/brand/ams/space.tokens.json +5 -14
- package/src/brand/ams/{text.compact.tokens.json → typography.compact.tokens.json} +14 -2
- package/src/brand/ams/typography.tokens.json +59 -0
- package/src/common/ams/links.tokens.json +32 -0
- package/src/components/ams/accordion.tokens.json +11 -12
- package/src/components/ams/action-group.tokens.json +1 -1
- package/src/components/ams/alert.tokens.json +27 -15
- package/src/components/ams/avatar.tokens.json +23 -53
- package/src/components/ams/badge.tokens.json +22 -48
- package/src/components/ams/blockquote.tokens.json +8 -6
- package/src/components/ams/breadcrumb.tokens.json +10 -10
- package/src/components/ams/button.tokens.json +31 -33
- package/src/components/ams/card.tokens.json +8 -8
- package/src/components/ams/character-count.tokens.json +6 -6
- package/src/components/ams/checkbox.tokens.json +31 -29
- package/src/components/ams/column.tokens.json +5 -6
- package/src/components/ams/date-input.tokens.json +18 -16
- package/src/components/ams/description-list.tokens.json +21 -10
- package/src/components/ams/dialog.tokens.json +19 -8
- package/src/components/ams/error-message.tokens.json +5 -5
- package/src/components/ams/field-set.tokens.json +8 -8
- package/src/components/ams/field.tokens.json +3 -3
- package/src/components/ams/figure.tokens.json +9 -7
- package/src/components/ams/file-input.tokens.json +29 -26
- package/src/components/ams/file-list.tokens.json +8 -8
- package/src/components/ams/footer.tokens.json +23 -2
- package/src/components/ams/grid.compact.tokens.json +1 -1
- package/src/components/ams/grid.tokens.json +12 -10
- package/src/components/ams/header.tokens.json +23 -19
- package/src/components/ams/heading.tokens.json +29 -29
- package/src/components/ams/hint.tokens.json +1 -1
- package/src/components/ams/icon-button.tokens.json +18 -16
- package/src/components/ams/icon.tokens.json +24 -14
- package/src/components/ams/image-slider.tokens.json +1 -1
- package/src/components/ams/image.tokens.json +1 -1
- package/src/components/ams/{form-error-list.tokens.json → invalid-form-alert.tokens.json} +1 -1
- package/src/components/ams/label.tokens.json +5 -5
- package/src/components/ams/link-list.tokens.json +22 -22
- package/src/components/ams/link.tokens.json +20 -31
- package/src/components/ams/logo.tokens.json +10 -7
- package/src/components/ams/mark.tokens.json +1 -1
- package/src/components/ams/mega-menu.tokens.json +3 -3
- package/src/components/ams/ordered-list.tokens.json +13 -11
- package/src/components/ams/page-heading.tokens.json +8 -6
- package/src/components/ams/page-menu.tokens.json +13 -13
- package/src/components/ams/pagination.tokens.json +13 -13
- package/src/components/ams/paragraph.tokens.json +12 -10
- package/src/components/ams/password-input.tokens.json +17 -16
- package/src/components/ams/radio.tokens.json +30 -28
- package/src/components/ams/row.tokens.json +5 -6
- package/src/components/ams/screen.tokens.json +1 -1
- package/src/components/ams/search-field.tokens.json +17 -18
- package/src/components/ams/select.tokens.json +17 -16
- package/src/components/ams/skip-link.tokens.json +9 -9
- package/src/components/ams/spotlight.tokens.json +10 -10
- package/src/components/ams/switch.tokens.json +7 -6
- package/src/components/ams/table-of-contents.tokens.json +17 -17
- package/src/components/ams/table.tokens.json +10 -13
- package/src/components/ams/tabs.tokens.json +16 -20
- package/src/components/ams/text-area.tokens.json +18 -18
- package/src/components/ams/text-input.tokens.json +17 -16
- package/src/components/ams/time-input.tokens.json +18 -16
- package/src/components/ams/top-task-link.tokens.json +16 -16
- package/src/components/ams/unordered-list.tokens.json +15 -13
- package/src/brand/ams/text.tokens.json +0 -41
- package/src/common/ams/action.tokens.json +0 -12
- package/src/common/ams/hyphenation.tokens.json +0 -9
- package/src/common/ams/link-appearance.tokens.json +0 -43
- package/src/components/ams/breakout.tokens.json +0 -11
- package/src/components/ams/gap.tokens.json +0 -11
- package/src/components/ams/margin.tokens.json +0 -11
- /package/src/{common → brand}/ams/focus.tokens.json +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,71 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [0.15.0](https://github.com/Amsterdam/design-system/compare/design-system-tokens-v0.14.0...design-system-tokens-v0.15.0) (2025-03-28)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### ⚠ BREAKING CHANGES
|
|
10
|
+
|
|
11
|
+
* Shorten size labels in prop values for Row and Column, tokens and utility classes ([#1940](https://github.com/Amsterdam/design-system/issues/1940), [#1951](https://github.com/Amsterdam/design-system/issues/1951))
|
|
12
|
+
* Shorten size labels in border tokens ([#1941](https://github.com/Amsterdam/design-system/issues/1941))
|
|
13
|
+
* Consolidate Grid Space and Component Space into one set of spacing tokens ([#1910](https://github.com/Amsterdam/design-system/issues/1910))
|
|
14
|
+
* **Tabs:** Remove unnecessary token, reuse color value ([#1932](https://github.com/Amsterdam/design-system/issues/1932))
|
|
15
|
+
* Update aspect ratio tokens and CSS utility classes ([#1913](https://github.com/Amsterdam/design-system/issues/1913))
|
|
16
|
+
* Update and document focus tokens ([#1919](https://github.com/Amsterdam/design-system/issues/1919))
|
|
17
|
+
* Update hyphenation tokens ([#1914](https://github.com/Amsterdam/design-system/issues/1914))
|
|
18
|
+
* **Header:** Add responsive version of Amsterdam Logo, remove Heading level 1 ([#1880](https://github.com/Amsterdam/design-system/issues/1880))
|
|
19
|
+
* Split typography tokens into ‘body text’ and ‘heading’ groups ([#1890](https://github.com/Amsterdam/design-system/issues/1890))
|
|
20
|
+
* **Dialog:** Prevent a focus indicator from being cut off ([#1879](https://github.com/Amsterdam/design-system/issues/1879))
|
|
21
|
+
* **Footer:** add FooterMenu component to replace PageMenu in Footer ([#1871](https://github.com/Amsterdam/design-system/issues/1871))
|
|
22
|
+
* Rename and document common tokens for links ([#1870](https://github.com/Amsterdam/design-system/issues/1870))
|
|
23
|
+
* **Avatar:** Use updated color names for azure, lime and green ([#1867](https://github.com/Amsterdam/design-system/issues/1867))
|
|
24
|
+
* **Badge:** Use updated color names for azure and lime ([#1866](https://github.com/Amsterdam/design-system/issues/1866))
|
|
25
|
+
* **Spotlight:** Use updated color names for lime and green and remove purple as an explicit option ([#1865](https://github.com/Amsterdam/design-system/issues/1865))
|
|
26
|
+
* Remove action tokens, add and implement cursor tokens ([#1860](https://github.com/Amsterdam/design-system/issues/1860))
|
|
27
|
+
* Combine contrast and inverse color options into a single prop ([#1822](https://github.com/Amsterdam/design-system/issues/1822))
|
|
28
|
+
* Change all brand colour tokens to use semantic names ([#1820](https://github.com/Amsterdam/design-system/issues/1820))
|
|
29
|
+
* Rename Form Error List to Invalid Form Alert ([#1835](https://github.com/Amsterdam/design-system/issues/1835))
|
|
30
|
+
* **Pagination:** Use links instead of buttons ([#1821](https://github.com/Amsterdam/design-system/issues/1821))
|
|
31
|
+
* **Badge:** Remove some colour options ([#1826](https://github.com/Amsterdam/design-system/issues/1826))
|
|
32
|
+
* **Avatar:** Remove some colour options and make purple the default ([#1825](https://github.com/Amsterdam/design-system/issues/1825))
|
|
33
|
+
* Move alert icon into thick left border ([#1792](https://github.com/Amsterdam/design-system/issues/1792))
|
|
34
|
+
|
|
35
|
+
### Features
|
|
36
|
+
|
|
37
|
+
* **Accordion:** Increase text size for Heading to level 4 ([#1837](https://github.com/Amsterdam/design-system/issues/1837)) ([1e914c9](https://github.com/Amsterdam/design-system/commit/1e914c9efd9087a0855e3f03661b46f6b228740a))
|
|
38
|
+
* **Avatar:** Remove some colour options and make purple the default ([#1825](https://github.com/Amsterdam/design-system/issues/1825)) ([52d8c64](https://github.com/Amsterdam/design-system/commit/52d8c64f653309cce34e222d250f56c7265078e0))
|
|
39
|
+
* **Avatar:** Use updated color names for azure, lime and green ([#1867](https://github.com/Amsterdam/design-system/issues/1867)) ([e8a2638](https://github.com/Amsterdam/design-system/commit/e8a2638882b95141c5e5e345bb7656f1f9968253))
|
|
40
|
+
* **Badge:** Remove some colour options ([#1826](https://github.com/Amsterdam/design-system/issues/1826)) ([1325e1b](https://github.com/Amsterdam/design-system/commit/1325e1b213e4704fd738dada1a92b5362a1a5174))
|
|
41
|
+
* **Badge:** Use updated color names for azure and lime ([#1866](https://github.com/Amsterdam/design-system/issues/1866)) ([fd25778](https://github.com/Amsterdam/design-system/commit/fd25778db56eeeecf2e716a72d25b91c49193fa1))
|
|
42
|
+
* Change all brand colour tokens to use semantic names ([#1820](https://github.com/Amsterdam/design-system/issues/1820)) ([778222b](https://github.com/Amsterdam/design-system/commit/778222b5f7176648c647315287f2e2ceff3de491))
|
|
43
|
+
* Combine contrast and inverse color options into a single prop ([#1822](https://github.com/Amsterdam/design-system/issues/1822)) ([51640be](https://github.com/Amsterdam/design-system/commit/51640bed21deee54d5dddcbaa22e2213155cd08a))
|
|
44
|
+
* Consolidate Grid Space and Component Space into one set of spacing tokens ([#1910](https://github.com/Amsterdam/design-system/issues/1910)) ([f36e985](https://github.com/Amsterdam/design-system/commit/f36e9855c78f582df95fa0906f0849c2832c25a3))
|
|
45
|
+
* **Description List:** Rename values for terms column widths ([#1942](https://github.com/Amsterdam/design-system/issues/1942)) ([e1a9669](https://github.com/Amsterdam/design-system/commit/e1a9669925927f1608433a4ae68676b925ba8bd2))
|
|
46
|
+
* **Dialog:** Change background colour of backdrop and add token for it ([#1876](https://github.com/Amsterdam/design-system/issues/1876)) ([d071bb4](https://github.com/Amsterdam/design-system/commit/d071bb4149d2789d967abcdb84ccdfa4d5b7aecc))
|
|
47
|
+
* **Footer:** add FooterMenu component to replace PageMenu in Footer ([#1871](https://github.com/Amsterdam/design-system/issues/1871)) ([85e0f0f](https://github.com/Amsterdam/design-system/commit/85e0f0f8c7fd9c281ba68155999e835921e4443d))
|
|
48
|
+
* **Header:** Add responsive version of Amsterdam Logo, remove Heading level 1 ([#1880](https://github.com/Amsterdam/design-system/issues/1880)) ([7de8138](https://github.com/Amsterdam/design-system/commit/7de813861a565da89fee246731dc1525bc5d2643))
|
|
49
|
+
* Move alert icon into thick left border ([#1792](https://github.com/Amsterdam/design-system/issues/1792)) ([ec53af7](https://github.com/Amsterdam/design-system/commit/ec53af73d05f22f5e077efdf3ce9a73ed4d7e235))
|
|
50
|
+
* **Pagination:** Use links instead of buttons ([#1821](https://github.com/Amsterdam/design-system/issues/1821)) ([6980251](https://github.com/Amsterdam/design-system/commit/698025132af2c0b944e9cc99f9754b065127fb68))
|
|
51
|
+
* Remove action tokens, add and implement cursor tokens ([#1860](https://github.com/Amsterdam/design-system/issues/1860)) ([40a04a8](https://github.com/Amsterdam/design-system/commit/40a04a88e8c5829df54eb3a6ca338557249aec5d))
|
|
52
|
+
* Rename and document common tokens for links ([#1870](https://github.com/Amsterdam/design-system/issues/1870)) ([551743d](https://github.com/Amsterdam/design-system/commit/551743d11436ff2363f8dd1187afe166e6c4a02b))
|
|
53
|
+
* Rename Form Error List to Invalid Form Alert ([#1835](https://github.com/Amsterdam/design-system/issues/1835)) ([e8d015a](https://github.com/Amsterdam/design-system/commit/e8d015ae6a1e785a29505c033f29cd67aaab3d66))
|
|
54
|
+
* Shorten size labels in border tokens ([#1941](https://github.com/Amsterdam/design-system/issues/1941)) ([fa154a6](https://github.com/Amsterdam/design-system/commit/fa154a6c96a11a43623f959a51f782abae27449e))
|
|
55
|
+
* Shorten size labels in prop values for Row and Column, space tokens and utility classes ([#1940](https://github.com/Amsterdam/design-system/issues/1940)) ([694987c](https://github.com/Amsterdam/design-system/commit/694987c88773983e4cd12d518cc957d34ec29d7e))
|
|
56
|
+
* Split typography tokens into ‘body text’ and ‘heading’ groups ([#1890](https://github.com/Amsterdam/design-system/issues/1890)) ([3126aa2](https://github.com/Amsterdam/design-system/commit/3126aa29d5aebccfca272892d55f140783a94d43))
|
|
57
|
+
* **Spotlight:** Use updated color names for lime and green and remove purple as an explicit option ([#1865](https://github.com/Amsterdam/design-system/issues/1865)) ([387ae45](https://github.com/Amsterdam/design-system/commit/387ae45ce263ae3b6a12fc9a3b22a37dc0aed997))
|
|
58
|
+
* **typography:** Improve line heights for all body text and headings ([#1894](https://github.com/Amsterdam/design-system/issues/1894)) ([8a57198](https://github.com/Amsterdam/design-system/commit/8a571988a8f11fb5aa1dfe550ca8b74e9d8b3e55))
|
|
59
|
+
* Update and document focus tokens ([#1919](https://github.com/Amsterdam/design-system/issues/1919)) ([4c85170](https://github.com/Amsterdam/design-system/commit/4c85170f2b8eec5ce956cecdbb41430ce2c37639))
|
|
60
|
+
* Update aspect ratio tokens and CSS utility classes ([#1913](https://github.com/Amsterdam/design-system/issues/1913)) ([968ef2b](https://github.com/Amsterdam/design-system/commit/968ef2bf053803c356e36424836fd9934da123fd))
|
|
61
|
+
* Update hyphenation tokens ([#1914](https://github.com/Amsterdam/design-system/issues/1914)) ([0c7f359](https://github.com/Amsterdam/design-system/commit/0c7f359ff094e281022441d171bd617047c660b2))
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
### Bug Fixes
|
|
65
|
+
|
|
66
|
+
* **Column, Row:** Do not use utility classes ([#1951](https://github.com/Amsterdam/design-system/issues/1951)) ([a5a74f8](https://github.com/Amsterdam/design-system/commit/a5a74f8bbb55ab54c7b179be29d4a804b088044a))
|
|
67
|
+
* **Dialog:** Prevent a focus indicator from being cut off ([#1879](https://github.com/Amsterdam/design-system/issues/1879)) ([336ff55](https://github.com/Amsterdam/design-system/commit/336ff554d2a4a213c1f62bd32b02219ca41a802c))
|
|
68
|
+
* **Dialog:** Update Dialog border to fix forced color mode ([#1893](https://github.com/Amsterdam/design-system/issues/1893)) ([8b83271](https://github.com/Amsterdam/design-system/commit/8b83271a06dbdef42600d82e92cd56f1ec7d5509))
|
|
69
|
+
* **Tabs:** Remove unnecessary token, reuse color value ([#1932](https://github.com/Amsterdam/design-system/issues/1932)) ([cabfd59](https://github.com/Amsterdam/design-system/commit/cabfd5967a9c0cb17ab0bac627f19261f29bcf2e))
|
|
70
|
+
|
|
6
71
|
## [0.14.0](https://github.com/Amsterdam/design-system/compare/design-system-tokens-v0.13.0...design-system-tokens-v0.14.0) (2025-01-10)
|
|
7
72
|
|
|
8
73
|
### ⚠ BREAKING CHANGES
|
package/README.md
CHANGED
|
@@ -80,15 +80,22 @@ Examples:
|
|
|
80
80
|
|
|
81
81
|
```css
|
|
82
82
|
:root {
|
|
83
|
-
--ams-color-
|
|
84
|
-
--ams-space-
|
|
83
|
+
--ams-color-feedback-error: #ec0000;
|
|
84
|
+
--ams-space-m: 1rem;
|
|
85
85
|
--ams-aspect-ratio-wide: 4/3;
|
|
86
|
-
--ams-border-width-
|
|
86
|
+
--ams-border-width-l: 0.1875rem;
|
|
87
87
|
}
|
|
88
88
|
```
|
|
89
89
|
|
|
90
90
|
Find the [list of brand tokens](https://github.com/Amsterdam/design-system/tree/main/proprietary/tokens/src/brand/ams) on GitHub.
|
|
91
91
|
|
|
92
|
+
##### Removing ‘default’ keys
|
|
93
|
+
|
|
94
|
+
Some brand tokens include a ‘default’ key in JSON to allow for additional variants, such as `ams.color.interactive.default` and `ams.color.interactive.disabled`
|
|
95
|
+
However, this key is not needed for collections of variables that are flat, like our CSS custom properties.
|
|
96
|
+
Therefore, we remove this key in non-nested variables.
|
|
97
|
+
For instance, `--ams-color-interactive` and `--ams-color-interactive-disabled`.
|
|
98
|
+
|
|
92
99
|
#### Common tokens
|
|
93
100
|
|
|
94
101
|
Related components share visual design characteristics.
|
|
@@ -104,8 +111,8 @@ The same goes for custom components that you may create in your application.
|
|
|
104
111
|
|
|
105
112
|
```css
|
|
106
113
|
.my-input {
|
|
107
|
-
color: var(--ams-
|
|
108
|
-
text-underline-offset: var(--ams-
|
|
114
|
+
color: var(--ams-links-color);
|
|
115
|
+
text-underline-offset: var(--ams-links-text-underline-offset);
|
|
109
116
|
}
|
|
110
117
|
```
|
|
111
118
|
|
|
@@ -160,7 +167,7 @@ Address these tokens through the `compact` namespace and do not use the spacious
|
|
|
160
167
|
@use "@amsterdam/design-system-tokens/dist/compact.scss";
|
|
161
168
|
|
|
162
169
|
.class {
|
|
163
|
-
padding-block: compact.$ams-space-
|
|
170
|
+
padding-block: compact.$ams-space-m;
|
|
164
171
|
}
|
|
165
172
|
```
|
|
166
173
|
|
|
@@ -175,7 +182,7 @@ Use ‘dot notation’ or square brackets to access the tokens.
|
|
|
175
182
|
import tokens from "@amsterdam/design-system-tokens/dist/index.json"
|
|
176
183
|
|
|
177
184
|
const buttonBackgroundColor = tokens.ams.color["primary-blue"]
|
|
178
|
-
const rowGap = tokens.ams.space.
|
|
185
|
+
const rowGap = tokens.ams.space.m
|
|
179
186
|
```
|
|
180
187
|
|
|
181
188
|
Import and merge the compact tokens if you need them.
|
package/build.js
CHANGED
|
@@ -1,4 +1,30 @@
|
|
|
1
|
+
import { camelCase, kebabCase } from 'change-case'
|
|
1
2
|
import StyleDictionary from 'style-dictionary'
|
|
3
|
+
import { transformTypes } from 'style-dictionary/enums'
|
|
4
|
+
|
|
5
|
+
// Remove last key if it is 'default' when transforming to kebab-case
|
|
6
|
+
// i.e. `ams.color.default` becomes `--ams-color`
|
|
7
|
+
StyleDictionary.registerTransform({
|
|
8
|
+
name: 'name/customKebab',
|
|
9
|
+
transform: function (token) {
|
|
10
|
+
const filteredPath = token.path[token.path.length - 1] === 'default' ? token.path.slice(0, -1) : token.path
|
|
11
|
+
|
|
12
|
+
return kebabCase(filteredPath.join(' '))
|
|
13
|
+
},
|
|
14
|
+
type: transformTypes.name,
|
|
15
|
+
})
|
|
16
|
+
|
|
17
|
+
// Remove last key if it is 'default' when transforming to camelCase
|
|
18
|
+
// i.e. `ams.color.default` becomes `amsColor`
|
|
19
|
+
StyleDictionary.registerTransform({
|
|
20
|
+
name: 'name/customCamel',
|
|
21
|
+
transform: function (token) {
|
|
22
|
+
const filteredPath = token.path[token.path.length - 1] === 'default' ? token.path.slice(0, -1) : token.path
|
|
23
|
+
|
|
24
|
+
return camelCase(filteredPath.join(' '))
|
|
25
|
+
},
|
|
26
|
+
type: transformTypes.name,
|
|
27
|
+
})
|
|
2
28
|
|
|
3
29
|
const modes = ['compact']
|
|
4
30
|
|
|
@@ -7,8 +33,6 @@ function generateSharedConfig(mode) {
|
|
|
7
33
|
|
|
8
34
|
return {
|
|
9
35
|
css: {
|
|
10
|
-
transforms: ['attribute/cti', 'name/kebab', 'color/hsl-4'],
|
|
11
|
-
transformGroup: 'css',
|
|
12
36
|
buildPath: 'dist/',
|
|
13
37
|
files: [
|
|
14
38
|
{
|
|
@@ -19,33 +43,34 @@ function generateSharedConfig(mode) {
|
|
|
19
43
|
},
|
|
20
44
|
},
|
|
21
45
|
],
|
|
46
|
+
transformGroup: 'css',
|
|
47
|
+
transforms: ['attribute/cti', 'name/customKebab', 'color/hsl-4'],
|
|
22
48
|
},
|
|
23
49
|
cssTheme: {
|
|
24
|
-
transforms: ['attribute/cti', 'name/kebab', 'color/hsl-4'],
|
|
25
50
|
buildPath: 'dist/',
|
|
26
51
|
files: [
|
|
27
52
|
{
|
|
28
53
|
destination: `${name}.theme.css`,
|
|
29
54
|
format: 'css/variables',
|
|
30
55
|
options: {
|
|
31
|
-
selector: `.ams-theme${name === 'index' ? '' : `--${name}`}`,
|
|
32
56
|
outputReferences: true,
|
|
57
|
+
selector: `.ams-theme${name === 'index' ? '' : `--${name}`}`,
|
|
33
58
|
},
|
|
34
59
|
},
|
|
35
60
|
],
|
|
61
|
+
transforms: ['attribute/cti', 'name/customKebab', 'color/hsl-4'],
|
|
36
62
|
},
|
|
37
63
|
js: {
|
|
38
|
-
transforms: ['attribute/cti', 'name/camel', 'color/hsl-4'],
|
|
39
64
|
buildPath: 'dist/',
|
|
40
65
|
files: [
|
|
41
66
|
{
|
|
42
|
-
format: 'javascript/es6',
|
|
43
67
|
destination: `${name}.mjs`,
|
|
68
|
+
format: 'javascript/es6',
|
|
44
69
|
},
|
|
45
70
|
],
|
|
71
|
+
transforms: ['attribute/cti', 'name/customCamel', 'color/hsl-4'],
|
|
46
72
|
},
|
|
47
73
|
json: {
|
|
48
|
-
transforms: ['attribute/cti', 'name/camel', 'color/hsl-4'],
|
|
49
74
|
buildPath: 'dist/',
|
|
50
75
|
files: [
|
|
51
76
|
{
|
|
@@ -53,9 +78,9 @@ function generateSharedConfig(mode) {
|
|
|
53
78
|
format: 'json/nested',
|
|
54
79
|
},
|
|
55
80
|
],
|
|
81
|
+
transforms: ['attribute/cti', 'name/camel', 'color/hsl-4'],
|
|
56
82
|
},
|
|
57
83
|
scss: {
|
|
58
|
-
transforms: ['attribute/cti', 'name/kebab', 'color/hsl-4'],
|
|
59
84
|
buildPath: 'dist/',
|
|
60
85
|
files: [
|
|
61
86
|
{
|
|
@@ -66,17 +91,18 @@ function generateSharedConfig(mode) {
|
|
|
66
91
|
},
|
|
67
92
|
},
|
|
68
93
|
],
|
|
94
|
+
transforms: ['attribute/cti', 'name/customKebab', 'color/hsl-4'],
|
|
69
95
|
},
|
|
70
96
|
typescript: {
|
|
71
|
-
transforms: ['attribute/cti', 'name/camel', 'color/hsl-4'],
|
|
72
|
-
transformGroup: 'js',
|
|
73
97
|
buildPath: 'dist/',
|
|
74
98
|
files: [
|
|
75
99
|
{
|
|
76
|
-
format: 'typescript/module-declarations',
|
|
77
100
|
destination: `${name}.d.ts`,
|
|
101
|
+
format: 'typescript/module-declarations',
|
|
78
102
|
},
|
|
79
103
|
],
|
|
104
|
+
transformGroup: 'js',
|
|
105
|
+
transforms: ['attribute/cti', 'name/camel', 'color/hsl-4'],
|
|
80
106
|
},
|
|
81
107
|
}
|
|
82
108
|
}
|
|
@@ -85,22 +111,19 @@ const defaultMode = new StyleDictionary({
|
|
|
85
111
|
log: {
|
|
86
112
|
verbosity: 'verbose',
|
|
87
113
|
},
|
|
114
|
+
platforms: generateSharedConfig(),
|
|
88
115
|
source: [
|
|
89
116
|
// exclude non-default modes from source
|
|
90
117
|
`./src/**/!(*.${modes.join(`|*.`)}).tokens.json`,
|
|
91
118
|
],
|
|
92
|
-
platforms: generateSharedConfig(),
|
|
93
119
|
})
|
|
94
120
|
|
|
95
121
|
defaultMode.buildAllPlatforms()
|
|
96
122
|
|
|
97
123
|
modes.map((mode) => {
|
|
98
124
|
const styleDictionary = new StyleDictionary({
|
|
99
|
-
log: {
|
|
100
|
-
verbosity: 'verbose',
|
|
101
|
-
},
|
|
102
|
-
source: [`./src/**/*.${mode}.tokens.json`],
|
|
103
125
|
platforms: generateSharedConfig(mode),
|
|
126
|
+
source: [`./src/**/*.${mode}.tokens.json`],
|
|
104
127
|
})
|
|
105
128
|
return styleDictionary.buildAllPlatforms()
|
|
106
129
|
})
|
package/dist/compact.css
CHANGED
|
@@ -3,22 +3,22 @@
|
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
5
|
:root {
|
|
6
|
-
--ams-space-xs: 0.25rem;
|
|
7
|
-
--ams-space-
|
|
8
|
-
--ams-space-
|
|
9
|
-
--ams-space-
|
|
10
|
-
--ams-space-xl:
|
|
11
|
-
--ams-space-
|
|
12
|
-
--ams-
|
|
13
|
-
--ams-
|
|
14
|
-
--ams-
|
|
15
|
-
--ams-
|
|
16
|
-
--ams-
|
|
17
|
-
--ams-
|
|
18
|
-
--ams-
|
|
19
|
-
--ams-
|
|
20
|
-
--ams-
|
|
21
|
-
--ams-
|
|
22
|
-
--ams-
|
|
23
|
-
--ams-grid-padding-inline: var(--ams-space-
|
|
6
|
+
--ams-space-xs: clamp(0.1875rem, 0.1719rem + 0.0781vw, 0.25rem);
|
|
7
|
+
--ams-space-s: clamp(0.375rem, 0.3438rem + 0.1563vw, 0.5rem);
|
|
8
|
+
--ams-space-m: clamp(0.75rem, 0.6875rem + 0.3125vw, 1rem);
|
|
9
|
+
--ams-space-l: clamp(1rem, 0.875rem + 0.625vw, 1.5rem);
|
|
10
|
+
--ams-space-xl: clamp(1.25rem, 1rem + 1.25vw, 2.25rem);
|
|
11
|
+
--ams-space-2xl: clamp(1.5rem, 1.125rem + 1.875vw, 3rem);
|
|
12
|
+
--ams-typography-body-text-font-size: 1rem;
|
|
13
|
+
--ams-typography-body-text-small-font-size: clamp(0.8889rem, calc(0.9141rem + -0.0253vw), 0.9091rem);
|
|
14
|
+
--ams-typography-body-text-large-font-size: clamp(1.1rem, calc(1.0938rem + 0.0313vw), 1.125rem);
|
|
15
|
+
--ams-typography-body-text-x-large-font-size: clamp(1.21rem, calc(1.1961rem + 0.0695vw), 1.2656rem);
|
|
16
|
+
--ams-typography-heading-0-font-size: clamp(1.6105rem, calc(1.5626rem + 0.2394vw), 1.802rem);
|
|
17
|
+
--ams-typography-heading-1-font-size: clamp(1.4641rem, calc(1.4297rem + 0.1721vw), 1.6018rem);
|
|
18
|
+
--ams-typography-heading-2-font-size: clamp(1.331rem, calc(1.3078rem + 0.116vw), 1.4238rem);
|
|
19
|
+
--ams-typography-heading-3-font-size: clamp(1.21rem, calc(1.1961rem + 0.0695vw), 1.2656rem);
|
|
20
|
+
--ams-typography-heading-4-font-size: clamp(1.1rem, calc(1.0938rem + 0.0313vw), 1.125rem);
|
|
21
|
+
--ams-typography-heading-5-font-size: 1rem;
|
|
22
|
+
--ams-typography-heading-6-font-size: clamp(0.8889rem, calc(0.9141rem + -0.0253vw), 0.9091rem);
|
|
23
|
+
--ams-grid-padding-inline: var(--ams-space-xl);
|
|
24
24
|
}
|
package/dist/compact.d.ts
CHANGED
|
@@ -18,20 +18,26 @@ declare const tokens: {
|
|
|
18
18
|
ams: {
|
|
19
19
|
space: {
|
|
20
20
|
xs: DesignToken;
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
21
|
+
s: DesignToken;
|
|
22
|
+
m: DesignToken;
|
|
23
|
+
l: DesignToken;
|
|
24
24
|
xl: DesignToken;
|
|
25
|
-
|
|
26
|
-
xs: DesignToken;
|
|
27
|
-
sm: DesignToken;
|
|
28
|
-
md: DesignToken;
|
|
29
|
-
lg: DesignToken;
|
|
30
|
-
xl: DesignToken;
|
|
31
|
-
};
|
|
25
|
+
"2xl": DesignToken;
|
|
32
26
|
};
|
|
33
|
-
|
|
34
|
-
|
|
27
|
+
typography: {
|
|
28
|
+
"body-text": {
|
|
29
|
+
"font-size": DesignToken;
|
|
30
|
+
small: {
|
|
31
|
+
"font-size": DesignToken;
|
|
32
|
+
};
|
|
33
|
+
large: {
|
|
34
|
+
"font-size": DesignToken;
|
|
35
|
+
};
|
|
36
|
+
"x-large": {
|
|
37
|
+
"font-size": DesignToken;
|
|
38
|
+
};
|
|
39
|
+
};
|
|
40
|
+
heading: {
|
|
35
41
|
"0": {
|
|
36
42
|
"font-size": DesignToken;
|
|
37
43
|
};
|
package/dist/compact.json
CHANGED
|
@@ -1,21 +1,27 @@
|
|
|
1
1
|
{
|
|
2
2
|
"ams": {
|
|
3
3
|
"space": {
|
|
4
|
-
"xs": "0.25rem",
|
|
5
|
-
"
|
|
6
|
-
"
|
|
7
|
-
"
|
|
8
|
-
"xl": "
|
|
9
|
-
"
|
|
10
|
-
"xs": "clamp(0.25rem, calc(0.390625vw - 0.015625rem), 0.625rem)",
|
|
11
|
-
"sm": "clamp(0.5rem, calc(0.78125vw - 0.03125rem), 1.25rem)",
|
|
12
|
-
"md": "clamp(1rem, calc(1.5625vw - 0.0625rem), 2.5rem)",
|
|
13
|
-
"lg": "clamp(1.5rem, calc(2.34375vw - 0.09375rem), 3.75rem)",
|
|
14
|
-
"xl": "clamp(2rem, calc(3.125vw - 0.125rem), 5rem)"
|
|
15
|
-
}
|
|
4
|
+
"xs": "clamp(0.1875rem, 0.1719rem + 0.0781vw, 0.25rem)",
|
|
5
|
+
"s": "clamp(0.375rem, 0.3438rem + 0.1563vw, 0.5rem)",
|
|
6
|
+
"m": "clamp(0.75rem, 0.6875rem + 0.3125vw, 1rem)",
|
|
7
|
+
"l": "clamp(1rem, 0.875rem + 0.625vw, 1.5rem)",
|
|
8
|
+
"xl": "clamp(1.25rem, 1rem + 1.25vw, 2.25rem)",
|
|
9
|
+
"2xl": "clamp(1.5rem, 1.125rem + 1.875vw, 3rem)"
|
|
16
10
|
},
|
|
17
|
-
"
|
|
18
|
-
"
|
|
11
|
+
"typography": {
|
|
12
|
+
"body-text": {
|
|
13
|
+
"font-size": "1rem",
|
|
14
|
+
"small": {
|
|
15
|
+
"font-size": "clamp(0.8889rem, calc(0.9141rem + -0.0253vw), 0.9091rem)"
|
|
16
|
+
},
|
|
17
|
+
"large": {
|
|
18
|
+
"font-size": "clamp(1.1rem, calc(1.0938rem + 0.0313vw), 1.125rem)"
|
|
19
|
+
},
|
|
20
|
+
"x-large": {
|
|
21
|
+
"font-size": "clamp(1.21rem, calc(1.1961rem + 0.0695vw), 1.2656rem)"
|
|
22
|
+
}
|
|
23
|
+
},
|
|
24
|
+
"heading": {
|
|
19
25
|
"0": {
|
|
20
26
|
"font-size": "clamp(1.6105rem, calc(1.5626rem + 0.2394vw), 1.802rem)"
|
|
21
27
|
},
|
|
@@ -40,7 +46,7 @@
|
|
|
40
46
|
}
|
|
41
47
|
},
|
|
42
48
|
"grid": {
|
|
43
|
-
"padding-inline": "clamp(
|
|
49
|
+
"padding-inline": "clamp(1.25rem, 1rem + 1.25vw, 2.25rem)"
|
|
44
50
|
}
|
|
45
51
|
}
|
|
46
52
|
}
|
package/dist/compact.mjs
CHANGED
|
@@ -2,31 +2,30 @@
|
|
|
2
2
|
* Do not edit directly, this file was auto-generated.
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
|
-
export const amsSpaceXs = "0.25rem";
|
|
6
|
-
export const
|
|
7
|
-
export const
|
|
8
|
-
export const
|
|
9
|
-
export const amsSpaceXl = "
|
|
10
|
-
export const
|
|
11
|
-
|
|
12
|
-
export const
|
|
13
|
-
"clamp(0.
|
|
14
|
-
export const
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
export const
|
|
5
|
+
export const amsSpaceXs = "clamp(0.1875rem, 0.1719rem + 0.0781vw, 0.25rem)";
|
|
6
|
+
export const amsSpaceS = "clamp(0.375rem, 0.3438rem + 0.1563vw, 0.5rem)";
|
|
7
|
+
export const amsSpaceM = "clamp(0.75rem, 0.6875rem + 0.3125vw, 1rem)";
|
|
8
|
+
export const amsSpaceL = "clamp(1rem, 0.875rem + 0.625vw, 1.5rem)";
|
|
9
|
+
export const amsSpaceXl = "clamp(1.25rem, 1rem + 1.25vw, 2.25rem)";
|
|
10
|
+
export const amsSpace_2xl = "clamp(1.5rem, 1.125rem + 1.875vw, 3rem)";
|
|
11
|
+
export const amsTypographyBodyTextFontSize = "1rem";
|
|
12
|
+
export const amsTypographyBodyTextSmallFontSize =
|
|
13
|
+
"clamp(0.8889rem, calc(0.9141rem + -0.0253vw), 0.9091rem)";
|
|
14
|
+
export const amsTypographyBodyTextLargeFontSize =
|
|
15
|
+
"clamp(1.1rem, calc(1.0938rem + 0.0313vw), 1.125rem)";
|
|
16
|
+
export const amsTypographyBodyTextXLargeFontSize =
|
|
17
|
+
"clamp(1.21rem, calc(1.1961rem + 0.0695vw), 1.2656rem)";
|
|
18
|
+
export const amsTypographyHeading_0FontSize =
|
|
19
19
|
"clamp(1.6105rem, calc(1.5626rem + 0.2394vw), 1.802rem)";
|
|
20
|
-
export const
|
|
20
|
+
export const amsTypographyHeading_1FontSize =
|
|
21
21
|
"clamp(1.4641rem, calc(1.4297rem + 0.1721vw), 1.6018rem)";
|
|
22
|
-
export const
|
|
22
|
+
export const amsTypographyHeading_2FontSize =
|
|
23
23
|
"clamp(1.331rem, calc(1.3078rem + 0.116vw), 1.4238rem)";
|
|
24
|
-
export const
|
|
24
|
+
export const amsTypographyHeading_3FontSize =
|
|
25
25
|
"clamp(1.21rem, calc(1.1961rem + 0.0695vw), 1.2656rem)";
|
|
26
|
-
export const
|
|
26
|
+
export const amsTypographyHeading_4FontSize =
|
|
27
27
|
"clamp(1.1rem, calc(1.0938rem + 0.0313vw), 1.125rem)";
|
|
28
|
-
export const
|
|
29
|
-
export const
|
|
28
|
+
export const amsTypographyHeading_5FontSize = "1rem";
|
|
29
|
+
export const amsTypographyHeading_6FontSize =
|
|
30
30
|
"clamp(0.8889rem, calc(0.9141rem + -0.0253vw), 0.9091rem)";
|
|
31
|
-
export const amsGridPaddingInline =
|
|
32
|
-
"clamp(1rem, calc(1.5625vw - 0.0625rem), 2.5rem)";
|
|
31
|
+
export const amsGridPaddingInline = "clamp(1.25rem, 1rem + 1.25vw, 2.25rem)";
|
package/dist/compact.scss
CHANGED
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
|
|
2
2
|
// Do not edit directly, this file was auto-generated.
|
|
3
3
|
|
|
4
|
-
$ams-space-xs: 0.25rem;
|
|
5
|
-
$ams-space-
|
|
6
|
-
$ams-space-
|
|
7
|
-
$ams-space-
|
|
8
|
-
$ams-space-xl:
|
|
9
|
-
$ams-space-
|
|
10
|
-
$ams-
|
|
11
|
-
$ams-
|
|
12
|
-
$ams-
|
|
13
|
-
$ams-
|
|
14
|
-
$ams-
|
|
15
|
-
$ams-
|
|
16
|
-
$ams-
|
|
17
|
-
$ams-
|
|
18
|
-
$ams-
|
|
19
|
-
$ams-
|
|
20
|
-
$ams-
|
|
21
|
-
$ams-grid-padding-inline: $ams-space-
|
|
4
|
+
$ams-space-xs: clamp(0.1875rem, 0.1719rem + 0.0781vw, 0.25rem);
|
|
5
|
+
$ams-space-s: clamp(0.375rem, 0.3438rem + 0.1563vw, 0.5rem);
|
|
6
|
+
$ams-space-m: clamp(0.75rem, 0.6875rem + 0.3125vw, 1rem);
|
|
7
|
+
$ams-space-l: clamp(1rem, 0.875rem + 0.625vw, 1.5rem);
|
|
8
|
+
$ams-space-xl: clamp(1.25rem, 1rem + 1.25vw, 2.25rem);
|
|
9
|
+
$ams-space-2xl: clamp(1.5rem, 1.125rem + 1.875vw, 3rem);
|
|
10
|
+
$ams-typography-body-text-font-size: 1rem;
|
|
11
|
+
$ams-typography-body-text-small-font-size: clamp(0.8889rem, calc(0.9141rem + -0.0253vw), 0.9091rem);
|
|
12
|
+
$ams-typography-body-text-large-font-size: clamp(1.1rem, calc(1.0938rem + 0.0313vw), 1.125rem);
|
|
13
|
+
$ams-typography-body-text-x-large-font-size: clamp(1.21rem, calc(1.1961rem + 0.0695vw), 1.2656rem);
|
|
14
|
+
$ams-typography-heading-0-font-size: clamp(1.6105rem, calc(1.5626rem + 0.2394vw), 1.802rem);
|
|
15
|
+
$ams-typography-heading-1-font-size: clamp(1.4641rem, calc(1.4297rem + 0.1721vw), 1.6018rem);
|
|
16
|
+
$ams-typography-heading-2-font-size: clamp(1.331rem, calc(1.3078rem + 0.116vw), 1.4238rem);
|
|
17
|
+
$ams-typography-heading-3-font-size: clamp(1.21rem, calc(1.1961rem + 0.0695vw), 1.2656rem);
|
|
18
|
+
$ams-typography-heading-4-font-size: clamp(1.1rem, calc(1.0938rem + 0.0313vw), 1.125rem);
|
|
19
|
+
$ams-typography-heading-5-font-size: 1rem;
|
|
20
|
+
$ams-typography-heading-6-font-size: clamp(0.8889rem, calc(0.9141rem + -0.0253vw), 0.9091rem);
|
|
21
|
+
$ams-grid-padding-inline: $ams-space-xl;
|
package/dist/compact.theme.css
CHANGED
|
@@ -3,22 +3,22 @@
|
|
|
3
3
|
*/
|
|
4
4
|
|
|
5
5
|
.ams-theme--compact {
|
|
6
|
-
--ams-space-xs: 0.25rem;
|
|
7
|
-
--ams-space-
|
|
8
|
-
--ams-space-
|
|
9
|
-
--ams-space-
|
|
10
|
-
--ams-space-xl:
|
|
11
|
-
--ams-space-
|
|
12
|
-
--ams-
|
|
13
|
-
--ams-
|
|
14
|
-
--ams-
|
|
15
|
-
--ams-
|
|
16
|
-
--ams-
|
|
17
|
-
--ams-
|
|
18
|
-
--ams-
|
|
19
|
-
--ams-
|
|
20
|
-
--ams-
|
|
21
|
-
--ams-
|
|
22
|
-
--ams-
|
|
23
|
-
--ams-grid-padding-inline: var(--ams-space-
|
|
6
|
+
--ams-space-xs: clamp(0.1875rem, 0.1719rem + 0.0781vw, 0.25rem);
|
|
7
|
+
--ams-space-s: clamp(0.375rem, 0.3438rem + 0.1563vw, 0.5rem);
|
|
8
|
+
--ams-space-m: clamp(0.75rem, 0.6875rem + 0.3125vw, 1rem);
|
|
9
|
+
--ams-space-l: clamp(1rem, 0.875rem + 0.625vw, 1.5rem);
|
|
10
|
+
--ams-space-xl: clamp(1.25rem, 1rem + 1.25vw, 2.25rem);
|
|
11
|
+
--ams-space-2xl: clamp(1.5rem, 1.125rem + 1.875vw, 3rem);
|
|
12
|
+
--ams-typography-body-text-font-size: 1rem;
|
|
13
|
+
--ams-typography-body-text-small-font-size: clamp(0.8889rem, calc(0.9141rem + -0.0253vw), 0.9091rem);
|
|
14
|
+
--ams-typography-body-text-large-font-size: clamp(1.1rem, calc(1.0938rem + 0.0313vw), 1.125rem);
|
|
15
|
+
--ams-typography-body-text-x-large-font-size: clamp(1.21rem, calc(1.1961rem + 0.0695vw), 1.2656rem);
|
|
16
|
+
--ams-typography-heading-0-font-size: clamp(1.6105rem, calc(1.5626rem + 0.2394vw), 1.802rem);
|
|
17
|
+
--ams-typography-heading-1-font-size: clamp(1.4641rem, calc(1.4297rem + 0.1721vw), 1.6018rem);
|
|
18
|
+
--ams-typography-heading-2-font-size: clamp(1.331rem, calc(1.3078rem + 0.116vw), 1.4238rem);
|
|
19
|
+
--ams-typography-heading-3-font-size: clamp(1.21rem, calc(1.1961rem + 0.0695vw), 1.2656rem);
|
|
20
|
+
--ams-typography-heading-4-font-size: clamp(1.1rem, calc(1.0938rem + 0.0313vw), 1.125rem);
|
|
21
|
+
--ams-typography-heading-5-font-size: 1rem;
|
|
22
|
+
--ams-typography-heading-6-font-size: clamp(0.8889rem, calc(0.9141rem + -0.0253vw), 0.9091rem);
|
|
23
|
+
--ams-grid-padding-inline: var(--ams-space-xl);
|
|
24
24
|
}
|