-
-
Save JacobKnaack/54a7f2a4ef7c3800f099b2dd1b25728f to your computer and use it in GitHub Desktop.
Gatsby Agency Portfolio Header Navigation Component
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Link } from "gatsby" | |
import PropTypes from "prop-types" | |
import React from "react" | |
import { Navbar, Nav } from "rsuite" | |
const Header = ({ siteTitle }) => ( | |
<Navbar style={{ | |
width: '100vw', | |
position: 'fixed', | |
}}> | |
<Navbar.Header> | |
<h1> | |
<Link to="/"> | |
{siteTitle} | |
</Link> | |
</h1> | |
</Navbar.Header> | |
<Navbar.Body> | |
<Nav> | |
<Nav.Item componentClass={Link} to="/#work"> | |
Work | |
</Nav.Item> | |
<Nav.Item componentClass={Link} to="/#projects"> | |
Projects | |
</Nav.Item> | |
<Nav.Item componentClass={Link} to="/#about"> | |
About | |
</Nav.Item> | |
<Nav.Item componentClass={Link} to="/#contact"> | |
Contact | |
</Nav.Item> | |
</Nav> | |
</Navbar.Body> | |
</Navbar> | |
) | |
Header.propTypes = { | |
siteTitle: PropTypes.string, | |
} | |
Header.defaultProps = { | |
siteTitle: ``, | |
} | |
export default Header |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment