Fix logo display and side-by-side layout

Use full block-character logo from bin/gniza, place logo Static
and OptionList directly in Horizontal container without extra
nesting. Style with proper widths.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
shuki
2026-03-05 23:51:01 +02:00
parent 85eb4232c8
commit 111b5ee607
2 changed files with 32 additions and 30 deletions

View File

@@ -18,28 +18,19 @@ Screen {
align: center middle; align: center middle;
} }
#logo-panel { #logo {
width: auto; width: auto;
min-width: 40;
height: auto; height: auto;
padding: 1 2; padding: 1 3;
align: center middle; content-align: center middle;
}
#menu-panel {
width: 1fr;
max-width: 40;
height: auto;
padding: 1 2;
} }
#menu-list { #menu-list {
width: 100%; width: 1fr;
height: auto; max-width: 35;
max-height: 100%;
}
#logo {
height: auto; height: auto;
margin: 1 2;
} }
/* Data tables */ /* Data tables */

View File

@@ -5,13 +5,26 @@ from textual.widgets.option_list import Option
from textual.containers import Horizontal, Vertical from textual.containers import Horizontal, Vertical
LOGO = """\ LOGO = """\
[green] [green]
\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593 ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593 \u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593 ▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓
\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593 ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593\u2593 ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
[/green]
gniza - Linux Backup Manager ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓ ▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓▓▓▓▓
▓▓▓▓▓▓
▓▓
[/green]
gniza - Linux Backup Manager
""" """
MENU_ITEMS = [ MENU_ITEMS = [
@@ -36,9 +49,7 @@ class MainMenuScreen(Screen):
def compose(self) -> ComposeResult: def compose(self) -> ComposeResult:
yield Header() yield Header()
with Horizontal(id="main-layout"): with Horizontal(id="main-layout"):
with Vertical(id="logo-panel"):
yield Static(LOGO, id="logo", markup=True) yield Static(LOGO, id="logo", markup=True)
with Vertical(id="menu-panel"):
yield OptionList( yield OptionList(
*[Option(label, id=mid) for mid, label in MENU_ITEMS], *[Option(label, id=mid) for mid, label in MENU_ITEMS],
id="menu-list", id="menu-list",