From 13e8e0ab9a265480c699656aceab86c2dbc7ad3e Mon Sep 17 00:00:00 2001 From: Will McGugan Date: Wed, 20 Sep 2023 17:31:44 +0100 Subject: [PATCH] selector --- src/textual/widgets/_selection_list.py | 6 +++--- src/textual/widgets/_toggle_button.py | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/textual/widgets/_selection_list.py b/src/textual/widgets/_selection_list.py index a448c5e412..f8dece7142 100644 --- a/src/textual/widgets/_selection_list.py +++ b/src/textual/widgets/_selection_list.py @@ -97,15 +97,15 @@ class SelectionList(Generic[SelectionType], OptionList): height: auto; } - .-light-mode SelectionList:focus > .selection-list--button-selected { + SelectionList:light:focus > .selection-list--button-selected { color: $primary; } - .-light-mode SelectionList > .selection-list--button-selected-highlighted { + SelectionList:light > .selection-list--button-selected-highlighted { color: $primary; } - .-light-mode SelectionList:focus > .selection-list--button-selected-highlighted { + SelectionList:light:focus > .selection-list--button-selected-highlighted { color: $primary; } diff --git a/src/textual/widgets/_toggle_button.py b/src/textual/widgets/_toggle_button.py index 4c29c236ae..90828c7ac1 100644 --- a/src/textual/widgets/_toggle_button.py +++ b/src/textual/widgets/_toggle_button.py @@ -94,16 +94,16 @@ class ToggleButton(Static, can_focus=True): /* Light mode overrides. */ - App.-light-mode ToggleButton > .toggle--button { + ToggleButton:light > .toggle--button { color: $background; background: $foreground 10%; } - App.-light-mode ToggleButton:focus > .toggle--button { + ToggleButton:light:focus > .toggle--button { background: $foreground 25%; } - App.-light-mode ToggleButton.-on > .toggle--button { + ToggleButton:light.-on > .toggle--button { color: $primary; } """ # TODO: https://github.com/Textualize/textual/issues/1780