From fa4ae2c8126dd0023e85a30cd9c6efaae3e2f4e4 Mon Sep 17 00:00:00 2001 From: Aarni Halinen Date: Thu, 3 Jun 2021 02:14:50 +0300 Subject: [PATCH] clean colors.ts --- src/theme/colors.ts | 46 +-------------------------------------------- 1 file changed, 1 insertion(+), 45 deletions(-) diff --git a/src/theme/colors.ts b/src/theme/colors.ts index ea83e2b..03da1be 100644 --- a/src/theme/colors.ts +++ b/src/theme/colors.ts @@ -1,41 +1,4 @@ -export type Colors = - "sik100-gold" | - "sik100-blue" | - "dark-blue" | - "light-blue" | - "white1" | - "black1" | - "grey1" | - "grey2" | - "orange1" | - "orange2" | - "blue1" | - "light-turquoise" | - "green1" | - "sand" | - "transparent" | - "inherit"; - -export const ColorMapper = new Map([ - ["sik100-gold", "#fee469"], - ["sik100-blue", "#12123d"], - ["dark-blue", "#002d3a"], - ["light-blue", "#bfdbd9"], - ["white1", "#fff"], - ["black1", "#000"], - ["grey1", "#d4d0c7"], - ["grey2", "#efece4"], - ["orange1", "#d57a2d"], - ["orange2", "#dd934e"], - ["blue1", "#57b2df"], - ["light-turquoise", "#beddeb"], - ["green1", "#c0dcd9"], - ["sand", "#fdf9d7"], - ["transparent", "transparent"], - ["inherit", "inherit"], -]); - -export const colors = { +const colors = { sik100Gold: "#fee469", sik100Blue: "#12123d", darkBlue: "#002d3a", @@ -54,11 +17,4 @@ export const colors = { inherit: "inherit", }; -export type Colors2 = keyof typeof colors; - -export const colorToClass = (color: Colors): string => (color ? `color-div__${color}` : undefined); -export const bgColorToClass = (color: Colors): string => (color ? `color-div__background_${color}` : undefined); -export const hoverColorToClass = (color: Colors): string => (color ? `color-div__${color}Hoverable` : undefined); -export const bgHoverColorToClass = (color: Colors): string => (color ? `color-div__background_${color}Hoverable` : undefined); - export default colors;