2021-09-13 18:44:46 +02:00
|
|
|
import React from "react";
|
|
|
|
import { createMuiTheme } from "@material-ui/core/styles";
|
|
|
|
|
|
|
|
import { ThemeProvider } from "@material-ui/core/styles";
|
|
|
|
|
|
|
|
export const colors = {
|
2021-09-13 23:11:02 +02:00
|
|
|
primarylight: "#0f0",
|
|
|
|
primary: "#0c0",
|
2021-09-13 18:44:46 +02:00
|
|
|
primarydark: "#090",
|
2021-09-13 23:11:02 +02:00
|
|
|
well: "#222",
|
2021-09-13 18:44:46 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
export const theme = createMuiTheme({
|
|
|
|
palette: {
|
|
|
|
primary: {
|
|
|
|
main: colors.primary,
|
|
|
|
dark: colors.primarydark,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
typography: {
|
|
|
|
button: {
|
|
|
|
textTransform: "none",
|
|
|
|
},
|
|
|
|
},
|
2021-09-13 23:11:02 +02:00
|
|
|
overrides: {
|
|
|
|
MuiInputBase: {
|
|
|
|
root: {
|
|
|
|
backgroundColor: colors.well,
|
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
2021-09-13 18:44:46 +02:00
|
|
|
});
|
|
|
|
|
|
|
|
interface IProps {
|
|
|
|
children: JSX.Element[] | JSX.Element;
|
|
|
|
}
|
|
|
|
|
|
|
|
export const Theme = ({ children }: IProps): React.ReactElement => (
|
|
|
|
<ThemeProvider theme={theme}>{children}</ThemeProvider>
|
|
|
|
);
|