From bf37686eb3bb18e62442502f44828c4724b3087c Mon Sep 17 00:00:00 2001 From: alstjr7375 Date: Mon, 7 Aug 2023 11:00:45 +0900 Subject: [PATCH] Fix: Icons - Sidebar menupopup for v106 #749 --- css/leptonChrome.css | 18 +++++++++--------- src/icons/layout/_menu.scss | 7 +++++-- src/icons/layout/_menu_common.scss | 6 +----- 3 files changed, 15 insertions(+), 16 deletions(-) diff --git a/css/leptonChrome.css b/css/leptonChrome.css index 3db34dc4..54e7a7f3 100644 --- a/css/leptonChrome.css +++ b/css/leptonChrome.css @@ -10711,7 +10711,7 @@ .openintabs-menuitem, #blockedPopupDontShowMessage, #BMB_viewBookmarksToolbar, - #sidebarMenu-popup, + #sidebarMenu-popup:is(menupopup), #context_openANewTab.tabmix-newtab-menu-icon { /* Color */ -moz-context-properties: fill, fill-opacity, stroke !important; @@ -10769,20 +10769,20 @@ .openintabs-menuitem, #blockedPopupDontShowMessage, #BMB_viewBookmarksToolbar, - #sidebarMenu-popup, + #sidebarMenu-popup:is(menupopup), #context_openANewTab.tabmix-newtab-menu-icon { background-position: var(--uc-menu-background-position) var(--context-menu-background-padding) center !important; padding-inline-start: var(--context-menu-background-padding) !important; } - #sidebarMenu-popup:has(menuitem) { - margin-inline-start: calc( - (var(--context-menu-background-padding) + var(--panel-shadow-margin, 4px)) * -1 - ) !important; + #sidebarMenu-popup:is(menupopup):not(panel) { + --context-menu-background-padding: var(--context-menu-background-padding-default); + padding-inline-start: 0 !important; } :not(menu, #ContentSelectDropdown, #context-navigation) - > #sidebarMenu-popup:has(menuitem) + > #sidebarMenu-popup:is(menupopup):not(panel) > menuitem:not(.menuitem-iconic, .bookmark-item, .in-menulist, [checked="true"]) { padding-inline-start: 28px !important; + margin-inline-start: var(--arrowpanel-menuitem-margin-inline) !important; } /* Menubar */ @supports -moz-bool-pref("userChrome.icon.global_menubar") { @@ -10935,7 +10935,7 @@ .openintabs-menuitem, #blockedPopupDontShowMessage, #BMB_viewBookmarksToolbar, - #sidebarMenu-popup, + #sidebarMenu-popup:is(menupopup), #context_openANewTab.tabmix-newtab-menu-icon { background-position: left var(--context-menu-background-padding) center !important; padding-inline-start: 0 !important; @@ -10961,7 +10961,7 @@ .openintabs-menuitem, #blockedPopupDontShowMessage, #BMB_viewBookmarksToolbar, - #sidebarMenu-popup, + #sidebarMenu-popup:is(menupopup), #context_openANewTab.tabmix-newtab-menu-icon { padding-inline-start: var(--menu-background-padding-default) !important; margin-left: 0 !important; diff --git a/src/icons/layout/_menu.scss b/src/icons/layout/_menu.scss index c4c8276a..ba2007c2 100644 --- a/src/icons/layout/_menu.scss +++ b/src/icons/layout/_menu.scss @@ -57,10 +57,13 @@ $_layoutCommonMenus: ( @include _layoutInitPaddingMenus { @include _layout_init_padding; } -#sidebarMenu-popup:has(menuitem) { - @include _layout_init_margin; +#sidebarMenu-popup:is(menupopup):not(panel) { + --context-menu-background-padding: var(--context-menu-background-padding-default); + padding-inline-start: 0 !important; + :not(menu, #ContentSelectDropdown, #context-navigation) > & > #{$_iconMenuitem} { padding-inline-start: 28px !important; + margin-inline-start: var(--arrowpanel-menuitem-margin-inline) !important; } } diff --git a/src/icons/layout/_menu_common.scss b/src/icons/layout/_menu_common.scss index f6a7a9b1..048e96f1 100644 --- a/src/icons/layout/_menu_common.scss +++ b/src/icons/layout/_menu_common.scss @@ -31,7 +31,7 @@ $_libraryMenuitem: "menupopup:is(#organizeButtonPopup, #maintenanceButtonPopup) $_libraryMenu: "menupopup:is(#viewMenuPopup, #maintenanceButtonPopup) > #{$_iconMenu}"; $_sendTabMenuPopup: "#context_sendTabToDevicePopupMenu, #context-sendpagetodevice-popup, #context-sendlinktodevice-popup"; $_otherPopupMenuitem: "menupopup:is(#{$_sendTabMenuPopup}, #frame > menupopup) > menuitem"; -$_otherIconMenu: ".openintabs-menuitem, #blockedPopupDontShowMessage, #BMB_viewBookmarksToolbar, #sidebarMenu-popup"; +$_otherIconMenu: ".openintabs-menuitem, #blockedPopupDontShowMessage, #BMB_viewBookmarksToolbar, #sidebarMenu-popup:is(menupopup)"; //-- Mixin --------------------------------------------------------------------- // Init Menu @@ -79,10 +79,6 @@ $_initialMenus: $_initialMenus + "," + background-position: var(--uc-menu-background-position) var(--context-menu-background-padding) center !important; padding-inline-start: var(--context-menu-background-padding) !important; } -@mixin _layout_init_margin() { - // Fix sidebar position - margin-inline-start: calc((var(--context-menu-background-padding) + var(--panel-shadow-margin, 4px)) * -1) !important -} @mixin _layout_win_native_menu_popup() { @include NativeMenuPopup {