Skip to content

Commit

Permalink
rm fallbacks for themes
Browse files Browse the repository at this point in the history
  • Loading branch information
lukasoppermann committed May 16, 2023
1 parent ebaade4 commit be483ee
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
9 changes: 8 additions & 1 deletion scripts/buildTokens.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,14 @@ export const buildDesignTokens = (buildOptions: ConfigGeneratorOptions): void =>
for (const {filename, source, include} of themes) {
// build functional scales
PrimerStyleDictionary.extend(
getStyleDictionaryConfig(`functional/themes/${filename}`, source, include, {...buildOptions, themed: true}),
getStyleDictionaryConfig(
`functional/themes/${filename}`,
source,
include,
{...buildOptions, themed: true},
// disable fallbacks for themes
{fallbacks: undefined},
),
).buildAllPlatforms()
}

Expand Down
2 changes: 1 addition & 1 deletion src/types/StyleDictionaryConfigGenerator.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@ export type StyleDictionaryConfigGenerator = (
source: string[],
include: string[],
options: ConfigGeneratorOptions,
platforms?: Record<string, StyleDictionary.Platform>,
platforms?: Record<string, StyleDictionary.Platform | undefined>,
) => StyleDictionary.Config

0 comments on commit be483ee

Please sign in to comment.