diff --git a/packages/sketch/src/commands/themes/generate.js b/packages/sketch/src/commands/themes/generate.js index 8b9da9f012b1..7a129003c49a 100644 --- a/packages/sketch/src/commands/themes/generate.js +++ b/packages/sketch/src/commands/themes/generate.js @@ -21,7 +21,7 @@ export function generate() { command('commands/themes/generate', () => { const document = Document.getSelectedDocument(); const page = selectPage(findOrCreatePage(document, 'themes')); - const sharedStyles = syncThemeColorStyles(document, 'fill'); + const sharedStyles = syncThemeColorStyles(document); const tokens = groupByKey(sharedStyles, (sharedStyle) => { const [_namespace, _category, _group, token] = sharedStyle.name.split( diff --git a/packages/sketch/src/commands/themes/sync.js b/packages/sketch/src/commands/themes/sync.js index 4868bc5756e4..2314f035b16d 100644 --- a/packages/sketch/src/commands/themes/sync.js +++ b/packages/sketch/src/commands/themes/sync.js @@ -12,6 +12,6 @@ import { syncThemeColorStyles } from '../../sharedStyles/themes'; export function sync() { command('commands/themes/sync', () => { const document = Document.getSelectedDocument(); - syncThemeColorStyles(document, 'fill'); + syncThemeColorStyles(document); }); } diff --git a/packages/sketch/src/sharedStyles/themes.js b/packages/sketch/src/sharedStyles/themes.js index 04e5054f95cd..909080254937 100644 --- a/packages/sketch/src/sharedStyles/themes.js +++ b/packages/sketch/src/sharedStyles/themes.js @@ -21,10 +21,9 @@ const { colors } = tokens; /** * Sync theme color shared styles to the given document and return the result * @param {Document} document - * @param {string} styleType * @returns {Array} */ -export function syncThemeColorStyles(document, styleType) { +export function syncThemeColorStyles(document) { const themes = { 'White theme': white, 'Gray 10 theme': g10, @@ -48,7 +47,6 @@ export function syncThemeColorStyles(document, styleType) { document, name, value: themes[theme][token], - type: styleType, }); }); });