From 310cc0e2ec8ca05b6196b40c11423301d0db631f Mon Sep 17 00:00:00 2001 From: beo3000 Date: Fri, 9 Jan 2026 10:59:15 +0100 Subject: [PATCH] layout optimization for tablets --- .../Components/Game/GameInputPanel.razor | 143 +++++++++++------- 1 file changed, 91 insertions(+), 52 deletions(-) diff --git a/src/Koogle.Web/Components/Game/GameInputPanel.razor b/src/Koogle.Web/Components/Game/GameInputPanel.razor index d16e414..8606ea6 100644 --- a/src/Koogle.Web/Components/Game/GameInputPanel.razor +++ b/src/Koogle.Web/Components/Game/GameInputPanel.razor @@ -14,72 +14,77 @@ @GameState.Value.ThrowPanelBefore *@
- @* Current player display *@ -
- Aktueller Spieler - - @(CurrentPlayerName ?? "Kein Spieler") - - @if (GameState.Value.Participants.Mode == ParticipantsMode.FreeToChoose) + @* Left column: Player + Pins *@ +
+ @* Current player display *@ +
+ Aktueller Spieler + + @(CurrentPlayerName ?? "Kein Spieler") + + @if (GameState.Value.Participants.Mode == ParticipantsMode.FreeToChoose) + { + + Spieler wechseln + + } +
+ + @* Pin input area *@ +
+ +
+ + @* Number quick-entry (below pins) *@ + @if (@GameState.Value.ThrowPanelAfter.ThrowMode == ThrowMode.Reposition) { - - Spieler wechseln - +
+ +
}
- @* Pin input area *@ -
- -
+ @* Right column: Controls *@ +
+ - - @if (@GameState.Value.ThrowPanelAfter.ThrowMode == ThrowMode.Reposition) - { - @* Number quick-entry *@ -
- + @* Throw info and controls *@ +
+
- } - - - @* Throw info and controls *@ -
- + @* Undo/Redo buttons *@ +
+ +
+ + @* Game-specific actions *@ +
- @* Undo/Redo buttons *@ -
- -
- - @* Game-specific actions *@ - - - @* Error display *@ + @* Error display (full width) *@ @if (!string.IsNullOrEmpty(GameState.Value.Error)) { - + @GameState.Value.Error } - @* Saving indicator *@ + @* Saving indicator (full width) *@ @if (GameState.Value.IsSaving) {
@@ -95,10 +100,44 @@ flex-direction: column; gap: 16px; padding: 16px; - max-width: 500px; + max-width: 900px; margin: 0 auto; } + .left-column { + display: flex; + flex-direction: column; + gap: 16px; + } + + .right-column { + display: flex; + flex-direction: column; + gap: 16px; + } + + /* Tablet and larger: two-column layout */ + @@media (min-width: 768px) { + .game-input-panel { + display: grid; + grid-template-columns: minmax(300px, 1fr) minmax(280px, 1fr); + gap: 24px; + align-items: start; + } + + .error-section, + .saving-indicator { + grid-column: 1 / -1; + } + } + + /* Mobile: stack everything vertically */ + @@media (max-width: 767px) { + .game-input-panel { + max-width: 500px; + } + } + .current-player-section { text-align: center; padding: 16px;