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 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 | import { GraphIcon } from "@assets/analyticsIcons";
import { DiagonalIcon } from "@assets/icons";
import { Button } from "@common/Button";
import { palette } from "@palette";
import { Stack, styled } from "@mui/material";
export const ViewAnalyticsLink = ({
onClick,
Icon = <GraphIcon />,
labelProps,
stroke,
}: {
onClick?: () => void;
Icon?: JSX.Element;
labelProps?: any;
stroke?: string;
}) => {
return (
<Stack
direction="column"
gap="4px"
alignItems="stretch"
justifyContent="flex-end"
sx={(theme) => ({
[theme.breakpoints.down("sm")]: {
marginInline: "auto",
},
})}
>
{Icon}
<ViewAnalyticsButton
background="tertiary"
onClick={onClick}
{...labelProps}
>
Analytics <DiagonalIcon stroke={stroke} />
</ViewAnalyticsButton>
</Stack>
);
};
const ViewAnalyticsButton = styled(Button)(() => ({
color: palette.black[300],
textDecoration: "underline",
minWidth: "100%",
padding: 0,
lineHeight: "16.8px",
fontWeight: 350,
height: "max-content",
textAlign: "center",
whiteSpace: "nowrap",
}));
|