diff --git a/components/Header/index.tsx b/components/Header/index.tsx index 62ca0da6..90bde250 100644 --- a/components/Header/index.tsx +++ b/components/Header/index.tsx @@ -1,7 +1,9 @@ -import React, { useEffect, useState } from 'react' +import React, { useContext, useEffect, useState } from 'react' import { useCookies } from 'react-cookie' import { useRouter } from 'next/router' +import AppContext from '~context/AppContext' + import Button from '~components/Button' import HeaderMenu from '~components/HeaderMenu' @@ -10,6 +12,8 @@ import './index.scss' interface Props {} const Header = (props: Props) => { + const { editable } = useContext(AppContext) + const [username, setUsername] = useState(undefined) const [cookies, _, removeCookie] = useCookies(['user']) @@ -54,10 +58,9 @@ const Header = (props: Props) => {
-
- {/* { (location.pathname.includes('/p/')) ? +