Add missing theme functions for metamigo-frontend

This commit is contained in:
Darren Clarke 2023-05-26 08:06:16 +00:00
parent 3ca903cf4f
commit 8fabcbaba2
4 changed files with 56 additions and 22 deletions

View file

@ -1,4 +1,5 @@
export const theme = {
spacing: () => 8,
palette: {
primary: {
main: "#337799",
@ -12,10 +13,35 @@ export const theme = {
background: {
default: "#fff",
},
getContrastText(color: string) { return color === "#ffffff" ? "#000" : "#fff"; },
},
shape: {
borderRadius: 5,
},
breakpoints: {
up: (key: any) => `@media (min-width:${key})`,
down: (key: any) => `@media (max-width:${key})`,
},
transitions: {
create(props: any) {
return `all ${props.duration}ms ${props.easing}`;
},
easing: {
easeInOut: "cubic-bezier(0.4, 0, 0.2, 1)",
easeOut: "cubic-bezier(0.0, 0, 0.2, 1)",
easeIn: "cubic-bezier(0.4, 0, 1, 1)",
sharp: "cubic-bezier(0.4, 0, 0.6, 1)",
},
duration: {
shortest: 150,
shorter: 200,
short: 250,
standard: 300,
complex: 375,
enteringScreen: 225,
leavingScreen: 195,
},
},
typography: {
h6: { fontSize: 16, fontWeight: 600, color: "#1bb1bb" },
},