Skip to content

Commit

Permalink
(CSS) add styles to avoid a weird crash.
Browse files Browse the repository at this point in the history
update onboarding styles.
(prefs) add recommended pref to remove Private browsing label.
  • Loading branch information
aminomancer committed Sep 16, 2022
1 parent 87954d6 commit 93ffbcb
Show file tree
Hide file tree
Showing 7 changed files with 45 additions and 10 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ I also recommend setting the following prefs in `about:config`. There are two pr
| browser.display.background_color.dark | String | `#19191b` | Default background color for `color-scheme: dark` pages like about:blank. Great new prefs from [bug 1525107](https://phabricator.services.mozilla.com/D129746)! |
| browser.display.use_system_colors | Boolean | false | |
| <i>browser.display.windows.non_native_menus</i> | Number | 1 | |
| browser.privatebrowsing.enable-new-indicator | Boolean | false | Remove the "Private browsing" window label |
| <i>browser.startup.blankWindow</i> | Boolean | false | These two settings eliminate the blank white window during startup |
| <i>browser.startup.preXulSkeletonUI</i> | Boolean | false | |
| browser.tabs.tabMinWidth | Number | 90 | User preference, but mine is 90 |
Expand Down
18 changes: 18 additions & 0 deletions prefs/.eslintrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
module.exports = {
parserOptions: {
sourceType: "script",
ecmaVersion: "latest",
},
overrides: [
{
files: [".eslintrc.js"],
env: {
node: true,
browser: false,
},
},
],
globals: {
user_pref: "readonly",
},
};
1 change: 1 addition & 0 deletions prefs/recommended.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ user_pref("extensions.autoDisableScopes", 0);
user_pref("browser.shell.checkDefaultBrowser", false);
user_pref("browser.startup.homepage_override.mstone", "ignore");
user_pref("browser.display.use_system_colors", false);
user_pref("browser.privatebrowsing.enable-new-indicator", false);
user_pref("accessibility.mouse_focuses_formcontrol", 0);
user_pref("browser.tabs.tabMinWidth", 90);
user_pref("browser.urlbar.accessibility.tabToSearch.announceResults", false);
Expand Down
2 changes: 1 addition & 1 deletion resources/in-content/system.css
Original file line number Diff line number Diff line change
Expand Up @@ -468,7 +468,7 @@
}

.onboardingContainer.featureCallout .screen[pos="callout"] .section-main .main-content,
.onboardingContainer.featureCallout.arrow-inline-end::before {
.onboardingContainer.featureCallout.callout-arrow::before {
background-color: var(--newtab-background-color-secondary) !important;
border-color: var(--fxview-contrast-border) !important;
}
Expand Down
8 changes: 7 additions & 1 deletion uc-popups.css
Original file line number Diff line number Diff line change
Expand Up @@ -1591,7 +1591,8 @@ rtl languages. adjust the border radius accordingly */

@supports -moz-bool-pref("userChrome.css.mac-ui-fonts") {
:root[dialogroot],
:root[dialogroot] dialog {
:root[dialogroot] dialog,
:root[dialogroot] body {
font-family: SF Pro Text, SF Arabic, Segoe UI, sans-serif !important;
font-kerning: normal !important;
}
Expand All @@ -1600,6 +1601,11 @@ rtl languages. adjust the border radius accordingly */
font-weight: var(--uc-font-weight-semibold, 400) !important;
font-family: SF Pro Display, SF Arabic, Segoe UI, sans-serif !important;
}

:root[dialogroot] .onboardingContainer h1 {
font-weight: var(--uc-font-weight-bold, 600) !important;
font-family: SF Pro Display, SF Arabic, Segoe UI, sans-serif !important;
}
}
}

Expand Down
8 changes: 0 additions & 8 deletions uc-tabs-bar.css
Original file line number Diff line number Diff line change
Expand Up @@ -363,19 +363,11 @@ overflowing tabs don't draw shadows on the special new tab button */
background: none !important;
}

:root[privatebrowsingmode="temporary"] .private-browsing-indicator {
display: revert !important;
}

#private-browsing-indicator-with-label {
-moz-context-properties: fill, fill-opacity !important;
fill: currentColor !important;
}

.private-browsing-indicator + #private-browsing-indicator-with-label {
display: none !important;
}

.private-browsing-indicator::before {
content: "";
display: -moz-box;
Expand Down
17 changes: 17 additions & 0 deletions userChrome.ag.css
Original file line number Diff line number Diff line change
Expand Up @@ -212,6 +212,23 @@ scrollbar[disabled="true"] {
margin: 0 !important;
}

:is(scrollcorner, resizer, scrollbar, scrollbarbutton, slider):where(:-moz-native-anonymous) {
/* cribbed from minimal-xul.css to avoid crashes */
-moz-box-layout: initial;
direction: ltr;
font: 16px sans-serif;
justify-items: start;
vertical-align: initial !important;
-moz-user-focus: ignore;
user-select: none;
display: -moz-box;
box-sizing: border-box;
}

:is(scrollbarbutton, slider, thumb):where(:-moz-native-anonymous) {
cursor: inherit;
}

/* overlay scrollbars in content, if the pref is enabled. I don't recommend
using this pref because overlay scrollbars can cause problems on certain
websites where multiple scrollable divs are nested inside each other or
Expand Down

0 comments on commit 93ffbcb

Please sign in to comment.