Press n or j to go to the next uncovered block, b, p or k for the previous block.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | import { styled, Typography, TypographyProps } from "@mui/material"; interface ExternalNavButtonProps { route: string; label: string; labelVariant: Exclude<TypographyProps["variant"], undefined>; } const StyledLink = styled("a")(({ theme }) => ({ color: theme.palette.text.secondary, display: "flex", flex: "1", fontSize: "2rem", maxWidth: "10.5rem", padding: theme.spacing(1, 1.5), })); const StyledTypography = styled(Typography)(() => ({ alignSelf: "center", marginTop: 0, })); export default function ExternalNavButton({ route, label, labelVariant, }: ExternalNavButtonProps) { return ( <StyledLink href={route} target="_blank" rel="noreferrer noopener"> <StyledTypography variant={labelVariant} noWrap> {label} </StyledTypography> </StyledLink> ); } |