Skip to content

Commit

Permalink
Wording
Browse files Browse the repository at this point in the history
  • Loading branch information
BakerNet committed Aug 23, 2024
1 parent 7477d38 commit 4151055
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion web/src/app/minesweeper/players.rs
Original file line number Diff line number Diff line change
Expand Up @@ -107,9 +107,15 @@ pub fn ActivePlayers() -> impl IntoView {

#[component]
pub fn InactivePlayers(players: Vec<Option<ClientPlayer>>) -> impl IntoView {
let is_victory = players
.iter()
.filter_map(|cp| cp.as_ref())
.any(|cp| cp.victory_click);
view! {
<div class="flex flex-col items-center my-8 space-y-4">
<h4 class="text-2xl my-4 text-gray-900 dark:text-gray-200">Game Over</h4>
<h4 class="text-2xl my-4 text-gray-900 dark:text-gray-200">
{if is_victory { "Complete" } else { "Game Over" }}
</h4>
<Scoreboard buttons=move || ()>

{players
Expand Down

0 comments on commit 4151055

Please sign in to comment.