@fortawesome/free-solid-svg-icons#faMoon TypeScript Examples

The following examples show how to use @fortawesome/free-solid-svg-icons#faMoon. 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: IconLibrary.ts    From react-memory-game with MIT License 6 votes vote down vote up
library.add(
  faChevronLeft,
  faPlay,
  faPause,
  faUndo,
  faClock,
  faQuestionCircle,
  faTimes,
  faPalette,

  // Icons for the game
  faPoo,
  faAnchor,
  faMoon,
  faAppleAlt,
  faBell,
  faBible,
  faBomb,
  faBone,
  faCar,
  faCat,
  faChess,
  faSkull,
  faFeatherAlt,
  faFire,
  faHeart,
  faMusic,
)
Example #2
Source File: index.tsx    From pPhone2 with MIT License 6 votes vote down vote up
settingsDataList: ISettingsProps[] = [
    { id: 1, title: 'Mode Avion', img: faPlaneDeparture, imgType: 'fontAwesome-icon1', imgColor: '#fff', backround: '#f09a37', checkbox: true },
    { id: 2, title: 'Wifi', img: faWifi, imgType: 'fontAwesome-icon1', imgColor: '#fff', backround: '#3478f6 ', /*rightLabel: "test" */ },
    { id: 3, title: 'Bluetooth', img: faBluetooth, imgType: 'fontAwesome-icon2', imgColor: '#fff', backround: '#3478f6 '  },
    { id: 4, title: 'Cartes SIM', img: faSimCard, imgType: 'fontAwesome-icon4', imgColor: '#fff', backround: '#65c466'  },

    { id: 0, alt: true },
    { id: 5, title: 'Notifications', img: faBell, imgType: 'fontAwesome-icon2', imgColor: '#fff', backround: '#d70015'  },
    { id: 6, title: 'Sons & Vibrations', img: faVolumeUp, imgType: 'fontAwesome-icon3', imgColor: '#fff', backround: '#d70015'  },
    { id: 7, title: 'Fond d\'ecran', img: faPalette, imgType: 'fontAwesome-icon3', imgColor: '#fff', backround: '#70d7ff'  },
    { id: 8, title: 'Mode Nuit', img: faMoon, imgType: 'fontAwesome-icon3', imgColor: '#fff', backround: '#5756ce'  },
    { id: 9, title: 'Theme', img: faBrush, imgType: 'fontAwesome-icon4', imgColor: '#fff', backround: '#8944ab'  },

]
Example #3
Source File: AppBar.tsx    From hacker-ui with MIT License 5 votes vote down vote up
function AppBar(props: Props) {
  const { Root, styles, onOpenMobileNav } = useStyles(props);
  const theme = useTheme();

  const isMobile = useMediaQuery(theme.media.down('tablet'));
  const { darkMode, setDarkMode } = useDarkMode();

  return (
    <Root>
      {isMobile && (
        <Tooltip title="Open nav" position="right">
          {(tooltipProps) => (
            <Button
              {...tooltipProps}
              onClick={onOpenMobileNav}
              className={styles.navButton}
              aria-label="Open nav"
              shape="icon"
              color="black"
            >
              <FontAwesomeIcon icon={faBars} size="lg" />
            </Button>
          )}
        </Tooltip>
      )}

      <Tooltip title="Contribute on GitHub" position="left">
        {(tooltipProps) => (
          <Button
            className={styles.githubButton}
            aria-label="Contribute on GitHub"
            shape="icon"
            color="black"
            component="a"
            // @ts-ignore
            href="https://github.com/ricokahler/hacker-ui"
            {...tooltipProps}
          >
            <FontAwesomeIcon icon={faGithub} size="3x" />
          </Button>
        )}
      </Tooltip>

      <Tooltip title="Toggle dark mode" position="left">
        {(tooltipProps) => (
          <Button
            className={styles.darkModeButton}
            aria-label="Dark mode"
            shape="icon"
            color="black"
            onClick={() => setDarkMode((darkMode) => !darkMode)}
            {...tooltipProps}
          >
            <FontAwesomeIcon icon={darkMode ? faSun : faMoon} size="3x" />
          </Button>
        )}
      </Tooltip>
    </Root>
  );
}
Example #4
Source File: Footer.tsx    From devex with GNU General Public License v3.0 4 votes vote down vote up
Footer: React.FC = () => {

  const themeContext = useContext(ThemeContext)
  const { theme, toggle } = themeContext!

  return <div className='custom-footer'>
    <Container>
      <Row className='justify-content-between'>
        <Col sm md lg={2}>
          <Row>
            <span className='social-header'>Social</span>
          </Row>
          <Row>
            <a target='_blank' rel='noopener noreferrer' href='https://www.twitter.com/zilliqa'>
              <FontAwesomeIcon size='lg' icon={faTwitter} cursor='pointer' />
            </a>
            <a target='_blank' rel='noopener noreferrer' href='https://www.facebook.com/zilliqa/'>
              <FontAwesomeIcon size='lg' icon={faFacebookF} cursor='pointer' />
            </a>
            <a target='_blank' rel='noopener noreferrer' href='https://www.reddit.com/r/zilliqa'>
              <FontAwesomeIcon size='lg' icon={faRedditAlien} cursor='pointer' />
            </a>
          </Row>
          <Row>
            <a target='_blank' rel='noopener noreferrer' href='https://blog.zilliqa.com'>
              <FontAwesomeIcon size='lg' icon={faMediumM} cursor='pointer' />
            </a>
            <a target='_blank' rel='noopener noreferrer' href='https://www.youtube.com/channel/UCvinnFbf0u71cajoxKcfZIQ'>
              <FontAwesomeIcon size='lg' icon={faYoutube} cursor='pointer' />
            </a>
            <a target='_blank' rel='noopener noreferrer' href='https://t.me/zilliqachat'>
              <FontAwesomeIcon size='lg' icon={faTelegramPlane} cursor='pointer' />
            </a>
          </Row>
        </Col>
        <Col>
          <span className='related-links-header'>Related Links</span>
          <div>
            <a target='_blank' rel='noopener noreferrer' href='https://github.com/Zilliqa/dev-explorer'>Project Repo</a>
          </div>
          <div>
            <a target='_blank' rel='noopener noreferrer' href='https://ide.zilliqa.com/#/'>Neo Savant IDE</a>
          </div>
          <div>
            <a target='_blank' rel='noopener noreferrer' href='https://github.com/Zilliqa/Zilliqa-JavaScript-Library'>Javascript SDK</a>
          </div>
          <div>
            <a target='_blank' rel='noopener noreferrer' href='https://viewblock.io/zilliqa'>ViewBlock</a>
          </div>
        </Col>
        <Col className='align-self-center'>
          <Row className='justify-content-end'>
            Powered by <a href='http://www.zilliqa.com'>
              <span><u>Zilliqa</u></span></a>
          </Row>
          <Row className='justify-content-end'>
            <span><small>© 2020 Zilliqa</small></span>
          </Row>
          <Row className='justify-content-end pt-1'>
            <OverlayTrigger placement='top'
              overlay={<Tooltip id={'theme-tt'}>Toggle Light/Dark</Tooltip>}>
              <Switch
                className='theme-switch'
                loadingIcon={null}
                onChange={() => {
                  toggle()
                }}
                disabled={false}
                defaultChecked={theme === 'light'}
                checkedChildren={
                  <div className='theme-icon-div'>
                    <FontAwesomeIcon className='theme-icon' icon={faMoon} size='xs' color='white' />
                  </div>}
                unCheckedChildren={
                  <div className='theme-icon-div'>
                    <FontAwesomeIcon className='theme-icon' icon={faSun} size='xs' color='white' />
                  </div>}
              />
            </OverlayTrigger>
          </Row>
        </Col>
      </Row>
    </Container>
  </div >
}