@@ -4,10 +4,9 @@ import React, { memo, useMemo } from 'react'
4
4
import { motion , useMotionValue } from 'framer-motion'
5
5
import Link from 'next/link'
6
6
import { usePathname } from 'next/navigation'
7
- import type { IHeaderMenu } from './config'
7
+ import type { IHeaderMenu } from '.. /config'
8
8
9
9
import { FloatPopover } from '~/components/ui/float-popover'
10
- import { OnlyLg } from '~/components/ui/viewport'
11
10
import { usePageScrollDirection } from '~/providers/root/page-scroll-info-provider'
12
11
import { clsxm } from '~/utils/helper'
13
12
@@ -16,11 +15,9 @@ import { useHeaderConfig } from './HeaderDataConfigureProvider'
16
15
17
16
export const HeaderContent = ( ) => {
18
17
return (
19
- < OnlyLg >
20
- < AnimatedMenu >
21
- < ForDesktop />
22
- </ AnimatedMenu >
23
- </ OnlyLg >
18
+ < AnimatedMenu >
19
+ < ForDesktop />
20
+ </ AnimatedMenu >
24
21
)
25
22
}
26
23
@@ -116,6 +113,7 @@ const HeaderMenuItem = memo<{
116
113
</ MenuPopover >
117
114
)
118
115
} )
116
+
119
117
const MenuPopover : Component < {
120
118
subMenu : IHeaderMenu [ 'subMenu' ]
121
119
} > = memo ( ( { children, subMenu } ) => {
@@ -128,17 +126,17 @@ const MenuPopover: Component<{
128
126
placement = "bottom"
129
127
offset = { 10 }
130
128
popoverWrapperClassNames = "z-[19] relative"
131
- popoverClassNames = "rounded-xl"
129
+ popoverClassNames = "rounded-xl !p-0 "
132
130
TriggerComponent = { TriggerComponent }
133
131
>
134
132
{ ! ! subMenu . length && (
135
- < div className = "relative flex w-[130px] flex-col p -4" >
133
+ < div className = "relative flex w-[130px] flex-col px -4" >
136
134
{ subMenu . map ( ( m ) => {
137
135
return (
138
136
< Link
139
137
key = { m . title }
140
138
href = { m . path }
141
- className = "flex w-full items-center justify-around space-x-2 py-3 duration-200 first:pt-0 last:pb-0 hover:text-accent"
139
+ className = "flex w-full items-center justify-around space-x-2 py-3 duration-200 hover:text-accent"
142
140
role = "button"
143
141
>
144
142
{ ! ! m . icon && < span > { m . icon } </ span > }
0 commit comments