@material-ui/icons#ArrowDownwardOutlined TypeScript Examples

The following examples show how to use @material-ui/icons#ArrowDownwardOutlined. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: UserMenuSheet.tsx    From homebase-app with MIT License 5 votes vote down vote up
UserMenuSheet: React.FC<Props> = (props) => {
  const { account, reset, connect } = useTezos();

  const handleAccountClick = () => {
    if(account) {
      navigator.clipboard.writeText(account)
    } else {
      connect()
    }

    props.onClose()
  }

  const handleLogout = () => {
    reset()
    props.onClose()
  }

  return (
    <BottomSheet open={props.open} onDismiss={props.onClose}>
      <SheetContainer>
        <SheetItem>
          <Grid
            container
            justifyContent="center"
            style={{ gap: 9 }}
            alignItems="center"
            onClick={handleAccountClick}
          >
            {account ? (
              <>
                <Grid item>
                  <Blockie address={account} size={24} />
                </Grid>
                <Grid item>
                  <MenuText color="textPrimary">
                    {toShortAddress(account)}
                  </MenuText>
                </Grid>
                <Grid item>
                  <FileCopyOutlined htmlColor="#FFF" fontSize="small" />
                </Grid>
              </>
            ) : (
              <>
                <Grid item>
                  <ArrowDownwardOutlined htmlColor="#FFF" fontSize="small" />
                </Grid>
                <Grid item>
                  <MenuText color="textPrimary">Connect Wallet</MenuText>
                </Grid>
              </>
            )}
          </Grid>
        </SheetItem>
        <SheetItem>
          <Grid
            container
            justifyContent="center"
            style={{ gap: 9 }}
            alignItems="center"
            onClick={handleLogout}
          >
            <Grid item>
              <ExitToApp htmlColor="#FFF" fontSize="small" />
            </Grid>
            <Grid item>
              <MenuText color="textPrimary">Log Out</MenuText>
            </Grid>
          </Grid>
        </SheetItem>
      </SheetContainer>
    </BottomSheet>
  );
}