@c-rex/components 0.1.10 → 0.1.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +3 -3
- package/src/navbar/navbar.tsx +35 -32
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@c-rex/components",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.11",
|
|
4
4
|
"files": [
|
|
5
5
|
"src"
|
|
6
6
|
],
|
|
@@ -144,8 +144,8 @@
|
|
|
144
144
|
"next": "^14",
|
|
145
145
|
"next-intl": "^4.1.0",
|
|
146
146
|
"nuqs": "^2.4.3",
|
|
147
|
-
"react": "^18",
|
|
148
|
-
"react-dom": "^18",
|
|
147
|
+
"react": "^18.3.1",
|
|
148
|
+
"react-dom": "^18.3.1",
|
|
149
149
|
"react-icons": "^5.5.0",
|
|
150
150
|
"tailwindcss-animate": "^1.0.7"
|
|
151
151
|
},
|
package/src/navbar/navbar.tsx
CHANGED
|
@@ -22,43 +22,46 @@ export const NavBar: FC<NavBarProps> = async ({ title, showInput, showPkgFilter
|
|
|
22
22
|
}
|
|
23
23
|
|
|
24
24
|
return (
|
|
25
|
-
<header className="sticky top-0 z-40
|
|
26
|
-
<div className="
|
|
27
|
-
<
|
|
28
|
-
<
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
/>
|
|
35
|
-
</Link>
|
|
25
|
+
<header className="sticky flex flex-wrap sm:flex-nowrap justify-between sm:items-center top-0 z-40 w-full p-4 backdrop-blur-xl transition-all bg-transparent border-b">
|
|
26
|
+
<div className="flex gap-2">
|
|
27
|
+
<Link href="/" className="flex items-center w-24 lg:w-60">
|
|
28
|
+
<img
|
|
29
|
+
src="/img/logo.png"
|
|
30
|
+
alt="C-rex Logo"
|
|
31
|
+
className="max-h-14"
|
|
32
|
+
/>
|
|
33
|
+
</Link>
|
|
36
34
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
35
|
+
{title.length > 0 && (
|
|
36
|
+
<div className="hidden sm:flex items-center">
|
|
37
|
+
<h1 className="mt-4 sm:mt-0 sm:px-4 lg:px-0 text-xl sm:text-2xl md:text-3xl font-bold tracking-tight text-balance">{title}</h1>
|
|
38
|
+
</div>
|
|
39
|
+
)}
|
|
40
|
+
</div>
|
|
43
41
|
|
|
44
|
-
|
|
45
|
-
|
|
42
|
+
<div className="flex items-center gap-2 absolute sm:static top-4 h-14 sm:h-min right-4">
|
|
43
|
+
<SearchInput showInput={showInput} showPkgFilter={showPkgFilter} placedOn="NAVBAR" />
|
|
46
44
|
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
45
|
+
{configs.OIDC.user.enabled && (
|
|
46
|
+
<>
|
|
47
|
+
{session ? (
|
|
48
|
+
<UserMenu session={session} />
|
|
49
|
+
) : (
|
|
50
|
+
<SignInBtn />
|
|
51
|
+
)}
|
|
52
|
+
</>
|
|
53
|
+
)}
|
|
56
54
|
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
</div>
|
|
55
|
+
{configs.languageSwitcher.enabled && (
|
|
56
|
+
<SettingsMenu />
|
|
57
|
+
)}
|
|
61
58
|
</div>
|
|
59
|
+
|
|
60
|
+
{title.length > 0 && (
|
|
61
|
+
<div className="flex w-full sm:hidden items-center">
|
|
62
|
+
<h1 className="mt-4 sm:mt-0 sm:px-4 text-xl sm:text-2xl md:text-3xl font-bold tracking-tight text-balance">{title}</h1>
|
|
63
|
+
</div>
|
|
64
|
+
)}
|
|
62
65
|
</header>
|
|
63
66
|
);
|
|
64
67
|
};
|