summary refs log tree commit diff
diff options
context:
space:
mode:
authorRobert Günzler <r@gnzler.io>2024-12-08 23:33:46 +0100
committerRobert Günzler <r@gnzler.io>2024-12-08 23:33:46 +0100
commit295a8a28fcbd52f5c8eceff9f6a6ec3bc4b32f52 (patch)
tree0ea58d44826be9f41b832de53a9043db402ac44c
parent23de12baba9fbfc4ca24581b37c374aa5345cc25 (diff)
fix firefox userchrome with sidebar.revamp
Signed-off-by: Robert Günzler <r@gnzler.io>
Diffstat (limited to '')
-rw-r--r--.mozilla/firefox/hibiki.default/chrome/csshacks.hide_tabs_toolbar_v2.css51
-rw-r--r--.mozilla/firefox/hibiki.default/chrome/user.sidebar.css58
-rw-r--r--.mozilla/firefox/hibiki.default/chrome/user.urlbar.css60
-rw-r--r--.mozilla/firefox/hibiki.default/chrome/userChrome.css134
-rw-r--r--.mozilla/firefox/hibiki.default/user.js7
5 files changed, 194 insertions, 116 deletions
diff --git a/.mozilla/firefox/hibiki.default/chrome/csshacks.hide_tabs_toolbar_v2.css b/.mozilla/firefox/hibiki.default/chrome/csshacks.hide_tabs_toolbar_v2.css
new file mode 100644
index 0000000..37dadb8
--- /dev/null
+++ b/.mozilla/firefox/hibiki.default/chrome/csshacks.hide_tabs_toolbar_v2.css
@@ -0,0 +1,51 @@
+/* Source file https://github.com/MrOtherGuy/firefox-csshacks/tree/master/chrome/hide_tabs_toolbar_v2.css made available under Mozilla Public License v. 2.0
+See the above repository for updates as well as full license text. */
+
+/* This requires Firefox 133+ to work */
+
+@media (-moz-bool-pref: "sidebar.verticalTabs"){
+  #sidebar-main{
+    visibility: collapse;
+  }
+}
+@media (-moz-bool-pref: "userchrome.force-window-controls-on-left.enabled"){
+  #nav-bar > .titlebar-buttonbox-container{
+    order: -1 !important;
+    > .titlebar-buttonbox{
+      flex-direction: row-reverse;
+    }
+  }
+}
+@media not (-moz-bool-pref: "sidebar.verticalTabs"){
+  #TabsToolbar:not([customizing]){
+    visibility: collapse;
+  }
+  :root[sizemode="fullscreen"] #nav-bar > .titlebar-buttonbox-container{
+    display: flex !important;
+  }
+  :root:is([tabsintitlebar],[customtitlebar]) #toolbar-menubar:not([autohide="false"]) ~ #nav-bar{
+    > .titlebar-buttonbox-container{
+      display: flex !important;
+    }
+    :root[sizemode="normal"] & {
+      > .titlebar-spacer{
+        display: flex !important;
+      }
+    }
+    :root[sizemode="maximized"] & {
+      > .titlebar-spacer[type="post-tabs"]{
+        display: flex !important;
+      }
+      @media (-moz-bool-pref: "userchrome.force-window-controls-on-left.enabled"),
+        (-moz-gtk-csd-reversed-placement),
+        (-moz-platform: macos){
+        > .titlebar-spacer[type="post-tabs"]{
+          display: none !important;
+        }
+        > .titlebar-spacer[type="pre-tabs"]{
+          display: flex !important;
+        }
+      }
+    }
+  }
+}
\ No newline at end of file
diff --git a/.mozilla/firefox/hibiki.default/chrome/user.sidebar.css b/.mozilla/firefox/hibiki.default/chrome/user.sidebar.css
new file mode 100644
index 0000000..e286126
--- /dev/null
+++ b/.mozilla/firefox/hibiki.default/chrome/user.sidebar.css
@@ -0,0 +1,58 @@
+/* = SIDEBAR STUFF ========================================================== */
+
+/* sidebar that collapses when not hovered */
+:root {
+	--thin-tab-width: 31px;
+	--wide-tab-width: 280px;
+}
+
+@media (-moz-bool-pref: "sidebar.revamp") {
+	#sidebar-box {
+		padding: 0 !important;
+	}
+
+	#sidebar {
+		border-radius: 0 !important;
+	}
+}
+
+#sidebar-box {
+	width: unset !important;
+	z-index: 1;
+	opacity: 1.0 !important;
+	border-right: 1px solid var(--chrome-content-separator-color);
+	background-color: var(--toolbar-bgcolor) !important;
+}
+
+#sidebar-box:not([hidden]) {
+	min-width: var(--thin-tab-width) !important;
+	max-width: var(--thin-tab-width) !important;
+	overflow-x: hidden !important;
+	/*animate transition*/
+	/*transition: all 40ms !important;*/
+}
+
+#sidebar-box:not([hidden]):hover,
+#sidebar-box:not([hidden]):active,
+#sidebar-box:not([hidden]):focus-within,
+#sidebar-box:not([hidden]):-moz-drag-over {
+	min-width: var(--wide-tab-width) !important;
+	max-width: var(--wide-tab-width) !important;
+}
+
+/* make sure the contents of the sidebar are not squished */
+#sidebar {
+	min-width: var(--wide-tab-width) !important;
+	max-width: var(--wide-tab-width) !important;
+	margin-left: 0 !important;
+}
+
+/* hide sidebar header */
+#sidebar-header {
+	visibility: collapse;
+}
+
+/* hide sidebar shadow */
+#sidebar-splitter {
+	display: none !important;
+}
diff --git a/.mozilla/firefox/hibiki.default/chrome/user.urlbar.css b/.mozilla/firefox/hibiki.default/chrome/user.urlbar.css
new file mode 100644
index 0000000..158c59b
--- /dev/null
+++ b/.mozilla/firefox/hibiki.default/chrome/user.urlbar.css
@@ -0,0 +1,60 @@
+/* = URLBAR STUFF =========================================================== */
+
+#urlbar-container {
+	--urlbar-container-height: 29px !important;
+	--urlbar-container-padding: 0px !important;
+}
+
+#urlbar {
+	--urlbar-height: var(--urlbar-container-height) !important;
+	--urlbar-toolbar-height: var(--urlbar-container-height) !important;
+}
+
+#urlbar-background {
+	border: none !important;
+}
+
+#urlbar:not([focused="true"])>#urlbar-background {
+	background-color: var(--toolbar-bgcolor) !important;
+}
+
+#urlbar-input-container {
+	padding-right: 5px !important;
+	border: none !important;
+}
+
+#urlbar-results,
+.urlbarView-row {
+	padding-top: 0px !important;
+	padding-bottom: 0px !important;
+}
+
+.search-one-offs {
+	padding-block: 0px !important;
+}
+
+.search-panel-one-offs {
+	padding-left: 7px !important;
+}
+
+.searchbar-engine-one-off-item {
+	margin: 0px !important;
+}
+
+/* make sure the lock icon aligns with the collapsed sidebar */
+#urlbar-container {
+	padding-block: 0 !important;
+	margin-left: 0 !important;
+}
+
+#tracking-protection-icon-container {
+	padding: 0 6px !important;
+}
+
+#identity-box {
+	margin-inline-start: var(--identity-box-margin-inline);
+}
+
+#tracking-protection-icon-container {
+	padding-left: 8px !important;
+}
diff --git a/.mozilla/firefox/hibiki.default/chrome/userChrome.css b/.mozilla/firefox/hibiki.default/chrome/userChrome.css
index 1f0cb3d..ef1a5d2 100644
--- a/.mozilla/firefox/hibiki.default/chrome/userChrome.css
+++ b/.mozilla/firefox/hibiki.default/chrome/userChrome.css
@@ -2,10 +2,17 @@
  */
 
 @import url(lepton.userChrome.css);
+@import url(csshacks.hide_tabs_toolbar_v2.css);
+@import url(user.urlbar.css);
+@import url(user.sidebar.css);
 
 @namespace xul "http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul";
 @namespace html "http://www.w3.org/1999/xhtml";
 
+* {
+    font-family: "Iosevka Aile", monospace !important;
+}
+
 @media (-moz-toolbar-prefers-color-scheme: dark),
 (prefers-color-scheme: dark) {
     :root {
@@ -23,10 +30,6 @@
     --chrome-content-separator-color: #70649ab0 !important;
 }
 
-* {
-    font-family: Iosevka Aile, monospace !important;
-}
-
 /* prevent pre-load flash bang */
 .browserContainer {
     background-color: var(--toolbar-bgcolor) !important;
@@ -40,6 +43,8 @@
     display: none !important;
 }
 
+/* = RADIUS STUFF ========================================================== */
+
 /* Makes urlbar and many other things sharper on the edges */
 :root {
     --any-border-radius: 0;
@@ -69,122 +74,19 @@ statuspanel {
     display: none !important;
 }
 
-/* = URLBAR STUFF =========================================================== */
-
-#urlbar-container {
-    --urlbar-container-height: 29px !important;
-    --urlbar-container-padding: 0px !important;
-    /* --lwt-toolbar-field-background-color: transparent !important; */
-}
-
-#urlbar {
-    --urlbar-height: var(--urlbar-container-height) !important;
-    --urlbar-toolbar-height: var(--urlbar-container-height) !important;
-}
-
-#urlbar-background {
-    border: none !important;
-}
-
-#urlbar:not([focused="true"])>#urlbar-background {
-    background-color: transparent !important;
-}
-
-#urlbar-input-container {
-    padding-right: 5px !important;
-    border: none !important;
-}
-
-#urlbar-results,
-.urlbarView-row {
-    padding-top: 0px !important;
-    padding-bottom: 0px !important;
-}
-
-.search-one-offs {
-    padding-block: 0px !important;
-}
-
-.search-panel-one-offs {
-    padding-left: 7px !important;
-}
-
-.searchbar-engine-one-off-item {
-    margin: 0px !important;
-}
-
-
-/* hide the bookmark button */
-#star-button-box,
-#pageActionSeparator {
-    display: none !important;
-}
-
-/* make sure the lock icon aligns with the collapsed sidebar */
-#urlbar-container {
-    padding-block: 0 !important;
-    margin-left: 0 !important;
-}
-
-#tracking-protection-icon-container {
-    padding: 0 6px !important;
-}
-
-#identity-box {
-    margin-inline-start: var(--identity-box-margin-inline);
-}
-
-#tracking-protection-icon-container {
-    padding-left: 8px !important;
-}
-
-/* = SIDEBAR STUFF ========================================================== */
+/* = PANEL STUFF =========================================================== */
 
-/* sidebar that collapses when not hovered */
 :root {
-    --thin-tab-width: 31px;
-    --wide-tab-width: 280px;
+    /*removes any excess space at start/end of toolbar*/
+    --toolbarbutton-outer-padding: 0 !important;
+    --toolbar-start-end-padding: 0 !important;
 }
 
-#sidebar-box:not([hidden]) {
-    overflow-x: hidden !important;
-    position: relative !important;
-    transition: all 40ms !important;
-    min-width: var(--thin-tab-width) !important;
-    max-width: var(--thin-tab-width) !important;
-
-    border-right: 1px solid var(--chrome-content-separator-color);
-
-    /* fix collapsed sidebar background-color */
-    background-color: var(--toolbar-bgcolor) !important;
-
-    z-index: 1;
-    opacity: 1.0 !important;
-}
-
-#sidebar-box:not([hidden]):hover,
-#sidebar-box:not([hidden]):active,
-#sidebar-box:not([hidden]):focus-within,
-#sidebar-box:not([hidden]):-moz-drag-over {
-    min-width: var(--wide-tab-width) !important;
-    max-width: var(--wide-tab-width) !important;
-    /* for right sidebar change 'margin-right' to 'margin-left' */
-    margin-right: calc((var(--wide-tab-width) - var(--thin-tab-width))*-1) !important;
-}
-
-/* make sure the contents of the sidebar are not squished */
-#sidebar {
-    min-width: var(--wide-tab-width) !important;
-    max-width: var(--wide-tab-width) !important;
-    margin-left: 0 !important;
-}
-
-/* hide sidebar header */
-#sidebar-header {
-    visibility: collapse;
+#TabsToolbar {
+    display: none !important;
 }
 
-/* hide sidebar shadow */
-#sidebar-splitter {
-    display: none !important;
+#nav-bar {
+    /*removes thin space at the top of window*/
+    border-top: none !important;
 }
diff --git a/.mozilla/firefox/hibiki.default/user.js b/.mozilla/firefox/hibiki.default/user.js
index 9fe5e9b..7ce65ac 100644
--- a/.mozilla/firefox/hibiki.default/user.js
+++ b/.mozilla/firefox/hibiki.default/user.js
@@ -1,3 +1,10 @@
+// new sidebar
+user_pref("sidebar.revamp", true);
+user_pref("sidebar.verticalTabs", true);
+user_pref("sidebar.animation.enabled", false);
+user_pref("sidebar.main.tools", "aichat,syncedtabs,history");
+user_pref("sidebar.visibility", "hide-sidebar");
+
 // required for my custom userChrome
 user_pref("extensions.webextensions.tabhide.enabled", true);
 user_pref("toolkit.legacyUserProfileCustomizations.stylesheets", true);