@@ -10,6 +10,14 @@ function HeaderMenuItem({ children }: { children: React.ReactNode }) {
10
10
) ;
11
11
}
12
12
13
+ function DropdownMenu ( { children } : { children : React . ReactNode } ) {
14
+ return (
15
+ < div className = "absolute right-0 top-full mt-2 w-56 bg-white rounded-lg shadow-lg opacity-0 invisible group-hover:opacity-100 group-hover:visible transition-all duration-200 z-50 border border-gray-100" >
16
+ < div className = "py-1" > { children } </ div >
17
+ </ div >
18
+ ) ;
19
+ }
20
+
13
21
export function Header ( { hasError } : { hasError ?: boolean } ) {
14
22
return (
15
23
< header className = "flex-shrink-0 h-16 px-3 items-center flex w-full bg-teal-25 opacity-1 border-b-blue-200 border-b" >
@@ -32,41 +40,38 @@ export function Header({ hasError }: { hasError?: boolean }) {
32
40
< div className = "flex items-center gap-4 mr-16" >
33
41
< div className = "flex items-center relative group" >
34
42
< HeaderMenuItem > Certificates</ HeaderMenuItem >
35
- < div className = "absolute right-0 top-full mt-2 w-56 bg-white rounded-lg shadow-lg opacity-0 invisible group-hover:opacity-100 group-hover:visible transition-all duration-200 z-50 border border-gray-100" >
36
- < div className = "py-1" >
37
- < Link
38
- to = "/certificates"
39
- className = "block px-5 py-3 text-gray-700 hover:bg-blue-50"
40
- >
41
- Download
42
- </ Link >
43
- < Link
44
- to = "/certificates/security"
45
- className = "block px-5 py-3 text-gray-700 hover:bg-blue-50"
46
- >
47
- Certificate Security
48
- </ Link >
49
- </ div >
50
- </ div >
43
+ < DropdownMenu >
44
+ < Link
45
+ to = "/certificates"
46
+ className = "block px-5 py-3 text-gray-700 hover:bg-blue-50"
47
+ >
48
+ Download
49
+ </ Link >
50
+ < Link
51
+ to = "/certificates/security"
52
+ className = "block px-5 py-3 text-gray-700 hover:bg-blue-50"
53
+ >
54
+ Certificate Security
55
+ </ Link >
56
+ </ DropdownMenu >
51
57
</ div >
52
58
< div className = "flex items-center relative group" >
53
59
< HeaderMenuItem > Help</ HeaderMenuItem >
54
- < div className = "absolute right-0 top-full mt-2 w-56 bg-white rounded-lg shadow-lg opacity-0 invisible group-hover:opacity-100 group-hover:visible transition-all duration-200 z-50 border border-gray-100" >
55
- < div className = "py-1" >
56
- < Link
57
- to = "/help/continue-setup"
58
- className = "block px-5 py-3 text-gray-700 hover:bg-blue-50"
59
- >
60
- Continue Setup
61
- </ Link >
62
- < Link
63
- to = "/help/copilot-setup"
64
- className = "block px-5 py-3 text-gray-700 hover:bg-blue-50"
65
- >
66
- Copilot Setup
67
- </ Link >
68
- </ div >
69
- </ div >
60
+
61
+ < DropdownMenu >
62
+ < Link
63
+ to = "/help/continue-setup"
64
+ className = "block px-5 py-3 text-gray-700 hover:bg-blue-50"
65
+ >
66
+ Continue Setup
67
+ </ Link >
68
+ < Link
69
+ to = "/help/copilot-setup"
70
+ className = "block px-5 py-3 text-gray-700 hover:bg-blue-50"
71
+ >
72
+ Copilot Setup
73
+ </ Link >
74
+ </ DropdownMenu >
70
75
</ div >
71
76
72
77
< div className = "flex items-center relative group" >
0 commit comments