From c3bbebfcfeed7a9b8c7470d7b48e12046d834e59 Mon Sep 17 00:00:00 2001 From: Wes Bos Date: Fri, 17 Aug 2018 15:51:02 -0400 Subject: suuuup everyone --- stepped-solutions/40/frontend/components/Nav.js | 45 +++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100755 stepped-solutions/40/frontend/components/Nav.js (limited to 'stepped-solutions/40/frontend/components/Nav.js') diff --git a/stepped-solutions/40/frontend/components/Nav.js b/stepped-solutions/40/frontend/components/Nav.js new file mode 100755 index 0000000..aebbcb2 --- /dev/null +++ b/stepped-solutions/40/frontend/components/Nav.js @@ -0,0 +1,45 @@ +import Link from 'next/link'; +import { Mutation } from 'react-apollo'; +import { TOGGLE_CART_MUTATION } from './Cart'; +import NavStyles from './styles/NavStyles'; +import User from './User'; +import Signout from './Signout'; + +const Nav = () => ( + + {({ data: { me } }) => ( + + + Shop + + {me && ( + <> + + Sell + + + Orders + + + Account + + + + {(toggleCart) => ( + + )} + + + )} + {!me && ( + + Sign In + + + )} + + )} + +); + +export default Nav; -- cgit v1.3