All sorts of BS

This commit is contained in:
Aarni Halinen
2020-10-08 23:33:51 +03:00
parent 1b6bee5493
commit 8e883d7eac
37 changed files with 414 additions and 564 deletions
+25 -7
View File
@@ -14,11 +14,22 @@ export type Colors =
"transparent" |
"inherit";
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 const ColorMapper = new Map<Colors, string>([
["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 = {
darkBlue: "#002d3a",
@@ -32,5 +43,12 @@ export const colors = {
blue1: "#57b2df",
lightTurquoise: "#beddeb",
green1: "#c0dcd9",
sand: "#fdf9d7"
}
sand: "#fdf9d7",
transparent: "transparent",
inherit: "inherit"
}
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;