From d7e220fd0cc0f0c9307c03cf64c4896f424cb185 Mon Sep 17 00:00:00 2001 From: Lukas Oppermann Date: Thu, 19 Dec 2024 12:42:04 +0100 Subject: [PATCH] fix --- src/preprocessors/themeOverrides.ts | 1 + src/transformers/colorToHex.ts | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/preprocessors/themeOverrides.ts b/src/preprocessors/themeOverrides.ts index 897fbef0a..80019741e 100644 --- a/src/preprocessors/themeOverrides.ts +++ b/src/preprocessors/themeOverrides.ts @@ -21,6 +21,7 @@ export const themeOverrides: Preprocessor = { // get override const override = token.$extensions?.[extensionProp][currentTheme] || token.$extensions?.[extensionProp][fallbackTheme] + // token an theme value exist return { ...token, diff --git a/src/transformers/colorToHex.ts b/src/transformers/colorToHex.ts index bd39c5c61..74a651b2b 100644 --- a/src/transformers/colorToHex.ts +++ b/src/transformers/colorToHex.ts @@ -16,7 +16,7 @@ export const colorToHex: Transform = { filter: isColor, transform: (token: TransformedToken, config: PlatformConfig) => { const alphaValue = token.alpha - if (alphaValue === null || alphaValue === undefined) { + if (alphaValue === null || alphaValue === undefined || alphaValue === 1) { return toHex(getTokenValue(token)) } return toHex(alpha(getTokenValue(token), alphaValue, token, config))