From a80bb83ce9bf9736c30ecf40acbdfe7423606982 Mon Sep 17 00:00:00 2001 From: the-djmaze <> Date: Wed, 22 Feb 2023 14:53:12 +0100 Subject: [PATCH] Simplify CSS folder .focused --- dev/Styles/User/FolderList.less | 16 ++++++---------- dev/View/User/MailBox/FolderList.js | 9 --------- snappymail/v/0.0.0/themes/BlackWood/styles.css | 4 ---- snappymail/v/0.0.0/themes/BlurredDark/styles.css | 4 ---- snappymail/v/0.0.0/themes/LoveDark/styles.css | 4 ---- snappymail/v/0.0.0/themes/NightShine/styles.css | 4 ---- snappymail/v/0.0.0/themes/SnowDarkV1/styles.css | 4 ---- snappymail/v/0.0.0/themes/SquaresDark/styles.css | 4 ---- snappymail/v/0.0.0/themes/StripesDark/styles.css | 4 ---- 9 files changed, 6 insertions(+), 47 deletions(-) diff --git a/dev/Styles/User/FolderList.less b/dev/Styles/User/FolderList.less index 6e5ef1b3f..b9788215d 100644 --- a/dev/Styles/User/FolderList.less +++ b/dev/Styles/User/FolderList.less @@ -7,6 +7,12 @@ height: 100%; } +.focused .b-folders a.focused { + background-color: var(--folders-focused-bg-color, #333); + border-left-color: #fff; + color: var(--folders-focused-color, #eee); +} + .b-folders { display: flex; flex-direction: column; @@ -101,22 +107,12 @@ background-color: var(--folders-selected-bg-color, #333); color: var(--folders-selected-color, #eee); } - - &.focused { - background-color: var(--folders-focused-bg-color, #333); - color: var(--folders-focused-color, #eee); - } } &:not(.selectable) { cursor: default; font-style: italic; } - &.focused { - background-color: #888; - border-left-color: #fff; - } - &.unread-sub { font-weight: bold; } diff --git a/dev/View/User/MailBox/FolderList.js b/dev/View/User/MailBox/FolderList.js index 3f013ffc8..dce24ed33 100644 --- a/dev/View/User/MailBox/FolderList.js +++ b/dev/View/User/MailBox/FolderList.js @@ -173,15 +173,6 @@ export class MailFolderList extends AbstractViewLeft { moveAction(false); return false; }); - - AppUserStore.focusedState.subscribe(value => { - let el = qs('li a.focused'); - el?.classList.remove('focused'); - if (Scope.FolderList === value) { - el = qs('li a.selected'); - el?.classList.add('focused'); - } - }); } scrollToFocused() { diff --git a/snappymail/v/0.0.0/themes/BlackWood/styles.css b/snappymail/v/0.0.0/themes/BlackWood/styles.css index 9a9f06178..b5cb11be8 100644 --- a/snappymail/v/0.0.0/themes/BlackWood/styles.css +++ b/snappymail/v/0.0.0/themes/BlackWood/styles.css @@ -160,10 +160,6 @@ dialog header, dialog footer, filter: invert(1); } -.b-folders li a.focused { - background-color: #111; -} - .tabs [id^="tab"]:checked + label { background: linear-gradient(#555 0%, #000 100%); } diff --git a/snappymail/v/0.0.0/themes/BlurredDark/styles.css b/snappymail/v/0.0.0/themes/BlurredDark/styles.css index e1de4c013..6af6eacf7 100644 --- a/snappymail/v/0.0.0/themes/BlurredDark/styles.css +++ b/snappymail/v/0.0.0/themes/BlurredDark/styles.css @@ -161,10 +161,6 @@ dialog header, dialog footer, filter: invert(1); } -.b-folders li a.focused { - background-color: #111; -} - .tabs [id^="tab"]:checked + label { background: linear-gradient(#555 0%, #000 100%); } diff --git a/snappymail/v/0.0.0/themes/LoveDark/styles.css b/snappymail/v/0.0.0/themes/LoveDark/styles.css index 9a9f06178..b5cb11be8 100644 --- a/snappymail/v/0.0.0/themes/LoveDark/styles.css +++ b/snappymail/v/0.0.0/themes/LoveDark/styles.css @@ -160,10 +160,6 @@ dialog header, dialog footer, filter: invert(1); } -.b-folders li a.focused { - background-color: #111; -} - .tabs [id^="tab"]:checked + label { background: linear-gradient(#555 0%, #000 100%); } diff --git a/snappymail/v/0.0.0/themes/NightShine/styles.css b/snappymail/v/0.0.0/themes/NightShine/styles.css index 9a9f06178..b5cb11be8 100644 --- a/snappymail/v/0.0.0/themes/NightShine/styles.css +++ b/snappymail/v/0.0.0/themes/NightShine/styles.css @@ -160,10 +160,6 @@ dialog header, dialog footer, filter: invert(1); } -.b-folders li a.focused { - background-color: #111; -} - .tabs [id^="tab"]:checked + label { background: linear-gradient(#555 0%, #000 100%); } diff --git a/snappymail/v/0.0.0/themes/SnowDarkV1/styles.css b/snappymail/v/0.0.0/themes/SnowDarkV1/styles.css index e1de4c013..6af6eacf7 100644 --- a/snappymail/v/0.0.0/themes/SnowDarkV1/styles.css +++ b/snappymail/v/0.0.0/themes/SnowDarkV1/styles.css @@ -161,10 +161,6 @@ dialog header, dialog footer, filter: invert(1); } -.b-folders li a.focused { - background-color: #111; -} - .tabs [id^="tab"]:checked + label { background: linear-gradient(#555 0%, #000 100%); } diff --git a/snappymail/v/0.0.0/themes/SquaresDark/styles.css b/snappymail/v/0.0.0/themes/SquaresDark/styles.css index 07f336d07..887433276 100644 --- a/snappymail/v/0.0.0/themes/SquaresDark/styles.css +++ b/snappymail/v/0.0.0/themes/SquaresDark/styles.css @@ -143,10 +143,6 @@ filter: invert(1); } -.b-folders li a.focused { - background-color: #111; -} - .tabs [id^="tab"]:checked + label { background: linear-gradient(#555 0%, #000 100%); } diff --git a/snappymail/v/0.0.0/themes/StripesDark/styles.css b/snappymail/v/0.0.0/themes/StripesDark/styles.css index 9a9f06178..b5cb11be8 100644 --- a/snappymail/v/0.0.0/themes/StripesDark/styles.css +++ b/snappymail/v/0.0.0/themes/StripesDark/styles.css @@ -160,10 +160,6 @@ dialog header, dialog footer, filter: invert(1); } -.b-folders li a.focused { - background-color: #111; -} - .tabs [id^="tab"]:checked + label { background: linear-gradient(#555 0%, #000 100%); }