feat(home): clean shared top bar with live online counter
CI / check (push) Successful in 28s
CI / tests-imaging-browsers (push) Successful in 1m34s
CI / tests-integration (push) Successful in 1m57s
CI / tests-unit (push) Successful in 2m1s
CI / tests-quality (push) Successful in 50s
CI / tests-ui (push) Successful in 4m39s
CI / preflight (push) Skipped
CI / deploy (push) Successful in 3m29s
CI / check (push) Successful in 28s
CI / tests-imaging-browsers (push) Successful in 1m34s
CI / tests-integration (push) Successful in 1m57s
CI / tests-unit (push) Successful in 2m1s
CI / tests-quality (push) Successful in 50s
CI / tests-ui (push) Successful in 4m39s
CI / preflight (push) Skipped
CI / deploy (push) Successful in 3m29s
The homepage duplicated the online count and recent-user avatars (hero plus community sidebar), and the public pages each kept their own chrome. Put one AuthTopBar at the top of index, login and register — logo + hotel name plus a live online indicator and the language/clock/theme controls — and drop the duplicated hero rows.
This commit is contained in:
1 parent
9cf1eb615c
commit
b40293bd06
5 files changed
+45
-83
No files matched your search
+2
-74
@@ -10,7 +10,6 @@ import { AnimatedCounter } from "@/components/animated-counter";
|
||||
import { AuthTopBar } from "@/components/auth/auth-top-bar";
|
||||
import { LoginForm } from "@/components/auth/login-form";
|
||||
import Link from "@/components/link";
|
||||
import { LiveOnlineCounter } from "@/components/live-online-counter";
|
||||
import { Reveal } from "@/components/motion-reveal";
|
||||
import { PublicLoadError } from "@/components/public/load-error";
|
||||
import { UserAvatarThumbnail } from "@/components/shared/user-avatar-thumbnail";
|
||||
@@ -402,9 +401,9 @@ async function Home() {
|
||||
|
||||
return (
|
||||
<div className="flex w-full flex-col gap-14 pb-16 pt-2 md:gap-20 md:pb-24">
|
||||
{/* ── Top bar ── */}
|
||||
{/* ── Top bar: logo + live online + language/clock/theme ── */}
|
||||
<div className="mx-auto w-full max-w-7xl">
|
||||
<AuthTopBar hotelName={hotelName} logo={logo} />
|
||||
<AuthTopBar hotelName={hotelName} logo={logo} online={online} />
|
||||
</div>
|
||||
{/* ── Cinematic hero ── */}
|
||||
<Reveal className="-mx-3 sm:-mx-4 md:-mx-6">
|
||||
@@ -454,46 +453,6 @@ async function Home() {
|
||||
style={{ opacity: 0.5, zIndex: 1 }}
|
||||
/>
|
||||
<div className="relative z-10 mx-auto flex min-h-[540px] w-full max-w-6xl flex-col items-center justify-center px-4 py-24 text-center sm:min-h-[580px] lg:min-h-[640px]">
|
||||
<span
|
||||
className="glass-chip gap-2.5 px-4 py-2"
|
||||
style={{
|
||||
fontWeight: 800,
|
||||
letterSpacing: "0.14em",
|
||||
textTransform: "uppercase",
|
||||
}}
|
||||
>
|
||||
<span className="relative flex h-2 w-2">
|
||||
<span
|
||||
className="absolute inline-flex h-full w-full animate-ping rounded-full opacity-70"
|
||||
style={{ background: "var(--color-primary)" }}
|
||||
/>
|
||||
<span
|
||||
className="relative inline-flex h-2 w-2 rounded-full"
|
||||
style={{ background: "var(--color-primary)" }}
|
||||
/>
|
||||
</span>
|
||||
<span
|
||||
className="text-[10px] font-black sm:text-xs"
|
||||
style={{ color: "var(--color-text-readable)" }}
|
||||
>
|
||||
{tp("onlineNow")}
|
||||
</span>
|
||||
{online === null ? (
|
||||
<span className="text-xs">{te("unavailable")}</span>
|
||||
) : (
|
||||
<span
|
||||
className="text-sm sm:text-base"
|
||||
style={{
|
||||
color:
|
||||
"var(--color-primary-readable, var(--color-primary))",
|
||||
fontWeight: 900,
|
||||
}}
|
||||
>
|
||||
<LiveOnlineCounter initial={online} />
|
||||
</span>
|
||||
)}
|
||||
</span>
|
||||
|
||||
<h1
|
||||
className="mt-7 sm:mt-8"
|
||||
style={{ fontFamily: "var(--font-nunito)" }}
|
||||
@@ -516,37 +475,6 @@ async function Home() {
|
||||
{tp("welcomeBody")}
|
||||
</p>
|
||||
|
||||
{recentUsers !== null && recentUsers.length > 0 && (
|
||||
<div
|
||||
className="animate-fade-in-up mt-7 inline-flex items-center gap-3 rounded-full border px-3 py-1.5"
|
||||
style={{
|
||||
background: "rgba(255,255,255,0.08)",
|
||||
borderColor: "rgba(255,255,255,0.22)",
|
||||
backdropFilter: "blur(12px)",
|
||||
WebkitBackdropFilter: "blur(12px)",
|
||||
animationDelay: "0.08s",
|
||||
}}
|
||||
>
|
||||
<div className="flex -space-x-2.5">
|
||||
{recentUsers.slice(0, 4).map((u) => (
|
||||
<UserAvatarThumbnail
|
||||
key={u.username}
|
||||
figure={u.look}
|
||||
alt={u.username}
|
||||
options={{ direction: 2 }}
|
||||
className="h-9 w-9 rounded-full ring-2 ring-white/70 shadow-lg"
|
||||
/>
|
||||
))}
|
||||
</div>
|
||||
<span
|
||||
className="pr-1 text-[10px] font-extrabold uppercase tracking-[0.22em]"
|
||||
style={{ color: "rgba(255,255,255,0.75)" }}
|
||||
>
|
||||
{tp("recentUsers")}
|
||||
</span>
|
||||
</div>
|
||||
)}
|
||||
|
||||
<div
|
||||
className="animate-fade-in-up mt-9 flex flex-wrap items-center justify-center gap-3"
|
||||
style={{ animationDelay: "0.2s" }}
|
||||
|
||||
Reference in new issue
Block a user