@aurodesignsystem/design-tokens 4.3.0 → 4.4.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 +19 -0
- package/README.md +62 -52
- package/dist/tokens/CSSCustomProperties.css +2 -1
- package/dist/tokens/CSSSizeCustomProperties.css +2 -1
- package/dist/tokens/JSData--color.js +125 -125
- package/dist/tokens/JSONVariablesFlat.json +274 -0
- package/dist/tokens/JSONVariablesNested.json +522 -0
- package/dist/tokens/JSObject--allTokens.js +297 -274
- package/dist/tokens/JSObject--deprecated.js +78 -78
- package/dist/tokens/JSVariables--color.js +1 -1
- package/dist/tokens/SCSSVariableMap.scss +3 -1
- package/dist/tokens/SCSSVariables.scss +2 -1
- package/dist/tokens/SCSSVariablesMapFlat.scss +3 -1
- package/dist/tokens/SassCustomProperties.scss +2 -1
- package/dist/tokens/SassSizeCustomProperties.scss +2 -1
- package/dist/tokens/darkmode/CSSCustomProperties.css +1 -1
- package/dist/tokens/darkmode/JSDataColor.js +14 -14
- package/dist/tokens/darkmode/JSObject--allDarkTokens.js +14 -14
- package/dist/tokens/darkmode/JSVariablesColor.js +1 -1
- package/dist/tokens/darkmode/SCSSVariables.scss +1 -1
- package/dist/tokens/darkmode/SCSSVariablesMapFlat.scss +1 -1
- package/dist/tokens/darkmode/SassCustomProperties.scss +1 -1
- package/package.json +9 -8
- package/packageScripts/postinstall.mjs +1 -1
- package/src/size/radius.json +1 -1
- package/src/size/scale.json +6 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,24 @@
|
|
|
1
1
|
# Semantic Release Automated Changelog
|
|
2
2
|
|
|
3
|
+
# [4.4.0](https://github.com/AlaskaAirlines/AuroDesignTokens/compare/v4.3.1...v4.4.0) (2024-05-09)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* add support for JSON flat and nested [#144](https://github.com/AlaskaAirlines/AuroDesignTokens/issues/144) ([af7a657](https://github.com/AlaskaAirlines/AuroDesignTokens/commit/af7a657f49aa247172d7f862fbc175992049d7a4))
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Performance Improvements
|
|
12
|
+
|
|
13
|
+
* convert hard value to token [#124](https://github.com/AlaskaAirlines/AuroDesignTokens/issues/124) ([f54d4f4](https://github.com/AlaskaAirlines/AuroDesignTokens/commit/f54d4f485b15893bb454bc32fb3f7f789dca8b7e))
|
|
14
|
+
|
|
15
|
+
## [4.3.1](https://github.com/AlaskaAirlines/AuroDesignTokens/compare/v4.3.0...v4.3.1) (2024-01-29)
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
### Performance Improvements
|
|
19
|
+
|
|
20
|
+
* update postinstall message ref to tokens ([35e78c4](https://github.com/AlaskaAirlines/AuroDesignTokens/commit/35e78c4bf1d8d208000089a0581e7e1b219e4fd7))
|
|
21
|
+
|
|
3
22
|
# [4.3.0](https://github.com/AlaskaAirlines/AuroDesignTokens/compare/v4.2.0...v4.3.0) (2023-12-29)
|
|
4
23
|
|
|
5
24
|
|
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Auro Design Tokens
|
|
2
2
|
|
|
3
|
-
##
|
|
3
|
+
## Installation
|
|
4
4
|
|
|
5
5
|
[](https://github.com/AlaskaAirlines/AuroDesignTokens/actions/workflows/testPublish.yml)
|
|
6
6
|
[](https://www.npmjs.com/package/@aurodesignsystem/design-tokens)
|
|
@@ -10,88 +10,98 @@
|
|
|
10
10
|
$ npm i @aurodesignsystem/design-tokens
|
|
11
11
|
```
|
|
12
12
|
|
|
13
|
-
##
|
|
13
|
+
## Using Pre-processed Resources
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
Pre-processed resources are available in the `./dist/tokens` directory of the [npm package](https://www.npmjs.com/package/@aurodesignsystem/design-tokens).
|
|
16
16
|
|
|
17
17
|
```
|
|
18
18
|
└── tokens
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
19
|
+
├── CSSCustomProperties.css
|
|
20
|
+
├── CSSSizeCustomProperties.css
|
|
21
|
+
├── JSData--color.js
|
|
22
|
+
├── JSONVariablesFlat.json
|
|
23
|
+
├── JSONVariablesNested.json
|
|
24
|
+
├── JSObject--allTokens.js
|
|
25
|
+
├── JSObject--deprecated.js
|
|
26
|
+
├── JSVariables--color.js
|
|
27
|
+
├── SCSSVariableMap.scss
|
|
28
|
+
├── SCSSVariables.scss
|
|
29
|
+
├── SCSSVariablesMapFlat.scss
|
|
30
|
+
├── SassCustomProperties.scss
|
|
31
|
+
├── SassSizeCustomProperties.scss
|
|
32
|
+
└── darkmode
|
|
33
|
+
├── CSSCustomProperties.css
|
|
34
|
+
├── JSDataColor.js
|
|
35
|
+
├── JSObject--allDarkTokens.js
|
|
36
|
+
├── JSVariablesColor.js
|
|
37
|
+
├── SCSSVariables.scss
|
|
38
|
+
├── SCSSVariablesMapFlat.scss
|
|
39
|
+
└── SassCustomProperties.scss
|
|
38
40
|
```
|
|
39
41
|
|
|
40
42
|
### Resource Descriptions
|
|
41
43
|
|
|
42
|
-
|
|
|
43
|
-
|
|
44
|
-
| CSSCustomProperties
|
|
45
|
-
| CSSSizeCustomProperties
|
|
46
|
-
| JSData--color
|
|
47
|
-
|
|
|
48
|
-
|
|
|
49
|
-
|
|
|
50
|
-
|
|
|
51
|
-
|
|
|
52
|
-
|
|
|
53
|
-
|
|
|
54
|
-
|
|
|
55
|
-
|
|
44
|
+
| File | Syntax | Type | Status | Filter Type / Description |
|
|
45
|
+
|------------------------|-----------|--------------------|---------|-----------------------------|
|
|
46
|
+
| CSSCustomProperties | CSS | Custom properties | Current | All v4.0x release tokens |
|
|
47
|
+
| CSSSizeCustomProperties| CSS | Custom properties | Current | Filter: size, public |
|
|
48
|
+
| JSData--color | JS module | Color data | Current | Filter: color, current |
|
|
49
|
+
| JSONVariablesFlat | JSON Data | All data | Current | All v4.0x release tokens |
|
|
50
|
+
| JSONVariablesNested | JSON Data | All data | Current | All v4.0x release tokens |
|
|
51
|
+
| JSObject--deprecated | JS module | Deprecated tokens | Current | Filter: deprecated, public |
|
|
52
|
+
| JSObject--allTokens.js | JS module | All data | Current | All v4.0x release tokens |
|
|
53
|
+
| JSVariables--color | JS ES6 | Color data | Current | Filter: color |
|
|
54
|
+
| SCSSVariableMap | Sass | Sass variable map | Current | Filter: size, public |
|
|
55
|
+
| SCSSVariables | SCSS | Sass variables | Current | All v4.0x release tokens |
|
|
56
|
+
| SCSSVariablesMapFlat | SCSS | Sass variable map | Current | All v4.0x release tokens |
|
|
57
|
+
| SassCustomProperties | SCSS | Custom properties | Current | All v4.0x release tokens |
|
|
58
|
+
| SassSizeCustomProperties| Sass | Custom properties | Current | Filter: size, public |
|
|
56
59
|
|
|
57
60
|
### Migration from 3.x to 4.x
|
|
58
61
|
|
|
59
|
-
With the release of Auro Design Tokens 4.x a new variable namespace was introduced. The project has
|
|
60
|
-
|
|
61
|
-
Since not all Auro web components are using the new tokens, simply removing the 3.x version and replacing with the 4.x version will break your UI.
|
|
62
|
+
With the release of Auro Design Tokens 4.x, a new variable namespace was introduced. The project has replaced `--auro` with `--ds` to support upcoming theming capabilities.
|
|
62
63
|
|
|
63
|
-
|
|
64
|
+
Since not all Auro web components are using the new tokens, simply replacing the 3.x version with the 4.x version will break your UI.
|
|
64
65
|
|
|
65
|
-
|
|
66
|
-
1. Update to use the new `@aurodesignsystem/webcorestylesheets` which fully supports the new token naming spec.
|
|
67
|
-
1. Please review the [Deprecated tokens list](https://auro.alaskaair.com/getting-started/developers/design-tokens/deprecated) for a matrix of changes. Understand that some tokens have been removed from the project and need to be updated.
|
|
66
|
+
To ensure a smooth transition between the two sets of design tokens, we highly recommend the following approach:
|
|
68
67
|
|
|
69
|
-
|
|
68
|
+
1. Install the new `@aurodesignsystem/design-tokens@4.x` in your app, but DO NOT uninstall `@alaskaairux/design-tokens@3.15.5`.
|
|
69
|
+
2. Update to use the new `@aurodesignsystem/webcorestylesheets`, which fully supports the new token naming spec.
|
|
70
|
+
3. Review the [Deprecated tokens list](https://auro.alaskaair.com/getting-started/developers/design-tokens/deprecated) for a matrix of changes. Some tokens have been removed from the project and need to be updated.
|
|
70
71
|
|
|
72
|
+
By supporting both the legacy and new Auro design tokens in your project, you ensure a smooth transition until all Auro components have been updated and your project has also updated local SCSS/CSS files with the new references.
|
|
71
73
|
|
|
72
74
|
### Install with Sass
|
|
73
75
|
|
|
76
|
+
When working with Sass, the preprocessor scripting language, there are several options for incorporating design tokens into your project. First, ensure that all design tokens are included to fulfill CSS custom property requests. This can be achieved by importing the SCSS file as demonstrated below:
|
|
77
|
+
|
|
74
78
|
```scss
|
|
75
|
-
@import "~@aurodesignsystem/design-tokens/dist/tokens/
|
|
79
|
+
@import "~@aurodesignsystem/design-tokens/dist/tokens/SassCustomProperties.scss";
|
|
80
|
+
```
|
|
76
81
|
|
|
77
|
-
|
|
82
|
+
Even if Sass isn't utilized, `SassCustomProperties.scss` remains an option, though not mandatory. Alternatively, you can load all tokens using `CSSCustomProperties.css` anywhere within the project's header.
|
|
78
83
|
|
|
79
|
-
|
|
84
|
+
Moreover, if project specifications dictate the use of Sass variables, `SCSSVariables.scss` can be imported. This is necessary for projects utilizing WCSS due to a dependency on these variables.
|
|
85
|
+
|
|
86
|
+
```scss
|
|
87
|
+
@import "~@aurodesignsystem/design-tokens/dist/tokens/SCSSVariables.scss";
|
|
80
88
|
```
|
|
81
89
|
|
|
90
|
+
**NOTE:** When developing new UI code in Sass, it's still advisable to leverage CSS custom properties over Sass variables. See **Install with CSS** below.
|
|
91
|
+
|
|
82
92
|
### Install with CSS
|
|
83
93
|
|
|
84
|
-
|
|
94
|
+
For React or similar frameworks, simply import the CSS file directly from npm:
|
|
85
95
|
|
|
86
96
|
```js
|
|
87
97
|
import "@aurodesignsystem/design-tokens/dist/tokens/CSSCustomProperties.css"
|
|
88
98
|
```
|
|
89
99
|
|
|
90
|
-
For other frameworks,
|
|
100
|
+
For other frameworks, you'll need to copy the CSS file from the npm resource into your project using a build scenario.
|
|
91
101
|
|
|
92
102
|
### Install ESModules
|
|
93
103
|
|
|
94
|
-
|
|
104
|
+
In a webpack-supported application or a `type="module"` script:
|
|
95
105
|
|
|
96
106
|
```js
|
|
97
107
|
import { AuroColorAlertNotificationOnLight, AuroColorBorderErrorOnLight } from '@aurodesignsystem/design-tokens/dist/tokens/JSVariables--color.js';
|
|
@@ -99,10 +109,10 @@ import { AuroColorAlertNotificationOnLight, AuroColorBorderErrorOnLight } from '
|
|
|
99
109
|
|
|
100
110
|
### Install from CDN
|
|
101
111
|
|
|
102
|
-
Using the `https://cdn.jsdelivr.net/npm/` CDN,
|
|
112
|
+
Using the `https://cdn.jsdelivr.net/npm/` CDN, every file in the dist directory can be accessed like so:
|
|
103
113
|
|
|
104
114
|
```html
|
|
105
115
|
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm//@aurodesignsystem/design-tokens@latest/dist/tokens/CSSCustomProperties.css">
|
|
106
116
|
```
|
|
107
117
|
|
|
108
|
-
**
|
|
118
|
+
**Note:** Exercise caution when using this CDN solution. The Auro team is NOT responsible for the maintenance of the CDN `https://cdn.jsdelivr.net/` [uptime](https://www.isitupdown.com/jsdelivr) and are unable to effectively troubleshoot response issues. It is recommended to use the installed version of Auro Design Tokens for critical UIs. Any additional CDN solution must be maintained by the team using this solution per this [Discussion](https://github.com/orgs/AlaskaAirlines/discussions/513).
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Do not edit directly
|
|
3
|
-
* Generated on
|
|
3
|
+
* Generated on Thu, 09 May 2024 18:13:44 GMT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
6
|
:root {
|
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
--ds-border-radius: 0.375rem;
|
|
13
13
|
--ds-size-25: 0.125rem; /* 2px */
|
|
14
14
|
--ds-size-50: 0.25rem; /* 4px */
|
|
15
|
+
--ds-size-75: 0.375rem; /* 6px */
|
|
15
16
|
--ds-size-100: 0.5rem; /* 8px */
|
|
16
17
|
--ds-size-150: 0.75rem; /* 12px */
|
|
17
18
|
--ds-size-200: 1rem; /* 16px */
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Do not edit directly
|
|
3
|
-
* Generated on
|
|
3
|
+
* Generated on Thu, 09 May 2024 18:13:44 GMT
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
6
|
:root {
|
|
7
7
|
--ds-size-25: 0.125rem; /* 2px */
|
|
8
8
|
--ds-size-50: 0.25rem; /* 4px */
|
|
9
|
+
--ds-size-75: 0.375rem; /* 6px */
|
|
9
10
|
--ds-size-100: 0.5rem; /* 8px */
|
|
10
11
|
--ds-size-150: 0.75rem; /* 12px */
|
|
11
12
|
--ds-size-200: 1rem; /* 16px */
|