// PEP-70: Peppa's mascot — a cartoon pug next to the agents' questions. Pure SVG (no external // images), fixed fawn/black colours that read on both themes; motion only without reduced-motion. import { cn } from "@/lib/utils"; type Mood = "sleep" | "alert"; export function PugMascot({ mood, size = 72, className }: { mood: Mood; size?: number; className?: string }) { const awake = mood === "alert"; return ( {/* head */} {/* folded "button" ears flop over the head */} {/* forehead wrinkles */} {/* cheeks */} {/* black mask */} {/* eyes */} {awake ? ( <> ) : ( <> )} {/* nose */} {/* mouth + tongue */} {awake && } {!awake && ( z z )} ); } /** Mascot with a speech bubble: sleeps when nothing waits, perks up when agents ask. */ export function PugBanner({ count }: { count: number }) { const awake = count > 0; return (
{awake ? ( <> Гав! {count === 1 ? "Агент ждёт" : "Агенты ждут"} твоего ответа — {plural(count)} ниже. ) : ( Тихо… Агентам от тебя ничего не нужно, мопс спит. )}
); } function plural(n: number) { const m10 = n % 10, m100 = n % 100; const w = m10 === 1 && m100 !== 11 ? "вопрос" : m10 >= 2 && m10 <= 4 && (m100 < 12 || m100 > 14) ? "вопроса" : "вопросов"; return `${n} ${w}`; }