feat: tabs
This commit is contained in:
1 parent
8661e8305d
commit
7d76aee647
1 file changed
+17
-11
@@ -58,8 +58,8 @@ const Account = ({ open = "profile" }) => {
|
|||||||
px={theme.spacing(20)}
|
px={theme.spacing(20)}
|
||||||
py={theme.spacing(12)}
|
py={theme.spacing(12)}
|
||||||
backgroundColor={theme.palette.primary.main}
|
backgroundColor={theme.palette.primary.main}
|
||||||
borderColor={theme.palette.primary.lowContrast}
|
|
||||||
border={1}
|
border={1}
|
||||||
|
borderColor={theme.palette.primary.lowContrast}
|
||||||
borderRadius={theme.shape.borderRadius}
|
borderRadius={theme.shape.borderRadius}
|
||||||
>
|
>
|
||||||
<TabContext value={tab}>
|
<TabContext value={tab}>
|
||||||
@@ -73,6 +73,11 @@ const Account = ({ open = "profile" }) => {
|
|||||||
<TabList
|
<TabList
|
||||||
onChange={handleTabChange}
|
onChange={handleTabChange}
|
||||||
aria-label="account tabs"
|
aria-label="account tabs"
|
||||||
|
sx={{
|
||||||
|
"& .MuiTabs-indicator": {
|
||||||
|
backgroundColor: theme.palette.tertiary.contrastText,
|
||||||
|
},
|
||||||
|
}}
|
||||||
>
|
>
|
||||||
{tabList.map((label, index) => (
|
{tabList.map((label, index) => (
|
||||||
<Tab
|
<Tab
|
||||||
@@ -86,23 +91,24 @@ const Account = ({ open = "profile" }) => {
|
|||||||
fontSize: 13,
|
fontSize: 13,
|
||||||
color: theme.palette.tertiary.contrastText,
|
color: theme.palette.tertiary.contrastText,
|
||||||
backgroundColor: theme.palette.tertiary.main,
|
backgroundColor: theme.palette.tertiary.main,
|
||||||
/*
|
|
||||||
TODO implement bg color and styling for tabs
|
|
||||||
*/
|
|
||||||
textTransform: "none",
|
textTransform: "none",
|
||||||
minWidth: "fit-content",
|
minWidth: "fit-content",
|
||||||
minHeight: 0,
|
|
||||||
paddingY: theme.spacing(6),
|
paddingY: theme.spacing(6),
|
||||||
fontWeight: 400,
|
fontWeight: 400,
|
||||||
/* marginRight: theme.spacing(8), */
|
|
||||||
borderBottom: "2px solid transparent",
|
borderBottom: "2px solid transparent",
|
||||||
|
borderRight: `1px solid ${theme.palette.primary.lowContrast}`,
|
||||||
"&:first-child": { borderTopLeftRadius: "8px" },
|
"&:first-child": { borderTopLeftRadius: "8px" },
|
||||||
"&:last-child": { borderTopRightRadius: "8px" },
|
"&:last-child": { borderTopRightRadius: "8px", borderRight: 0 },
|
||||||
"&:focus, &.Mui-selected": {
|
"&:focus-visible": {
|
||||||
/* TODO this appears and disapears. Investigate */
|
|
||||||
color: theme.palette.primary.contrastText,
|
color: theme.palette.primary.contrastText,
|
||||||
borderColor: theme.palette.primary.contrastText,
|
borderColor: theme.palette.tertiary.contrastText,
|
||||||
fontWeight: 700,
|
borderRightColor: theme.palette.primary.lowContrast,
|
||||||
|
},
|
||||||
|
"&.Mui-selected": {
|
||||||
|
backgroundColor: theme.palette.secondary.main,
|
||||||
|
color: theme.palette.secondary.contrastText,
|
||||||
|
borderColor: theme.palette.secondary.contrastText,
|
||||||
|
borderRightColor: theme.palette.primary.lowContrast,
|
||||||
},
|
},
|
||||||
"&:hover": {
|
"&:hover": {
|
||||||
borderColor: theme.palette.primary.lowContrast,
|
borderColor: theme.palette.primary.lowContrast,
|
||||||
|
|||||||
Reference in new issue
Block a user