Mobile: single-row logo+title on Home; add Sign Out to Profile
- Home: logo and «برگ وسط» now sit on one row (prevents overflow), with «بازی حکم آنلاین» as a small subtitle beneath the title next to the logo. - Profile: add a خروج (Sign Out) button at the bottom (when signed in). Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
"use client";
|
||||
|
||||
import { motion } from "framer-motion";
|
||||
import { Check, ChevronLeft, Crown, Eye, EyeOff, Lock, Music, Pencil, Star, Upload, Users, Volume2 } from "lucide-react";
|
||||
import { Check, ChevronLeft, Crown, Eye, EyeOff, Lock, LogOut, Music, Pencil, Star, Upload, Users, Volume2 } from "lucide-react";
|
||||
import { useRef, useState } from "react";
|
||||
import { ScreenHeader, ScreenShell } from "@/components/online/ScreenHeader";
|
||||
import { RankBadge } from "@/components/online/RankBadge";
|
||||
@@ -35,6 +35,8 @@ export function ProfileScreen() {
|
||||
const profile = useSessionStore((s) => s.profile);
|
||||
const updateProfile = useSessionStore((s) => s.updateProfile);
|
||||
const upgradePlan = useSessionStore((s) => s.upgradePlan);
|
||||
const signOut = useSessionStore((s) => s.signOut);
|
||||
const isAuthed = useSessionStore((s) => s.isAuthed);
|
||||
const go = useUIStore((st) => st.go);
|
||||
const fileRef = useRef<HTMLInputElement>(null);
|
||||
const [editing, setEditing] = useState(false);
|
||||
@@ -346,6 +348,20 @@ export function ProfileScreen() {
|
||||
})}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{/* Sign out */}
|
||||
{isAuthed && (
|
||||
<button
|
||||
onClick={() => {
|
||||
signOut();
|
||||
go("home");
|
||||
}}
|
||||
className="mt-6 w-full glass rounded-2xl py-3 flex items-center justify-center gap-2 text-rose-300 hover:bg-navy-800/80 transition"
|
||||
>
|
||||
<LogOut className="size-4" />
|
||||
{t("menu.signOut")}
|
||||
</button>
|
||||
)}
|
||||
</ScreenShell>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user