-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(EW): reproduce original navigation #195
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
@@ -0,0 +1,39 @@ | |||
'use client' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
converted this component to the "client" because we need framer-motion here (for animation when sale banner appears above, not implemented yet)
|
||
import { ThemeToggle } from './theme-toggle' | ||
|
||
export const getNavigationLinks = (): { | ||
export const useNavigationLinks = (): { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
renamed to the useNaviagtionLinks
to be able to use hooks inside
setHasMounted(true) | ||
}, []) | ||
|
||
const getTheme = (theme: string | undefined): 'light' | 'dark' => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
a bit of overhead to get the theme value here just to appease the typescript
@@ -0,0 +1,342 @@ | |||
import { useId } from 'react' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use it for unique id's inside svgs because we have two instances of each icons and values should be unique to get icons rendered properly
import { cn } from '@/utils/cn' | ||
|
||
// import { SearchIcon } from '@heroicons/react/outline' | ||
// import { useSearchBar } from 'search-bar/use-search-bar' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not implemented yet
This reproduces the Naviagtion Footer components from original EW:
Desktop nav
Mobile nav
Footer