Skip to content

Commit 7ce9e3a

Browse files
committed
fix: cleaned up color palettes
1 parent 156ff09 commit 7ce9e3a

File tree

2 files changed

+29
-88
lines changed

2 files changed

+29
-88
lines changed

src/themes/index.d.ts

Lines changed: 0 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import {
22
FederalBreakpointOverrides,
3-
FederalColor,
43
FederalTypographyPropsVariantOverrides,
54
FederalTypographyVariants,
65
FederalTypographyVariantsOptions,
@@ -45,40 +44,6 @@ declare module "@mui/material/Typography" {
4544

4645
declare module "@mui/material/styles" {
4746
interface BreakpointOverrides extends FederalBreakpointOverrides {}
48-
49-
interface Palette {
50-
cobalt: FederalColor & { main: string };
51-
monochrome: FederalColor & { main: string };
52-
red: FederalColor & { main: string };
53-
blue: FederalColor & { main: string };
54-
green: FederalColor & { main: string };
55-
yellow: FederalColor & { main: string };
56-
purple: FederalColor & { main: string };
57-
teal: FederalColor & { main: string };
58-
pink: FederalColor & { main: string };
59-
orange: FederalColor & { main: string };
60-
indigo: FederalColor & { main: string };
61-
62-
categorical: string[];
63-
sequential: string[];
64-
}
65-
66-
interface PaletteOptions {
67-
cobalt: FederalColor & { main: string };
68-
monochrome: FederalColor & { main: string };
69-
red: FederalColor & { main: string };
70-
blue: FederalColor & { main: string };
71-
green: FederalColor & { main: string };
72-
yellow: FederalColor & { main: string };
73-
purple: FederalColor & { main: string };
74-
teal: FederalColor & { main: string };
75-
pink: FederalColor & { main: string };
76-
orange: FederalColor & { main: string };
77-
indigo: FederalColor & { main: string };
78-
79-
categorical: string[];
80-
sequential: string[];
81-
}
8247
}
8348

8449
export { theme } from "./elcom";

src/themes/palette.ts

Lines changed: 29 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -5,66 +5,42 @@ export const palette = {
55
...colors,
66
text: {
77
primary: colors.monochrome[800],
8+
...colors.monochrome,
89
},
910
primary: {
1011
main: "#D8232A",
1112
contrastText: "#FFFFFF",
12-
},
13-
cobalt: {
14-
main: colors.cobalt[700],
15-
...colors.cobalt,
13+
...colors.red,
1614
},
1715
secondary: {
1816
main: colors.cobalt[700],
1917
...colors.cobalt,
2018
},
21-
monochrome: {
22-
main: colors.monochrome[700],
23-
...colors.monochrome,
24-
},
25-
red: {
26-
main: colors.red[700],
27-
...colors.red,
28-
},
29-
yellow: {
30-
main: "#B45309",
31-
50: "#FFFBEB",
32-
100: "#FEF3C7",
33-
200: "#FDE68A",
34-
300: "#FCD34D",
35-
400: "#FBBF24",
36-
500: "#F59E0B",
37-
600: "#D97706",
38-
700: "#B45309",
39-
800: "#92400E",
40-
900: "#78350F",
41-
},
42-
green: {
43-
main: "#047857",
44-
50: "#ECFDF5",
45-
100: "#D1FAE5",
46-
200: "#A7F3D0",
47-
300: "#6EE7B7",
48-
400: "#34D399",
49-
500: "#10B981",
50-
600: "#059669",
51-
700: "#047857",
52-
800: "#065F46",
53-
900: "#064E3B",
54-
},
55-
blue: {
56-
main: "#1D4ED8",
57-
50: "#EFF6FF",
58-
100: "#DBEAFE",
59-
200: "#BFDBFE",
60-
300: "#93C5FD",
61-
400: "#60A5FA",
62-
500: "#3B82F6",
63-
600: "#2563EB",
64-
700: "#1D4ED8",
65-
800: "#1E40AF",
66-
900: "#1E3A8A",
67-
},
68-
diverging: ["#51b581", "#a8dc90", "#e7ec83", "#f1b865", "#eb7c40"],
69-
categorical: ["#64afe9", "#01ADA1", "#939CB4", "#91C34B", "#E89F00"],
7019
} satisfies ThemeOptions["palette"];
20+
21+
// FIXME: Bring back once we use it to prevent knip from causing issues
22+
// export const chartPalette = {
23+
// categorical: [
24+
// "#3B82F6",
25+
// "#EC4899",
26+
// "#10B981",
27+
// "#8B5CF6",
28+
// "#059669",
29+
// "#6B7280",
30+
// "#EA580C",
31+
// ],
32+
// sequential: {
33+
// yellow: ["#FDE68A", "#FCD34D", "#FBBF24", "#F59E0B", "#D97706", "#B45309"],
34+
// orange: ["#FED7AA", "#FDBA74", "#FB923C", "#F97316", "#EA580C", "#C2410C"],
35+
// green: ["#A7F3D0", "#6EE7B7", "#34D399", "#10B981", "#059669", "#047857"],
36+
// teal: ["#98F6F3", "#5DE8EA", "#2BCED4", "#14AFB8", "#0D8B96", "#0F6B75"],
37+
// blue: ["#BFDBFE", "#93C5FD", "#60A5FA", "#3B82F6", "#2563EB", "#1D4ED8"],
38+
// indigo: ["#E0E7FF", "#C7D2FE", "#A5B4FC", "#818CF8", "#6366F1", "#4338CA"],
39+
// purple: ["#EDE9FE", "#DDD6FE", "#C4B5FD", "#A78BFA", "#8B5CF6", "#7C3AED"],
40+
// pink: ["#FBCFE8", "#F9A8D4", "#F472B6", "#EC4899", "#DB2777", "#BE185D"],
41+
// },
42+
// diverging: {
43+
// BP: ["#2563EB", "#60A5FA", "#BFDBFE", "#FBCFE8", "#DB2777"],
44+
// GO: ["#059669", "#34D399", "#A7F3D0", "#E4D78C", "#EA580C"],
45+
// },
46+
// };

0 commit comments

Comments
 (0)