@graftwork/tokens 0.0.0-stage → 1.0.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 +10 -0
- package/LICENSE +21 -0
- package/dist/css/tailwind-theme.css +83 -0
- package/dist/css/tokens.css +285 -0
- package/dist/js/tokens.d.ts +93 -0
- package/dist/js/tokens.js +273 -0
- package/package.json +53 -3
- package/tokens/primitives/color.tokens.json +654 -0
- package/tokens/primitives/scale.tokens.json +273 -0
- package/tokens/semantic/base.tokens.json +214 -0
- package/tokens/semantic/color.dark.tokens.json +502 -0
- package/tokens/semantic/color.high-contrast.tokens.json +502 -0
- package/tokens/semantic/color.light.tokens.json +502 -0
- package/README.md +0 -3
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# @graftwork/tokens
|
|
2
|
+
|
|
3
|
+
## 1.0.0
|
|
4
|
+
|
|
5
|
+
### Major Changes
|
|
6
|
+
|
|
7
|
+
- [#3](https://github.com/graftwork-studio/design-system/pull/3) [`c403dbd`](https://github.com/graftwork-studio/design-system/commit/c403dbd160b5ff037a4754a3265a4651df00547b) Thanks [@david-kenny](https://github.com/david-kenny)! - First release of the Graftwork design system.
|
|
8
|
+
|
|
9
|
+
- `@graftwork/tokens`: design tokens in DTCG format for light, dark and high-contrast themes, built into CSS variables, a Tailwind v4 theme and JS constants. Every text and non-text colour pair is checked for contrast when the tokens build.
|
|
10
|
+
- `@graftwork/ui`: Button, Input, Select, Card, Table, BarChart and ThemeToggle, built on shadcn/ui with React Aria, plus the stylesheet apps import.
|
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 graftwork-studio
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
/* Generated by @graftwork/tokens. Do not edit. */
|
|
2
|
+
|
|
3
|
+
@theme inline {
|
|
4
|
+
--color-*: initial;
|
|
5
|
+
--radius-*: initial;
|
|
6
|
+
--text-*: initial;
|
|
7
|
+
--font-*: initial;
|
|
8
|
+
--font-weight-*: initial;
|
|
9
|
+
--leading-*: initial;
|
|
10
|
+
--breakpoint-*: initial;
|
|
11
|
+
--color-transparent: transparent;
|
|
12
|
+
--color-current: currentColor;
|
|
13
|
+
/* Spacing utilities (p-4, gap-2 …) are multiples of the space.2xs token, 0.25rem. */
|
|
14
|
+
--spacing: var(--gw-space-2xs);
|
|
15
|
+
--color-surface-default: var(--gw-color-surface-default);
|
|
16
|
+
--color-surface-raised: var(--gw-color-surface-raised);
|
|
17
|
+
--color-surface-subtle: var(--gw-color-surface-subtle);
|
|
18
|
+
--color-surface-overlay: var(--gw-color-surface-overlay);
|
|
19
|
+
--color-action-primary-bg: var(--gw-color-action-primary-bg);
|
|
20
|
+
--color-action-primary-bg-hover: var(--gw-color-action-primary-bg-hover);
|
|
21
|
+
--color-action-secondary-bg: var(--gw-color-action-secondary-bg);
|
|
22
|
+
--color-action-secondary-bg-hover: var(--gw-color-action-secondary-bg-hover);
|
|
23
|
+
--color-action-ghost-bg-hover: var(--gw-color-action-ghost-bg-hover);
|
|
24
|
+
--color-action-destructive-bg: var(--gw-color-action-destructive-bg);
|
|
25
|
+
--color-action-destructive-bg-hover: var(--gw-color-action-destructive-bg-hover);
|
|
26
|
+
--color-status-success-bg: var(--gw-color-status-success-bg);
|
|
27
|
+
--color-status-warning-bg: var(--gw-color-status-warning-bg);
|
|
28
|
+
--color-status-error-bg: var(--gw-color-status-error-bg);
|
|
29
|
+
--color-status-info-bg: var(--gw-color-status-info-bg);
|
|
30
|
+
--color-text-default: var(--gw-color-text-default);
|
|
31
|
+
--color-text-secondary: var(--gw-color-text-secondary);
|
|
32
|
+
--color-text-placeholder: var(--gw-color-text-placeholder);
|
|
33
|
+
--color-text-link: var(--gw-color-text-link);
|
|
34
|
+
--color-text-on-primary: var(--gw-color-text-on-primary);
|
|
35
|
+
--color-text-on-destructive: var(--gw-color-text-on-destructive);
|
|
36
|
+
--color-text-success: var(--gw-color-text-success);
|
|
37
|
+
--color-text-warning: var(--gw-color-text-warning);
|
|
38
|
+
--color-text-error: var(--gw-color-text-error);
|
|
39
|
+
--color-text-info: var(--gw-color-text-info);
|
|
40
|
+
--color-border-input: var(--gw-color-border-input);
|
|
41
|
+
--color-border-input-invalid: var(--gw-color-border-input-invalid);
|
|
42
|
+
--color-border-default: var(--gw-color-border-default);
|
|
43
|
+
--color-border-status-success: var(--gw-color-border-status-success);
|
|
44
|
+
--color-border-status-warning: var(--gw-color-border-status-warning);
|
|
45
|
+
--color-border-status-error: var(--gw-color-border-status-error);
|
|
46
|
+
--color-border-status-info: var(--gw-color-border-status-info);
|
|
47
|
+
--color-icon-default: var(--gw-color-icon-default);
|
|
48
|
+
--color-icon-brand: var(--gw-color-icon-brand);
|
|
49
|
+
--color-focus-ring: var(--gw-color-focus-ring);
|
|
50
|
+
--color-chart-series-1: var(--gw-color-chart-series-1);
|
|
51
|
+
--color-chart-series-2: var(--gw-color-chart-series-2);
|
|
52
|
+
--color-chart-series-3: var(--gw-color-chart-series-3);
|
|
53
|
+
--color-chart-series-4: var(--gw-color-chart-series-4);
|
|
54
|
+
--color-chart-grid: var(--gw-color-chart-grid);
|
|
55
|
+
--radius-sm: var(--gw-radius-sm);
|
|
56
|
+
--radius-md: var(--gw-radius-md);
|
|
57
|
+
--radius-lg: var(--gw-radius-lg);
|
|
58
|
+
--radius-xl: var(--gw-radius-xl);
|
|
59
|
+
--radius-full: var(--gw-radius-full);
|
|
60
|
+
--font-sans: var(--gw-font-family-sans);
|
|
61
|
+
--font-mono: var(--gw-font-family-mono);
|
|
62
|
+
--text-xs: var(--gw-font-size-xs);
|
|
63
|
+
--text-sm: var(--gw-font-size-sm);
|
|
64
|
+
--text-md: var(--gw-font-size-md);
|
|
65
|
+
--text-lg: var(--gw-font-size-lg);
|
|
66
|
+
--text-xl: var(--gw-font-size-xl);
|
|
67
|
+
--text-2xl: var(--gw-font-size-2xl);
|
|
68
|
+
--text-3xl: var(--gw-font-size-3xl);
|
|
69
|
+
--text-4xl: var(--gw-font-size-4xl);
|
|
70
|
+
--font-weight-regular: var(--gw-font-weight-regular);
|
|
71
|
+
--font-weight-medium: var(--gw-font-weight-medium);
|
|
72
|
+
--font-weight-semibold: var(--gw-font-weight-semibold);
|
|
73
|
+
--font-weight-bold: var(--gw-font-weight-bold);
|
|
74
|
+
--leading-body: var(--gw-font-line-height-body);
|
|
75
|
+
--leading-heading: var(--gw-font-line-height-heading);
|
|
76
|
+
--leading-ui: var(--gw-font-line-height-ui);
|
|
77
|
+
--spacing-target-min: var(--gw-target-min);
|
|
78
|
+
--spacing-target-compact: var(--gw-target-compact);
|
|
79
|
+
--breakpoint-sm: var(--gw-breakpoint-sm);
|
|
80
|
+
--breakpoint-md: var(--gw-breakpoint-md);
|
|
81
|
+
--breakpoint-lg: var(--gw-breakpoint-lg);
|
|
82
|
+
--breakpoint-xl: var(--gw-breakpoint-xl);
|
|
83
|
+
}
|
|
@@ -0,0 +1,285 @@
|
|
|
1
|
+
/* Generated by @graftwork/tokens. Do not edit. */
|
|
2
|
+
|
|
3
|
+
/* Light is the default. */
|
|
4
|
+
:root,
|
|
5
|
+
[data-theme="light"] {
|
|
6
|
+
color-scheme: light;
|
|
7
|
+
--gw-radius-sm: 4px;
|
|
8
|
+
--gw-radius-md: 6px;
|
|
9
|
+
--gw-radius-lg: 10px;
|
|
10
|
+
--gw-radius-xl: 14px;
|
|
11
|
+
--gw-radius-full: 9999px;
|
|
12
|
+
--gw-space-3xs: 0.125rem;
|
|
13
|
+
--gw-space-2xs: 0.25rem;
|
|
14
|
+
--gw-space-xs: 0.5rem;
|
|
15
|
+
--gw-space-sm: 0.75rem;
|
|
16
|
+
--gw-space-md: 1rem;
|
|
17
|
+
--gw-space-lg: 1.5rem;
|
|
18
|
+
--gw-space-xl: 2rem;
|
|
19
|
+
--gw-space-2xl: 3rem;
|
|
20
|
+
--gw-space-3xl: 4rem;
|
|
21
|
+
--gw-font-family-sans: "Noto Sans Variable", "Noto Sans", system-ui, sans-serif;
|
|
22
|
+
--gw-font-family-mono: ui-monospace, SFMono-Regular, Menlo, monospace;
|
|
23
|
+
--gw-font-size-xs: 0.75rem;
|
|
24
|
+
--gw-font-size-sm: 0.875rem;
|
|
25
|
+
--gw-font-size-md: 1rem;
|
|
26
|
+
--gw-font-size-lg: 1.125rem;
|
|
27
|
+
--gw-font-size-xl: 1.25rem;
|
|
28
|
+
--gw-font-size-2xl: 1.5rem;
|
|
29
|
+
--gw-font-size-3xl: 1.875rem;
|
|
30
|
+
--gw-font-size-4xl: 2.25rem;
|
|
31
|
+
--gw-font-weight-regular: 400;
|
|
32
|
+
--gw-font-weight-medium: 500;
|
|
33
|
+
--gw-font-weight-semibold: 600;
|
|
34
|
+
--gw-font-weight-bold: 700;
|
|
35
|
+
--gw-font-line-height-body: 1.5;
|
|
36
|
+
--gw-font-line-height-heading: 1.25;
|
|
37
|
+
--gw-font-line-height-ui: 1.35;
|
|
38
|
+
--gw-paragraph-spacing-body: 2.25rem;
|
|
39
|
+
--gw-focus-ring-width: 2px;
|
|
40
|
+
--gw-focus-ring-offset: 2px;
|
|
41
|
+
--gw-target-min: 2.75rem;
|
|
42
|
+
--gw-target-compact: 1.5rem;
|
|
43
|
+
--gw-scroll-padding-top: 4.5rem;
|
|
44
|
+
--gw-scroll-padding-bottom: 4rem;
|
|
45
|
+
--gw-motion-duration-fast: 100ms;
|
|
46
|
+
--gw-motion-duration-normal: 200ms;
|
|
47
|
+
--gw-motion-duration-slow: 300ms;
|
|
48
|
+
--gw-motion-duration-fade: 150ms;
|
|
49
|
+
--gw-breakpoint-sm: 40rem;
|
|
50
|
+
--gw-breakpoint-md: 48rem;
|
|
51
|
+
--gw-breakpoint-lg: 64rem;
|
|
52
|
+
--gw-breakpoint-xl: 80rem;
|
|
53
|
+
--gw-color-surface-default: #ffffff;
|
|
54
|
+
--gw-color-surface-raised: #ffffff;
|
|
55
|
+
--gw-color-surface-subtle: #f4f4f4;
|
|
56
|
+
--gw-color-surface-overlay: #ffffff;
|
|
57
|
+
--gw-color-action-primary-bg: #0458a1;
|
|
58
|
+
--gw-color-action-primary-bg-hover: #034580;
|
|
59
|
+
--gw-color-action-secondary-bg: #ffffff;
|
|
60
|
+
--gw-color-action-secondary-bg-hover: #f4f4f4;
|
|
61
|
+
--gw-color-action-ghost-bg-hover: #f4f4f4;
|
|
62
|
+
--gw-color-action-destructive-bg: #a21a1e;
|
|
63
|
+
--gw-color-action-destructive-bg-hover: #811316;
|
|
64
|
+
--gw-color-status-success-bg: #eefbf1;
|
|
65
|
+
--gw-color-status-warning-bg: #fff5ea;
|
|
66
|
+
--gw-color-status-error-bg: #fff4f2;
|
|
67
|
+
--gw-color-status-info-bg: #f1f7ff;
|
|
68
|
+
--gw-color-text-default: #0a0a0a;
|
|
69
|
+
--gw-color-text-secondary: #525252;
|
|
70
|
+
--gw-color-text-placeholder: #525252;
|
|
71
|
+
--gw-color-text-link: #034580;
|
|
72
|
+
--gw-color-text-on-primary: #ffffff;
|
|
73
|
+
--gw-color-text-on-destructive: #ffffff;
|
|
74
|
+
--gw-color-text-success: #005428;
|
|
75
|
+
--gw-color-text-warning: #613c00;
|
|
76
|
+
--gw-color-text-error: #811316;
|
|
77
|
+
--gw-color-text-info: #034580;
|
|
78
|
+
--gw-color-border-input: #737373;
|
|
79
|
+
--gw-color-border-input-invalid: #a21a1e;
|
|
80
|
+
--gw-color-border-default: #e5e5e5;
|
|
81
|
+
--gw-color-border-status-success: #8bd5a0;
|
|
82
|
+
--gw-color-border-status-warning: #ecb573;
|
|
83
|
+
--gw-color-border-status-error: #ffa69d;
|
|
84
|
+
--gw-color-border-status-info: #93c5ff;
|
|
85
|
+
--gw-color-icon-default: #525252;
|
|
86
|
+
--gw-color-icon-brand: #2883de;
|
|
87
|
+
--gw-color-focus-ring: #2883de;
|
|
88
|
+
--gw-color-chart-series-1: #2883de;
|
|
89
|
+
--gw-color-chart-series-2: #b87600;
|
|
90
|
+
--gw-color-chart-series-3: #525252;
|
|
91
|
+
--gw-color-chart-series-4: #008241;
|
|
92
|
+
--gw-color-chart-grid: #e5e5e5;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
/* Follow the operating system unless the user has chosen a theme. */
|
|
96
|
+
@media (prefers-color-scheme: dark) {
|
|
97
|
+
:root:not([data-theme]) {
|
|
98
|
+
color-scheme: dark;
|
|
99
|
+
--gw-color-surface-default: #0a0a0a;
|
|
100
|
+
--gw-color-surface-raised: #171717;
|
|
101
|
+
--gw-color-surface-subtle: #1e1e1e;
|
|
102
|
+
--gw-color-surface-overlay: #171717;
|
|
103
|
+
--gw-color-action-primary-bg: #5ca8fc;
|
|
104
|
+
--gw-color-action-primary-bg-hover: #93c5ff;
|
|
105
|
+
--gw-color-action-secondary-bg: #171717;
|
|
106
|
+
--gw-color-action-secondary-bg-hover: #1e1e1e;
|
|
107
|
+
--gw-color-action-ghost-bg-hover: #1e1e1e;
|
|
108
|
+
--gw-color-action-destructive-bg: #ff7269;
|
|
109
|
+
--gw-color-action-destructive-bg-hover: #ffa69d;
|
|
110
|
+
--gw-color-status-success-bg: #002a11;
|
|
111
|
+
--gw-color-status-warning-bg: #311c00;
|
|
112
|
+
--gw-color-status-error-bg: #460104;
|
|
113
|
+
--gw-color-status-info-bg: #002244;
|
|
114
|
+
--gw-color-text-default: #fafafa;
|
|
115
|
+
--gw-color-text-secondary: #d4d4d4;
|
|
116
|
+
--gw-color-text-placeholder: #d4d4d4;
|
|
117
|
+
--gw-color-text-link: #93c5ff;
|
|
118
|
+
--gw-color-text-on-primary: #0a0a0a;
|
|
119
|
+
--gw-color-text-on-destructive: #0a0a0a;
|
|
120
|
+
--gw-color-text-success: #8bd5a0;
|
|
121
|
+
--gw-color-text-warning: #ecb573;
|
|
122
|
+
--gw-color-text-error: #ffa69d;
|
|
123
|
+
--gw-color-text-info: #93c5ff;
|
|
124
|
+
--gw-color-border-input: #737373;
|
|
125
|
+
--gw-color-border-input-invalid: #ff7269;
|
|
126
|
+
--gw-color-border-default: #262626;
|
|
127
|
+
--gw-color-border-status-success: #006a34;
|
|
128
|
+
--gw-color-border-status-warning: #7a4d00;
|
|
129
|
+
--gw-color-border-status-error: #a21a1e;
|
|
130
|
+
--gw-color-border-status-info: #0458a1;
|
|
131
|
+
--gw-color-icon-default: #a1a1a1;
|
|
132
|
+
--gw-color-icon-brand: #2883de;
|
|
133
|
+
--gw-color-focus-ring: #5ca8fc;
|
|
134
|
+
--gw-color-chart-series-1: #5ca8fc;
|
|
135
|
+
--gw-color-chart-series-2: #d99435;
|
|
136
|
+
--gw-color-chart-series-3: #a1a1a1;
|
|
137
|
+
--gw-color-chart-series-4: #59bd7a;
|
|
138
|
+
--gw-color-chart-grid: #262626;
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
/* High contrast wins over dark when both are requested. */
|
|
143
|
+
@media (prefers-contrast: more) {
|
|
144
|
+
:root:not([data-theme]) {
|
|
145
|
+
color-scheme: light;
|
|
146
|
+
--gw-color-surface-default: #ffffff;
|
|
147
|
+
--gw-color-surface-raised: #ffffff;
|
|
148
|
+
--gw-color-surface-subtle: #fafafa;
|
|
149
|
+
--gw-color-surface-overlay: #ffffff;
|
|
150
|
+
--gw-color-action-primary-bg: #003362;
|
|
151
|
+
--gw-color-action-primary-bg-hover: #002244;
|
|
152
|
+
--gw-color-action-secondary-bg: #ffffff;
|
|
153
|
+
--gw-color-action-secondary-bg-hover: #f4f4f4;
|
|
154
|
+
--gw-color-action-ghost-bg-hover: #f4f4f4;
|
|
155
|
+
--gw-color-action-destructive-bg: #811316;
|
|
156
|
+
--gw-color-action-destructive-bg-hover: #620a0d;
|
|
157
|
+
--gw-color-status-success-bg: #eefbf1;
|
|
158
|
+
--gw-color-status-warning-bg: #fff5ea;
|
|
159
|
+
--gw-color-status-error-bg: #fff4f2;
|
|
160
|
+
--gw-color-status-info-bg: #f1f7ff;
|
|
161
|
+
--gw-color-text-default: #000000;
|
|
162
|
+
--gw-color-text-secondary: #262626;
|
|
163
|
+
--gw-color-text-placeholder: #262626;
|
|
164
|
+
--gw-color-text-link: #003362;
|
|
165
|
+
--gw-color-text-on-primary: #ffffff;
|
|
166
|
+
--gw-color-text-on-destructive: #ffffff;
|
|
167
|
+
--gw-color-text-success: #003e1c;
|
|
168
|
+
--gw-color-text-warning: #482c00;
|
|
169
|
+
--gw-color-text-error: #620a0d;
|
|
170
|
+
--gw-color-text-info: #003362;
|
|
171
|
+
--gw-color-border-input: #0a0a0a;
|
|
172
|
+
--gw-color-border-input-invalid: #620a0d;
|
|
173
|
+
--gw-color-border-default: #404040;
|
|
174
|
+
--gw-color-border-status-success: #005428;
|
|
175
|
+
--gw-color-border-status-warning: #613c00;
|
|
176
|
+
--gw-color-border-status-error: #811316;
|
|
177
|
+
--gw-color-border-status-info: #034580;
|
|
178
|
+
--gw-color-icon-default: #171717;
|
|
179
|
+
--gw-color-icon-brand: #0458a1;
|
|
180
|
+
--gw-color-focus-ring: #000000;
|
|
181
|
+
--gw-color-chart-series-1: #0458a1;
|
|
182
|
+
--gw-color-chart-series-2: #7a4d00;
|
|
183
|
+
--gw-color-chart-series-3: #262626;
|
|
184
|
+
--gw-color-chart-series-4: #005428;
|
|
185
|
+
--gw-color-chart-grid: #d4d4d4;
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
/* Explicit choices from the theme toggle. */
|
|
190
|
+
[data-theme="dark"] {
|
|
191
|
+
color-scheme: dark;
|
|
192
|
+
--gw-color-surface-default: #0a0a0a;
|
|
193
|
+
--gw-color-surface-raised: #171717;
|
|
194
|
+
--gw-color-surface-subtle: #1e1e1e;
|
|
195
|
+
--gw-color-surface-overlay: #171717;
|
|
196
|
+
--gw-color-action-primary-bg: #5ca8fc;
|
|
197
|
+
--gw-color-action-primary-bg-hover: #93c5ff;
|
|
198
|
+
--gw-color-action-secondary-bg: #171717;
|
|
199
|
+
--gw-color-action-secondary-bg-hover: #1e1e1e;
|
|
200
|
+
--gw-color-action-ghost-bg-hover: #1e1e1e;
|
|
201
|
+
--gw-color-action-destructive-bg: #ff7269;
|
|
202
|
+
--gw-color-action-destructive-bg-hover: #ffa69d;
|
|
203
|
+
--gw-color-status-success-bg: #002a11;
|
|
204
|
+
--gw-color-status-warning-bg: #311c00;
|
|
205
|
+
--gw-color-status-error-bg: #460104;
|
|
206
|
+
--gw-color-status-info-bg: #002244;
|
|
207
|
+
--gw-color-text-default: #fafafa;
|
|
208
|
+
--gw-color-text-secondary: #d4d4d4;
|
|
209
|
+
--gw-color-text-placeholder: #d4d4d4;
|
|
210
|
+
--gw-color-text-link: #93c5ff;
|
|
211
|
+
--gw-color-text-on-primary: #0a0a0a;
|
|
212
|
+
--gw-color-text-on-destructive: #0a0a0a;
|
|
213
|
+
--gw-color-text-success: #8bd5a0;
|
|
214
|
+
--gw-color-text-warning: #ecb573;
|
|
215
|
+
--gw-color-text-error: #ffa69d;
|
|
216
|
+
--gw-color-text-info: #93c5ff;
|
|
217
|
+
--gw-color-border-input: #737373;
|
|
218
|
+
--gw-color-border-input-invalid: #ff7269;
|
|
219
|
+
--gw-color-border-default: #262626;
|
|
220
|
+
--gw-color-border-status-success: #006a34;
|
|
221
|
+
--gw-color-border-status-warning: #7a4d00;
|
|
222
|
+
--gw-color-border-status-error: #a21a1e;
|
|
223
|
+
--gw-color-border-status-info: #0458a1;
|
|
224
|
+
--gw-color-icon-default: #a1a1a1;
|
|
225
|
+
--gw-color-icon-brand: #2883de;
|
|
226
|
+
--gw-color-focus-ring: #5ca8fc;
|
|
227
|
+
--gw-color-chart-series-1: #5ca8fc;
|
|
228
|
+
--gw-color-chart-series-2: #d99435;
|
|
229
|
+
--gw-color-chart-series-3: #a1a1a1;
|
|
230
|
+
--gw-color-chart-series-4: #59bd7a;
|
|
231
|
+
--gw-color-chart-grid: #262626;
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
[data-theme="high-contrast"] {
|
|
235
|
+
color-scheme: light;
|
|
236
|
+
--gw-color-surface-default: #ffffff;
|
|
237
|
+
--gw-color-surface-raised: #ffffff;
|
|
238
|
+
--gw-color-surface-subtle: #fafafa;
|
|
239
|
+
--gw-color-surface-overlay: #ffffff;
|
|
240
|
+
--gw-color-action-primary-bg: #003362;
|
|
241
|
+
--gw-color-action-primary-bg-hover: #002244;
|
|
242
|
+
--gw-color-action-secondary-bg: #ffffff;
|
|
243
|
+
--gw-color-action-secondary-bg-hover: #f4f4f4;
|
|
244
|
+
--gw-color-action-ghost-bg-hover: #f4f4f4;
|
|
245
|
+
--gw-color-action-destructive-bg: #811316;
|
|
246
|
+
--gw-color-action-destructive-bg-hover: #620a0d;
|
|
247
|
+
--gw-color-status-success-bg: #eefbf1;
|
|
248
|
+
--gw-color-status-warning-bg: #fff5ea;
|
|
249
|
+
--gw-color-status-error-bg: #fff4f2;
|
|
250
|
+
--gw-color-status-info-bg: #f1f7ff;
|
|
251
|
+
--gw-color-text-default: #000000;
|
|
252
|
+
--gw-color-text-secondary: #262626;
|
|
253
|
+
--gw-color-text-placeholder: #262626;
|
|
254
|
+
--gw-color-text-link: #003362;
|
|
255
|
+
--gw-color-text-on-primary: #ffffff;
|
|
256
|
+
--gw-color-text-on-destructive: #ffffff;
|
|
257
|
+
--gw-color-text-success: #003e1c;
|
|
258
|
+
--gw-color-text-warning: #482c00;
|
|
259
|
+
--gw-color-text-error: #620a0d;
|
|
260
|
+
--gw-color-text-info: #003362;
|
|
261
|
+
--gw-color-border-input: #0a0a0a;
|
|
262
|
+
--gw-color-border-input-invalid: #620a0d;
|
|
263
|
+
--gw-color-border-default: #404040;
|
|
264
|
+
--gw-color-border-status-success: #005428;
|
|
265
|
+
--gw-color-border-status-warning: #613c00;
|
|
266
|
+
--gw-color-border-status-error: #811316;
|
|
267
|
+
--gw-color-border-status-info: #034580;
|
|
268
|
+
--gw-color-icon-default: #171717;
|
|
269
|
+
--gw-color-icon-brand: #0458a1;
|
|
270
|
+
--gw-color-focus-ring: #000000;
|
|
271
|
+
--gw-color-chart-series-1: #0458a1;
|
|
272
|
+
--gw-color-chart-series-2: #7a4d00;
|
|
273
|
+
--gw-color-chart-series-3: #262626;
|
|
274
|
+
--gw-color-chart-series-4: #005428;
|
|
275
|
+
--gw-color-chart-grid: #d4d4d4;
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
/* WCAG 2.3.3: no movement under reduced motion. Opacity fades keep their duration. */
|
|
279
|
+
@media (prefers-reduced-motion: reduce) {
|
|
280
|
+
:root {
|
|
281
|
+
--gw-motion-duration-fast: 0ms;
|
|
282
|
+
--gw-motion-duration-normal: 0ms;
|
|
283
|
+
--gw-motion-duration-slow: 0ms;
|
|
284
|
+
}
|
|
285
|
+
}
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
/* Generated by @graftwork/tokens. Do not edit. */
|
|
2
|
+
|
|
3
|
+
export type Theme = "light" | "dark" | "high-contrast";
|
|
4
|
+
export type TokenName =
|
|
5
|
+
| "color.surface.default"
|
|
6
|
+
| "color.surface.raised"
|
|
7
|
+
| "color.surface.subtle"
|
|
8
|
+
| "color.surface.overlay"
|
|
9
|
+
| "color.action.primary.bg"
|
|
10
|
+
| "color.action.primary.bg-hover"
|
|
11
|
+
| "color.action.secondary.bg"
|
|
12
|
+
| "color.action.secondary.bg-hover"
|
|
13
|
+
| "color.action.ghost.bg-hover"
|
|
14
|
+
| "color.action.destructive.bg"
|
|
15
|
+
| "color.action.destructive.bg-hover"
|
|
16
|
+
| "color.status.success.bg"
|
|
17
|
+
| "color.status.warning.bg"
|
|
18
|
+
| "color.status.error.bg"
|
|
19
|
+
| "color.status.info.bg"
|
|
20
|
+
| "color.text.default"
|
|
21
|
+
| "color.text.secondary"
|
|
22
|
+
| "color.text.placeholder"
|
|
23
|
+
| "color.text.link"
|
|
24
|
+
| "color.text.on-primary"
|
|
25
|
+
| "color.text.on-destructive"
|
|
26
|
+
| "color.text.success"
|
|
27
|
+
| "color.text.warning"
|
|
28
|
+
| "color.text.error"
|
|
29
|
+
| "color.text.info"
|
|
30
|
+
| "color.border.input"
|
|
31
|
+
| "color.border.input-invalid"
|
|
32
|
+
| "color.border.default"
|
|
33
|
+
| "color.border.status.success"
|
|
34
|
+
| "color.border.status.warning"
|
|
35
|
+
| "color.border.status.error"
|
|
36
|
+
| "color.border.status.info"
|
|
37
|
+
| "color.icon.default"
|
|
38
|
+
| "color.icon.brand"
|
|
39
|
+
| "color.focus.ring"
|
|
40
|
+
| "color.chart.series-1"
|
|
41
|
+
| "color.chart.series-2"
|
|
42
|
+
| "color.chart.series-3"
|
|
43
|
+
| "color.chart.series-4"
|
|
44
|
+
| "color.chart.grid"
|
|
45
|
+
| "radius.sm"
|
|
46
|
+
| "radius.md"
|
|
47
|
+
| "radius.lg"
|
|
48
|
+
| "radius.xl"
|
|
49
|
+
| "radius.full"
|
|
50
|
+
| "space.3xs"
|
|
51
|
+
| "space.2xs"
|
|
52
|
+
| "space.xs"
|
|
53
|
+
| "space.sm"
|
|
54
|
+
| "space.md"
|
|
55
|
+
| "space.lg"
|
|
56
|
+
| "space.xl"
|
|
57
|
+
| "space.2xl"
|
|
58
|
+
| "space.3xl"
|
|
59
|
+
| "font.family.sans"
|
|
60
|
+
| "font.family.mono"
|
|
61
|
+
| "font.size.xs"
|
|
62
|
+
| "font.size.sm"
|
|
63
|
+
| "font.size.md"
|
|
64
|
+
| "font.size.lg"
|
|
65
|
+
| "font.size.xl"
|
|
66
|
+
| "font.size.2xl"
|
|
67
|
+
| "font.size.3xl"
|
|
68
|
+
| "font.size.4xl"
|
|
69
|
+
| "font.weight.regular"
|
|
70
|
+
| "font.weight.medium"
|
|
71
|
+
| "font.weight.semibold"
|
|
72
|
+
| "font.weight.bold"
|
|
73
|
+
| "font.line-height.body"
|
|
74
|
+
| "font.line-height.heading"
|
|
75
|
+
| "font.line-height.ui"
|
|
76
|
+
| "paragraph-spacing.body"
|
|
77
|
+
| "focus.ring-width"
|
|
78
|
+
| "focus.ring-offset"
|
|
79
|
+
| "target.min"
|
|
80
|
+
| "target.compact"
|
|
81
|
+
| "scroll-padding.top"
|
|
82
|
+
| "scroll-padding.bottom"
|
|
83
|
+
| "motion.duration.fast"
|
|
84
|
+
| "motion.duration.normal"
|
|
85
|
+
| "motion.duration.slow"
|
|
86
|
+
| "motion.duration.fade"
|
|
87
|
+
| "breakpoint.sm"
|
|
88
|
+
| "breakpoint.md"
|
|
89
|
+
| "breakpoint.lg"
|
|
90
|
+
| "breakpoint.xl";
|
|
91
|
+
export declare const themes: readonly Theme[];
|
|
92
|
+
export declare const tokens: Record<Theme, Record<TokenName, string>>;
|
|
93
|
+
export declare function cssVar(path: TokenName): string;
|