import 'package:flutter/material.dart'; /// Encart affichant le score courant et le meilleur score personnel. class ScoreBoard extends StatelessWidget { final int currentScore; final int bestScore; const ScoreBoard({super.key, required this.currentScore, required this.bestScore}); @override Widget build(BuildContext context) { return Container( width: double.infinity, padding: const EdgeInsets.all(16), decoration: BoxDecoration( color: Colors.white.withAlpha(153), border: Border.all(color: Colors.black12), borderRadius: BorderRadius.circular(8), ), child: Column( children: [ const Text( "CURRENT SCORE", style: TextStyle(color: Colors.black54, fontSize: 14, fontWeight: FontWeight.bold), ), Text( "$currentScore", style: const TextStyle(fontSize: 32, fontWeight: FontWeight.bold, color: Color(0xFF3B6EE3)), ), const Divider(height: 24), Text( "PERSONAL BEST: $bestScore", style: const TextStyle(fontSize: 18, fontWeight: FontWeight.bold, color: Colors.black87), ), ], ), ); } }