From 89d1626bb2c1c05952bb207afd2e4e9b08247486 Mon Sep 17 00:00:00 2001 From: LQ63 Date: Tue, 4 Nov 2025 19:11:19 +0100 Subject: [PATCH 1/7] feat(ui): add Lobby and Main Menu Body Added main Menu body and a Lobby with Bootstrap --- .../app/controllers/IngameController.scala | 15 +++- .../app/controllers/MainMenuController.scala | 22 +++-- .../app/logic/game/GameLobby.scala | 12 ++- .../app/views/lobby/lobby.scala.html | 84 +++++++++++++++++++ .../app/views/mainmenu/creategame.scala.html | 31 +++++++ .../app/views/mainmenu/navbar.scala.html | 2 - knockoutwhistweb/conf/routes | 5 +- 7 files changed, 154 insertions(+), 17 deletions(-) create mode 100644 knockoutwhistweb/app/views/lobby/lobby.scala.html create mode 100644 knockoutwhistweb/app/views/mainmenu/creategame.scala.html diff --git a/knockoutwhistweb/app/controllers/IngameController.scala b/knockoutwhistweb/app/controllers/IngameController.scala index 59749c3..c70aede 100644 --- a/knockoutwhistweb/app/controllers/IngameController.scala +++ b/knockoutwhistweb/app/controllers/IngameController.scala @@ -8,6 +8,7 @@ import model.sessions.{PlayerSession, UserSession} import play.api.* import play.api.mvc.* +import java.util.UUID import javax.inject.* import scala.util.Try @@ -28,7 +29,7 @@ class IngameController @Inject()( game match { case Some(g) => g.logic.getCurrentState match { - case Lobby => Ok("Lobby: " + gameId) + case Lobby => Ok(views.html.lobby.lobby(Some(request.user), g)) case InGame => Ok(views.html.ingame.ingame( g.getPlayerByUser(request.user), @@ -63,7 +64,7 @@ class IngameController @Inject()( } } if (result.isSuccess) { - NoContent + Redirect(routes.IngameController.game(gameId)) } else { val throwable = result.failed.get throwable match { @@ -78,6 +79,16 @@ class IngameController @Inject()( } } } + def kickPlayer(gameId: String, playerToKick: UUID): Action[AnyContent] = authAction { implicit request: AuthenticatedRequest[AnyContent] => + val game = podManager.getGame(gameId) + game.get.leaveGame(playerToKick) + Redirect(routes.IngameController.game(gameId)) + } + def leaveGame(gameId: String): Action[AnyContent] = authAction { implicit request: AuthenticatedRequest[AnyContent] => + val game = podManager.getGame(gameId) + game.get.leaveGame(request.user.id) + Redirect(routes.MainMenuController.mainMenu()) + } def joinGame(gameId: String): Action[AnyContent] = authAction { implicit request: AuthenticatedRequest[AnyContent] => val game = podManager.getGame(gameId) val result = Try { diff --git a/knockoutwhistweb/app/controllers/MainMenuController.scala b/knockoutwhistweb/app/controllers/MainMenuController.scala index 7032b52..60b0081 100644 --- a/knockoutwhistweb/app/controllers/MainMenuController.scala +++ b/knockoutwhistweb/app/controllers/MainMenuController.scala @@ -21,7 +21,7 @@ class MainMenuController @Inject()( // Pass the request-handling function directly to authAction (no nested Action) def mainMenu(): Action[AnyContent] = authAction { implicit request: AuthenticatedRequest[AnyContent] => - Ok(views.html.mainmenu.navbar(Some(request.user))) + Ok(views.html.mainmenu.creategame(Some(request.user))) } def index(): Action[AnyContent] = authAction { implicit request: AuthenticatedRequest[AnyContent] => @@ -29,12 +29,20 @@ class MainMenuController @Inject()( } def createGame(): Action[AnyContent] = authAction { implicit request: AuthenticatedRequest[AnyContent] => - val gameLobby = podManager.createGame( - host = request.user, - name = s"${request.user.name}'s Game", - maxPlayers = 4 - ) - Redirect(routes.IngameController.game(gameLobby.id)) + val postData = request.body.asFormUrlEncoded + if (postData.isDefined) { + val gamename = postData.get.get("lobbyname").flatMap(_.headOption).getOrElse(s"${request.user.name}'s Game") + val playeramount = postData.get.get("playeramount").flatMap(_.headOption).getOrElse("") + val gameLobby = podManager.createGame( + host = request.user, + name = gamename, + maxPlayers = playeramount.toInt + ) + Redirect(routes.IngameController.game(gameLobby.id)) + } else { + BadRequest("Invalid form submission") + } + } def joinGame(): Action[AnyContent] = authAction { implicit request: AuthenticatedRequest[AnyContent] => diff --git a/knockoutwhistweb/app/logic/game/GameLobby.scala b/knockoutwhistweb/app/logic/game/GameLobby.scala index 6743bdb..eedbd58 100644 --- a/knockoutwhistweb/app/logic/game/GameLobby.scala +++ b/knockoutwhistweb/app/logic/game/GameLobby.scala @@ -88,12 +88,12 @@ class GameLobby private( * Remove the user from the game lobby. * @param user the user who wants to leave the game. */ - def leaveGame(user: User): Unit = { - val sessionOpt = users.get(user.id) + def leaveGame(userId: UUID): Unit = { + val sessionOpt = users.get(userId) if (sessionOpt.isEmpty) { throw new NotInThisGameException("You are not in this game!") } - users.remove(user.id) + users.remove(userId) } /** @@ -176,6 +176,10 @@ class GameLobby private( getPlayerBySession(getUserSession(user.id)) } + def getPlayers: mutable.Map[UUID, UserSession] = { + users.clone() + } + private def getPlayerBySession(userSession: UserSession): AbstractPlayer = { val playerOption = getMatch.totalplayers.find(_.id == userSession.id) if (playerOption.isEmpty) { @@ -225,7 +229,7 @@ class GameLobby private( } trickOpt.get } - + } object GameLobby { diff --git a/knockoutwhistweb/app/views/lobby/lobby.scala.html b/knockoutwhistweb/app/views/lobby/lobby.scala.html new file mode 100644 index 0000000..090b1a7 --- /dev/null +++ b/knockoutwhistweb/app/views/lobby/lobby.scala.html @@ -0,0 +1,84 @@ +@(user: Option[model.users.User], gamelobby: logic.game.GameLobby) + +@main("Lobby") { +
+
+
+
+
+ Lobby-Name: @gamelobby.name +
+
+ +
+
+
+
+
+
+
Playeramount: @gamelobby.getPlayers.size / @gamelobby.maxPlayers
+
+
+
+ + @if((gamelobby.getUserSession(user.get.id).host)) { + @for(playersession <- gamelobby.getPlayers.values) { +
+
+ Profile +
+ @if(playersession.id == user.get.id) { +
@playersession.name (You)
+

Your text could be here!

+ Remove + } else { +
@playersession.name
+

Your text could be here!

+
+ +
+ } +
+
+
+ } +
+ +
+ } else { + @for(playersession <- gamelobby.getPlayers.values) { +
+
+ Profile +
+ @if(playersession.id == user.get.id) { +
@playersession.name (You)
+

Your text could be here!

+ } else { +
@playersession.name
+

Your text could be here!

+ } +
+
+
+ } +
+
+

Waiting for the host to start the game...

+
+
+
+
+
+
+ Loading... +
+
+
+
+ } +
+
+} \ No newline at end of file diff --git a/knockoutwhistweb/app/views/mainmenu/creategame.scala.html b/knockoutwhistweb/app/views/mainmenu/creategame.scala.html new file mode 100644 index 0000000..47dc09c --- /dev/null +++ b/knockoutwhistweb/app/views/mainmenu/creategame.scala.html @@ -0,0 +1,31 @@ +@(user: Option[model.users.User]) +@navbar(user) +@main("Create Game") { +
+
+
+ + +
+
+ + +
+
+ + +
+ 2 + 3 + 4 + 5 + 6 + 7 +
+
+
+ +
+
+
+} \ No newline at end of file diff --git a/knockoutwhistweb/app/views/mainmenu/navbar.scala.html b/knockoutwhistweb/app/views/mainmenu/navbar.scala.html index a5f9cc4..99d5c83 100644 --- a/knockoutwhistweb/app/views/mainmenu/navbar.scala.html +++ b/knockoutwhistweb/app/views/mainmenu/navbar.scala.html @@ -1,5 +1,4 @@ @(user: Option[model.users.User]) -@main("Knockout Whist - Main Menu") { -} diff --git a/knockoutwhistweb/conf/routes b/knockoutwhistweb/conf/routes index f1867c7..bba5dda 100644 --- a/knockoutwhistweb/conf/routes +++ b/knockoutwhistweb/conf/routes @@ -24,6 +24,7 @@ GET /logout controllers.UserController.logout() # In-game routes GET /game/:id controllers.IngameController.game(id: String) GET /game/:id/join controllers.IngameController.joinGame(id: String) -POST /game/:id/start controllers.IngameController.startGame(id: String) - +GET /game/:id/start controllers.IngameController.startGame(id: String) +POST /game/:id/kickPlayer controllers.IngameController.kickPlayer(id: String, playerId: java.util.UUID) +GET /game/:id/leaveGame controllers.IngameController.leaveGame(id: String) POST /game/:id/playCard controllers.IngameController.playCard(id: String) \ No newline at end of file -- 2.52.0 From ee3f65efd9209740c624fe8972f5dc3990259009 Mon Sep 17 00:00:00 2001 From: LQ63 Date: Wed, 5 Nov 2025 02:19:26 +0100 Subject: [PATCH 2/7] feat(ui): added working ingame ui Added ingame ui with bootstrap. There were problems with the lock procedure which are now fixed. --- .../app/controllers/IngameController.scala | 2 +- .../app/logic/game/GameLobby.scala | 4 + .../app/views/ingame/ingame.scala.html | 77 ++++++++++--------- .../app/views/mainmenu/creategame.scala.html | 3 +- .../app/views/render/card.scala.html | 2 +- 5 files changed, 47 insertions(+), 41 deletions(-) diff --git a/knockoutwhistweb/app/controllers/IngameController.scala b/knockoutwhistweb/app/controllers/IngameController.scala index c70aede..1f19c51 100644 --- a/knockoutwhistweb/app/controllers/IngameController.scala +++ b/knockoutwhistweb/app/controllers/IngameController.scala @@ -33,7 +33,7 @@ class IngameController @Inject()( case InGame => Ok(views.html.ingame.ingame( g.getPlayerByUser(request.user), - g.logic + g )) case SelectTrump => Ok(views.html.ingame.selecttrump( diff --git a/knockoutwhistweb/app/logic/game/GameLobby.scala b/knockoutwhistweb/app/logic/game/GameLobby.scala index eedbd58..e7b8edb 100644 --- a/knockoutwhistweb/app/logic/game/GameLobby.scala +++ b/knockoutwhistweb/app/logic/game/GameLobby.scala @@ -180,6 +180,10 @@ class GameLobby private( users.clone() } + def getLogic: GameLogic = { + logic + } + private def getPlayerBySession(userSession: UserSession): AbstractPlayer = { val playerOption = getMatch.totalplayers.find(_.id == userSession.id) if (playerOption.isEmpty) { diff --git a/knockoutwhistweb/app/views/ingame/ingame.scala.html b/knockoutwhistweb/app/views/ingame/ingame.scala.html index f587dbc..302d262 100644 --- a/knockoutwhistweb/app/views/ingame/ingame.scala.html +++ b/knockoutwhistweb/app/views/ingame/ingame.scala.html @@ -1,50 +1,51 @@ -@(player: de.knockoutwhist.player.AbstractPlayer, logic: de.knockoutwhist.control.GameLogic) +@(player: de.knockoutwhist.player.AbstractPlayer, gamelobby: logic.game.GameLobby) @main("Ingame") { -
-

Knockout Whist

-
-

Next Player:

-

@logic.getPlayerQueue.get.duplicate().nextPlayer()

-
-
-
-

Trumpsuit:

-

@logic.getCurrentRound.get.trumpSuit

+
+
+
+

Next Player

+

@gamelobby.getLogic.getPlayerQueue.get.duplicate().nextPlayer()

-
-

First Card

- @if(logic.getCurrentTrick.get.firstCard.isDefined) { - @util.WebUIUtils.cardtoImage(logic.getCurrentTrick.get.firstCard.get) +
+

Cards played

+
+
+

Trumpsuit:

+

@gamelobby.getLogic.getCurrentRound.get.trumpSuit

+

First Card:

+ @if(gamelobby.getLogic.getCurrentTrick.get.firstCard.isDefined) { + @util.WebUIUtils.cardtoImage(gamelobby.getLogic.getCurrentTrick.get.firstCard.get) width="30%"/> } else { - @views.html.render.card.apply("images/cards/1B.png")("Blank Card") + @views.html.render.card.apply("images/cards/1B.png")("Blank Card") width="30%"/> }
- -

@logic.getCurrentPlayer.get has to play a card!

- @if(logic.getCurrentTrick.get.cards.nonEmpty) { -

Cards played

- } else { -

Cards played

- } - -
- @for((cardplayed, player) <- logic.getCurrentTrick.get.cards) { -
-

@player

- @util.WebUIUtils.cardtoImage(cardplayed) +
+
+ @for((cardplayed, player) <- gamelobby.getLogic.getCurrentTrick.get.cards) { +
+
+ @util.WebUIUtils.cardtoImage(cardplayed) /> +
+
@player
+
+
+
+ }
- }
- -

Your cards

-
- @for(card <- player.currentHand().get.cards) { - @util.WebUIUtils.cardtoImage(card) - } +
+ @for(i <- 0 until player.currentHand().get.cards.size) { +
+
+ + +
+
+ }
- -
} \ No newline at end of file diff --git a/knockoutwhistweb/app/views/mainmenu/creategame.scala.html b/knockoutwhistweb/app/views/mainmenu/creategame.scala.html index 47dc09c..372449b 100644 --- a/knockoutwhistweb/app/views/mainmenu/creategame.scala.html +++ b/knockoutwhistweb/app/views/mainmenu/creategame.scala.html @@ -1,6 +1,7 @@ @(user: Option[model.users.User]) -@navbar(user) + @main("Create Game") { +@navbar(user)
diff --git a/knockoutwhistweb/app/views/render/card.scala.html b/knockoutwhistweb/app/views/render/card.scala.html index 788be74..a4fca9e 100644 --- a/knockoutwhistweb/app/views/render/card.scala.html +++ b/knockoutwhistweb/app/views/render/card.scala.html @@ -1,2 +1,2 @@ @(src: String)(alt: String) -@alt \ No newline at end of file +@alt Date: Tue, 4 Nov 2025 19:11:19 +0100 Subject: [PATCH 3/7] feat(ui): add Lobby and Main Menu Body Added main Menu body and a Lobby with Bootstrap --- knockoutwhistweb/app/logic/game/GameLobby.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/knockoutwhistweb/app/logic/game/GameLobby.scala b/knockoutwhistweb/app/logic/game/GameLobby.scala index e7b8edb..486bf4f 100644 --- a/knockoutwhistweb/app/logic/game/GameLobby.scala +++ b/knockoutwhistweb/app/logic/game/GameLobby.scala @@ -233,7 +233,7 @@ class GameLobby private( } trickOpt.get } - + } object GameLobby { -- 2.52.0 From edfba93f83624145ecf992180430a30e4fd9396f Mon Sep 17 00:00:00 2001 From: LQ63 Date: Wed, 5 Nov 2025 02:19:26 +0100 Subject: [PATCH 4/7] feat(ui): added working ingame ui Added ingame ui with bootstrap. There were problems with the lock procedure --- knockoutwhistweb/app/controllers/IngameController.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/knockoutwhistweb/app/controllers/IngameController.scala b/knockoutwhistweb/app/controllers/IngameController.scala index 1f19c51..373701d 100644 --- a/knockoutwhistweb/app/controllers/IngameController.scala +++ b/knockoutwhistweb/app/controllers/IngameController.scala @@ -84,7 +84,7 @@ class IngameController @Inject()( game.get.leaveGame(playerToKick) Redirect(routes.IngameController.game(gameId)) } - def leaveGame(gameId: String): Action[AnyContent] = authAction { implicit request: AuthenticatedRequest[AnyContent] => + def leaveGame(gameId: String): Action[AnyContent] = authAction { implicit request: AuthenticatedRequest[AnyContent] => val game = podManager.getGame(gameId) game.get.leaveGame(request.user.id) Redirect(routes.MainMenuController.mainMenu()) -- 2.52.0 From a765ebd33f1817d6d9f7e53a5cc7a726b24ce27b Mon Sep 17 00:00:00 2001 From: Janis Date: Wed, 5 Nov 2025 12:44:27 +0100 Subject: [PATCH 5/7] feat(ui): enhance ingame UI layout and player information display --- .../app/views/ingame/ingame.scala.html | 106 +++++++++++------- 1 file changed, 63 insertions(+), 43 deletions(-) diff --git a/knockoutwhistweb/app/views/ingame/ingame.scala.html b/knockoutwhistweb/app/views/ingame/ingame.scala.html index 302d262..28b8550 100644 --- a/knockoutwhistweb/app/views/ingame/ingame.scala.html +++ b/knockoutwhistweb/app/views/ingame/ingame.scala.html @@ -1,51 +1,71 @@ +@import de.knockoutwhist.control.controllerBaseImpl.sublogic.util.TrickUtil + @(player: de.knockoutwhist.player.AbstractPlayer, gamelobby: logic.game.GameLobby) @main("Ingame") { -
-
-
-

Next Player

-

@gamelobby.getLogic.getPlayerQueue.get.duplicate().nextPlayer()

+
+ + +
+
+

Current Player

+

@gamelobby.getLogic.getCurrentPlayer.get.name

+ @if(!TrickUtil.isOver(gamelobby.getLogic.getCurrentMatch.get, gamelobby.getLogic.getPlayerQueue.get)) { +

Next Player

+ @for(nextplayer <- gamelobby.getLogic.getPlayerQueue.get.duplicate()) { +

@nextplayer

+ } + } +
+ + +
+ +
+ +
+

Trumpsuit

+

@gamelobby.getLogic.getCurrentRound.get.trumpSuit

+ +
First Card
+
+ @if(gamelobby.getLogic.getCurrentTrick.get.firstCard.isDefined) { + @util.WebUIUtils.cardtoImage(gamelobby.getLogic.getCurrentTrick.get.firstCard.get) width="80px"/> + } else { + @views.html.render.card.apply("images/cards/1B.png")("Blank Card") width="80px"/> + } +
+
-
-

Cards played

-
-
-

Trumpsuit:

-

@gamelobby.getLogic.getCurrentRound.get.trumpSuit

-

First Card:

- @if(gamelobby.getLogic.getCurrentTrick.get.firstCard.isDefined) { - @util.WebUIUtils.cardtoImage(gamelobby.getLogic.getCurrentTrick.get.firstCard.get) width="30%"/> - } else { - @views.html.render.card.apply("images/cards/1B.png")("Blank Card") width="30%"/> - } -
-
-
-
- @for((cardplayed, player) <- gamelobby.getLogic.getCurrentTrick.get.cards) { -
-
- @util.WebUIUtils.cardtoImage(cardplayed) /> -
-
@player
-
+ + +
+ @for((cardplayed, player) <- gamelobby.getLogic.getCurrentTrick.get.cards) { +
+
+
+ @util.WebUIUtils.cardtoImage(cardplayed) width="100%"/> +
+
+ @player
- } +
+ } +
+ + +
+ @for(i <- player.currentHand().get.cards.indices) { +
+ + + + +
+ }
-
- @for(i <- 0 until player.currentHand().get.cards.size) { -
-
- - -
-
- } -
-
-} \ No newline at end of file +} -- 2.52.0 From 802b76ac1aa99084805fa1259c2df02e7dc3ac6c Mon Sep 17 00:00:00 2001 From: Janis Date: Wed, 5 Nov 2025 15:10:49 +0100 Subject: [PATCH 6/7] feat(ui): enhance UI elements and improve layout for game creation and rules pages --- .../app/assets/stylesheets/dark-mode.less | 9 +- .../app/assets/stylesheets/main.less | 41 +++++- .../app/controllers/MainMenuController.scala | 6 +- .../app/logic/user/impl/StubUserManager.scala | 6 + .../app/views/ingame/ingame.scala.html | 20 +-- .../app/views/login/login.scala.html | 16 ++- knockoutwhistweb/app/views/main.scala.html | 18 ++- .../app/views/mainmenu/creategame.scala.html | 4 +- .../app/views/mainmenu/navbar.scala.html | 8 +- .../app/views/mainmenu/rules.scala.html | 131 ++++++++++-------- knockoutwhistweb/public/javascripts/main.js | 83 ++++++++++- 11 files changed, 247 insertions(+), 95 deletions(-) diff --git a/knockoutwhistweb/app/assets/stylesheets/dark-mode.less b/knockoutwhistweb/app/assets/stylesheets/dark-mode.less index 6249ca9..17b7f1a 100644 --- a/knockoutwhistweb/app/assets/stylesheets/dark-mode.less +++ b/knockoutwhistweb/app/assets/stylesheets/dark-mode.less @@ -1,6 +1,13 @@ @media (prefers-color-scheme: dark) { :root { --background-image: url('/assets/images/background.png'); - --color: white; + --color: #f8f9fa; /* Light text on dark bg */ + + /* Bootstrap variable overrides for dark mode */ + --bs-body-color: var(--color); + --bs-link-color: #66b2ff; + --bs-link-hover-color: #99ccff; + --bs-border-color: rgba(255, 255, 255, 0.2); + --bs-heading-color: var(--color); } } diff --git a/knockoutwhistweb/app/assets/stylesheets/main.less b/knockoutwhistweb/app/assets/stylesheets/main.less index 8bc3b69..d43ad95 100644 --- a/knockoutwhistweb/app/assets/stylesheets/main.less +++ b/knockoutwhistweb/app/assets/stylesheets/main.less @@ -2,6 +2,19 @@ @import "dark-mode.less"; @import "login.less"; +/* Provide default (light) variables so the site works even if light-mode.less fails */ +:root { + --background-image: url('/assets/images/img.png'); + --color: #212529; /* Bootstrap body text default */ + + /* Bootstrap variable overrides for light mode */ + --bs-body-color: var(--color) !important; + --bs-link-color: #0d6efd !important; + --bs-link-hover-color: #0a58ca !important; + --bs-border-color: rgba(0, 0, 0, 0.125) !important; + --bs-heading-color: var(--color) !important; +} + @background-image: var(--background-image); @color: var(--color); @keyframes slideIn { @@ -10,8 +23,33 @@ } .game-field-background { background-image: @background-image; - background-size: 100vw 100vh; + background-size: cover; + background-position: center center; background-repeat: no-repeat; + background-attachment: fixed; +} + +.navbar-header{ + text-align:center; +} + +.navbar-toggle { + float: none; + margin-right:0; +} + +/* Ensure body text color follows theme variable and works with Bootstrap */ +body { + color: @color; +} + +.footer { + width: 100%; + text-align: center; + font-size: 12px; + color: @color; + padding: 0.5rem 0; + flex-grow: 1; /* fill remaining vertical space as visual footer background */ } .game-field { @@ -19,6 +57,7 @@ inset: 0; overflow: auto; } + #sessions { display: flex; flex-direction: column; diff --git a/knockoutwhistweb/app/controllers/MainMenuController.scala b/knockoutwhistweb/app/controllers/MainMenuController.scala index 60b0081..55c4a1b 100644 --- a/knockoutwhistweb/app/controllers/MainMenuController.scala +++ b/knockoutwhistweb/app/controllers/MainMenuController.scala @@ -61,9 +61,7 @@ class MainMenuController @Inject()( } } - def rules(): Action[AnyContent] = { - Action { implicit request => - Ok(views.html.mainmenu.rules()) - } + def rules(): Action[AnyContent] = authAction { implicit request: AuthenticatedRequest[AnyContent] => + Ok(views.html.mainmenu.rules(Some(request.user))) } } \ No newline at end of file diff --git a/knockoutwhistweb/app/logic/user/impl/StubUserManager.scala b/knockoutwhistweb/app/logic/user/impl/StubUserManager.scala index 44f71ee..398a908 100644 --- a/knockoutwhistweb/app/logic/user/impl/StubUserManager.scala +++ b/knockoutwhistweb/app/logic/user/impl/StubUserManager.scala @@ -22,6 +22,12 @@ class StubUserManager @Inject()(val config: Config) extends UserManager { id = java.util.UUID.fromString("223e4567-e89b-12d3-a456-426614174000"), name = "Leon", passwordHash = UserHash.hashPW("password123") + ), + "Jakob" -> User( + internalId = 2L, + id = java.util.UUID.fromString("323e4567-e89b-12d3-a456-426614174000"), + name = "Jakob", + passwordHash = UserHash.hashPW("password123") ) ) diff --git a/knockoutwhistweb/app/views/ingame/ingame.scala.html b/knockoutwhistweb/app/views/ingame/ingame.scala.html index 28b8550..dc35d77 100644 --- a/knockoutwhistweb/app/views/ingame/ingame.scala.html +++ b/knockoutwhistweb/app/views/ingame/ingame.scala.html @@ -56,16 +56,16 @@
- @for(i <- player.currentHand().get.cards.indices) { -
-
- - -
-
- } + @for(i <- player.currentHand().get.cards.indices) { +
+
+ + +
+
+ }
} diff --git a/knockoutwhistweb/app/views/login/login.scala.html b/knockoutwhistweb/app/views/login/login.scala.html index 219707e..60aa0e4 100644 --- a/knockoutwhistweb/app/views/login/login.scala.html +++ b/knockoutwhistweb/app/views/login/login.scala.html @@ -1,20 +1,21 @@ @() @main("Login") { +