refactor, fix font
This commit is contained in:
parent
d94b23249f
commit
ee229387d7
23
src/theme.ts
23
src/theme.ts
@ -1,5 +1,5 @@
|
|||||||
import { Theme } from '@mui/material/styles';
|
import { Theme } from '@mui/material/styles';
|
||||||
import {createTheme, PaletteColorOptions} from "@mui/material";
|
import { createTheme, PaletteColorOptions, ThemeOptions } from "@mui/material";
|
||||||
import { deepmerge } from '@mui/utils';
|
import { deepmerge } from '@mui/utils';
|
||||||
//import { createTheme } from "./types";
|
//import { createTheme } from "./types";
|
||||||
|
|
||||||
@ -17,7 +17,7 @@ declare module '@mui/material/styles' {
|
|||||||
interface Theme {
|
interface Theme {
|
||||||
palette: {
|
palette: {
|
||||||
primary: {
|
primary: {
|
||||||
main: string
|
main: string;
|
||||||
},
|
},
|
||||||
secondary: {
|
secondary: {
|
||||||
main: string;
|
main: string;
|
||||||
@ -54,8 +54,8 @@ declare module '@mui/material/styles' {
|
|||||||
},
|
},
|
||||||
caption: {
|
caption: {
|
||||||
main: string;
|
main: string;
|
||||||
}
|
};
|
||||||
}
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
interface PaletteOptions {
|
interface PaletteOptions {
|
||||||
@ -125,8 +125,8 @@ const paletteColor = {
|
|||||||
main: "#2a2b1d"
|
main: "#2a2b1d"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
}
|
};
|
||||||
const theme = {
|
const theme: ThemeOptions = {
|
||||||
typography: {
|
typography: {
|
||||||
body1: {
|
body1: {
|
||||||
fontFamily: fontFamily
|
fontFamily: fontFamily
|
||||||
@ -211,9 +211,14 @@ const theme = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
},
|
||||||
|
MuiButtonBase: {
|
||||||
|
styleOverrides: {
|
||||||
|
root: {
|
||||||
|
fontFamily
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
||||||
};
|
};
|
||||||
export default createTheme(deepmerge(paletteColor, theme));
|
export default createTheme(deepmerge(paletteColor, theme));
|
Loading…
Reference in New Issue
Block a user