summaryrefslogtreecommitdiff
path: root/sw-ui-kt/src
diff options
context:
space:
mode:
Diffstat (limited to 'sw-ui-kt/src')
-rw-r--r--sw-ui-kt/src/main/kotlin/org/luxons/sevenwonders/ui/components/gameBrowser/GameList.kt4
-rw-r--r--sw-ui-kt/src/main/kotlin/org/luxons/sevenwonders/ui/components/lobby/Lobby.kt3
2 files changed, 4 insertions, 3 deletions
diff --git a/sw-ui-kt/src/main/kotlin/org/luxons/sevenwonders/ui/components/gameBrowser/GameList.kt b/sw-ui-kt/src/main/kotlin/org/luxons/sevenwonders/ui/components/gameBrowser/GameList.kt
index 375ac96f..10d5c868 100644
--- a/sw-ui-kt/src/main/kotlin/org/luxons/sevenwonders/ui/components/gameBrowser/GameList.kt
+++ b/sw-ui-kt/src/main/kotlin/org/luxons/sevenwonders/ui/components/gameBrowser/GameList.kt
@@ -108,9 +108,9 @@ private fun RBuilder.playerCount(nPlayers: Int) {
private fun RBuilder.joinButton(lobby: LobbyDTO, joinGame: (Long) -> Unit) {
bpButton(
minimal = true,
- title = "Join Game",
+ title = lobby.joinAction.tooltip,
icon = "arrow-right",
- disabled = lobby.state != State.LOBBY,
+ disabled = !lobby.joinAction.canDo,
onClick = { joinGame(lobby.id) }
)
}
diff --git a/sw-ui-kt/src/main/kotlin/org/luxons/sevenwonders/ui/components/lobby/Lobby.kt b/sw-ui-kt/src/main/kotlin/org/luxons/sevenwonders/ui/components/lobby/Lobby.kt
index 62f1c524..668a41c2 100644
--- a/sw-ui-kt/src/main/kotlin/org/luxons/sevenwonders/ui/components/lobby/Lobby.kt
+++ b/sw-ui-kt/src/main/kotlin/org/luxons/sevenwonders/ui/components/lobby/Lobby.kt
@@ -40,7 +40,8 @@ class LobbyPresenter(props: LobbyProps) : RComponent<LobbyProps, RState>(props)
large = true,
intent = Intent.PRIMARY,
icon = "play",
- disabled = !currentGame.canBeStarted,
+ title = currentGame.startAction.tooltip,
+ disabled = !currentGame.startAction.canDo,
onClick = { props.startGame() }
) {
+ "START"
bgstack15