From 29e1ca2bda3bd5a896246e0121ecae3283dbb6db Mon Sep 17 00:00:00 2001 From: Ryan <7389646+ryanbarlow97@users.noreply.github.com> Date: Tue, 3 Mar 2026 02:01:49 +0000 Subject: [PATCH] new homepage (#3332) ## Description: updated homepage to make ffa the primary focus. closes https://github.com/openfrontio/OpenFrontIO/issues/3288 and closes https://github.com/openfrontio/OpenFrontIO/pull/3328 image image ## Please complete the following: - [x] I have added screenshots for all UI updates - [x] I process any text displayed to the user through translateText() and I've added it to the en.json file - [x] I have added relevant tests to the test directory - [x] I confirm I have thoroughly tested these changes and take full responsibility for any bugs introduced ## Please put your Discord username so you can be contacted if a bug or regression is found: w.o.n --- src/client/GameModeSelector.ts | 50 +++++++++++++++++++---------- src/client/components/MainLayout.ts | 2 +- src/client/components/PlayPage.ts | 2 +- 3 files changed, 35 insertions(+), 19 deletions(-) diff --git a/src/client/GameModeSelector.ts b/src/client/GameModeSelector.ts index 526adf036..6992e342e 100644 --- a/src/client/GameModeSelector.ts +++ b/src/client/GameModeSelector.ts @@ -89,14 +89,23 @@ export class GameModeSelector extends LitElement { const special = this.lobbies?.games?.["special"]?.[0]; return html` -
- ${ffa ? this.renderLobbyCard(ffa, this.getLobbyTitle(ffa)) : nothing} - ${teams - ? this.renderLobbyCard(teams, this.getLobbyTitle(teams)) - : nothing} - ${special ? this.renderSpecialLobbyCard(special) : nothing} +
+
+ ${this.renderSoloButton()} +
+
+ ${ffa + ? html`
+ ${this.renderLobbyCard(ffa, this.getLobbyTitle(ffa))} +
` + : nothing} + ${teams + ? this.renderLobbyCard(teams, this.getLobbyTitle(teams)) + : nothing} + ${special ? this.renderSpecialLobbyCard(special) : nothing} +
${this.renderQuickActionsSection()}
`; @@ -116,20 +125,27 @@ export class GameModeSelector extends LitElement { return this.renderLobbyCard(lobby, titleContent); } + private renderSoloButton() { + const title = translateText("main.solo"); + return html` + + `; + } + private renderQuickActionsSection() { return html` -
-
- ${this.renderSmallActionCard( - translateText("main.solo"), - this.openSinglePlayerModal, - )} +
+ +
${this.renderSmallActionCard( translateText("mode_selector.ranked_title"), this.openRankedMenu, )} -
-
${this.renderSmallActionCard( translateText("main.create"), this.openHostLobby, @@ -213,7 +229,7 @@ export class GameModeSelector extends LitElement { return html`