adminFront/src/theme.ts

122 lines
2.2 KiB
TypeScript
Raw Normal View History

2022-09-09 13:54:49 +00:00
import { createTheme, PaletteColorOptions } from "@mui/material";
2022-09-05 14:57:41 +00:00
//import { createTheme } from "./types";
2022-09-02 06:36:26 +00:00
2022-09-05 14:57:41 +00:00
const fontFamily: string = "GilroyRegular";
const fontWeight: string = "600";
2022-09-02 06:36:26 +00:00
const theme = createTheme({
palette: {
primary: {
2022-09-09 13:54:49 +00:00
main: "#111217"
2022-09-02 06:36:26 +00:00
},
2022-09-05 14:57:41 +00:00
secondary: {
main: "#ffffff"
},
2022-09-09 13:54:49 +00:00
menu: {
main: "#2f3339"
},
content: {
main: "#26272c"
},
gray: {
main: "#707070"
},
golden: {
main: "#eaba5b"
},
goldenDark: {
main: "#fe9903"
2022-09-05 14:57:41 +00:00
}
},
typography: {
body1: {
fontFamily: fontFamily
},
subtitle1: {
fontFamily: fontFamily,
fontWeight: fontWeight,
2022-09-06 11:52:36 +00:00
fontSize: 25
2022-09-05 14:57:41 +00:00
},
subtitle2: {
fontFamily: fontFamily,
2022-09-08 17:21:17 +00:00
fontSize: 25,
textAlign: "center"
2022-09-05 14:57:41 +00:00
},
caption: {
fontFamily: fontFamily,
fontWeight: fontWeight,
2022-09-06 11:52:36 +00:00
fontSize: 21
2022-09-05 14:57:41 +00:00
},
h5: {
fontFamily: fontFamily,
fontWeight: fontWeight,
2022-09-06 11:52:36 +00:00
fontSize: 35
2022-09-05 14:57:41 +00:00
},
h6: {
fontFamily: fontFamily,
fontWeight: fontWeight,
2022-09-08 17:21:17 +00:00
fontSize: 18,
textAlign: "center"
2022-09-05 14:57:41 +00:00
},
2022-09-06 11:52:36 +00:00
button: {
fontFamily: fontFamily,
fontWeight: fontWeight,
fontSize: 22
},
h4: {
fontFamily: fontFamily,
fontWeight: fontWeight,
fontSize: 16
}
2022-09-02 06:36:26 +00:00
},
});
2022-09-05 14:57:41 +00:00
declare module '@mui/material/styles' {
interface Theme {
palette: {
primary: {
2022-09-09 13:54:49 +00:00
main: string
2022-09-05 14:57:41 +00:00
},
secondary: {
main: string;
2022-09-06 11:52:36 +00:00
},
2022-09-09 13:54:49 +00:00
menu: {
main: string;
},
content: {
2022-09-06 11:52:36 +00:00
main: string;
2022-09-09 13:54:49 +00:00
},
gray: {
main: string;
},
golden: {
main: string;
},
goldenDark: {
main: string;
},
2022-09-05 14:57:41 +00:00
}
}
2022-09-09 13:54:49 +00:00
interface PaletteOptions {
menu?: PaletteColorOptions;
content?: PaletteColorOptions;
gray?: PaletteColorOptions;
golden?: PaletteColorOptions;
goldenDark?: PaletteColorOptions;
}
2022-09-05 14:57:41 +00:00
// allow configuration using `createTheme`
interface TypographyVariants {
body1: React.CSSProperties;
subtitle1: React.CSSProperties;
subtitle2: React.CSSProperties;
caption: React.CSSProperties;
h5: React.CSSProperties;
h6: React.CSSProperties;
2022-09-06 11:52:36 +00:00
button: React.CSSProperties;
2022-09-05 14:57:41 +00:00
}
}
2022-09-02 06:36:26 +00:00
export default theme;