From b90580286dae0ed398d68ae0283137e1f0142ae4 Mon Sep 17 00:00:00 2001 From: death916 Date: Thu, 13 Nov 2025 03:42:30 -0800 Subject: [PATCH] resizing to fit pi screen --- deathclock/deathclock.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/deathclock/deathclock.py b/deathclock/deathclock.py index 0d86f04..30cbd5a 100755 --- a/deathclock/deathclock.py +++ b/deathclock/deathclock.py @@ -11,12 +11,10 @@ from typing import Any, Dict, List import reflex as rx - from utils.news import News from utils.scores import NBAScores, mlbScores, nflScores from utils.weather import Weather - # --- Constants --- WEATHER_IMAGE_PATH = "/weather.jpg" # Web path in assets folder WEATHER_FETCH_INTERVAL = 360 @@ -259,13 +257,15 @@ def index() -> rx.Component: padding="2", align_items="stretch", width="100%", + wrap="wrap", ) nba_card = rx.card( rx.box( rx.text("NBA Scores"), nba_scores_list, - ) + ), + height="70vh", # shrinking the height of the card ) # Weather card @@ -359,7 +359,7 @@ def index() -> rx.Component: spacing="3", width="100%", justify="center", - align="stretch", + align="baseline", ) # Top clock button @@ -404,7 +404,7 @@ def index() -> rx.Component: # Compose the page page = rx.container( # pyright: ignore[reportReturnType] rx.theme_panel(default_open=False), - rx.center( + rx.flex( rx.vstack( clock_button, main_flex, @@ -416,6 +416,7 @@ def index() -> rx.Component: padding="2rem", max_width="1200px", margin="0 auto", + flex_direction="column", ) return page