Turn and Check markers.

This commit is contained in:
2024-10-28 21:01:44 -05:00
parent a7e26f5210
commit cfd62eeca9
5 changed files with 57 additions and 13 deletions

View File

@@ -1,7 +1,14 @@
<p style="margin: 0">
@if (IsTurn)
{
<span>*&nbsp;</span>
<span class="turn-marker" title="Shows which player is next to move a piece.">Turn</span>
<span>&nbsp;</span>
}
@if (InCheck)
{
<span class="check-marker" title="King is in danger!">Check</span>
<span>&nbsp;</span>
}
@if (string.IsNullOrEmpty(Name))
@@ -17,5 +24,6 @@
@code {
[Parameter][EditorRequired] public bool IsTurn { get; set; }
[Parameter][EditorRequired] public bool InCheck { get; set; }
[Parameter][EditorRequired] public string Name { get; set; } = string.Empty;
}