3 Коміти 649bdc25ee ... c21e70fb69

Автор SHA1 Опис Дата
  Steve0Greatness c21e70fb69 Version Bump: 1.4.1 5 місяців тому
  Steve0Greatness 57e0ae6fcc Verion Bump: 1.4 5 місяців тому
  Steve0Greatness df7b1f1781 Version Bump 1.3 5 місяців тому
3 змінених файлів з 169 додано та 6 видалено
  1. 25 0
      CHANGELOG.md
  2. 143 5
      fandom-debloater.user.css
  3. 1 1
      fandom-debloater.user.js

+ 25 - 0
CHANGELOG.md

@@ -1,3 +1,28 @@
+# 1.4.1
+
+* Some bug fixes
+* Theme to page what wasn't before
+* Added new option to theme elements created by Fandom (currently only the slider)
+
+_Yes, another update_
+
+# 1.4
+
+* Added the ability for notifications and user dropdowns in sidebar
+  to be colored according wiki theme (optional)
+* Added ability for search popup to be themed according to the
+  wiki's theme (optional)
+* Top searches can now be hidden. (optional)
+* Hide "related wikis" from search.
+
+_Yes, I'm aware this was the second update in 24 hours._
+
+# 1.3
+
+* Don't display the highlight action.
+* Bugfix for Pale Moon: the selector that used :has is now
+  its own rule
+
 # 1.2
 
 * Fixed a bug that didn't let the userstyle get installed

+ 143 - 5
fandom-debloater.user.css

@@ -1,7 +1,7 @@
 /* ==UserStyle==
 @name         YA Fandom Debloater
 @namespace    github.com/openstyles/stylus
-@version      1.2.0
+@version      1.4.1
 @preprocessor less
 @description  (Yet Another Fandom Debloater)
 @author       Steve0Greatness
@@ -9,13 +9,21 @@
 @supportURL   https://notabug.org/Steve0Greatness/Yet-Another-Fandom-Debloater/issues
 @updateURL    https://notabug.org/Steve0Greatness/Yet-Another-Fandom-Debloater/raw/master/fandom-debloater.user.css
 @license      GPL-v3
+@var checkbox show-comments "Show article comments" 0
+@var checkbox use-global-colors-notifications "Use global colors for Fandom elements (sidebar)" 0
+@var checkbox use-global-colors-search "Use global colors for search" 0
+@var checkbox hide-popular-searches "Hide popular searches" 0
+@var checkbox use-global-colors-fandom-el "Use global colors for elements made by Fandom (e.g. slider)" 0
 ===/UserStyle== */
 @-moz-document domain("fandom.com") {
     #articleComments {
         margin-top: 3em;
-        display: if((true), none) !important;
+        & when (@show-comments = 0) {
+            display: none !important;
+        }
     }
 
+    .nkch-rdp,
     .ad-slot-placeholder,
     .global-navigation__logo,
     .global-navigation__search,
@@ -27,13 +35,25 @@
     .page__right-rail,
     .global-footer__section.global-footer__section-fandom-apps,
     .global-footer__section.global-footer__section-fandom-stores,
-    .global-footer__content div:has(.global-footer__section-fandom-apps),
     .global-footer__section.global-footer__section-social-links,
     .global-footer__section-fandom-overview,
     .global-footer__bottom,
-    .global-footer__content div:nth-child(1) {
+    .global-footer__content div:nth-child(1),
+    .highlight__sticky-container,
+    .unified-search__layout__right-rail,
+    .unified-search__input__wrapper .wds-dropdown,
+    .global-navigation__bottom .wds-dropdown__content .wds-list::before,
+    .global-navigation__bottom .wds-dropdown__content .wds-list::after {
         display: none !important;
     }
+    
+    .global-footer__content div:has(.global-footer__section-fandom-apps) {
+        display: none !important;
+    }
+    
+    .fandom-slider__nav when (@use-global-colors-fandom-el = 0) {
+        background-color: rgba(var(--theme-page-background-color--secondary--rgb), 0.5);
+    }
 
     .global-navigation_bottom {
         box-shadow: none;
@@ -58,7 +78,7 @@
         padding-right: 18px;
     }
 
-    .CommentList_empty-state__Cx7nB {
+    [class^=CommentList_empty-state__] {
         padding: 20px 10px;
     }
 
@@ -79,6 +99,29 @@
 
     .global-navigation__icon {
         background-color: var(--fandom-dropdown-background-color);
+        & when (@use-global-colors-notifications = 0) {
+            background-color: var(--theme-page-background-color);
+            border-color: var(--theme-border-color);
+        }
+    }
+    
+    .search-seeding when (@hide-popular-searches = 1) {
+        display: none !important;
+    }
+    
+    .search-modal__content {
+        height: auto !important;
+        min-height: 0 !important;
+        & when (@use-global-colors-search = 0) {
+            border-color: var(--theme-border-color);
+        }
+    }
+    
+    .search-modal__content .top-results__link when (@use-global-colors-search = 0)  {
+        color: var(--theme-link-color);
+    }
+    .search-modal__content .top-results__link:hover when (@use-global-colors-search = 0)  {
+        color: var(--theme-link-color--hover);
     }
 
     .global-footer {
@@ -86,4 +129,99 @@
         border-top: #fff 1px solid;
         background-color: #0005 !important;
     }
+    
+    .search-modal,
+    .search-modal::before {
+        left: 0 !important;
+    }
+    
+    .search-modal::before when (@use-global-colors-search = 0) {
+        background-color: #000000e6;
+    }
+    
+    .search-modal form .wds-button when (@use-global-colors-search = 0) {
+        --wds-primary-button-background-color: var(--theme-link-color);
+        --wds-primary-button-background-color--hover: var(--theme-link-color--hover);
+        --wds-primary-button-label-color: var(--theme-link-label-color);
+    }
+    
+    .search-modal form when (@use-global-colors-search = 0) {
+        border-bottom-color: var(--theme-link-color);
+    }
+    
+    .search-modal__content .wds-list :any-link {
+        color: var(--theme-link-color) !important;
+        background: none !important;
+    }
+    .search-modal__content .wds-list :any-link:hover {
+        color: var(--theme-link-color--hover) !important;
+    }
+    
+    .search-modal__content when (@use-global-colors-search = 0) {
+        background-color: var(--theme-page-background-color) !important;
+    }
+    
+    .search-seeding when (@use-global-colors-search = 0)  {
+        color: var(--theme-body-text-color);
+    }
+    
+    .highlight__wiki-btn when (@use-global-colors-search = 0)  {
+        color: var(--theme-body-text-color);
+    }
+    
+    .unified-search__layout {
+        display: grid;
+        grid-template-areas: "left left main main main main main main main right right right" !important;
+        grid-template-columns: 1fr !important;
+    }
+    
+    .global-navigation__bottom .wds-dropdown__content when (@use-global-colors-notifications = 0) {
+        background-color: var(--theme-page-background-color);
+        border-color: var(--theme-border-color);
+        color: var(--theme-body-text-color) !important;
+    }
+    
+    .global-navigation__bottom .wds-dropdown__content :any-link,
+    .global-navigation__signout-button {
+        & when (@use-global-colors-notifications = 0) {
+            color: var(--theme-link-color) !important;
+        }
+        &:hover when (@use-global-colors-notifications = 0) {
+            color: var(--theme-link-color--hover) !important;
+            background: var(--theme-page-background-color--secondary) !important;
+        }
+    }
+    
+    
+    .global-navigation__bottom .wds-dropdown__content ul when (@use-global-colors-notifications = 0) {
+        background: none !important;
+        border-color: var(--theme-border-color);
+    }
+    
+    .global-navigation__bottom .wds-tabs__tab when (@use-global-colors-notifications = 0) {
+        color: var(--theme-body-text-color);
+        &.wds-is-current {
+            color: var(--theme-link-color);
+            &:hover {
+                color: var(--theme-link-color--hover);
+            }
+        }
+    }
+    
+    .global-navigation__bottom .wds-dropdown.wds-open-to-right::before when (@use-global-colors-notifications = 0) {
+        border-right-color: var(--theme-border-color);
+    }
+    
+    .global-navigation .wds-dropdown when (@use-global-colors-notifications = 0) {
+        --wds-dropdown-background-color: var(--theme-page-background-color);
+    }
+    
+    
+    [class^=NotificationsContent-module_specialPageLink__] when (@use-global-colors-notifications = 0) {
+        background-color: var(--theme-page-background-color);
+    }
+    
+    [class^=NotificationsContent-module_contentHeader__] when (@use-global-colors-notifications = 0) {
+        border-color: var(--theme-border-color);
+    }
 }

+ 1 - 1
fandom-debloater.user.js

@@ -3,7 +3,7 @@
 // @namespace   Violentmonkey Scripts
 // @match       https://*.fandom.com/*
 // @grant       none
-// @version     1.2
+// @version     1.4
 // @author      Steve0Greatness
 // @description (Yet Another Fandom Debloater)
 // @copyright   GPL-v3