@solexllc/usx-theme 0.1.1 → 0.2.1
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/README.md +60 -2
- package/build.js +74 -7
- package/dist/_themes-registry.scss +948 -0
- package/dist/themes/all.css +677 -0
- package/dist/themes/aurora.css +77 -0
- package/dist/themes/borealis.css +104 -0
- package/dist/themes/carbon.css +79 -0
- package/dist/themes/forest.css +52 -0
- package/dist/themes/gov-uk.css +72 -0
- package/dist/themes/midnight.css +79 -0
- package/dist/themes/nasa.css +72 -0
- package/dist/themes/ocean.css +52 -0
- package/dist/themes/sunset.css +52 -0
- package/dist/themes/vads.css +38 -0
- package/package.json +16 -1
- package/src/_themes.scss +120 -0
- package/src/_variables.scss +0 -1
- package/src/derive.js +233 -0
- package/src/presets.js +348 -0
- package/src/theme-manifest.js +2 -2
package/src/presets.js
ADDED
|
@@ -0,0 +1,348 @@
|
|
|
1
|
+
// presets.js — the prebuilt theme palettes.
|
|
2
|
+
//
|
|
3
|
+
// Single source for: the Storybook toolbar theme toggle and Theme Playground
|
|
4
|
+
// preset buttons, and build.js, which resolves each preset (derive.js) and
|
|
5
|
+
// bakes it into dist/themes/<slug>.css, dist/themes/all.css and the Sass registry
|
|
6
|
+
// behind `pkg:@solexllc/usx-theme/themes`. Keys are manifest token names;
|
|
7
|
+
// values are CSS values (hex, `var(--usx-*)`, lengths, keywords).
|
|
8
|
+
|
|
9
|
+
// The header/footer border-color tokens are each individually configurable
|
|
10
|
+
// (see COMPONENT_COLOR_GROUPS' Header/Footer entries), but every preset and
|
|
11
|
+
// the randomize buttons treat them as one unit, all pointing at whatever
|
|
12
|
+
// color-border landed on — rather than 6 separately-varying colors — so a
|
|
13
|
+
// preset/randomized theme reads as one coherent divider color everywhere
|
|
14
|
+
// instead of a mismatched set.
|
|
15
|
+
const HEADER_FOOTER_BORDER_TOKENS = [
|
|
16
|
+
'usx-header-border',
|
|
17
|
+
'usx-header-nav-top-border',
|
|
18
|
+
'usx-header-nav-bottom-border',
|
|
19
|
+
'usx-footer-border',
|
|
20
|
+
'usx-footer-primary-section-border',
|
|
21
|
+
'usx-footer-secondary-section-border'
|
|
22
|
+
];
|
|
23
|
+
|
|
24
|
+
export function headerFooterBorderOverrides() {
|
|
25
|
+
return HEADER_FOOTER_BORDER_TOKENS.reduce((acc, name) => {
|
|
26
|
+
acc[name] = 'var(--usx-color-border)';
|
|
27
|
+
return acc;
|
|
28
|
+
}, {});
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
// Header background now defaults to transparent (real USWDS renders no
|
|
32
|
+
// explicit background there either), so any theme that wants a filled
|
|
33
|
+
// header/nav shell — i.e. every preset/randomize below except Default —
|
|
34
|
+
// must opt in explicitly. Nav now matches the header (surface-3); the
|
|
35
|
+
// hover-state background (usx-nav-link-hover-bg-color) is what provides
|
|
36
|
+
// the visibly distinct tone against that shared surface.
|
|
37
|
+
export function headerNavBackgroundOverrides() {
|
|
38
|
+
return {
|
|
39
|
+
'usx-header-bg': 'var(--usx-surface-3)',
|
|
40
|
+
'usx-header-nav-bg': 'var(--usx-surface-3)',
|
|
41
|
+
'usx-header-nav-bg-mobile': 'var(--usx-surface-3)'
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
// Themes with dark header/footer shells ship white logo artwork. Branding
|
|
46
|
+
// renders both variants and these tokens pick the one that reads against the
|
|
47
|
+
// shell — only used by presets whose header AND footer are both dark.
|
|
48
|
+
export function inverseLogoOverrides() {
|
|
49
|
+
return {
|
|
50
|
+
'usx-logo-display': 'none',
|
|
51
|
+
'usx-logo-inverse-display': 'block'
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export const PRESETS = {
|
|
56
|
+
// Left with no overrides at all — including the header/footer borders,
|
|
57
|
+
// which are transparent by default (real USWDS renders no border there).
|
|
58
|
+
Default: {},
|
|
59
|
+
Forest: {
|
|
60
|
+
'color-primary': '#2e7d32',
|
|
61
|
+
'color-secondary': '#00695c',
|
|
62
|
+
'color-accent-cool': '#81c784',
|
|
63
|
+
'color-accent-warm': '#ffb300',
|
|
64
|
+
'surface-3': '#f4faf4',
|
|
65
|
+
'usx-summary-box-bg': 'var(--usx-surface-3)',
|
|
66
|
+
'usx-summary-box-border-color': 'var(--usx-color-primary)',
|
|
67
|
+
...headerFooterBorderOverrides(),
|
|
68
|
+
...headerNavBackgroundOverrides()
|
|
69
|
+
},
|
|
70
|
+
Sunset: {
|
|
71
|
+
'color-primary': '#d84315',
|
|
72
|
+
'color-secondary': '#6a1b9a',
|
|
73
|
+
'color-accent-cool': '#ff8a65',
|
|
74
|
+
'color-accent-warm': '#ffd54f',
|
|
75
|
+
'surface-3': '#fdf6f1',
|
|
76
|
+
'usx-summary-box-bg': 'var(--usx-surface-3)',
|
|
77
|
+
'usx-summary-box-border-color': 'var(--usx-color-primary)',
|
|
78
|
+
...headerFooterBorderOverrides(),
|
|
79
|
+
...headerNavBackgroundOverrides()
|
|
80
|
+
},
|
|
81
|
+
Ocean: {
|
|
82
|
+
'color-primary': '#0891b2',
|
|
83
|
+
'color-secondary': '#4338ca',
|
|
84
|
+
'color-accent-cool': '#67e8f9',
|
|
85
|
+
'color-accent-warm': '#fb923c',
|
|
86
|
+
'surface-3': '#f0f9fb',
|
|
87
|
+
'usx-summary-box-bg': 'var(--usx-surface-3)',
|
|
88
|
+
'usx-summary-box-border-color': 'var(--usx-color-primary)',
|
|
89
|
+
...headerFooterBorderOverrides(),
|
|
90
|
+
...headerNavBackgroundOverrides()
|
|
91
|
+
},
|
|
92
|
+
// Built around a fixed, given set of state colors (sky blue / peach /
|
|
93
|
+
// teal / red-orange / violet) rather than starting from a theme palette
|
|
94
|
+
// and leaving the states at their defaults like the presets above — the
|
|
95
|
+
// theme colors here are chosen to echo those five hues instead.
|
|
96
|
+
Aurora: {
|
|
97
|
+
'color-primary': '#3457d5', // echoes the info blue as the brand anchor
|
|
98
|
+
'color-secondary': '#7c4dff', // brighter kin of the emergency violet
|
|
99
|
+
'color-accent-cool': '#00b8d9', // echoes the success teal
|
|
100
|
+
'color-accent-warm': '#ff8f6b', // saturated kin of the warning peach
|
|
101
|
+
'surface-3': '#f5f7fc',
|
|
102
|
+
'color-info': '#58b4ff',
|
|
103
|
+
'color-warning': '#fdb8ae',
|
|
104
|
+
'color-success': '#009ec1',
|
|
105
|
+
'color-error': '#e52207',
|
|
106
|
+
'color-emergency': '#5942d2',
|
|
107
|
+
'usx-accordion-icon-position': 'auto 1.25rem',
|
|
108
|
+
'usx-accordion-icon-padding-start': '1.25rem',
|
|
109
|
+
'usx-accordion-icon-padding-end': '3.5rem',
|
|
110
|
+
'usx-accordion-bg-hover': 'var(--usx-surface-3)',
|
|
111
|
+
'usx-summary-box-bg': 'var(--usx-surface-3)',
|
|
112
|
+
'usx-summary-box-border-color': 'var(--usx-color-primary)',
|
|
113
|
+
...headerFooterBorderOverrides(),
|
|
114
|
+
...headerNavBackgroundOverrides(),
|
|
115
|
+
},
|
|
116
|
+
// Aurora's dark counterpart — same fixed state colors, but the theme hues
|
|
117
|
+
// are brightened kin of Aurora's (rather than reused as-is) so they still
|
|
118
|
+
// read clearly against the near-black surfaces, and surface/border/text
|
|
119
|
+
// are flipped the same way Midnight/Carbon do below.
|
|
120
|
+
Borealis: {
|
|
121
|
+
'color-primary': '#5b7cfa',
|
|
122
|
+
'color-secondary': '#b98cff',
|
|
123
|
+
'color-accent-cool': '#2dd4bf',
|
|
124
|
+
'color-accent-warm': '#ffab91',
|
|
125
|
+
'surface-1': '#161a2e',
|
|
126
|
+
'surface-3': '#0b0e1c',
|
|
127
|
+
'surface-2': '#232849',
|
|
128
|
+
'text-ink': '#e6e8f5',
|
|
129
|
+
'text-muted': '#dcddff',
|
|
130
|
+
'text-subtle': '#aeafc9',
|
|
131
|
+
'text-inverse': '#161a2e',
|
|
132
|
+
'color-info': '#58b4ff',
|
|
133
|
+
'color-warning': '#fdb8ae',
|
|
134
|
+
'color-success': '#009ec1',
|
|
135
|
+
'color-error': '#e52207',
|
|
136
|
+
'color-emergency': '#5942d2',
|
|
137
|
+
'usx-accordion-icon-position': 'auto 1.25rem',
|
|
138
|
+
'usx-accordion-icon-padding-start': '1.25rem',
|
|
139
|
+
'usx-accordion-icon-padding-end': '3.5rem',
|
|
140
|
+
'usx-accordion-bg-hover': 'var(--usx-surface-3)',
|
|
141
|
+
'usx-summary-box-bg': '#101b33',
|
|
142
|
+
'usx-summary-box-border-color': '#5b7cfa',
|
|
143
|
+
'usx-link-text-visited': '#c9a8ff',
|
|
144
|
+
'usx-tooltip-bg': '#e6e8f5',
|
|
145
|
+
'usx-tooltip-text': '#0b0e1c',
|
|
146
|
+
'usx-banner-button-text': 'var(--usx-text-ink)',
|
|
147
|
+
// The date-picker toggle button's hover/active background defaults to
|
|
148
|
+
// color-base-light (#a9aeb1) — too close to this preset's light 'text-ink'
|
|
149
|
+
// color for the calendar icon to stay visible. color-base-dark (#565c65)
|
|
150
|
+
// is the mirrored mid-gray on the dark side of the same scale.
|
|
151
|
+
'usx-date-picker-button-hover-active-bg': '#565c65',
|
|
152
|
+
// Nav background defaults transparent; a filled card reads better
|
|
153
|
+
// against this preset's dark page background.
|
|
154
|
+
'usx-in-page-nav-bg': 'var(--usx-surface-2)',
|
|
155
|
+
...headerFooterBorderOverrides(),
|
|
156
|
+
...headerNavBackgroundOverrides(),
|
|
157
|
+
...inverseLogoOverrides()
|
|
158
|
+
},
|
|
159
|
+
// Dark themes: unlike the light presets above (which only nudge the page
|
|
160
|
+
// background), these also flip the surface/border/text tokens so cards,
|
|
161
|
+
// dividers and copy stay legible against a dark page.
|
|
162
|
+
Midnight: {
|
|
163
|
+
'color-primary': '#60a5fa',
|
|
164
|
+
'color-secondary': '#a78bfa',
|
|
165
|
+
'color-accent-cool': '#38bdf8',
|
|
166
|
+
'color-accent-warm': '#fbbf24',
|
|
167
|
+
'surface-1': '#1e293b',
|
|
168
|
+
'surface-3': '#0f172a',
|
|
169
|
+
'surface-2': '#334155',
|
|
170
|
+
'text-ink': '#e2e8f0',
|
|
171
|
+
'text-muted': '#c7c9da',
|
|
172
|
+
'text-subtle': '#aeafc9',
|
|
173
|
+
'text-inverse': '#1e293b',
|
|
174
|
+
'usx-summary-box-bg': '#0f1b2e',
|
|
175
|
+
'usx-summary-box-border-color': '#60a5fa',
|
|
176
|
+
'usx-link-text-visited': '#b39ddb',
|
|
177
|
+
'usx-tooltip-bg': '#e2e8f0',
|
|
178
|
+
'usx-tooltip-text': '#020617',
|
|
179
|
+
'usx-banner-button-text': 'var(--usx-text-ink)',
|
|
180
|
+
// See Borealis's comment above for why this can't just chain to
|
|
181
|
+
// color-base-light.
|
|
182
|
+
'usx-date-picker-button-hover-active-bg': '#565c65',
|
|
183
|
+
'usx-in-page-nav-bg': 'var(--usx-surface-2)',
|
|
184
|
+
...headerFooterBorderOverrides(),
|
|
185
|
+
...headerNavBackgroundOverrides(),
|
|
186
|
+
...inverseLogoOverrides(),
|
|
187
|
+
},
|
|
188
|
+
Carbon: {
|
|
189
|
+
'color-primary': '#fa9441',
|
|
190
|
+
'color-secondary': '#22d3ee',
|
|
191
|
+
'color-accent-cool': '#38bdf8',
|
|
192
|
+
'color-accent-warm': '#facc15',
|
|
193
|
+
'surface-1': '#1c1c1e',
|
|
194
|
+
'surface-3': '#121214',
|
|
195
|
+
'surface-2': '#3a3a3d',
|
|
196
|
+
'text-ink': '#e5e5e5',
|
|
197
|
+
'text-muted': '#c0c0c0',
|
|
198
|
+
'text-subtle': '#a3a3a3',
|
|
199
|
+
'text-inverse': '#1c1c1e',
|
|
200
|
+
'usx-summary-box-bg': '#241a10',
|
|
201
|
+
'usx-summary-box-border-color': '#fb923c',
|
|
202
|
+
'usx-link-text-visited': '#b39ddb',
|
|
203
|
+
'usx-tooltip-bg': '#e5e5e5',
|
|
204
|
+
'usx-tooltip-text': '#000000',
|
|
205
|
+
// See Borealis's comment above for why this can't just chain to
|
|
206
|
+
// color-base-light.
|
|
207
|
+
'usx-date-picker-button-hover-active-bg': '#565c65',
|
|
208
|
+
'usx-in-page-nav-bg': 'var(--usx-surface-2)',
|
|
209
|
+
...headerFooterBorderOverrides(),
|
|
210
|
+
...headerNavBackgroundOverrides(),
|
|
211
|
+
// Carbon wants the desktop nav bar one tone lighter than the header
|
|
212
|
+
// (surface-2), but the mobile drawer matching the header (surface-3).
|
|
213
|
+
'usx-header-nav-bg': 'var(--usx-surface-2)',
|
|
214
|
+
'usx-header-nav-bg-mobile': 'var(--usx-surface-3)',
|
|
215
|
+
// Overrides banner's own surface-2 default — Carbon wants the banner to
|
|
216
|
+
// match the header's surface-3 instead.
|
|
217
|
+
'usx-banner-bg': 'var(--usx-surface-3)',
|
|
218
|
+
'usx-banner-button-text': 'var(--usx-text-ink)',
|
|
219
|
+
...inverseLogoOverrides()
|
|
220
|
+
},
|
|
221
|
+
// The three presets below are sourced from real design systems/sites
|
|
222
|
+
// rather than invented palettes — VADS/GOVUK values come from each
|
|
223
|
+
// system's own documented color tokens; NASA's are pulled directly from
|
|
224
|
+
// nasa.gov's live rendered CSS (see that preset's own comment).
|
|
225
|
+
VADS: {
|
|
226
|
+
// VA.gov Design System (design.va.gov) semantic color tokens.
|
|
227
|
+
'color-primary': '#005ea2', // vads-color-primary (USWDS blue-vivid-60)
|
|
228
|
+
'color-secondary': '#00bde3', // vads-color-primary-alt (cyan-vivid-30)
|
|
229
|
+
'color-accent-cool': '#97d4ea', // vads-color-primary-alt-light
|
|
230
|
+
'color-accent-warm': '#bd5727', // vads-color-hub-careers (orange-warm-50)
|
|
231
|
+
'surface-3': '#f0f0f0', // vads-color-background-muted
|
|
232
|
+
'font-family': '"Source Sans Pro Web", "Source Sans Pro", "Helvetica Neue", Helvetica, Roboto, Arial, sans-serif', // real va.gov body font
|
|
233
|
+
'font-family-heading': 'Bitter, Georgia, Cambria, "Times New Roman", Times, serif', // real va.gov heading font — a distinct serif face
|
|
234
|
+
...headerFooterBorderOverrides(),
|
|
235
|
+
...headerNavBackgroundOverrides()
|
|
236
|
+
},
|
|
237
|
+
"GOV.UK": {
|
|
238
|
+
// GOV.UK Design System (design-system.service.gov.uk) web palette +
|
|
239
|
+
// functional colours.
|
|
240
|
+
'color-primary': '#1d70b8', // govuk-colour('blue') / functional brand
|
|
241
|
+
'color-secondary': '#0f7a52', // govuk-colour('green') — the "Start now" button
|
|
242
|
+
'color-accent-cool': '#8eb8dc', // govuk-colour('blue', $variant: 'tint-50')
|
|
243
|
+
'color-accent-warm': '#f47738', // govuk-colour('orange')
|
|
244
|
+
'surface-3': '#f4f8fb', // functional template-background
|
|
245
|
+
'color-border': '#cecece', // functional border
|
|
246
|
+
'color-focus': '#ffdd00', // functional focus — GOV.UK's signature yellow focus state
|
|
247
|
+
'font-family': '"GDS Transport", arial, sans-serif', // real gov.uk body/heading font
|
|
248
|
+
...headerFooterBorderOverrides(),
|
|
249
|
+
...headerNavBackgroundOverrides(),
|
|
250
|
+
// gov.uk's real header/nav bar is filled with brand blue, not a neutral
|
|
251
|
+
// surface — override past the shared surface-3 default to match.
|
|
252
|
+
'usx-header-bg': 'var(--usx-color-primary)',
|
|
253
|
+
'usx-header-nav-bg': 'var(--usx-color-primary)',
|
|
254
|
+
'usx-header-text': 'var(--usx-text-inverse)',
|
|
255
|
+
// text-subtle/text-muted are tuned for a light/neutral surface — real
|
|
256
|
+
// gov.uk nav links are white against the blue bar (verified live), and
|
|
257
|
+
// color-primary as a hover color would be invisible against the
|
|
258
|
+
// color-primary background it now sits on.
|
|
259
|
+
'usx-header-nav-link-text': 'var(--usx-text-inverse)',
|
|
260
|
+
'usx-header-nav-link-text-hover': 'var(--usx-text-inverse)',
|
|
261
|
+
'usx-header-secondary-link-text': 'var(--usx-text-ink)',
|
|
262
|
+
'usx-header-secondary-link-text-hover': 'var(--usx-text-ink)',
|
|
263
|
+
'usx-header-nav-bg-mobile': '#f4f8fb',
|
|
264
|
+
'usx-header-nav-link-text-mobile': '#1a65a6',
|
|
265
|
+
'usx-header-nav-link-text-hover-mobile': '#0f385c',
|
|
266
|
+
// GOV.UK famously never rounds a corner (buttons, inputs, panels, tags,
|
|
267
|
+
// checkboxes all render dead square — verified live on the design
|
|
268
|
+
// system's own component pages). Overriding the three base radius
|
|
269
|
+
// scales cascades to every component that chains to them; tile/badge
|
|
270
|
+
// are independent literals so need their own overrides.
|
|
271
|
+
'radius-field': '0', // buttons/inputs/textarea
|
|
272
|
+
'radius-box': '0', // summary box/alert/code/hero-callout/image
|
|
273
|
+
'radius-selector': '0', // tags/checkboxes
|
|
274
|
+
'usx-checkable-tile-radius': '0',
|
|
275
|
+
'usx-misc-banner-badge-radius': '0',
|
|
276
|
+
// Real GOV.UK form inputs render with a thick 2px black border — one of
|
|
277
|
+
// its most recognizable traits (verified on design-system.service.gov.uk).
|
|
278
|
+
'border-width-inputs': '2px',
|
|
279
|
+
// Real GOV.UK accordion sections are divided by a thin 1px rule (not a
|
|
280
|
+
// heavy border) with a light-grey button background (#f3f3f3) and
|
|
281
|
+
// near-black text — verified live on the design system's accordion
|
|
282
|
+
// example page.
|
|
283
|
+
'usx-accordion-border-width': '1px',
|
|
284
|
+
'usx-accordion-bg': '#f3f3f3',
|
|
285
|
+
'usx-accordion-content-bg': '#ffffff',
|
|
286
|
+
'usx-accordion-text': '#0b0c0c',
|
|
287
|
+
'usx-accordion-content-text': '#0b0c0c',
|
|
288
|
+
// Modeled on the real GOV.UK notification banner (a blue-bordered white
|
|
289
|
+
// panel) as the closest analog to our summary box.
|
|
290
|
+
'usx-summary-box-bg': 'var(--usx-surface-3)',
|
|
291
|
+
'usx-summary-box-border-color': 'var(--usx-color-primary)',
|
|
292
|
+
'usx-summary-box-text': '#0b0c0c',
|
|
293
|
+
},
|
|
294
|
+
NASA: {
|
|
295
|
+
// nasa.gov's live site itself (not the unaffiliated/outdated NASAWDS
|
|
296
|
+
// template) — colors pulled from its actual rendered CSS.
|
|
297
|
+
'color-primary': '#d83933', // real CTA button background (e.g. "Live Mission Coverage")
|
|
298
|
+
'color-secondary': '#1c67e3', // real accent blue (download-link icon)
|
|
299
|
+
'color-accent-cool': '#959599', // real neutral gray used across icons/labels
|
|
300
|
+
'color-accent-warm': '#f64137', // real "read more" arrow-icon accent
|
|
301
|
+
'surface-3': '#000000', // real header background — solid black
|
|
302
|
+
'color-border': '#b9b9bb', // real divider/border gray (light enough to read against the black header)
|
|
303
|
+
'usx-header-text': 'var(--usx-text-inverse)', // real header text is white against the black bar
|
|
304
|
+
// text-subtle/text-muted are tuned for a light/neutral surface — against
|
|
305
|
+
// the solid black header/nav they'd be low-contrast, so match the real
|
|
306
|
+
// white nav text instead. color-primary (red) already reads fine as the
|
|
307
|
+
// hover color against black, so it's left on the default.
|
|
308
|
+
'usx-header-nav-link-text': 'var(--usx-text-inverse)',
|
|
309
|
+
'usx-header-secondary-link-text': 'var(--usx-text-inverse)',
|
|
310
|
+
'font-family': '"Source Sans Pro Web", "Helvetica Neue", Helvetica, Roboto, Arial, sans-serif', // real nasa.gov body font (same USWDS default stack)
|
|
311
|
+
// The real CTA button (e.g. "Live Mission Coverage") measures a 4px
|
|
312
|
+
// corner radius, not our default 0.5rem — verified via computed style
|
|
313
|
+
// on the live site.
|
|
314
|
+
'radius-box': '0',
|
|
315
|
+
'radius-field': '0',
|
|
316
|
+
'radius-selector': '2px',
|
|
317
|
+
'radius-button': '4px',
|
|
318
|
+
// nasa.gov's content cards (hds-content-card) render perfectly square —
|
|
319
|
+
// verified live.
|
|
320
|
+
'usx-checkable-tile-radius': '0',
|
|
321
|
+
// nasa.gov's nav literally renders stock USWDS usa-accordion markup, so
|
|
322
|
+
// its button background is stock USWDS base-lightest rather than our
|
|
323
|
+
// slightly darker surface-2 default.
|
|
324
|
+
'usx-accordion-bg': 'var(--usx-surface-3)',
|
|
325
|
+
'usx-accordion-bg-hover': 'var(--usx-color-primary)',
|
|
326
|
+
'usx-accordion-text': 'var(--usx-text-inverse)',
|
|
327
|
+
'usx-range-slider-track-bg': 'var(--usx-surface-1)',
|
|
328
|
+
'usx-range-slider-thumb-bg': 'var(--usx-surface-1)',
|
|
329
|
+
'usx-range-slider-track-border': '#000000',
|
|
330
|
+
'usx-range-slider-thumb-border': '#000000',
|
|
331
|
+
'usx-summary-box-bg': 'var(--usx-surface-3)',
|
|
332
|
+
'usx-summary-box-border-color': 'var(--usx-color-primary)',
|
|
333
|
+
'usx-summary-box-text': 'var(--usx-text-inverse)',
|
|
334
|
+
...headerFooterBorderOverrides(),
|
|
335
|
+
...headerNavBackgroundOverrides(),
|
|
336
|
+
// Keep the mobile drawer the same black as the desktop header/nav bar.
|
|
337
|
+
'usx-header-nav-bg-mobile': 'var(--usx-surface-3)',
|
|
338
|
+
// The footer's secondary section (logo + contact block) chains its
|
|
339
|
+
// background to surface-3 too, so it's solid black here just like the
|
|
340
|
+
// header — same text-color/heading-color-secondary fix as above.
|
|
341
|
+
// Link colors are untouched since color-primary (red) already reads
|
|
342
|
+
// fine against black.
|
|
343
|
+
'usx-footer-text': 'var(--usx-text-inverse)',
|
|
344
|
+
'usx-footer-heading-secondary-text': 'var(--usx-text-inverse)',
|
|
345
|
+
'usx-table-grouped-row-text': 'var(--usx-text-inverse)',
|
|
346
|
+
...inverseLogoOverrides(),
|
|
347
|
+
}
|
|
348
|
+
};
|
package/src/theme-manifest.js
CHANGED
|
@@ -485,7 +485,7 @@ export const themeManifest = [
|
|
|
485
485
|
// fixed-color background-image at build time, so it never follows the
|
|
486
486
|
// theme; repainted via mask-image instead (see _date-picker.scss).
|
|
487
487
|
component('usx-date-picker-button-icon-color', 'var(--usx-text-ink)'),
|
|
488
|
-
// Hover and active share one token/color by design (see
|
|
488
|
+
// Hover and active share one token/color by design (see presets.js's
|
|
489
489
|
// Midnight/Carbon/Borealis overrides for why dark presets need their own
|
|
490
490
|
// hardcoded value here instead of just chaining to color-base-light).
|
|
491
491
|
component('usx-date-picker-button-hover-active-bg', '#a9aeb1', 'color-base-light'),
|
|
@@ -517,7 +517,7 @@ export const themeManifest = [
|
|
|
517
517
|
// own. Chain each role to the same shared tokens already used elsewhere
|
|
518
518
|
// (text, link-text, border, primary) — see _in-page-nav.scss. Background
|
|
519
519
|
// defaults transparent (opts back into a filled surface-2 card only on
|
|
520
|
-
// presets with a dark shell — see
|
|
520
|
+
// presets with a dark shell — see presets.js/Theme.stories.jsx).
|
|
521
521
|
component('usx-in-page-nav-bg', 'transparent'),
|
|
522
522
|
component('usx-in-page-nav-text', 'var(--usx-text-ink)'),
|
|
523
523
|
component('usx-in-page-nav-border', 'var(--usx-color-border)'),
|