"use client"; import { ScoresaberPlayer } from "@/schemas/scoresaber/player"; import { useSettingsStore } from "@/store/settingsStore"; import { formatNumber } from "@/utils/number"; import dynamic from "next/dynamic"; import { useStore } from "zustand"; import Avatar from "../Avatar"; import Label from "../Label"; type PlayerRankingProps = { player: ScoresaberPlayer; showCountryFlag?: boolean; }; const ReactCountryFlag = dynamic(() => import("react-country-flag")); export default function PlayerRankingMobile({ player, showCountryFlag = true, }: PlayerRankingProps) { const settingsStore = useStore(useSettingsStore, (store) => store); return (

#{formatNumber(player.rank)}

{showCountryFlag && ( )}

{player.name}

); }