From bded1bc818511d958227f58ecc1fe8f2af526137 Mon Sep 17 00:00:00 2001 From: Darren Burns Date: Thu, 24 Oct 2024 10:39:53 +0100 Subject: [PATCH] Updating progress bar colors --- examples/theme_sandbox.py | 6 ++++-- src/textual/theme.py | 2 -- src/textual/widgets/_progress_bar.py | 8 ++++---- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/examples/theme_sandbox.py b/examples/theme_sandbox.py index 1b3294728..07513f08a 100644 --- a/examples/theme_sandbox.py +++ b/examples/theme_sandbox.py @@ -16,9 +16,9 @@ from textual.widgets import ( Label, ListItem, ListView, - LoadingIndicator, MarkdownViewer, OptionList, + ProgressBar, RadioSet, RichLog, Select, @@ -267,7 +267,9 @@ class ChangingThemeApp(App[None]): with Collapsible(title="An interesting story."): yield Label("Interesting but verbose story.") - yield LoadingIndicator() + progress = ProgressBar(total=100) + progress.advance(70) + yield progress rich_log = RichLog(highlight=True, markup=True) rich_log.write("Hello, world!") diff --git a/src/textual/theme.py b/src/textual/theme.py index 2c8e47edf..39e0c2f8f 100644 --- a/src/textual/theme.py +++ b/src/textual/theme.py @@ -102,8 +102,6 @@ BUILTIN_THEMES: dict[str, Theme] = { "block-cursor-foreground": "#2E3440", "block-cursor-text-style": "none", "footer-key-foreground": "#88C0D0", - "input-cursor-foreground": "#2E3440", - "input-cursor-background": "#88C0D0", "input-selection-background": "#81a1c1 35%", }, ), diff --git a/src/textual/widgets/_progress_bar.py b/src/textual/widgets/_progress_bar.py index 6ad585a3b..a1c0260b8 100644 --- a/src/textual/widgets/_progress_bar.py +++ b/src/textual/widgets/_progress_bar.py @@ -44,16 +44,16 @@ class Bar(Widget, can_focus=False): height: 1; &> .bar--bar { - color: $warning; - background: $foreground 10%; + color: $primary; + background: $surface; } &> .bar--indeterminate { color: $error; - background: $foreground 10%; + background: $surface; } &> .bar--complete { color: $success; - background: $foreground 10%; + background: $surface; } } """