diff --git a/web/src/pages/game.rs b/web/src/pages/game.rs index e64204d..8aff79b 100644 --- a/web/src/pages/game.rs +++ b/web/src/pages/game.rs @@ -247,9 +247,10 @@ fn table_view( let hand_number = game.hand_number; let target_score = game.target_score; - let hand = player_for_seat(&game, viewer_seat) - .and_then(|p| p.hand) - .unwrap_or_default(); + let viewer = player_for_seat(&game, viewer_seat); + let my_captured = viewer.as_ref().map(|p| p.captured_count).unwrap_or(0); + let my_scope = viewer.as_ref().map(|p| p.scope).unwrap_or(0); + let hand = viewer.and_then(|p| p.hand).unwrap_or_default(); let current_selection = selected.get_clone(); let hand_cards = hand .into_iter() @@ -301,6 +302,9 @@ fn table_view( } (right) div(class="seat-bottom") { + div(class="seat-stats own-stats") { + (my_captured) " captured ยท " (my_scope) " scope" + } div(class="hand") { (hand_cards) } (hint) } diff --git a/web/style.css b/web/style.css index b81de66..9400934 100644 --- a/web/style.css +++ b/web/style.css @@ -310,6 +310,11 @@ table.matches td.lost { margin-top: auto; } +/* The viewer's own stats sit above the hand; no flex context here. */ +.seat-bottom .seat-stats { + margin-bottom: 0.35rem; +} + .center { grid-area: center; display: flex;