Lobby: leagues are play buttons w/ arrow; remove background music feature
- OnlineLobbyScreen: each league row is now a tappable play button (queues a ranked match at that league's stake) with a forward arrow; the cheapest enterable league is highlighted gold. Drops the redundant separate "ranked random" CTA and the select-then-play step. - Remove the background-music feature entirely: deleted the floating MusicToggle, the TopBar music button, and the Profile audio music toggle + style picker. sound.startMusic() is now an inert no-op so music never plays (sfx unchanged). 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, LogOut, Music, Pencil, Star, Upload, Users, Volume2 } from "lucide-react";
|
||||
import { Check, ChevronLeft, Crown, Eye, EyeOff, Lock, LogOut, 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";
|
||||
@@ -509,34 +509,11 @@ function SocialSettings() {
|
||||
|
||||
function SoundSettings() {
|
||||
const { t } = useI18n();
|
||||
const { sfx, music, musicTrack, toggleSfx, toggleMusic, setMusicTrack } = useSoundStore();
|
||||
const tracks = [
|
||||
{ id: "santoor" as const, label: t("settings.trackSantoor") },
|
||||
{ id: "playful" as const, label: t("settings.trackPlayful") },
|
||||
];
|
||||
const { sfx, toggleSfx } = useSoundStore();
|
||||
return (
|
||||
<div className="panel rounded-2xl p-4">
|
||||
<h3 className="text-sm font-bold text-cream/80 mb-2">{t("settings.audio")}</h3>
|
||||
<ToggleRow icon={<Volume2 className="size-4 text-gold-400" />} label={t("settings.sound")} on={sfx} onClick={toggleSfx} />
|
||||
<ToggleRow icon={<Music className="size-4 text-gold-400" />} label={t("settings.music")} on={music} onClick={toggleMusic} />
|
||||
{/* music style picker */}
|
||||
<div className="mt-3">
|
||||
<div className="text-[11px] text-cream/55 mb-1.5">{t("settings.musicStyle")}</div>
|
||||
<div className="grid grid-cols-2 gap-2">
|
||||
{tracks.map((tr) => (
|
||||
<button
|
||||
key={tr.id}
|
||||
onClick={() => setMusicTrack(tr.id)}
|
||||
className={cn(
|
||||
"press-3d rounded-xl py-2.5 text-sm font-bold",
|
||||
musicTrack === tr.id ? "btn-gold" : "bg-navy-900/70 gold-border text-cream/70"
|
||||
)}
|
||||
>
|
||||
{tr.label}
|
||||
</button>
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user