@equinor/eds-tokens 2.2.0 → 2.3.0-beta.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.
Files changed (39) hide show
  1. package/README.md +11 -1
  2. package/build/js/spacing/comfortable.d.ts +0 -1
  3. package/build/js/spacing/comfortable.js +0 -1
  4. package/build/js/spacing/spacious.d.ts +0 -1
  5. package/build/js/spacing/spacious.js +0 -1
  6. package/build/ts/color/color-scheme/dark-color-scheme.ts +116 -0
  7. package/build/ts/color/color-scheme/dark-semantic.ts +162 -0
  8. package/build/ts/color/color-scheme/light-color-scheme.ts +116 -0
  9. package/build/ts/color/color-scheme/light-semantic.ts +162 -0
  10. package/build/ts/spacing/comfortable.ts +558 -0
  11. package/build/ts/spacing/index.ts +6 -0
  12. package/build/ts/spacing/spacious.ts +558 -0
  13. package/build/ts/typography/font-family-header.ts +122 -0
  14. package/build/ts/typography/font-family-ui.ts +122 -0
  15. package/build/ts/typography/font-size-2xl.ts +21 -0
  16. package/build/ts/typography/font-size-3xl.ts +21 -0
  17. package/build/ts/typography/font-size-4xl.ts +21 -0
  18. package/build/ts/typography/font-size-5xl.ts +21 -0
  19. package/build/ts/typography/font-size-6xl.ts +21 -0
  20. package/build/ts/typography/font-size-lg.ts +21 -0
  21. package/build/ts/typography/font-size-md.ts +21 -0
  22. package/build/ts/typography/font-size-sm.ts +21 -0
  23. package/build/ts/typography/font-size-xl.ts +21 -0
  24. package/build/ts/typography/font-size-xs.ts +21 -0
  25. package/build/ts/typography/font-weight-bolder.ts +9 -0
  26. package/build/ts/typography/font-weight-lighter.ts +9 -0
  27. package/build/ts/typography/font-weight-normal.ts +9 -0
  28. package/build/ts/typography/line-height-default.ts +9 -0
  29. package/build/ts/typography/line-height-squished.ts +9 -0
  30. package/build/ts/typography/tracking-loose.ts +9 -0
  31. package/build/ts/typography/tracking-normal.ts +9 -0
  32. package/build/ts/typography/tracking-tight.ts +9 -0
  33. package/build/ts/typography/tracking-wide.ts +9 -0
  34. package/instructions/colors-dynamic.md +29 -0
  35. package/instructions/colors-static.md +78 -0
  36. package/instructions/colors.md +13 -0
  37. package/instructions/typography.md +161 -0
  38. package/package.json +31 -28
  39. package/LICENSE +0 -21
package/README.md CHANGED
@@ -133,7 +133,17 @@ const darkSurface = darkSemanticNested.bg.neutral.surface // "#262626"
133
133
 
134
134
  * **Colors** -- Semantic color tokens for backgrounds, text, borders, and states
135
135
  * **Spacing** -- Layout spacing including inline, stack, inset, and border radius
136
- * **Typography** -- Font sizes, line heights, and font families (requires font files)
136
+ * **Typography** -- Font sizes, line heights, and font families (requires font files, see below)
137
+
138
+ ### Font loading
139
+
140
+ The typography system requires two font families: **Equinor** (headings) and **Inter** (UI/body text). Load both via the EDS variable font stylesheet:
141
+
142
+ ```html
143
+ <link rel="stylesheet" href="https://cdn.eds.equinor.com/font/eds-uprights-vf.css" />
144
+ ```
145
+
146
+ > **Note:** The older `equinor-font.css` only includes the Equinor font. Components using `data-font-family="ui"` (Button, TextField, Input, etc.) will fall back to a generic sans-serif if Inter is not loaded.
137
147
 
138
148
  ### Typography variables that adapt to data-attributes
139
149
  * Font family setup (UI and Header fonts)
@@ -2,7 +2,6 @@
2
2
  * Do not edit directly, this file was auto-generated.
3
3
  */
4
4
 
5
- export const DOCUMENTATION: string;
6
5
  export const SIZING_ICON_XS: number;
7
6
  export const SIZING_ICON_XS_CONTAINER: number;
8
7
  export const SIZING_ICON_SM: number;
@@ -2,7 +2,6 @@
2
2
  * Do not edit directly, this file was auto-generated.
3
3
  */
4
4
 
5
- export const DOCUMENTATION = "Comfortable";
6
5
  export const SIZING_ICON_XS = 14;
7
6
  export const SIZING_ICON_XS_CONTAINER = 8;
8
7
  export const SIZING_ICON_SM = 16;
@@ -2,7 +2,6 @@
2
2
  * Do not edit directly, this file was auto-generated.
3
3
  */
4
4
 
5
- export const DOCUMENTATION: string;
6
5
  export const SIZING_ICON_XS: number;
7
6
  export const SIZING_ICON_XS_CONTAINER: number;
8
7
  export const SIZING_ICON_SM: number;
@@ -2,7 +2,6 @@
2
2
  * Do not edit directly, this file was auto-generated.
3
3
  */
4
4
 
5
- export const DOCUMENTATION = "Spacious";
6
5
  export const SIZING_ICON_XS = 16;
7
6
  export const SIZING_ICON_XS_CONTAINER = 8;
8
7
  export const SIZING_ICON_SM = 18;
@@ -0,0 +1,116 @@
1
+ /**
2
+ * Do not edit directly, this file was auto-generated.
3
+ */
4
+
5
+ export const color = {
6
+ bgFloating: '#202223',
7
+ bgBackdrop: '#738696',
8
+ bgInput: '#0b0b0b',
9
+ borderFocus: '#2d8bc5',
10
+ textLink: '#5abbfb',
11
+ bgDisabled: '#525c65',
12
+ borderDisabled: '#738696',
13
+ textDisabled: '#738696',
14
+ accent: {
15
+ '1': '#0a0b0b',
16
+ '2': '#1e2323',
17
+ '3': '#3c6266',
18
+ '4': '#3e7378',
19
+ '5': '#41878e',
20
+ '6': '#3c6266',
21
+ '7': '#439199',
22
+ '8': '#6ec0c9',
23
+ '9': '#8cd2da',
24
+ '10': '#ace3e9',
25
+ '11': '#c7f1f6',
26
+ '12': '#bcebf1',
27
+ '13': '#e6ffff',
28
+ '14': '#2c3839',
29
+ '15': '#030303',
30
+ },
31
+ neutral: {
32
+ '1': '#0b0b0b',
33
+ '2': '#202223',
34
+ '3': '#525c65',
35
+ '4': '#5d6b76',
36
+ '5': '#6b7d8b',
37
+ '6': '#525c65',
38
+ '7': '#738696',
39
+ '8': '#9fb4c6',
40
+ '9': '#b4c7d7',
41
+ '10': '#cadae7',
42
+ '11': '#deeaf4',
43
+ '12': '#d6e3ee',
44
+ '13': '#f5fdff',
45
+ '14': '#333639',
46
+ '15': '#030303',
47
+ },
48
+ info: {
49
+ '1': '#0a0b0c',
50
+ '2': '#1d2226',
51
+ '3': '#33607e',
52
+ '4': '#316f98',
53
+ '5': '#2e82b7',
54
+ '6': '#33607e',
55
+ '7': '#2d8bc5',
56
+ '8': '#5abbfb',
57
+ '9': '#7dceff',
58
+ '10': '#a2e0ff',
59
+ '11': '#c4eeff',
60
+ '12': '#b7e8ff',
61
+ '13': '#ecffff',
62
+ '14': '#2a3741',
63
+ '15': '#030304',
64
+ },
65
+ success: {
66
+ '1': '#0a0c0a',
67
+ '2': '#1e231e',
68
+ '3': '#3c673a',
69
+ '4': '#3e793c',
70
+ '5': '#418e3e',
71
+ '6': '#3c673a',
72
+ '7': '#439941',
73
+ '8': '#6eca6a',
74
+ '9': '#8cdb87',
75
+ '10': '#aceba8',
76
+ '11': '#c7f7c3',
77
+ '12': '#bcf2b8',
78
+ '13': '#e6ffe3',
79
+ '14': '#2c392b',
80
+ '15': '#030303',
81
+ },
82
+ warning: {
83
+ '1': '#0c0b0a',
84
+ '2': '#27201b',
85
+ '3': '#7e4e25',
86
+ '4': '#97571b',
87
+ '5': '#b46201',
88
+ '6': '#7e4e25',
89
+ '7': '#c36800',
90
+ '8': '#f99539',
91
+ '9': '#ffad63',
92
+ '10': '#ffc791',
93
+ '11': '#ffddb9',
94
+ '12': '#ffd4aa',
95
+ '13': '#fff7e6',
96
+ '14': '#413226',
97
+ '15': '#040303',
98
+ },
99
+ danger: {
100
+ '1': '#0d0a0a',
101
+ '2': '#2a1e1e',
102
+ '3': '#923a3c',
103
+ '4': '#b03940',
104
+ '5': '#d43745',
105
+ '6': '#923a3c',
106
+ '7': '#e53748',
107
+ '8': '#ff8082',
108
+ '9': '#ffa3a1',
109
+ '10': '#ffc1bf',
110
+ '11': '#ffd9d7',
111
+ '12': '#ffd0ce',
112
+ '13': '#fff5f4',
113
+ '14': '#492d2c',
114
+ '15': '#040303',
115
+ },
116
+ } as const
@@ -0,0 +1,162 @@
1
+ /**
2
+ * Do not edit directly, this file was auto-generated.
3
+ */
4
+
5
+ export const color = {
6
+ bg: {
7
+ neutral: {
8
+ canvas: '#0b0b0b',
9
+ surface: '#202223',
10
+ fillMuted: {
11
+ default: '#525c65',
12
+ hover: '#5d6b76',
13
+ active: '#6b7d8b',
14
+ },
15
+ fillEmphasis: {
16
+ default: '#b4c7d7',
17
+ hover: '#cadae7',
18
+ active: '#deeaf4',
19
+ },
20
+ },
21
+ accent: {
22
+ canvas: '#0a0b0b',
23
+ surface: '#1e2323',
24
+ fillMuted: {
25
+ default: '#3c6266',
26
+ hover: '#3e7378',
27
+ active: '#41878e',
28
+ },
29
+ fillEmphasis: {
30
+ default: '#8cd2da',
31
+ hover: '#ace3e9',
32
+ active: '#c7f1f6',
33
+ },
34
+ },
35
+ success: {
36
+ canvas: '#0a0c0a',
37
+ surface: '#1e231e',
38
+ fillMuted: {
39
+ default: '#3c673a',
40
+ hover: '#3e793c',
41
+ active: '#418e3e',
42
+ },
43
+ fillEmphasis: {
44
+ default: '#8cdb87',
45
+ hover: '#aceba8',
46
+ active: '#c7f7c3',
47
+ },
48
+ },
49
+ info: {
50
+ canvas: '#0a0b0c',
51
+ surface: '#1d2226',
52
+ fillMuted: {
53
+ default: '#33607e',
54
+ hover: '#316f98',
55
+ active: '#2e82b7',
56
+ },
57
+ fillEmphasis: {
58
+ default: '#7dceff',
59
+ hover: '#a2e0ff',
60
+ active: '#c4eeff',
61
+ },
62
+ },
63
+ warning: {
64
+ canvas: '#0c0b0a',
65
+ surface: '#27201b',
66
+ fillMuted: {
67
+ default: '#7e4e25',
68
+ hover: '#97571b',
69
+ active: '#b46201',
70
+ },
71
+ fillEmphasis: {
72
+ default: '#ffad63',
73
+ hover: '#ffc791',
74
+ active: '#ffddb9',
75
+ },
76
+ },
77
+ danger: {
78
+ canvas: '#0d0a0a',
79
+ surface: '#2a1e1e',
80
+ fillMuted: {
81
+ default: '#923a3c',
82
+ hover: '#b03940',
83
+ active: '#d43745',
84
+ },
85
+ fillEmphasis: {
86
+ default: '#ffa3a1',
87
+ hover: '#ffc1bf',
88
+ active: '#ffd9d7',
89
+ },
90
+ },
91
+ },
92
+ border: {
93
+ neutral: {
94
+ subtle: '#525c65',
95
+ medium: '#738696',
96
+ strong: '#9fb4c6',
97
+ },
98
+ accent: {
99
+ subtle: '#3c6266',
100
+ medium: '#439199',
101
+ strong: '#6ec0c9',
102
+ },
103
+ success: {
104
+ subtle: '#3c673a',
105
+ medium: '#439941',
106
+ strong: '#6eca6a',
107
+ },
108
+ info: {
109
+ subtle: '#33607e',
110
+ medium: '#2d8bc5',
111
+ strong: '#5abbfb',
112
+ },
113
+ warning: {
114
+ subtle: '#7e4e25',
115
+ medium: '#c36800',
116
+ strong: '#f99539',
117
+ },
118
+ danger: {
119
+ subtle: '#923a3c',
120
+ medium: '#e53748',
121
+ strong: '#ff8082',
122
+ },
123
+ },
124
+ text: {
125
+ neutral: {
126
+ subtle: '#d6e3ee',
127
+ strong: '#f5fdff',
128
+ subtleOnEmphasis: '#333639',
129
+ strongOnEmphasis: '#030303',
130
+ },
131
+ accent: {
132
+ subtle: '#bcebf1',
133
+ strong: '#e6ffff',
134
+ subtleOnEmphasis: '#2c3839',
135
+ strongOnEmphasis: '#030303',
136
+ },
137
+ success: {
138
+ subtle: '#bcf2b8',
139
+ strong: '#e6ffe3',
140
+ subtleOnEmphasis: '#2c392b',
141
+ strongOnEmphasis: '#030303',
142
+ },
143
+ info: {
144
+ subtle: '#b7e8ff',
145
+ strong: '#ecffff',
146
+ subtleOnEmphasis: '#2a3741',
147
+ strongOnEmphasis: '#030304',
148
+ },
149
+ warning: {
150
+ subtle: '#ffd4aa',
151
+ strong: '#fff7e6',
152
+ subtleOnEmphasis: '#413226',
153
+ strongOnEmphasis: '#040303',
154
+ },
155
+ danger: {
156
+ subtle: '#ffd0ce',
157
+ strong: '#fff5f4',
158
+ subtleOnEmphasis: '#492d2c',
159
+ strongOnEmphasis: '#040303',
160
+ },
161
+ },
162
+ } as const
@@ -0,0 +1,116 @@
1
+ /**
2
+ * Do not edit directly, this file was auto-generated.
3
+ */
4
+
5
+ export const color = {
6
+ bgFloating: '#ffffff',
7
+ bgBackdrop: '#aeaeae',
8
+ bgInput: '#f5f5f5',
9
+ borderFocus: '#6fb6e9',
10
+ textLink: '#0070a9',
11
+ bgDisabled: '#e1e1e1',
12
+ borderDisabled: '#aeaeae',
13
+ textDisabled: '#aeaeae',
14
+ accent: {
15
+ '1': '#eaf8fa',
16
+ '2': '#f6ffff',
17
+ '3': '#cfe7e9',
18
+ '4': '#bbdbdf',
19
+ '5': '#a2cdd2',
20
+ '6': '#bbdbdf',
21
+ '7': '#7cbac1',
22
+ '8': '#21767e',
23
+ '9': '#206f77',
24
+ '10': '#205c62',
25
+ '11': '#20565c',
26
+ '12': '#1f6369',
27
+ '13': '#141f20',
28
+ '14': '#cae4e7',
29
+ '15': '#ffffff',
30
+ },
31
+ neutral: {
32
+ '1': '#f5f5f5',
33
+ '2': '#ffffff',
34
+ '3': '#e1e1e1',
35
+ '4': '#d4d4d4',
36
+ '5': '#c4c4c4',
37
+ '6': '#d4d4d4',
38
+ '7': '#aeaeae',
39
+ '8': '#696969',
40
+ '9': '#636363',
41
+ '10': '#525252',
42
+ '11': '#4d4d4d',
43
+ '12': '#585858',
44
+ '13': '#1d1d1d',
45
+ '14': '#dedede',
46
+ '15': '#ffffff',
47
+ },
48
+ info: {
49
+ '1': '#e7f8ff',
50
+ '2': '#f4ffff',
51
+ '3': '#cae6fa',
52
+ '4': '#b5daf5',
53
+ '5': '#99cbf0',
54
+ '6': '#b5daf5',
55
+ '7': '#6fb6e9',
56
+ '8': '#0070a9',
57
+ '9': '#006aa0',
58
+ '10': '#085883',
59
+ '11': '#0e5279',
60
+ '12': '#015e8d',
61
+ '13': '#121e27',
62
+ '14': '#c5e3f9',
63
+ '15': '#ffffff',
64
+ },
65
+ success: {
66
+ '1': '#eafbe8',
67
+ '2': '#f6fff5',
68
+ '3': '#cfeacc',
69
+ '4': '#bbe0b8',
70
+ '5': '#a2d49e',
71
+ '6': '#bbe0b8',
72
+ '7': '#7cc278',
73
+ '8': '#227e22',
74
+ '9': '#207720',
75
+ '10': '#20621f',
76
+ '11': '#215c1f',
77
+ '12': '#20691f',
78
+ '13': '#142114',
79
+ '14': '#cae8c7',
80
+ '15': '#ffffff',
81
+ },
82
+ warning: {
83
+ '1': '#fff1e2',
84
+ '2': '#fffcf0',
85
+ '3': '#fbdac1',
86
+ '4': '#f6caaa',
87
+ '5': '#f0b689',
88
+ '6': '#f6caaa',
89
+ '7': '#e89959',
90
+ '8': '#a34e00',
91
+ '9': '#9b4900',
92
+ '10': '#813e00',
93
+ '11': '#773a00',
94
+ '12': '#8a4100',
95
+ '13': '#27190e',
96
+ '14': '#fad6bc',
97
+ '15': '#ffffff',
98
+ },
99
+ danger: {
100
+ '1': '#ffecea',
101
+ '2': '#fff9f8',
102
+ '3': '#ffd0ce',
103
+ '4': '#ffbcba',
104
+ '5': '#ffa3a1',
105
+ '6': '#ffbcba',
106
+ '7': '#ff7a7d',
107
+ '8': '#c6002d',
108
+ '9': '#bc002a',
109
+ '10': '#9a1026',
110
+ '11': '#8e1525',
111
+ '12': '#a50827',
112
+ '13': '#2e1414',
113
+ '14': '#ffcbc9',
114
+ '15': '#ffffff',
115
+ },
116
+ } as const
@@ -0,0 +1,162 @@
1
+ /**
2
+ * Do not edit directly, this file was auto-generated.
3
+ */
4
+
5
+ export const color = {
6
+ bg: {
7
+ neutral: {
8
+ canvas: '#f5f5f5',
9
+ surface: '#ffffff',
10
+ fillMuted: {
11
+ default: '#e1e1e1',
12
+ hover: '#d4d4d4',
13
+ active: '#c4c4c4',
14
+ },
15
+ fillEmphasis: {
16
+ default: '#636363',
17
+ hover: '#525252',
18
+ active: '#4d4d4d',
19
+ },
20
+ },
21
+ accent: {
22
+ canvas: '#eaf8fa',
23
+ surface: '#f6ffff',
24
+ fillMuted: {
25
+ default: '#cfe7e9',
26
+ hover: '#bbdbdf',
27
+ active: '#a2cdd2',
28
+ },
29
+ fillEmphasis: {
30
+ default: '#206f77',
31
+ hover: '#205c62',
32
+ active: '#20565c',
33
+ },
34
+ },
35
+ success: {
36
+ canvas: '#eafbe8',
37
+ surface: '#f6fff5',
38
+ fillMuted: {
39
+ default: '#cfeacc',
40
+ hover: '#bbe0b8',
41
+ active: '#a2d49e',
42
+ },
43
+ fillEmphasis: {
44
+ default: '#207720',
45
+ hover: '#20621f',
46
+ active: '#215c1f',
47
+ },
48
+ },
49
+ info: {
50
+ canvas: '#e7f8ff',
51
+ surface: '#f4ffff',
52
+ fillMuted: {
53
+ default: '#cae6fa',
54
+ hover: '#b5daf5',
55
+ active: '#99cbf0',
56
+ },
57
+ fillEmphasis: {
58
+ default: '#006aa0',
59
+ hover: '#085883',
60
+ active: '#0e5279',
61
+ },
62
+ },
63
+ warning: {
64
+ canvas: '#fff1e2',
65
+ surface: '#fffcf0',
66
+ fillMuted: {
67
+ default: '#fbdac1',
68
+ hover: '#f6caaa',
69
+ active: '#f0b689',
70
+ },
71
+ fillEmphasis: {
72
+ default: '#9b4900',
73
+ hover: '#813e00',
74
+ active: '#773a00',
75
+ },
76
+ },
77
+ danger: {
78
+ canvas: '#ffecea',
79
+ surface: '#fff9f8',
80
+ fillMuted: {
81
+ default: '#ffd0ce',
82
+ hover: '#ffbcba',
83
+ active: '#ffa3a1',
84
+ },
85
+ fillEmphasis: {
86
+ default: '#bc002a',
87
+ hover: '#9a1026',
88
+ active: '#8e1525',
89
+ },
90
+ },
91
+ },
92
+ border: {
93
+ neutral: {
94
+ subtle: '#d4d4d4',
95
+ medium: '#aeaeae',
96
+ strong: '#696969',
97
+ },
98
+ accent: {
99
+ subtle: '#bbdbdf',
100
+ medium: '#7cbac1',
101
+ strong: '#21767e',
102
+ },
103
+ success: {
104
+ subtle: '#bbe0b8',
105
+ medium: '#7cc278',
106
+ strong: '#227e22',
107
+ },
108
+ info: {
109
+ subtle: '#b5daf5',
110
+ medium: '#6fb6e9',
111
+ strong: '#0070a9',
112
+ },
113
+ warning: {
114
+ subtle: '#f6caaa',
115
+ medium: '#e89959',
116
+ strong: '#a34e00',
117
+ },
118
+ danger: {
119
+ subtle: '#ffbcba',
120
+ medium: '#ff7a7d',
121
+ strong: '#c6002d',
122
+ },
123
+ },
124
+ text: {
125
+ neutral: {
126
+ subtle: '#585858',
127
+ strong: '#1d1d1d',
128
+ subtleOnEmphasis: '#dedede',
129
+ strongOnEmphasis: '#ffffff',
130
+ },
131
+ accent: {
132
+ subtle: '#1f6369',
133
+ strong: '#141f20',
134
+ subtleOnEmphasis: '#cae4e7',
135
+ strongOnEmphasis: '#ffffff',
136
+ },
137
+ success: {
138
+ subtle: '#20691f',
139
+ strong: '#142114',
140
+ subtleOnEmphasis: '#cae8c7',
141
+ strongOnEmphasis: '#ffffff',
142
+ },
143
+ info: {
144
+ subtle: '#015e8d',
145
+ strong: '#121e27',
146
+ subtleOnEmphasis: '#c5e3f9',
147
+ strongOnEmphasis: '#ffffff',
148
+ },
149
+ warning: {
150
+ subtle: '#8a4100',
151
+ strong: '#27190e',
152
+ subtleOnEmphasis: '#fad6bc',
153
+ strongOnEmphasis: '#ffffff',
154
+ },
155
+ danger: {
156
+ subtle: '#a50827',
157
+ strong: '#2e1414',
158
+ subtleOnEmphasis: '#ffcbc9',
159
+ strongOnEmphasis: '#ffffff',
160
+ },
161
+ },
162
+ } as const