🔧 Add ff for typography composite token

This commit is contained in:
Florian Schroedl
2025-08-27 12:47:46 +02:00
committed by Andrés Moya
parent 2a5f1f870b
commit a20bbeff79
3 changed files with 7 additions and 1 deletions

View File

@@ -120,6 +120,7 @@
:tiered-file-data-storage
:token-units
:token-typography-types
:token-typography-composite
:transit-readable-response
:user-feedback
;; TODO: remove this flag.

View File

@@ -84,7 +84,10 @@ const setupTypographyTokensFile = async (page, options = {}) => {
return setupTokensFile(page, {
file: "workspace/get-file-typography-tokens.json",
fileFragment: "workspace/get-file-fragment-typography-tokens.json",
flags: ["enable-token-typography-types"],
flags: [
"enable-token-typography-types",
"enable-token-typography-composite",
],
...options,
});
};

View File

@@ -32,9 +32,11 @@
If `:token-units` is not in cf/flags, number tokens are excluded."
[tokens-by-type]
(let [token-units? (contains? cf/flags :token-units)
token-typography-composite-types? (contains? cf/flags :token-typography-composite)
token-typography-types? (contains? cf/flags :token-typography-types)
all-types (cond-> dwta/token-properties
(not token-units?) (dissoc :number)
(not token-typography-composite-types?) (remove-keys ctt/typography-token-keys)
(not token-typography-types?) (remove-keys ctt/ff-typography-keys))
all-types (-> all-types keys seq)]
(loop [empty #js []