From 8536f3cc320d550340a834c8357e1c8fd4318649 Mon Sep 17 00:00:00 2001 From: Henry Jameson Date: Thu, 16 Jan 2020 21:59:06 +0200 Subject: [PATCH] small fix --- src/components/style_switcher/style_switcher.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/style_switcher/style_switcher.js b/src/components/style_switcher/style_switcher.js index b78d8236..03cbb2a1 100644 --- a/src/components/style_switcher/style_switcher.js +++ b/src/components/style_switcher/style_switcher.js @@ -163,8 +163,8 @@ export default { ) if (!slotIsText) return acc const { layer, variant } = slotIsBaseText ? { layer: 'bg' } : value - const opacitySlot = getOpacitySlot(SLOT_INHERITANCE[variant || layer]) const background = variant || layer + const opacitySlot = getOpacitySlot(SLOT_INHERITANCE[background]) const textColors = [ key, ...(background === 'bg' ? ['cRed', 'cGreen', 'cBlue', 'cOrange'] : [])