import { Gem } from "@/components/brand/Gem"; import { Card } from "@/components/ui/Card"; import { formatRubisToHours } from "@/lib/format"; import { cn } from "@/lib/utils"; /** * RubisHero — la pièce centrale du dashboard. * Cf. wireframe 4.1 : ◆ géant + "X rubis gagnés ce mois" + verbalisation * de la conversion en heures + barre de progression vers l'objectif mensuel. * * Layout asymétrique : * - Mobile : centré, gem en haut * - Desktop : gem à gauche (XL), texte au milieu, progression à droite * * Pas une carte plate "X stat" : c'est l'identité émotionnelle de l'app. */ type RubisHeroProps = { rubisThisMonth: number; /** Pourcentage 0-100 vers l'objectif. */ monthlyGoalProgress: number; /** Top X% des utilisateurs sur le mois (si disponible). */ percentile?: number; className?: string; }; export function RubisHero({ rubisThisMonth, monthlyGoalProgress, percentile, className, }: RubisHeroProps) { const progress = Math.min(100, Math.max(0, monthlyGoalProgress)); const hoursLabel = formatRubisToHours(rubisThisMonth); return ( {/* Halo rubis-glow en arrière-plan, très discret */}