@motion-proto/live-tokens 0.91.2 → 0.92.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/.claude/skills/live-tokens-create-page/SKILL.md +10 -3
- package/.claude/skills/live-tokens-set-type/SKILL.md +3 -3
- package/CHANGELOG.md +140 -0
- package/bin/lib/tokenVocabulary.mjs +2 -2
- package/bin/rules/testRuns.mjs +1 -1
- package/bin/rules/tokens.mjs +3 -3
- package/dist-plugin/chunk-JOSSYGR2.js +1634 -0
- package/dist-plugin/index.cjs +932 -15
- package/dist-plugin/index.js +1 -1
- package/dist-plugin/setType/index.cjs +23 -2
- package/dist-plugin/setType/index.js +23 -2
- package/dist-plugin/tokensCssMigrations/index.cjs +936 -15
- package/dist-plugin/tokensCssMigrations/index.d.cts +23 -3
- package/dist-plugin/tokensCssMigrations/index.d.ts +23 -3
- package/dist-plugin/tokensCssMigrations/index.js +5 -1
- package/package.json +1 -1
- package/src/app/site.css +243 -9
- package/src/demo/TestingLoops.svelte +9 -9
- package/src/editor/core/fonts/weightCoverage.ts +31 -2
- package/src/editor/core/palettes/tokenRegistry.ts +36 -37
- package/src/editor/core/themes/parsers/mediaBlocks.ts +46 -0
- package/src/editor/core/typeScale/typeScale.ts +341 -0
- package/src/editor/skill-atlas/SourcePane.svelte +3 -3
- package/src/editor/skill-atlas/skillSources.generated.ts +2 -2
- package/src/editor/skill-atlas/trees/create-page.ts +14 -14
- package/src/editor/skill-atlas/trees/set-type.ts +2 -2
- package/src/editor/ui/UIFontFamilySelector.svelte +5 -1
- package/src/editor/ui/UIFontWeightSelector.svelte +4 -0
- package/src/editor/ui/UILetterSpacingSelector.svelte +4 -0
- package/src/editor/ui/UILineHeightSelector.svelte +4 -0
- package/src/editor/ui/UITextTransformSelector.svelte +4 -0
- package/src/editor/ui/UIVariantSelector.svelte +6 -8
- package/src/editor/ui/VariablesTab.svelte +4 -4
- package/src/editor/ui/sections/textStyles.ts +44 -92
- package/src/editor/ui/text-styles/ControlBody.svelte +100 -0
- package/src/editor/ui/text-styles/ResetIcon.svelte +60 -0
- package/src/editor/ui/text-styles/StepRow.svelte +330 -0
- package/src/editor/ui/text-styles/StyleControl.svelte +128 -0
- package/src/editor/ui/text-styles/TextStylesSection.svelte +551 -0
- package/src/editor/ui/text-styles/textStyleEdits.ts +308 -0
- package/src/editor/ui/variantScales.ts +16 -0
- package/src/system/styles/tokens.css +412 -48
- package/src/testing-js/page-compliance.contract.js +233 -80
- package/src/testing-js/page-compliance.contract.js.map +1 -1
- package/dist-plugin/chunk-GWMEYBZ2.js +0 -715
- package/src/editor/ui/TextStylesSection.svelte +0 -171
|
@@ -31,6 +31,7 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
|
|
|
31
31
|
var tokensCssMigrations_exports = {};
|
|
32
32
|
__export(tokensCssMigrations_exports, {
|
|
33
33
|
TOKENS_CSS_MIGRATIONS: () => TOKENS_CSS_MIGRATIONS,
|
|
34
|
+
appendMediaBlock: () => appendMediaBlock,
|
|
34
35
|
collectDefinedTokens: () => collectDefinedTokens,
|
|
35
36
|
collectReferencedTokens: () => collectReferencedTokens,
|
|
36
37
|
collectTokenValues: () => collectTokenValues,
|
|
@@ -44,6 +45,7 @@ __export(tokensCssMigrations_exports, {
|
|
|
44
45
|
runAdditiveTokensCssMigrations: () => runAdditiveTokensCssMigrations,
|
|
45
46
|
runTokensCssMigrations: () => runTokensCssMigrations,
|
|
46
47
|
semverBumpType: () => semverBumpType,
|
|
48
|
+
setTokenValue: () => setTokenValue,
|
|
47
49
|
validateTokensCss: () => validateTokensCss
|
|
48
50
|
});
|
|
49
51
|
module.exports = __toCommonJS(tokensCssMigrations_exports);
|
|
@@ -59,6 +61,43 @@ function extractGlobalRootBody(source) {
|
|
|
59
61
|
return bodies.join("\n");
|
|
60
62
|
}
|
|
61
63
|
|
|
64
|
+
// src/editor/core/themes/parsers/mediaBlocks.ts
|
|
65
|
+
function stripMediaBlocks(css) {
|
|
66
|
+
const kept = [];
|
|
67
|
+
let from = 0;
|
|
68
|
+
let i = 0;
|
|
69
|
+
while (i < css.length) {
|
|
70
|
+
if (css.startsWith("/*", i)) {
|
|
71
|
+
i = commentEnd(css, i);
|
|
72
|
+
} else if (css[i] === "@" && /^@media\b/i.test(css.slice(i, i + 7))) {
|
|
73
|
+
kept.push(css.slice(from, i));
|
|
74
|
+
i = from = blockEnd(css, i);
|
|
75
|
+
} else {
|
|
76
|
+
i++;
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
kept.push(css.slice(from));
|
|
80
|
+
return kept.join("");
|
|
81
|
+
}
|
|
82
|
+
function commentEnd(css, start) {
|
|
83
|
+
const end = css.indexOf("*/", start + 2);
|
|
84
|
+
return end === -1 ? css.length : end + 2;
|
|
85
|
+
}
|
|
86
|
+
function blockEnd(css, start) {
|
|
87
|
+
let depth = 0;
|
|
88
|
+
let i = start;
|
|
89
|
+
while (i < css.length) {
|
|
90
|
+
if (css.startsWith("/*", i)) {
|
|
91
|
+
i = commentEnd(css, i);
|
|
92
|
+
continue;
|
|
93
|
+
}
|
|
94
|
+
const c = css[i++];
|
|
95
|
+
if (c === "{") depth++;
|
|
96
|
+
else if (c === "}" && --depth === 0) return i;
|
|
97
|
+
}
|
|
98
|
+
return css.length;
|
|
99
|
+
}
|
|
100
|
+
|
|
62
101
|
// vite-plugin/tokensCssMigrations/cssTokenOps.ts
|
|
63
102
|
var DECL_RE = /(^|[\s;{])(--[a-z0-9-]+)\s*:/gi;
|
|
64
103
|
var REF_RE = /var\(\s*(--[a-z0-9-]+)/gi;
|
|
@@ -70,7 +109,7 @@ function collectDefinedTokens(css) {
|
|
|
70
109
|
}
|
|
71
110
|
function collectTokenValues(css) {
|
|
72
111
|
const out = /* @__PURE__ */ new Map();
|
|
73
|
-
for (const m of css.matchAll(DECL_VALUE_RE)) out.set(m[2], m[3].trim());
|
|
112
|
+
for (const m of stripMediaBlocks(css).matchAll(DECL_VALUE_RE)) out.set(m[2], m[3].trim());
|
|
74
113
|
return out;
|
|
75
114
|
}
|
|
76
115
|
function collectReferencedTokens(css) {
|
|
@@ -113,6 +152,58 @@ function removeTokensMatching(css, predicate) {
|
|
|
113
152
|
if (kept.length === lines.length) return css;
|
|
114
153
|
return kept.join("\n");
|
|
115
154
|
}
|
|
155
|
+
function setTokenValue(css, name, value, opts = {}) {
|
|
156
|
+
const lines = css.split("\n");
|
|
157
|
+
const declRe = new RegExp("(^|[\\s;{])(" + escapeRe(name) + ")(\\s*:)([^;}]*)");
|
|
158
|
+
let changed = false;
|
|
159
|
+
for (const root of findTopLevelRoots(lines)) {
|
|
160
|
+
let depth = 1;
|
|
161
|
+
for (let i = root.start + 1; i < root.end; i++) {
|
|
162
|
+
if (depth === 1) {
|
|
163
|
+
const m = lines[i].match(declRe);
|
|
164
|
+
const current = m?.[4].trim();
|
|
165
|
+
if (m && current !== value && (opts.from === void 0 || current === opts.from.trim())) {
|
|
166
|
+
const at = m.index + m[1].length + m[2].length + m[3].length;
|
|
167
|
+
lines[i] = lines[i].slice(0, at) + " " + value + lines[i].slice(at + m[4].length);
|
|
168
|
+
changed = true;
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
depth += braceDelta(lines[i]);
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
return changed ? lines.join("\n") : css;
|
|
175
|
+
}
|
|
176
|
+
function appendMediaBlock(css, query, entries) {
|
|
177
|
+
const lines = css.split("\n");
|
|
178
|
+
const at = query.trim();
|
|
179
|
+
const blocks = findTopLevelBlocks(lines, (line) => mediaQueryOf(line) === at);
|
|
180
|
+
const declared = collectDefinedTokens(
|
|
181
|
+
blocks.map((b) => lines.slice(b.start, b.end + 1).join("\n")).join("\n")
|
|
182
|
+
);
|
|
183
|
+
const missing = entries.filter((e) => !declared.has(e.name));
|
|
184
|
+
if (missing.length === 0) return css;
|
|
185
|
+
const media = blocks.find((b) => b.end > b.start);
|
|
186
|
+
if (!media) {
|
|
187
|
+
const block = [`@media ${at} {`, " :root {", ...declarationLines(missing, " "), " }", "}", ""];
|
|
188
|
+
while (lines.length > 0 && lines[lines.length - 1].trim() === "") lines.pop();
|
|
189
|
+
return [...lines, "", ...block].join("\n");
|
|
190
|
+
}
|
|
191
|
+
const root = findNestedRoot(lines, media);
|
|
192
|
+
if (!root) {
|
|
193
|
+
lines.splice(media.end, 0, " :root {", ...declarationLines(missing, " "), " }");
|
|
194
|
+
return lines.join("\n");
|
|
195
|
+
}
|
|
196
|
+
let indent = (lines[root.end].match(/^\s*/)?.[0] ?? "") + " ";
|
|
197
|
+
for (let i = root.start + 1; i < root.end; i++) {
|
|
198
|
+
const m = lines[i].match(/^(\s*)--[a-z0-9-]+\s*:/i);
|
|
199
|
+
if (m) indent = m[1];
|
|
200
|
+
}
|
|
201
|
+
lines.splice(root.end, 0, ...declarationLines(missing, indent));
|
|
202
|
+
return lines.join("\n");
|
|
203
|
+
}
|
|
204
|
+
function declarationLines(entries, indent) {
|
|
205
|
+
return entries.map((e) => `${indent}${e.name}: ${e.value};`);
|
|
206
|
+
}
|
|
116
207
|
function findInsertionPoint(lines, anchorPrefixes) {
|
|
117
208
|
const root = findTopLevelRoot(lines);
|
|
118
209
|
if (!root) return { indent: " ", insertAfter: lines.length - 1 };
|
|
@@ -131,7 +222,7 @@ function findInsertionPoint(lines, anchorPrefixes) {
|
|
|
131
222
|
}
|
|
132
223
|
}
|
|
133
224
|
}
|
|
134
|
-
depth += (line
|
|
225
|
+
depth += braceDelta(line);
|
|
135
226
|
}
|
|
136
227
|
for (const prefix of anchorPrefixes) {
|
|
137
228
|
const hit = lastByPrefix.get(prefix);
|
|
@@ -139,22 +230,52 @@ function findInsertionPoint(lines, anchorPrefixes) {
|
|
|
139
230
|
}
|
|
140
231
|
return { indent: lastDecl?.indent ?? " ", insertAfter: root.end - 1 };
|
|
141
232
|
}
|
|
233
|
+
var ROOT_OPEN_RE = /(^|[\s,]):root[^{]*\{/;
|
|
142
234
|
function findTopLevelRoot(lines) {
|
|
235
|
+
return findTopLevelRoots(lines)[0] ?? null;
|
|
236
|
+
}
|
|
237
|
+
function findTopLevelRoots(lines) {
|
|
238
|
+
return findTopLevelBlocks(lines, (line) => ROOT_OPEN_RE.test(line));
|
|
239
|
+
}
|
|
240
|
+
function findTopLevelBlocks(lines, opens) {
|
|
241
|
+
const blocks = [];
|
|
143
242
|
let depth = 0;
|
|
144
243
|
for (let i = 0; i < lines.length; i++) {
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
244
|
+
if (depth === 0 && opens(lines[i])) {
|
|
245
|
+
const end = blockEnd2(lines, i);
|
|
246
|
+
blocks.push({ start: i, end });
|
|
247
|
+
i = end;
|
|
248
|
+
continue;
|
|
249
|
+
}
|
|
250
|
+
depth += braceDelta(lines[i]);
|
|
251
|
+
}
|
|
252
|
+
return blocks;
|
|
253
|
+
}
|
|
254
|
+
function findNestedRoot(lines, parent) {
|
|
255
|
+
let depth = 1;
|
|
256
|
+
for (let i = parent.start + 1; i < parent.end; i++) {
|
|
257
|
+
if (depth === 1 && ROOT_OPEN_RE.test(lines[i])) {
|
|
258
|
+
const end = blockEnd2(lines, i);
|
|
259
|
+
if (end > i && end < parent.end) return { start: i, end };
|
|
153
260
|
}
|
|
154
|
-
depth += (
|
|
261
|
+
depth += braceDelta(lines[i]);
|
|
155
262
|
}
|
|
156
263
|
return null;
|
|
157
264
|
}
|
|
265
|
+
function blockEnd2(lines, start) {
|
|
266
|
+
let depth = 0;
|
|
267
|
+
for (let j = start; j < lines.length; j++) {
|
|
268
|
+
depth += braceDelta(lines[j]);
|
|
269
|
+
if (depth === 0) return j;
|
|
270
|
+
}
|
|
271
|
+
return lines.length - 1;
|
|
272
|
+
}
|
|
273
|
+
function mediaQueryOf(line) {
|
|
274
|
+
return line.match(/^\s*@media\s+([^{]*?)\s*\{/i)?.[1] ?? null;
|
|
275
|
+
}
|
|
276
|
+
function braceDelta(line) {
|
|
277
|
+
return (line.match(/\{/g)?.length ?? 0) - (line.match(/\}/g)?.length ?? 0);
|
|
278
|
+
}
|
|
158
279
|
function escapeRe(s) {
|
|
159
280
|
return s.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
160
281
|
}
|
|
@@ -371,11 +492,12 @@ var BUNDLE = [
|
|
|
371
492
|
{ name: "--body-sm-font-weight", value: "var(--font-weight-normal)" },
|
|
372
493
|
{ name: "--body-sm-line-height", value: "var(--line-height-tight)" },
|
|
373
494
|
{ name: "--body-sm-letter-spacing", value: "var(--letter-spacing-normal)" },
|
|
495
|
+
// The code bundle's size, leading and tracking belong to 2026-10-08-type-scales,
|
|
496
|
+
// which renames them to `--code-md-*`. An additive migration must not re-add
|
|
497
|
+
// names a later breaking rename removes, or re-running the fold loses
|
|
498
|
+
// idempotency.
|
|
374
499
|
{ name: "--code-font-family", value: "var(--font-mono)" },
|
|
375
|
-
{ name: "--code-font-size", value: "var(--font-size-sm)" },
|
|
376
500
|
{ name: "--code-font-weight", value: "var(--font-weight-normal)" },
|
|
377
|
-
{ name: "--code-line-height", value: "var(--line-height-normal)" },
|
|
378
|
-
{ name: "--code-letter-spacing", value: "var(--letter-spacing-normal)" },
|
|
379
501
|
{ name: "--eyebrow-font-family", value: "var(--font-sans)" },
|
|
380
502
|
{ name: "--eyebrow-font-size", value: "var(--font-size-sm)" },
|
|
381
503
|
{ name: "--eyebrow-font-weight", value: "var(--font-weight-normal)" },
|
|
@@ -679,6 +801,802 @@ var tokensCssMigration_2026_09_21_tintColorAndOpacity = {
|
|
|
679
801
|
}
|
|
680
802
|
};
|
|
681
803
|
|
|
804
|
+
// vite-plugin/tokensCssMigrations/migrations/2026-10-08-type-scales.ts
|
|
805
|
+
var RENAMES3 = [
|
|
806
|
+
["--code-font-size", "--code-md-font-size"],
|
|
807
|
+
["--code-line-height", "--code-md-line-height"],
|
|
808
|
+
["--code-letter-spacing", "--code-md-letter-spacing"]
|
|
809
|
+
];
|
|
810
|
+
var CARRIED = [
|
|
811
|
+
{
|
|
812
|
+
prefix: "--heading-xl",
|
|
813
|
+
size: "var(--font-size-4xl)",
|
|
814
|
+
links: [
|
|
815
|
+
{ name: "--heading-xl-font-family", from: "var(--font-display)", to: "var(--heading-font-family)" },
|
|
816
|
+
{ name: "--heading-xl-font-weight", from: "var(--font-weight-semibold)", to: "var(--heading-font-weight)" }
|
|
817
|
+
]
|
|
818
|
+
},
|
|
819
|
+
{
|
|
820
|
+
prefix: "--heading-lg",
|
|
821
|
+
size: "var(--font-size-2xl)",
|
|
822
|
+
links: [
|
|
823
|
+
{ name: "--heading-lg-font-family", from: "var(--font-display)", to: "var(--heading-font-family)" },
|
|
824
|
+
{ name: "--heading-lg-font-weight", from: "var(--font-weight-semibold)", to: "var(--heading-font-weight)" }
|
|
825
|
+
]
|
|
826
|
+
},
|
|
827
|
+
{
|
|
828
|
+
prefix: "--heading-md",
|
|
829
|
+
size: "var(--font-size-xl)",
|
|
830
|
+
links: [
|
|
831
|
+
{ name: "--heading-md-font-family", from: "var(--font-display)", to: "var(--heading-font-family)" },
|
|
832
|
+
{ name: "--heading-md-font-weight", from: "var(--font-weight-semibold)", to: "var(--heading-font-weight)" }
|
|
833
|
+
]
|
|
834
|
+
},
|
|
835
|
+
{
|
|
836
|
+
// heading-sm keeps the sans face it shipped with, so only its weight links.
|
|
837
|
+
prefix: "--heading-sm",
|
|
838
|
+
size: "var(--font-size-lg)",
|
|
839
|
+
links: [
|
|
840
|
+
{ name: "--heading-sm-font-weight", from: "var(--font-weight-semibold)", to: "var(--heading-font-weight)" }
|
|
841
|
+
]
|
|
842
|
+
},
|
|
843
|
+
{
|
|
844
|
+
prefix: "--body-md",
|
|
845
|
+
size: "var(--font-size-md)",
|
|
846
|
+
links: [
|
|
847
|
+
{ name: "--body-md-font-family", from: "var(--font-sans)", to: "var(--body-font-family)" },
|
|
848
|
+
{ name: "--body-md-font-weight", from: "var(--font-weight-normal)", to: "var(--body-font-weight)" }
|
|
849
|
+
]
|
|
850
|
+
},
|
|
851
|
+
{
|
|
852
|
+
prefix: "--body-sm",
|
|
853
|
+
size: "var(--font-size-sm)",
|
|
854
|
+
links: [
|
|
855
|
+
{ name: "--body-sm-font-family", from: "var(--font-sans)", to: "var(--body-font-family)" },
|
|
856
|
+
{ name: "--body-sm-font-weight", from: "var(--font-weight-normal)", to: "var(--body-font-weight)" }
|
|
857
|
+
]
|
|
858
|
+
},
|
|
859
|
+
{
|
|
860
|
+
// 0.91.2 had no code-md face or weight: `--code-font-family` and
|
|
861
|
+
// `--code-font-weight` keep their names as the code usage's settings.
|
|
862
|
+
prefix: "--code-md",
|
|
863
|
+
size: "var(--font-size-sm)",
|
|
864
|
+
links: []
|
|
865
|
+
},
|
|
866
|
+
{
|
|
867
|
+
prefix: "--editorial-xl",
|
|
868
|
+
size: "var(--font-size-xl)",
|
|
869
|
+
links: [
|
|
870
|
+
{ name: "--editorial-xl-font-family", from: "var(--font-editorial)", to: "var(--editorial-font-family)" },
|
|
871
|
+
{ name: "--editorial-xl-font-weight", from: "var(--font-weight-normal)", to: "var(--editorial-font-weight)" }
|
|
872
|
+
]
|
|
873
|
+
},
|
|
874
|
+
{
|
|
875
|
+
prefix: "--editorial-lg",
|
|
876
|
+
size: "var(--font-size-lg)",
|
|
877
|
+
links: [
|
|
878
|
+
{ name: "--editorial-lg-font-family", from: "var(--font-editorial)", to: "var(--editorial-font-family)" },
|
|
879
|
+
{ name: "--editorial-lg-font-weight", from: "var(--font-weight-normal)", to: "var(--editorial-font-weight)" }
|
|
880
|
+
]
|
|
881
|
+
},
|
|
882
|
+
{
|
|
883
|
+
prefix: "--editorial-md",
|
|
884
|
+
size: "var(--font-size-md)",
|
|
885
|
+
links: [
|
|
886
|
+
{ name: "--editorial-md-font-family", from: "var(--font-editorial)", to: "var(--editorial-font-family)" },
|
|
887
|
+
{ name: "--editorial-md-font-weight", from: "var(--font-weight-normal)", to: "var(--editorial-font-weight)" }
|
|
888
|
+
]
|
|
889
|
+
},
|
|
890
|
+
{
|
|
891
|
+
prefix: "--editorial-sm",
|
|
892
|
+
size: "var(--font-size-sm)",
|
|
893
|
+
links: [
|
|
894
|
+
{ name: "--editorial-sm-font-family", from: "var(--font-editorial)", to: "var(--editorial-font-family)" },
|
|
895
|
+
{ name: "--editorial-sm-font-weight", from: "var(--font-weight-normal)", to: "var(--editorial-font-weight)" }
|
|
896
|
+
]
|
|
897
|
+
},
|
|
898
|
+
{
|
|
899
|
+
prefix: "--eyebrow",
|
|
900
|
+
size: "var(--font-size-sm)",
|
|
901
|
+
links: [
|
|
902
|
+
{ name: "--eyebrow-font-family", from: "var(--font-sans)", to: "var(--body-font-family)" },
|
|
903
|
+
{ name: "--eyebrow-font-weight", from: "var(--font-weight-normal)", to: "var(--body-font-weight)" }
|
|
904
|
+
]
|
|
905
|
+
}
|
|
906
|
+
];
|
|
907
|
+
var COMPRESSION = [
|
|
908
|
+
{ name: "--type-tablet-scale-compression", value: "0.75" },
|
|
909
|
+
{ name: "--type-phone-scale-compression", value: "0.63" }
|
|
910
|
+
];
|
|
911
|
+
var COMPRESSED_VIEWPORTS = ["tablet", "phone"];
|
|
912
|
+
function literalRem(size) {
|
|
913
|
+
const m = /^(-?\d*\.?\d+)(rem|px)$/.exec(size.trim());
|
|
914
|
+
if (!m) return null;
|
|
915
|
+
return m[2] === "rem" ? Number(m[1]) : Number(m[1]) / 16;
|
|
916
|
+
}
|
|
917
|
+
function editedSizes(prefix, rem) {
|
|
918
|
+
const count = String(Number(rem.toFixed(4)));
|
|
919
|
+
return COMPRESSED_VIEWPORTS.map((viewport) => ({
|
|
920
|
+
name: `${prefix}-${viewport}-font-size`,
|
|
921
|
+
value: `min(var(${prefix}-desktop-font-size), calc(pow(${count}, var(--type-${viewport}-scale-compression)) * 1rem))`
|
|
922
|
+
}));
|
|
923
|
+
}
|
|
924
|
+
var USAGES = [
|
|
925
|
+
{
|
|
926
|
+
usage: "display",
|
|
927
|
+
comment: "Display: type outside the page outline, such as heroes, section titles and big numbers",
|
|
928
|
+
follows: "type",
|
|
929
|
+
settings: [
|
|
930
|
+
{ name: "--display-font-family", value: "var(--font-display)" },
|
|
931
|
+
{ name: "--display-font-weight", value: "var(--font-weight-semibold)" },
|
|
932
|
+
{ name: "--display-scale-base", value: "3" },
|
|
933
|
+
{ name: "--display-scale-ratio", value: "1.2" }
|
|
934
|
+
],
|
|
935
|
+
steps: [
|
|
936
|
+
{
|
|
937
|
+
prefix: "--display-2xl",
|
|
938
|
+
entries: [
|
|
939
|
+
{ name: "--display-2xl-font-family", value: "var(--display-font-family)" },
|
|
940
|
+
{ name: "--display-2xl-desktop-font-size", value: "calc(var(--display-scale-base) * pow(var(--display-scale-ratio), 3) * 1rem)" },
|
|
941
|
+
{ name: "--display-2xl-tablet-font-size", value: "min(var(--display-2xl-desktop-font-size), calc(pow(var(--display-scale-base) * pow(var(--display-scale-ratio), 3), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
942
|
+
{ name: "--display-2xl-phone-font-size", value: "min(var(--display-2xl-desktop-font-size), calc(pow(var(--display-scale-base) * pow(var(--display-scale-ratio), 3), var(--type-phone-scale-compression)) * 1rem))" },
|
|
943
|
+
{ name: "--display-2xl-font-size", value: "var(--display-2xl-desktop-font-size)" },
|
|
944
|
+
{ name: "--display-2xl-font-weight", value: "var(--display-font-weight)" },
|
|
945
|
+
{ name: "--display-2xl-line-height", value: "var(--line-height-tightest)" },
|
|
946
|
+
{ name: "--display-2xl-letter-spacing", value: "var(--letter-spacing-tight)" }
|
|
947
|
+
]
|
|
948
|
+
},
|
|
949
|
+
{
|
|
950
|
+
prefix: "--display-xl",
|
|
951
|
+
entries: [
|
|
952
|
+
{ name: "--display-xl-font-family", value: "var(--display-font-family)" },
|
|
953
|
+
{ name: "--display-xl-desktop-font-size", value: "calc(var(--display-scale-base) * pow(var(--display-scale-ratio), 2) * 1rem)" },
|
|
954
|
+
{ name: "--display-xl-tablet-font-size", value: "min(var(--display-xl-desktop-font-size), calc(pow(var(--display-scale-base) * pow(var(--display-scale-ratio), 2), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
955
|
+
{ name: "--display-xl-phone-font-size", value: "min(var(--display-xl-desktop-font-size), calc(pow(var(--display-scale-base) * pow(var(--display-scale-ratio), 2), var(--type-phone-scale-compression)) * 1rem))" },
|
|
956
|
+
{ name: "--display-xl-font-size", value: "var(--display-xl-desktop-font-size)" },
|
|
957
|
+
{ name: "--display-xl-font-weight", value: "var(--display-font-weight)" },
|
|
958
|
+
{ name: "--display-xl-line-height", value: "var(--line-height-tightest)" },
|
|
959
|
+
{ name: "--display-xl-letter-spacing", value: "var(--letter-spacing-tight)" }
|
|
960
|
+
]
|
|
961
|
+
},
|
|
962
|
+
{
|
|
963
|
+
prefix: "--display-lg",
|
|
964
|
+
entries: [
|
|
965
|
+
{ name: "--display-lg-font-family", value: "var(--display-font-family)" },
|
|
966
|
+
{ name: "--display-lg-desktop-font-size", value: "calc(var(--display-scale-base) * pow(var(--display-scale-ratio), 1) * 1rem)" },
|
|
967
|
+
{ name: "--display-lg-tablet-font-size", value: "min(var(--display-lg-desktop-font-size), calc(pow(var(--display-scale-base) * pow(var(--display-scale-ratio), 1), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
968
|
+
{ name: "--display-lg-phone-font-size", value: "min(var(--display-lg-desktop-font-size), calc(pow(var(--display-scale-base) * pow(var(--display-scale-ratio), 1), var(--type-phone-scale-compression)) * 1rem))" },
|
|
969
|
+
{ name: "--display-lg-font-size", value: "var(--display-lg-desktop-font-size)" },
|
|
970
|
+
{ name: "--display-lg-font-weight", value: "var(--display-font-weight)" },
|
|
971
|
+
{ name: "--display-lg-line-height", value: "var(--line-height-tightest)" },
|
|
972
|
+
{ name: "--display-lg-letter-spacing", value: "var(--letter-spacing-tight)" }
|
|
973
|
+
]
|
|
974
|
+
},
|
|
975
|
+
{
|
|
976
|
+
prefix: "--display-md",
|
|
977
|
+
entries: [
|
|
978
|
+
{ name: "--display-md-font-family", value: "var(--display-font-family)" },
|
|
979
|
+
{ name: "--display-md-desktop-font-size", value: "calc(var(--display-scale-base) * 1rem)" },
|
|
980
|
+
{ name: "--display-md-tablet-font-size", value: "min(var(--display-md-desktop-font-size), calc(pow(var(--display-scale-base), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
981
|
+
{ name: "--display-md-phone-font-size", value: "min(var(--display-md-desktop-font-size), calc(pow(var(--display-scale-base), var(--type-phone-scale-compression)) * 1rem))" },
|
|
982
|
+
{ name: "--display-md-font-size", value: "var(--display-md-desktop-font-size)" },
|
|
983
|
+
{ name: "--display-md-font-weight", value: "var(--display-font-weight)" },
|
|
984
|
+
{ name: "--display-md-line-height", value: "var(--line-height-tightest)" },
|
|
985
|
+
{ name: "--display-md-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
986
|
+
]
|
|
987
|
+
},
|
|
988
|
+
{
|
|
989
|
+
prefix: "--display-sm",
|
|
990
|
+
entries: [
|
|
991
|
+
{ name: "--display-sm-font-family", value: "var(--display-font-family)" },
|
|
992
|
+
{ name: "--display-sm-desktop-font-size", value: "calc(var(--display-scale-base) * pow(var(--display-scale-ratio), -1) * 1rem)" },
|
|
993
|
+
{ name: "--display-sm-tablet-font-size", value: "min(var(--display-sm-desktop-font-size), calc(pow(var(--display-scale-base) * pow(var(--display-scale-ratio), -1), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
994
|
+
{ name: "--display-sm-phone-font-size", value: "min(var(--display-sm-desktop-font-size), calc(pow(var(--display-scale-base) * pow(var(--display-scale-ratio), -1), var(--type-phone-scale-compression)) * 1rem))" },
|
|
995
|
+
{ name: "--display-sm-font-size", value: "var(--display-sm-desktop-font-size)" },
|
|
996
|
+
{ name: "--display-sm-font-weight", value: "var(--display-font-weight)" },
|
|
997
|
+
{ name: "--display-sm-line-height", value: "var(--line-height-tighter)" },
|
|
998
|
+
{ name: "--display-sm-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
999
|
+
]
|
|
1000
|
+
},
|
|
1001
|
+
{
|
|
1002
|
+
prefix: "--display-xs",
|
|
1003
|
+
entries: [
|
|
1004
|
+
{ name: "--display-xs-font-family", value: "var(--display-font-family)" },
|
|
1005
|
+
{ name: "--display-xs-desktop-font-size", value: "calc(var(--display-scale-base) * pow(var(--display-scale-ratio), -2) * 1rem)" },
|
|
1006
|
+
{ name: "--display-xs-tablet-font-size", value: "min(var(--display-xs-desktop-font-size), calc(pow(var(--display-scale-base) * pow(var(--display-scale-ratio), -2), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1007
|
+
{ name: "--display-xs-phone-font-size", value: "min(var(--display-xs-desktop-font-size), calc(pow(var(--display-scale-base) * pow(var(--display-scale-ratio), -2), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1008
|
+
{ name: "--display-xs-font-size", value: "var(--display-xs-desktop-font-size)" },
|
|
1009
|
+
{ name: "--display-xs-font-weight", value: "var(--display-font-weight)" },
|
|
1010
|
+
{ name: "--display-xs-line-height", value: "var(--line-height-tighter)" },
|
|
1011
|
+
{ name: "--display-xs-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1012
|
+
]
|
|
1013
|
+
},
|
|
1014
|
+
{
|
|
1015
|
+
prefix: "--display-2xs",
|
|
1016
|
+
entries: [
|
|
1017
|
+
{ name: "--display-2xs-font-family", value: "var(--display-font-family)" },
|
|
1018
|
+
{ name: "--display-2xs-desktop-font-size", value: "calc(var(--display-scale-base) * pow(var(--display-scale-ratio), -3) * 1rem)" },
|
|
1019
|
+
{ name: "--display-2xs-tablet-font-size", value: "min(var(--display-2xs-desktop-font-size), calc(pow(var(--display-scale-base) * pow(var(--display-scale-ratio), -3), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1020
|
+
{ name: "--display-2xs-phone-font-size", value: "min(var(--display-2xs-desktop-font-size), calc(pow(var(--display-scale-base) * pow(var(--display-scale-ratio), -3), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1021
|
+
{ name: "--display-2xs-font-size", value: "var(--display-2xs-desktop-font-size)" },
|
|
1022
|
+
{ name: "--display-2xs-font-weight", value: "var(--display-font-weight)" },
|
|
1023
|
+
{ name: "--display-2xs-line-height", value: "var(--line-height-tighter)" },
|
|
1024
|
+
{ name: "--display-2xs-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1025
|
+
]
|
|
1026
|
+
}
|
|
1027
|
+
]
|
|
1028
|
+
},
|
|
1029
|
+
{
|
|
1030
|
+
usage: "heading",
|
|
1031
|
+
comment: "Heading: the page outline, h1 at xl down to h6 at 2xs",
|
|
1032
|
+
follows: "display",
|
|
1033
|
+
settings: [
|
|
1034
|
+
{ name: "--heading-font-family", value: "var(--font-display)" },
|
|
1035
|
+
{ name: "--heading-font-weight", value: "var(--font-weight-semibold)" },
|
|
1036
|
+
{ name: "--heading-scale-base", value: "1.5" },
|
|
1037
|
+
{ name: "--heading-scale-ratio", value: "1.25" }
|
|
1038
|
+
],
|
|
1039
|
+
steps: [
|
|
1040
|
+
{
|
|
1041
|
+
prefix: "--heading-2xl",
|
|
1042
|
+
entries: [
|
|
1043
|
+
{ name: "--heading-2xl-font-family", value: "var(--heading-font-family)" },
|
|
1044
|
+
{ name: "--heading-2xl-desktop-font-size", value: "calc(var(--heading-scale-base) * pow(var(--heading-scale-ratio), 3) * 1rem)" },
|
|
1045
|
+
{ name: "--heading-2xl-tablet-font-size", value: "min(var(--heading-2xl-desktop-font-size), calc(pow(var(--heading-scale-base) * pow(var(--heading-scale-ratio), 3), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1046
|
+
{ name: "--heading-2xl-phone-font-size", value: "min(var(--heading-2xl-desktop-font-size), calc(pow(var(--heading-scale-base) * pow(var(--heading-scale-ratio), 3), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1047
|
+
{ name: "--heading-2xl-font-size", value: "var(--heading-2xl-desktop-font-size)" },
|
|
1048
|
+
{ name: "--heading-2xl-font-weight", value: "var(--heading-font-weight)" },
|
|
1049
|
+
{ name: "--heading-2xl-line-height", value: "var(--line-height-tightest)" },
|
|
1050
|
+
{ name: "--heading-2xl-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1051
|
+
]
|
|
1052
|
+
},
|
|
1053
|
+
{
|
|
1054
|
+
prefix: "--heading-xl",
|
|
1055
|
+
entries: [
|
|
1056
|
+
{ name: "--heading-xl-font-family", value: "var(--heading-font-family)" },
|
|
1057
|
+
{ name: "--heading-xl-desktop-font-size", value: "calc(var(--heading-scale-base) * pow(var(--heading-scale-ratio), 2) * 1rem)" },
|
|
1058
|
+
{ name: "--heading-xl-tablet-font-size", value: "min(var(--heading-xl-desktop-font-size), calc(pow(var(--heading-scale-base) * pow(var(--heading-scale-ratio), 2), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1059
|
+
{ name: "--heading-xl-phone-font-size", value: "min(var(--heading-xl-desktop-font-size), calc(pow(var(--heading-scale-base) * pow(var(--heading-scale-ratio), 2), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1060
|
+
{ name: "--heading-xl-font-size", value: "var(--heading-xl-desktop-font-size)" },
|
|
1061
|
+
{ name: "--heading-xl-font-weight", value: "var(--heading-font-weight)" },
|
|
1062
|
+
{ name: "--heading-xl-line-height", value: "var(--line-height-tightest)" },
|
|
1063
|
+
{ name: "--heading-xl-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1064
|
+
]
|
|
1065
|
+
},
|
|
1066
|
+
{
|
|
1067
|
+
prefix: "--heading-lg",
|
|
1068
|
+
entries: [
|
|
1069
|
+
{ name: "--heading-lg-font-family", value: "var(--heading-font-family)" },
|
|
1070
|
+
{ name: "--heading-lg-desktop-font-size", value: "calc(var(--heading-scale-base) * pow(var(--heading-scale-ratio), 1) * 1rem)" },
|
|
1071
|
+
{ name: "--heading-lg-tablet-font-size", value: "min(var(--heading-lg-desktop-font-size), calc(pow(var(--heading-scale-base) * pow(var(--heading-scale-ratio), 1), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1072
|
+
{ name: "--heading-lg-phone-font-size", value: "min(var(--heading-lg-desktop-font-size), calc(pow(var(--heading-scale-base) * pow(var(--heading-scale-ratio), 1), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1073
|
+
{ name: "--heading-lg-font-size", value: "var(--heading-lg-desktop-font-size)" },
|
|
1074
|
+
{ name: "--heading-lg-font-weight", value: "var(--heading-font-weight)" },
|
|
1075
|
+
{ name: "--heading-lg-line-height", value: "var(--line-height-tightest)" },
|
|
1076
|
+
{ name: "--heading-lg-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1077
|
+
]
|
|
1078
|
+
},
|
|
1079
|
+
{
|
|
1080
|
+
prefix: "--heading-md",
|
|
1081
|
+
entries: [
|
|
1082
|
+
{ name: "--heading-md-font-family", value: "var(--heading-font-family)" },
|
|
1083
|
+
{ name: "--heading-md-desktop-font-size", value: "calc(var(--heading-scale-base) * 1rem)" },
|
|
1084
|
+
{ name: "--heading-md-tablet-font-size", value: "min(var(--heading-md-desktop-font-size), calc(pow(var(--heading-scale-base), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1085
|
+
{ name: "--heading-md-phone-font-size", value: "min(var(--heading-md-desktop-font-size), calc(pow(var(--heading-scale-base), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1086
|
+
{ name: "--heading-md-font-size", value: "var(--heading-md-desktop-font-size)" },
|
|
1087
|
+
{ name: "--heading-md-font-weight", value: "var(--heading-font-weight)" },
|
|
1088
|
+
{ name: "--heading-md-line-height", value: "var(--line-height-tighter)" },
|
|
1089
|
+
{ name: "--heading-md-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1090
|
+
]
|
|
1091
|
+
},
|
|
1092
|
+
{
|
|
1093
|
+
prefix: "--heading-sm",
|
|
1094
|
+
entries: [
|
|
1095
|
+
{ name: "--heading-sm-font-family", value: "var(--font-sans)" },
|
|
1096
|
+
{ name: "--heading-sm-desktop-font-size", value: "calc(var(--heading-scale-base) * pow(var(--heading-scale-ratio), -1) * 1rem)" },
|
|
1097
|
+
{ name: "--heading-sm-tablet-font-size", value: "min(var(--heading-sm-desktop-font-size), calc(pow(var(--heading-scale-base) * pow(var(--heading-scale-ratio), -1), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1098
|
+
{ name: "--heading-sm-phone-font-size", value: "min(var(--heading-sm-desktop-font-size), calc(pow(var(--heading-scale-base) * pow(var(--heading-scale-ratio), -1), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1099
|
+
{ name: "--heading-sm-font-size", value: "var(--heading-sm-desktop-font-size)" },
|
|
1100
|
+
{ name: "--heading-sm-font-weight", value: "var(--heading-font-weight)" },
|
|
1101
|
+
{ name: "--heading-sm-line-height", value: "var(--line-height-tighter)" },
|
|
1102
|
+
{ name: "--heading-sm-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1103
|
+
]
|
|
1104
|
+
},
|
|
1105
|
+
{
|
|
1106
|
+
prefix: "--heading-xs",
|
|
1107
|
+
entries: [
|
|
1108
|
+
{ name: "--heading-xs-font-family", value: "var(--font-sans)" },
|
|
1109
|
+
{ name: "--heading-xs-desktop-font-size", value: "calc(var(--heading-scale-base) * pow(var(--heading-scale-ratio), -2) * 1rem)" },
|
|
1110
|
+
{ name: "--heading-xs-tablet-font-size", value: "min(var(--heading-xs-desktop-font-size), calc(pow(var(--heading-scale-base) * pow(var(--heading-scale-ratio), -2), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1111
|
+
{ name: "--heading-xs-phone-font-size", value: "min(var(--heading-xs-desktop-font-size), calc(pow(var(--heading-scale-base) * pow(var(--heading-scale-ratio), -2), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1112
|
+
{ name: "--heading-xs-font-size", value: "var(--heading-xs-desktop-font-size)" },
|
|
1113
|
+
{ name: "--heading-xs-font-weight", value: "var(--heading-font-weight)" },
|
|
1114
|
+
{ name: "--heading-xs-line-height", value: "var(--line-height-tight)" },
|
|
1115
|
+
{ name: "--heading-xs-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1116
|
+
]
|
|
1117
|
+
},
|
|
1118
|
+
{
|
|
1119
|
+
prefix: "--heading-2xs",
|
|
1120
|
+
entries: [
|
|
1121
|
+
{ name: "--heading-2xs-font-family", value: "var(--font-sans)" },
|
|
1122
|
+
{ name: "--heading-2xs-desktop-font-size", value: "calc(var(--heading-scale-base) * pow(var(--heading-scale-ratio), -3) * 1rem)" },
|
|
1123
|
+
{ name: "--heading-2xs-tablet-font-size", value: "min(var(--heading-2xs-desktop-font-size), calc(pow(var(--heading-scale-base) * pow(var(--heading-scale-ratio), -3), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1124
|
+
{ name: "--heading-2xs-phone-font-size", value: "min(var(--heading-2xs-desktop-font-size), calc(pow(var(--heading-scale-base) * pow(var(--heading-scale-ratio), -3), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1125
|
+
{ name: "--heading-2xs-font-size", value: "var(--heading-2xs-desktop-font-size)" },
|
|
1126
|
+
{ name: "--heading-2xs-font-weight", value: "var(--heading-font-weight)" },
|
|
1127
|
+
{ name: "--heading-2xs-line-height", value: "var(--line-height-tight)" },
|
|
1128
|
+
{ name: "--heading-2xs-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1129
|
+
]
|
|
1130
|
+
}
|
|
1131
|
+
]
|
|
1132
|
+
},
|
|
1133
|
+
{
|
|
1134
|
+
usage: "body",
|
|
1135
|
+
comment: "Body: interface text and short copy",
|
|
1136
|
+
follows: "heading",
|
|
1137
|
+
settings: [
|
|
1138
|
+
{ name: "--body-font-family", value: "var(--font-sans)" },
|
|
1139
|
+
{ name: "--body-font-weight", value: "var(--font-weight-normal)" },
|
|
1140
|
+
{ name: "--body-scale-base", value: "1" },
|
|
1141
|
+
{ name: "--body-scale-ratio", value: "1.125" }
|
|
1142
|
+
],
|
|
1143
|
+
steps: [
|
|
1144
|
+
{
|
|
1145
|
+
prefix: "--body-2xl",
|
|
1146
|
+
entries: [
|
|
1147
|
+
{ name: "--body-2xl-font-family", value: "var(--body-font-family)" },
|
|
1148
|
+
{ name: "--body-2xl-desktop-font-size", value: "calc(var(--body-scale-base) * pow(var(--body-scale-ratio), 3) * 1rem)" },
|
|
1149
|
+
{ name: "--body-2xl-tablet-font-size", value: "min(var(--body-2xl-desktop-font-size), calc(pow(var(--body-scale-base) * pow(var(--body-scale-ratio), 3), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1150
|
+
{ name: "--body-2xl-phone-font-size", value: "min(var(--body-2xl-desktop-font-size), calc(pow(var(--body-scale-base) * pow(var(--body-scale-ratio), 3), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1151
|
+
{ name: "--body-2xl-font-size", value: "var(--body-2xl-desktop-font-size)" },
|
|
1152
|
+
{ name: "--body-2xl-font-weight", value: "var(--body-font-weight)" },
|
|
1153
|
+
{ name: "--body-2xl-line-height", value: "var(--line-height-tighter)" },
|
|
1154
|
+
{ name: "--body-2xl-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1155
|
+
]
|
|
1156
|
+
},
|
|
1157
|
+
{
|
|
1158
|
+
prefix: "--body-xl",
|
|
1159
|
+
entries: [
|
|
1160
|
+
{ name: "--body-xl-font-family", value: "var(--body-font-family)" },
|
|
1161
|
+
{ name: "--body-xl-desktop-font-size", value: "calc(var(--body-scale-base) * pow(var(--body-scale-ratio), 2) * 1rem)" },
|
|
1162
|
+
{ name: "--body-xl-tablet-font-size", value: "min(var(--body-xl-desktop-font-size), calc(pow(var(--body-scale-base) * pow(var(--body-scale-ratio), 2), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1163
|
+
{ name: "--body-xl-phone-font-size", value: "min(var(--body-xl-desktop-font-size), calc(pow(var(--body-scale-base) * pow(var(--body-scale-ratio), 2), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1164
|
+
{ name: "--body-xl-font-size", value: "var(--body-xl-desktop-font-size)" },
|
|
1165
|
+
{ name: "--body-xl-font-weight", value: "var(--body-font-weight)" },
|
|
1166
|
+
{ name: "--body-xl-line-height", value: "var(--line-height-tighter)" },
|
|
1167
|
+
{ name: "--body-xl-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1168
|
+
]
|
|
1169
|
+
},
|
|
1170
|
+
{
|
|
1171
|
+
prefix: "--body-lg",
|
|
1172
|
+
entries: [
|
|
1173
|
+
{ name: "--body-lg-font-family", value: "var(--body-font-family)" },
|
|
1174
|
+
{ name: "--body-lg-desktop-font-size", value: "calc(var(--body-scale-base) * pow(var(--body-scale-ratio), 1) * 1rem)" },
|
|
1175
|
+
{ name: "--body-lg-tablet-font-size", value: "min(var(--body-lg-desktop-font-size), calc(pow(var(--body-scale-base) * pow(var(--body-scale-ratio), 1), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1176
|
+
{ name: "--body-lg-phone-font-size", value: "min(var(--body-lg-desktop-font-size), calc(pow(var(--body-scale-base) * pow(var(--body-scale-ratio), 1), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1177
|
+
{ name: "--body-lg-font-size", value: "var(--body-lg-desktop-font-size)" },
|
|
1178
|
+
{ name: "--body-lg-font-weight", value: "var(--body-font-weight)" },
|
|
1179
|
+
{ name: "--body-lg-line-height", value: "var(--line-height-tight)" },
|
|
1180
|
+
{ name: "--body-lg-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1181
|
+
]
|
|
1182
|
+
},
|
|
1183
|
+
{
|
|
1184
|
+
prefix: "--body-md",
|
|
1185
|
+
entries: [
|
|
1186
|
+
{ name: "--body-md-font-family", value: "var(--body-font-family)" },
|
|
1187
|
+
{ name: "--body-md-desktop-font-size", value: "calc(var(--body-scale-base) * 1rem)" },
|
|
1188
|
+
{ name: "--body-md-tablet-font-size", value: "min(var(--body-md-desktop-font-size), calc(pow(var(--body-scale-base), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1189
|
+
{ name: "--body-md-phone-font-size", value: "min(var(--body-md-desktop-font-size), calc(pow(var(--body-scale-base), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1190
|
+
{ name: "--body-md-font-size", value: "var(--body-md-desktop-font-size)" },
|
|
1191
|
+
{ name: "--body-md-font-weight", value: "var(--body-font-weight)" },
|
|
1192
|
+
{ name: "--body-md-line-height", value: "var(--line-height-normal)" },
|
|
1193
|
+
{ name: "--body-md-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1194
|
+
]
|
|
1195
|
+
},
|
|
1196
|
+
{
|
|
1197
|
+
prefix: "--body-sm",
|
|
1198
|
+
entries: [
|
|
1199
|
+
{ name: "--body-sm-font-family", value: "var(--body-font-family)" },
|
|
1200
|
+
{ name: "--body-sm-desktop-font-size", value: "calc(var(--body-scale-base) * pow(var(--body-scale-ratio), -1) * 1rem)" },
|
|
1201
|
+
{ name: "--body-sm-tablet-font-size", value: "min(var(--body-sm-desktop-font-size), calc(pow(var(--body-scale-base) * pow(var(--body-scale-ratio), -1), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1202
|
+
{ name: "--body-sm-phone-font-size", value: "min(var(--body-sm-desktop-font-size), calc(pow(var(--body-scale-base) * pow(var(--body-scale-ratio), -1), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1203
|
+
{ name: "--body-sm-font-size", value: "var(--body-sm-desktop-font-size)" },
|
|
1204
|
+
{ name: "--body-sm-font-weight", value: "var(--body-font-weight)" },
|
|
1205
|
+
{ name: "--body-sm-line-height", value: "var(--line-height-tight)" },
|
|
1206
|
+
{ name: "--body-sm-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1207
|
+
]
|
|
1208
|
+
},
|
|
1209
|
+
{
|
|
1210
|
+
prefix: "--body-xs",
|
|
1211
|
+
entries: [
|
|
1212
|
+
{ name: "--body-xs-font-family", value: "var(--body-font-family)" },
|
|
1213
|
+
{ name: "--body-xs-desktop-font-size", value: "calc(var(--body-scale-base) * pow(var(--body-scale-ratio), -2) * 1rem)" },
|
|
1214
|
+
{ name: "--body-xs-tablet-font-size", value: "min(var(--body-xs-desktop-font-size), calc(pow(var(--body-scale-base) * pow(var(--body-scale-ratio), -2), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1215
|
+
{ name: "--body-xs-phone-font-size", value: "min(var(--body-xs-desktop-font-size), calc(pow(var(--body-scale-base) * pow(var(--body-scale-ratio), -2), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1216
|
+
{ name: "--body-xs-font-size", value: "var(--body-xs-desktop-font-size)" },
|
|
1217
|
+
{ name: "--body-xs-font-weight", value: "var(--body-font-weight)" },
|
|
1218
|
+
{ name: "--body-xs-line-height", value: "var(--line-height-tight)" },
|
|
1219
|
+
{ name: "--body-xs-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1220
|
+
]
|
|
1221
|
+
},
|
|
1222
|
+
{
|
|
1223
|
+
prefix: "--body-2xs",
|
|
1224
|
+
entries: [
|
|
1225
|
+
{ name: "--body-2xs-font-family", value: "var(--body-font-family)" },
|
|
1226
|
+
{ name: "--body-2xs-desktop-font-size", value: "calc(var(--body-scale-base) * pow(var(--body-scale-ratio), -3) * 1rem)" },
|
|
1227
|
+
{ name: "--body-2xs-tablet-font-size", value: "min(var(--body-2xs-desktop-font-size), calc(pow(var(--body-scale-base) * pow(var(--body-scale-ratio), -3), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1228
|
+
{ name: "--body-2xs-phone-font-size", value: "min(var(--body-2xs-desktop-font-size), calc(pow(var(--body-scale-base) * pow(var(--body-scale-ratio), -3), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1229
|
+
{ name: "--body-2xs-font-size", value: "var(--body-2xs-desktop-font-size)" },
|
|
1230
|
+
{ name: "--body-2xs-font-weight", value: "var(--body-font-weight)" },
|
|
1231
|
+
{ name: "--body-2xs-line-height", value: "var(--line-height-tight)" },
|
|
1232
|
+
{ name: "--body-2xs-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1233
|
+
]
|
|
1234
|
+
}
|
|
1235
|
+
]
|
|
1236
|
+
},
|
|
1237
|
+
{
|
|
1238
|
+
usage: "code",
|
|
1239
|
+
comment: "Code: code blocks and inline code",
|
|
1240
|
+
follows: "body",
|
|
1241
|
+
settings: [
|
|
1242
|
+
{ name: "--code-font-family", value: "var(--font-mono)" },
|
|
1243
|
+
{ name: "--code-font-weight", value: "var(--font-weight-normal)" },
|
|
1244
|
+
{ name: "--code-scale-base", value: "0.875" },
|
|
1245
|
+
{ name: "--code-scale-ratio", value: "1.125" }
|
|
1246
|
+
],
|
|
1247
|
+
steps: [
|
|
1248
|
+
{
|
|
1249
|
+
prefix: "--code-2xl",
|
|
1250
|
+
entries: [
|
|
1251
|
+
{ name: "--code-2xl-font-family", value: "var(--code-font-family)" },
|
|
1252
|
+
{ name: "--code-2xl-desktop-font-size", value: "calc(var(--code-scale-base) * pow(var(--code-scale-ratio), 3) * 1rem)" },
|
|
1253
|
+
{ name: "--code-2xl-tablet-font-size", value: "min(var(--code-2xl-desktop-font-size), calc(pow(var(--code-scale-base) * pow(var(--code-scale-ratio), 3), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1254
|
+
{ name: "--code-2xl-phone-font-size", value: "min(var(--code-2xl-desktop-font-size), calc(pow(var(--code-scale-base) * pow(var(--code-scale-ratio), 3), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1255
|
+
{ name: "--code-2xl-font-size", value: "var(--code-2xl-desktop-font-size)" },
|
|
1256
|
+
{ name: "--code-2xl-font-weight", value: "var(--code-font-weight)" },
|
|
1257
|
+
{ name: "--code-2xl-line-height", value: "var(--line-height-normal)" },
|
|
1258
|
+
{ name: "--code-2xl-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1259
|
+
]
|
|
1260
|
+
},
|
|
1261
|
+
{
|
|
1262
|
+
prefix: "--code-xl",
|
|
1263
|
+
entries: [
|
|
1264
|
+
{ name: "--code-xl-font-family", value: "var(--code-font-family)" },
|
|
1265
|
+
{ name: "--code-xl-desktop-font-size", value: "calc(var(--code-scale-base) * pow(var(--code-scale-ratio), 2) * 1rem)" },
|
|
1266
|
+
{ name: "--code-xl-tablet-font-size", value: "min(var(--code-xl-desktop-font-size), calc(pow(var(--code-scale-base) * pow(var(--code-scale-ratio), 2), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1267
|
+
{ name: "--code-xl-phone-font-size", value: "min(var(--code-xl-desktop-font-size), calc(pow(var(--code-scale-base) * pow(var(--code-scale-ratio), 2), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1268
|
+
{ name: "--code-xl-font-size", value: "var(--code-xl-desktop-font-size)" },
|
|
1269
|
+
{ name: "--code-xl-font-weight", value: "var(--code-font-weight)" },
|
|
1270
|
+
{ name: "--code-xl-line-height", value: "var(--line-height-normal)" },
|
|
1271
|
+
{ name: "--code-xl-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1272
|
+
]
|
|
1273
|
+
},
|
|
1274
|
+
{
|
|
1275
|
+
prefix: "--code-lg",
|
|
1276
|
+
entries: [
|
|
1277
|
+
{ name: "--code-lg-font-family", value: "var(--code-font-family)" },
|
|
1278
|
+
{ name: "--code-lg-desktop-font-size", value: "calc(var(--code-scale-base) * pow(var(--code-scale-ratio), 1) * 1rem)" },
|
|
1279
|
+
{ name: "--code-lg-tablet-font-size", value: "min(var(--code-lg-desktop-font-size), calc(pow(var(--code-scale-base) * pow(var(--code-scale-ratio), 1), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1280
|
+
{ name: "--code-lg-phone-font-size", value: "min(var(--code-lg-desktop-font-size), calc(pow(var(--code-scale-base) * pow(var(--code-scale-ratio), 1), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1281
|
+
{ name: "--code-lg-font-size", value: "var(--code-lg-desktop-font-size)" },
|
|
1282
|
+
{ name: "--code-lg-font-weight", value: "var(--code-font-weight)" },
|
|
1283
|
+
{ name: "--code-lg-line-height", value: "var(--line-height-normal)" },
|
|
1284
|
+
{ name: "--code-lg-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1285
|
+
]
|
|
1286
|
+
},
|
|
1287
|
+
{
|
|
1288
|
+
prefix: "--code-md",
|
|
1289
|
+
entries: [
|
|
1290
|
+
{ name: "--code-md-font-family", value: "var(--code-font-family)" },
|
|
1291
|
+
{ name: "--code-md-desktop-font-size", value: "calc(var(--code-scale-base) * 1rem)" },
|
|
1292
|
+
{ name: "--code-md-tablet-font-size", value: "min(var(--code-md-desktop-font-size), calc(pow(var(--code-scale-base), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1293
|
+
{ name: "--code-md-phone-font-size", value: "min(var(--code-md-desktop-font-size), calc(pow(var(--code-scale-base), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1294
|
+
{ name: "--code-md-font-size", value: "var(--code-md-desktop-font-size)" },
|
|
1295
|
+
{ name: "--code-md-font-weight", value: "var(--code-font-weight)" },
|
|
1296
|
+
{ name: "--code-md-line-height", value: "var(--line-height-normal)" },
|
|
1297
|
+
{ name: "--code-md-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1298
|
+
]
|
|
1299
|
+
},
|
|
1300
|
+
{
|
|
1301
|
+
prefix: "--code-sm",
|
|
1302
|
+
entries: [
|
|
1303
|
+
{ name: "--code-sm-font-family", value: "var(--code-font-family)" },
|
|
1304
|
+
{ name: "--code-sm-desktop-font-size", value: "calc(var(--code-scale-base) * pow(var(--code-scale-ratio), -1) * 1rem)" },
|
|
1305
|
+
{ name: "--code-sm-tablet-font-size", value: "min(var(--code-sm-desktop-font-size), calc(pow(var(--code-scale-base) * pow(var(--code-scale-ratio), -1), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1306
|
+
{ name: "--code-sm-phone-font-size", value: "min(var(--code-sm-desktop-font-size), calc(pow(var(--code-scale-base) * pow(var(--code-scale-ratio), -1), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1307
|
+
{ name: "--code-sm-font-size", value: "var(--code-sm-desktop-font-size)" },
|
|
1308
|
+
{ name: "--code-sm-font-weight", value: "var(--code-font-weight)" },
|
|
1309
|
+
{ name: "--code-sm-line-height", value: "var(--line-height-normal)" },
|
|
1310
|
+
{ name: "--code-sm-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1311
|
+
]
|
|
1312
|
+
},
|
|
1313
|
+
{
|
|
1314
|
+
prefix: "--code-xs",
|
|
1315
|
+
entries: [
|
|
1316
|
+
{ name: "--code-xs-font-family", value: "var(--code-font-family)" },
|
|
1317
|
+
{ name: "--code-xs-desktop-font-size", value: "calc(var(--code-scale-base) * pow(var(--code-scale-ratio), -2) * 1rem)" },
|
|
1318
|
+
{ name: "--code-xs-tablet-font-size", value: "min(var(--code-xs-desktop-font-size), calc(pow(var(--code-scale-base) * pow(var(--code-scale-ratio), -2), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1319
|
+
{ name: "--code-xs-phone-font-size", value: "min(var(--code-xs-desktop-font-size), calc(pow(var(--code-scale-base) * pow(var(--code-scale-ratio), -2), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1320
|
+
{ name: "--code-xs-font-size", value: "var(--code-xs-desktop-font-size)" },
|
|
1321
|
+
{ name: "--code-xs-font-weight", value: "var(--code-font-weight)" },
|
|
1322
|
+
{ name: "--code-xs-line-height", value: "var(--line-height-normal)" },
|
|
1323
|
+
{ name: "--code-xs-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1324
|
+
]
|
|
1325
|
+
},
|
|
1326
|
+
{
|
|
1327
|
+
prefix: "--code-2xs",
|
|
1328
|
+
entries: [
|
|
1329
|
+
{ name: "--code-2xs-font-family", value: "var(--code-font-family)" },
|
|
1330
|
+
{ name: "--code-2xs-desktop-font-size", value: "calc(var(--code-scale-base) * pow(var(--code-scale-ratio), -3) * 1rem)" },
|
|
1331
|
+
{ name: "--code-2xs-tablet-font-size", value: "min(var(--code-2xs-desktop-font-size), calc(pow(var(--code-scale-base) * pow(var(--code-scale-ratio), -3), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1332
|
+
{ name: "--code-2xs-phone-font-size", value: "min(var(--code-2xs-desktop-font-size), calc(pow(var(--code-scale-base) * pow(var(--code-scale-ratio), -3), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1333
|
+
{ name: "--code-2xs-font-size", value: "var(--code-2xs-desktop-font-size)" },
|
|
1334
|
+
{ name: "--code-2xs-font-weight", value: "var(--code-font-weight)" },
|
|
1335
|
+
{ name: "--code-2xs-line-height", value: "var(--line-height-normal)" },
|
|
1336
|
+
{ name: "--code-2xs-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1337
|
+
]
|
|
1338
|
+
}
|
|
1339
|
+
]
|
|
1340
|
+
},
|
|
1341
|
+
{
|
|
1342
|
+
usage: "editorial",
|
|
1343
|
+
comment: "Editorial: the long-reading role",
|
|
1344
|
+
follows: "code",
|
|
1345
|
+
settings: [
|
|
1346
|
+
{ name: "--editorial-font-family", value: "var(--font-editorial)" },
|
|
1347
|
+
{ name: "--editorial-font-weight", value: "var(--font-weight-normal)" },
|
|
1348
|
+
{ name: "--editorial-scale-base", value: "1" },
|
|
1349
|
+
{ name: "--editorial-scale-ratio", value: "1.125" }
|
|
1350
|
+
],
|
|
1351
|
+
steps: [
|
|
1352
|
+
{
|
|
1353
|
+
prefix: "--editorial-2xl",
|
|
1354
|
+
entries: [
|
|
1355
|
+
{ name: "--editorial-2xl-font-family", value: "var(--editorial-font-family)" },
|
|
1356
|
+
{ name: "--editorial-2xl-desktop-font-size", value: "calc(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), 3) * 1rem)" },
|
|
1357
|
+
{ name: "--editorial-2xl-tablet-font-size", value: "min(var(--editorial-2xl-desktop-font-size), calc(pow(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), 3), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1358
|
+
{ name: "--editorial-2xl-phone-font-size", value: "min(var(--editorial-2xl-desktop-font-size), calc(pow(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), 3), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1359
|
+
{ name: "--editorial-2xl-font-size", value: "var(--editorial-2xl-desktop-font-size)" },
|
|
1360
|
+
{ name: "--editorial-2xl-font-weight", value: "var(--editorial-font-weight)" },
|
|
1361
|
+
{ name: "--editorial-2xl-line-height", value: "var(--line-height-tightest)" },
|
|
1362
|
+
{ name: "--editorial-2xl-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1363
|
+
]
|
|
1364
|
+
},
|
|
1365
|
+
{
|
|
1366
|
+
prefix: "--editorial-xl",
|
|
1367
|
+
entries: [
|
|
1368
|
+
{ name: "--editorial-xl-font-family", value: "var(--editorial-font-family)" },
|
|
1369
|
+
{ name: "--editorial-xl-desktop-font-size", value: "calc(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), 2) * 1rem)" },
|
|
1370
|
+
{ name: "--editorial-xl-tablet-font-size", value: "min(var(--editorial-xl-desktop-font-size), calc(pow(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), 2), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1371
|
+
{ name: "--editorial-xl-phone-font-size", value: "min(var(--editorial-xl-desktop-font-size), calc(pow(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), 2), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1372
|
+
{ name: "--editorial-xl-font-size", value: "var(--editorial-xl-desktop-font-size)" },
|
|
1373
|
+
{ name: "--editorial-xl-font-weight", value: "var(--editorial-font-weight)" },
|
|
1374
|
+
{ name: "--editorial-xl-line-height", value: "var(--line-height-tighter)" },
|
|
1375
|
+
{ name: "--editorial-xl-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1376
|
+
]
|
|
1377
|
+
},
|
|
1378
|
+
{
|
|
1379
|
+
prefix: "--editorial-lg",
|
|
1380
|
+
entries: [
|
|
1381
|
+
{ name: "--editorial-lg-font-family", value: "var(--editorial-font-family)" },
|
|
1382
|
+
{ name: "--editorial-lg-desktop-font-size", value: "calc(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), 1) * 1rem)" },
|
|
1383
|
+
{ name: "--editorial-lg-tablet-font-size", value: "min(var(--editorial-lg-desktop-font-size), calc(pow(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), 1), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1384
|
+
{ name: "--editorial-lg-phone-font-size", value: "min(var(--editorial-lg-desktop-font-size), calc(pow(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), 1), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1385
|
+
{ name: "--editorial-lg-font-size", value: "var(--editorial-lg-desktop-font-size)" },
|
|
1386
|
+
{ name: "--editorial-lg-font-weight", value: "var(--editorial-font-weight)" },
|
|
1387
|
+
{ name: "--editorial-lg-line-height", value: "var(--line-height-tight)" },
|
|
1388
|
+
{ name: "--editorial-lg-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1389
|
+
]
|
|
1390
|
+
},
|
|
1391
|
+
{
|
|
1392
|
+
prefix: "--editorial-md",
|
|
1393
|
+
entries: [
|
|
1394
|
+
{ name: "--editorial-md-font-family", value: "var(--editorial-font-family)" },
|
|
1395
|
+
{ name: "--editorial-md-desktop-font-size", value: "calc(var(--editorial-scale-base) * 1rem)" },
|
|
1396
|
+
{ name: "--editorial-md-tablet-font-size", value: "min(var(--editorial-md-desktop-font-size), calc(pow(var(--editorial-scale-base), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1397
|
+
{ name: "--editorial-md-phone-font-size", value: "min(var(--editorial-md-desktop-font-size), calc(pow(var(--editorial-scale-base), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1398
|
+
{ name: "--editorial-md-font-size", value: "var(--editorial-md-desktop-font-size)" },
|
|
1399
|
+
{ name: "--editorial-md-font-weight", value: "var(--editorial-font-weight)" },
|
|
1400
|
+
{ name: "--editorial-md-line-height", value: "var(--line-height-normal)" },
|
|
1401
|
+
{ name: "--editorial-md-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1402
|
+
]
|
|
1403
|
+
},
|
|
1404
|
+
{
|
|
1405
|
+
prefix: "--editorial-sm",
|
|
1406
|
+
entries: [
|
|
1407
|
+
{ name: "--editorial-sm-font-family", value: "var(--editorial-font-family)" },
|
|
1408
|
+
{ name: "--editorial-sm-desktop-font-size", value: "calc(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), -1) * 1rem)" },
|
|
1409
|
+
{ name: "--editorial-sm-tablet-font-size", value: "min(var(--editorial-sm-desktop-font-size), calc(pow(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), -1), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1410
|
+
{ name: "--editorial-sm-phone-font-size", value: "min(var(--editorial-sm-desktop-font-size), calc(pow(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), -1), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1411
|
+
{ name: "--editorial-sm-font-size", value: "var(--editorial-sm-desktop-font-size)" },
|
|
1412
|
+
{ name: "--editorial-sm-font-weight", value: "var(--editorial-font-weight)" },
|
|
1413
|
+
{ name: "--editorial-sm-line-height", value: "var(--line-height-tight)" },
|
|
1414
|
+
{ name: "--editorial-sm-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1415
|
+
]
|
|
1416
|
+
},
|
|
1417
|
+
{
|
|
1418
|
+
prefix: "--editorial-xs",
|
|
1419
|
+
entries: [
|
|
1420
|
+
{ name: "--editorial-xs-font-family", value: "var(--editorial-font-family)" },
|
|
1421
|
+
{ name: "--editorial-xs-desktop-font-size", value: "calc(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), -2) * 1rem)" },
|
|
1422
|
+
{ name: "--editorial-xs-tablet-font-size", value: "min(var(--editorial-xs-desktop-font-size), calc(pow(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), -2), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1423
|
+
{ name: "--editorial-xs-phone-font-size", value: "min(var(--editorial-xs-desktop-font-size), calc(pow(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), -2), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1424
|
+
{ name: "--editorial-xs-font-size", value: "var(--editorial-xs-desktop-font-size)" },
|
|
1425
|
+
{ name: "--editorial-xs-font-weight", value: "var(--editorial-font-weight)" },
|
|
1426
|
+
{ name: "--editorial-xs-line-height", value: "var(--line-height-tighter)" },
|
|
1427
|
+
{ name: "--editorial-xs-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1428
|
+
]
|
|
1429
|
+
},
|
|
1430
|
+
{
|
|
1431
|
+
prefix: "--editorial-2xs",
|
|
1432
|
+
entries: [
|
|
1433
|
+
{ name: "--editorial-2xs-font-family", value: "var(--editorial-font-family)" },
|
|
1434
|
+
{ name: "--editorial-2xs-desktop-font-size", value: "calc(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), -3) * 1rem)" },
|
|
1435
|
+
{ name: "--editorial-2xs-tablet-font-size", value: "min(var(--editorial-2xs-desktop-font-size), calc(pow(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), -3), var(--type-tablet-scale-compression)) * 1rem))" },
|
|
1436
|
+
{ name: "--editorial-2xs-phone-font-size", value: "min(var(--editorial-2xs-desktop-font-size), calc(pow(var(--editorial-scale-base) * pow(var(--editorial-scale-ratio), -3), var(--type-phone-scale-compression)) * 1rem))" },
|
|
1437
|
+
{ name: "--editorial-2xs-font-size", value: "var(--editorial-2xs-desktop-font-size)" },
|
|
1438
|
+
{ name: "--editorial-2xs-font-weight", value: "var(--editorial-font-weight)" },
|
|
1439
|
+
{ name: "--editorial-2xs-line-height", value: "var(--line-height-tighter)" },
|
|
1440
|
+
{ name: "--editorial-2xs-letter-spacing", value: "var(--letter-spacing-normal)" }
|
|
1441
|
+
]
|
|
1442
|
+
}
|
|
1443
|
+
]
|
|
1444
|
+
}
|
|
1445
|
+
];
|
|
1446
|
+
var EYEBROW = [
|
|
1447
|
+
{ name: "--eyebrow-font-family", value: "var(--body-font-family)" },
|
|
1448
|
+
{ name: "--eyebrow-desktop-font-size", value: "var(--body-sm-desktop-font-size)" },
|
|
1449
|
+
{ name: "--eyebrow-tablet-font-size", value: "var(--body-sm-tablet-font-size)" },
|
|
1450
|
+
{ name: "--eyebrow-phone-font-size", value: "var(--body-sm-phone-font-size)" },
|
|
1451
|
+
{ name: "--eyebrow-font-size", value: "var(--eyebrow-desktop-font-size)" },
|
|
1452
|
+
{ name: "--eyebrow-font-weight", value: "var(--body-font-weight)" },
|
|
1453
|
+
{ name: "--eyebrow-line-height", value: "var(--line-height-normal)" },
|
|
1454
|
+
{ name: "--eyebrow-letter-spacing", value: "var(--letter-spacing-normal)" },
|
|
1455
|
+
{ name: "--eyebrow-text-transform", value: "none" }
|
|
1456
|
+
];
|
|
1457
|
+
var MEDIA = [
|
|
1458
|
+
{
|
|
1459
|
+
query: "(max-width: 768px)",
|
|
1460
|
+
entries: [
|
|
1461
|
+
{ name: "--display-2xl-font-size", value: "var(--display-2xl-tablet-font-size)" },
|
|
1462
|
+
{ name: "--display-xl-font-size", value: "var(--display-xl-tablet-font-size)" },
|
|
1463
|
+
{ name: "--display-lg-font-size", value: "var(--display-lg-tablet-font-size)" },
|
|
1464
|
+
{ name: "--display-md-font-size", value: "var(--display-md-tablet-font-size)" },
|
|
1465
|
+
{ name: "--display-sm-font-size", value: "var(--display-sm-tablet-font-size)" },
|
|
1466
|
+
{ name: "--display-xs-font-size", value: "var(--display-xs-tablet-font-size)" },
|
|
1467
|
+
{ name: "--display-2xs-font-size", value: "var(--display-2xs-tablet-font-size)" },
|
|
1468
|
+
{ name: "--heading-2xl-font-size", value: "var(--heading-2xl-tablet-font-size)" },
|
|
1469
|
+
{ name: "--heading-xl-font-size", value: "var(--heading-xl-tablet-font-size)" },
|
|
1470
|
+
{ name: "--heading-lg-font-size", value: "var(--heading-lg-tablet-font-size)" },
|
|
1471
|
+
{ name: "--heading-md-font-size", value: "var(--heading-md-tablet-font-size)" },
|
|
1472
|
+
{ name: "--heading-sm-font-size", value: "var(--heading-sm-tablet-font-size)" },
|
|
1473
|
+
{ name: "--heading-xs-font-size", value: "var(--heading-xs-tablet-font-size)" },
|
|
1474
|
+
{ name: "--heading-2xs-font-size", value: "var(--heading-2xs-tablet-font-size)" },
|
|
1475
|
+
{ name: "--body-2xl-font-size", value: "var(--body-2xl-tablet-font-size)" },
|
|
1476
|
+
{ name: "--body-xl-font-size", value: "var(--body-xl-tablet-font-size)" },
|
|
1477
|
+
{ name: "--body-lg-font-size", value: "var(--body-lg-tablet-font-size)" },
|
|
1478
|
+
{ name: "--body-md-font-size", value: "var(--body-md-tablet-font-size)" },
|
|
1479
|
+
{ name: "--body-sm-font-size", value: "var(--body-sm-tablet-font-size)" },
|
|
1480
|
+
{ name: "--body-xs-font-size", value: "var(--body-xs-tablet-font-size)" },
|
|
1481
|
+
{ name: "--body-2xs-font-size", value: "var(--body-2xs-tablet-font-size)" },
|
|
1482
|
+
{ name: "--editorial-2xl-font-size", value: "var(--editorial-2xl-tablet-font-size)" },
|
|
1483
|
+
{ name: "--editorial-xl-font-size", value: "var(--editorial-xl-tablet-font-size)" },
|
|
1484
|
+
{ name: "--editorial-lg-font-size", value: "var(--editorial-lg-tablet-font-size)" },
|
|
1485
|
+
{ name: "--editorial-md-font-size", value: "var(--editorial-md-tablet-font-size)" },
|
|
1486
|
+
{ name: "--editorial-sm-font-size", value: "var(--editorial-sm-tablet-font-size)" },
|
|
1487
|
+
{ name: "--editorial-xs-font-size", value: "var(--editorial-xs-tablet-font-size)" },
|
|
1488
|
+
{ name: "--editorial-2xs-font-size", value: "var(--editorial-2xs-tablet-font-size)" },
|
|
1489
|
+
{ name: "--code-2xl-font-size", value: "var(--code-2xl-tablet-font-size)" },
|
|
1490
|
+
{ name: "--code-xl-font-size", value: "var(--code-xl-tablet-font-size)" },
|
|
1491
|
+
{ name: "--code-lg-font-size", value: "var(--code-lg-tablet-font-size)" },
|
|
1492
|
+
{ name: "--code-md-font-size", value: "var(--code-md-tablet-font-size)" },
|
|
1493
|
+
{ name: "--code-sm-font-size", value: "var(--code-sm-tablet-font-size)" },
|
|
1494
|
+
{ name: "--code-xs-font-size", value: "var(--code-xs-tablet-font-size)" },
|
|
1495
|
+
{ name: "--code-2xs-font-size", value: "var(--code-2xs-tablet-font-size)" },
|
|
1496
|
+
{ name: "--eyebrow-font-size", value: "var(--eyebrow-tablet-font-size)" }
|
|
1497
|
+
]
|
|
1498
|
+
},
|
|
1499
|
+
{
|
|
1500
|
+
query: "(max-width: 480px)",
|
|
1501
|
+
entries: [
|
|
1502
|
+
{ name: "--display-2xl-font-size", value: "var(--display-2xl-phone-font-size)" },
|
|
1503
|
+
{ name: "--display-xl-font-size", value: "var(--display-xl-phone-font-size)" },
|
|
1504
|
+
{ name: "--display-lg-font-size", value: "var(--display-lg-phone-font-size)" },
|
|
1505
|
+
{ name: "--display-md-font-size", value: "var(--display-md-phone-font-size)" },
|
|
1506
|
+
{ name: "--display-sm-font-size", value: "var(--display-sm-phone-font-size)" },
|
|
1507
|
+
{ name: "--display-xs-font-size", value: "var(--display-xs-phone-font-size)" },
|
|
1508
|
+
{ name: "--display-2xs-font-size", value: "var(--display-2xs-phone-font-size)" },
|
|
1509
|
+
{ name: "--heading-2xl-font-size", value: "var(--heading-2xl-phone-font-size)" },
|
|
1510
|
+
{ name: "--heading-xl-font-size", value: "var(--heading-xl-phone-font-size)" },
|
|
1511
|
+
{ name: "--heading-lg-font-size", value: "var(--heading-lg-phone-font-size)" },
|
|
1512
|
+
{ name: "--heading-md-font-size", value: "var(--heading-md-phone-font-size)" },
|
|
1513
|
+
{ name: "--heading-sm-font-size", value: "var(--heading-sm-phone-font-size)" },
|
|
1514
|
+
{ name: "--heading-xs-font-size", value: "var(--heading-xs-phone-font-size)" },
|
|
1515
|
+
{ name: "--heading-2xs-font-size", value: "var(--heading-2xs-phone-font-size)" },
|
|
1516
|
+
{ name: "--body-2xl-font-size", value: "var(--body-2xl-phone-font-size)" },
|
|
1517
|
+
{ name: "--body-xl-font-size", value: "var(--body-xl-phone-font-size)" },
|
|
1518
|
+
{ name: "--body-lg-font-size", value: "var(--body-lg-phone-font-size)" },
|
|
1519
|
+
{ name: "--body-md-font-size", value: "var(--body-md-phone-font-size)" },
|
|
1520
|
+
{ name: "--body-sm-font-size", value: "var(--body-sm-phone-font-size)" },
|
|
1521
|
+
{ name: "--body-xs-font-size", value: "var(--body-xs-phone-font-size)" },
|
|
1522
|
+
{ name: "--body-2xs-font-size", value: "var(--body-2xs-phone-font-size)" },
|
|
1523
|
+
{ name: "--editorial-2xl-font-size", value: "var(--editorial-2xl-phone-font-size)" },
|
|
1524
|
+
{ name: "--editorial-xl-font-size", value: "var(--editorial-xl-phone-font-size)" },
|
|
1525
|
+
{ name: "--editorial-lg-font-size", value: "var(--editorial-lg-phone-font-size)" },
|
|
1526
|
+
{ name: "--editorial-md-font-size", value: "var(--editorial-md-phone-font-size)" },
|
|
1527
|
+
{ name: "--editorial-sm-font-size", value: "var(--editorial-sm-phone-font-size)" },
|
|
1528
|
+
{ name: "--editorial-xs-font-size", value: "var(--editorial-xs-phone-font-size)" },
|
|
1529
|
+
{ name: "--editorial-2xs-font-size", value: "var(--editorial-2xs-phone-font-size)" },
|
|
1530
|
+
{ name: "--code-2xl-font-size", value: "var(--code-2xl-phone-font-size)" },
|
|
1531
|
+
{ name: "--code-xl-font-size", value: "var(--code-xl-phone-font-size)" },
|
|
1532
|
+
{ name: "--code-lg-font-size", value: "var(--code-lg-phone-font-size)" },
|
|
1533
|
+
{ name: "--code-md-font-size", value: "var(--code-md-phone-font-size)" },
|
|
1534
|
+
{ name: "--code-sm-font-size", value: "var(--code-sm-phone-font-size)" },
|
|
1535
|
+
{ name: "--code-xs-font-size", value: "var(--code-xs-phone-font-size)" },
|
|
1536
|
+
{ name: "--code-2xs-font-size", value: "var(--code-2xs-phone-font-size)" },
|
|
1537
|
+
{ name: "--eyebrow-font-size", value: "var(--eyebrow-phone-font-size)" }
|
|
1538
|
+
]
|
|
1539
|
+
}
|
|
1540
|
+
];
|
|
1541
|
+
var DECLARED = new Map(
|
|
1542
|
+
USAGES.flatMap((u) => u.steps.flatMap((s) => s.entries)).concat(EYEBROW).map((e) => [e.name, e.value])
|
|
1543
|
+
);
|
|
1544
|
+
var TYPE_PRIMITIVES = ["--letter-spacing-", "--line-height-", "--font-weight-", "--font-size-", "--font-"];
|
|
1545
|
+
var tokensCssMigration_2026_10_08_typeScales = {
|
|
1546
|
+
id: "2026-10-08-type-scales",
|
|
1547
|
+
kind: "breaking",
|
|
1548
|
+
description: "Rebuild the text styles as five type scales with per-viewport sizes, and rename --code-font-size, --code-line-height and --code-letter-spacing to --code-md-*",
|
|
1549
|
+
apply(css) {
|
|
1550
|
+
let out = css;
|
|
1551
|
+
for (const [from, to] of RENAMES3) out = renameToken(out, from, to);
|
|
1552
|
+
const values = collectTokenValues(out);
|
|
1553
|
+
for (const step of CARRIED) {
|
|
1554
|
+
const size = values.get(`${step.prefix}-font-size`);
|
|
1555
|
+
if (size === void 0) continue;
|
|
1556
|
+
const desktop = `${step.prefix}-desktop-font-size`;
|
|
1557
|
+
const edited = size !== step.size;
|
|
1558
|
+
const rem = edited ? literalRem(size) : null;
|
|
1559
|
+
out = ensureScale(out, {
|
|
1560
|
+
anchorPrefixes: [`${step.prefix}-font-family`, `${step.prefix}-`],
|
|
1561
|
+
entries: [
|
|
1562
|
+
{ name: desktop, value: edited ? size : DECLARED.get(desktop) },
|
|
1563
|
+
...rem === null ? [] : editedSizes(step.prefix, rem)
|
|
1564
|
+
]
|
|
1565
|
+
});
|
|
1566
|
+
out = setTokenValue(out, `${step.prefix}-font-size`, `var(${desktop})`);
|
|
1567
|
+
for (const link of step.links) out = setTokenValue(out, link.name, link.to, { from: link.from });
|
|
1568
|
+
}
|
|
1569
|
+
out = ensureScale(out, {
|
|
1570
|
+
sectionComment: "Text styles: the compression that sets each tablet and phone size",
|
|
1571
|
+
anchorPrefixes: ["--type-", ...TYPE_PRIMITIVES],
|
|
1572
|
+
entries: COMPRESSION
|
|
1573
|
+
});
|
|
1574
|
+
for (const block of USAGES) {
|
|
1575
|
+
const fallback = [`--${block.usage}-scale-`, `--${block.follows}-`, "--type-"];
|
|
1576
|
+
out = ensureScale(out, { sectionComment: block.comment, anchorPrefixes: fallback, entries: block.settings });
|
|
1577
|
+
block.steps.forEach((step, i) => {
|
|
1578
|
+
const above = block.steps.slice(0, i).reverse().map((s) => `${s.prefix}-`);
|
|
1579
|
+
out = ensureScale(out, {
|
|
1580
|
+
anchorPrefixes: [
|
|
1581
|
+
`${step.prefix}-desktop-font-size`,
|
|
1582
|
+
`${step.prefix}-font-family`,
|
|
1583
|
+
`${step.prefix}-`,
|
|
1584
|
+
...above,
|
|
1585
|
+
...fallback
|
|
1586
|
+
],
|
|
1587
|
+
entries: step.entries
|
|
1588
|
+
});
|
|
1589
|
+
});
|
|
1590
|
+
}
|
|
1591
|
+
out = ensureScale(out, {
|
|
1592
|
+
anchorPrefixes: ["--eyebrow-desktop-font-size", "--eyebrow-font-family", "--eyebrow-", "--editorial-"],
|
|
1593
|
+
entries: EYEBROW
|
|
1594
|
+
});
|
|
1595
|
+
for (const media of MEDIA) out = appendMediaBlock(out, media.query, media.entries);
|
|
1596
|
+
return out;
|
|
1597
|
+
}
|
|
1598
|
+
};
|
|
1599
|
+
|
|
682
1600
|
// vite-plugin/files/dataPaths.ts
|
|
683
1601
|
var import_fs = __toESM(require("fs"), 1);
|
|
684
1602
|
var import_path = __toESM(require("path"), 1);
|
|
@@ -733,7 +1651,8 @@ var TOKENS_CSS_MIGRATIONS = [
|
|
|
733
1651
|
tokensCssMigration_2026_09_01_scrimRename,
|
|
734
1652
|
tokensCssMigration_2026_09_01_tintScale,
|
|
735
1653
|
tokensCssMigration_2026_09_20_scrimColorAndOpacity,
|
|
736
|
-
tokensCssMigration_2026_09_21_tintColorAndOpacity
|
|
1654
|
+
tokensCssMigration_2026_09_21_tintColorAndOpacity,
|
|
1655
|
+
tokensCssMigration_2026_10_08_typeScales
|
|
737
1656
|
];
|
|
738
1657
|
function runTokensCssMigrations(css) {
|
|
739
1658
|
return foldMigrations(css, () => true);
|
|
@@ -821,6 +1740,7 @@ function validateTokensCss(input) {
|
|
|
821
1740
|
// Annotate the CommonJS export names for ESM import in node:
|
|
822
1741
|
0 && (module.exports = {
|
|
823
1742
|
TOKENS_CSS_MIGRATIONS,
|
|
1743
|
+
appendMediaBlock,
|
|
824
1744
|
collectDefinedTokens,
|
|
825
1745
|
collectReferencedTokens,
|
|
826
1746
|
collectTokenValues,
|
|
@@ -834,5 +1754,6 @@ function validateTokensCss(input) {
|
|
|
834
1754
|
runAdditiveTokensCssMigrations,
|
|
835
1755
|
runTokensCssMigrations,
|
|
836
1756
|
semverBumpType,
|
|
1757
|
+
setTokenValue,
|
|
837
1758
|
validateTokensCss
|
|
838
1759
|
});
|