Skip to content

Commit

Permalink
Merge branch 'Paul_Test_Branch'
Browse files Browse the repository at this point in the history
  • Loading branch information
PDykes1996 committed Sep 14, 2024
2 parents 8cbd96f + 9271009 commit 6a541e3
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 3 deletions.
6 changes: 5 additions & 1 deletion BlazorBattleship/Pages/Index.razor
Original file line number Diff line number Diff line change
Expand Up @@ -264,7 +264,11 @@
#region Opponent Board
private string OpponentBoardInfo(int x, int y)
{
if(opponentDefaultBoard[x,y] && opponentBoard[x,y])
if(coordinates.HasValue && coordinates.Value.x == x && coordinates.Value.y == y && !opponentDefaultBoard[x,y])
{
return "hit-preview";
}
else if(opponentDefaultBoard[x,y] && opponentBoard[x,y])
{
return "hit";
}
Expand Down
2 changes: 1 addition & 1 deletion BlazorBattleship/obj/Debug/net6.0/project.razor.vs.json

Large diffs are not rendered by default.

7 changes: 6 additions & 1 deletion BlazorBattleship/wwwroot/css/site.css
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,11 @@ a, .btn-link {
background-color: #17392e !important; /* Different color for preview */
}

.hit-preview{
border: 3px solid red;
background-color: lightblue;
}

.column-headers {
display: flex;
margin-left: 0;
Expand All @@ -126,4 +131,4 @@ a, .btn-link {
text-align: center;
font-size: 25px;
margin-bottom: 0;
}
}

0 comments on commit 6a541e3

Please sign in to comment.