Improve mobile navigation, responsive layout, and theme styling

This commit is contained in:
Rami Bitar
2026-09-16 12:09:39 -04:00
parent f9550116d7
commit 55ae7f2e42
10 changed files with 187 additions and 31 deletions
+20 -5
View File
@@ -1,8 +1,11 @@
"use client"
import { type COBEOptions } from "cobe"
import { useTheme } from "next-themes"
import { Globe } from "@/components/ui/globe"
const globeConfig = {
const darkGlobeConfig: COBEOptions = {
width: 800,
height: 800,
onRender: () => {},
@@ -28,13 +31,25 @@ const globeConfig = {
],
}
const lightGlobeConfig: COBEOptions = {
...darkGlobeConfig,
dark: 0,
diffuse: 0.4,
mapBrightness: 1.2,
baseColor: [0.9, 0.94, 1],
markerColor: [0.09, 0.24, 0.65],
glowColor: [0.85, 0.9, 1],
}
export function GlobalGlobe() {
const { resolvedTheme } = useTheme()
return (
<div className="relative h-[360px] shrink-0 overflow-hidden bg-background">
<Globe className="top-6 max-w-[360px]" config={globeConfig} />
<div className="absolute left-5 top-5 flex items-center gap-2 rounded-full border bg-background/85 px-3 py-1.5 font-mono text-[10px] shadow-sm backdrop-blur">
<span className="size-1.5 animate-pulse rounded-full bg-emerald-500" /> 8 regions online
</div>
<Globe
className="top-6 max-w-[360px]"
config={resolvedTheme === "light" ? lightGlobeConfig : darkGlobeConfig}
/>
</div>
)
}