2024-08-16 05:38:11 +02:00
|
|
|
{ pkgs, firefox-addons, ... }:
|
2024-05-26 11:39:55 +02:00
|
|
|
|
2024-08-13 23:13:47 +02:00
|
|
|
let
|
|
|
|
friendlyfox = pkgs.stdenvNoCC.mkDerivation (finalAttrs: {
|
|
|
|
pname = "mobile-friendly-firefox";
|
|
|
|
version = "2.11.1";
|
|
|
|
|
|
|
|
src = pkgs.fetchFromGitea {
|
|
|
|
domain = "codeberg.org";
|
|
|
|
owner = "user0";
|
|
|
|
repo = "Mobile-Friendly-Firefox";
|
|
|
|
rev = "v${finalAttrs.version}";
|
|
|
|
hash = "sha256-rA5lnfW5zOyfJ6pbcrsTBEhMEof5h/heGaHxST+q+AY=";
|
|
|
|
};
|
|
|
|
|
|
|
|
patches = [
|
|
|
|
# Fix for Firefox 127 and later (renamed id)
|
|
|
|
(pkgs.fetchpatch2 {
|
|
|
|
url = "https://codeberg.org/user0/Mobile-Friendly-Firefox/commit/bfb7946973bf707d0494714679df47ec66017f97.patch";
|
|
|
|
hash = "sha256-wJLXgNUUaNHVgCMi8sGnC5cx2yNwZwh2JoDaVMsVehY=";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
runHook preInstall
|
|
|
|
|
|
|
|
install -Dm644 src/userContent/styles/fenix-colors/userContent.css -t $out
|
|
|
|
cat src/userChrome/fenix_one.css src/userChrome/dynamic_popups_pro.css > $out/userChrome.css
|
|
|
|
|
|
|
|
runHook postInstall
|
|
|
|
'';
|
|
|
|
});
|
|
|
|
in
|
2023-06-17 02:15:45 +02:00
|
|
|
{
|
|
|
|
programs.librewolf = {
|
|
|
|
enable = true;
|
|
|
|
|
2024-08-07 22:32:53 +02:00
|
|
|
package = pkgs.librewolf.override { cfg.speechSynthesisSupport = false; };
|
2024-05-26 11:39:55 +02:00
|
|
|
|
2024-08-13 22:24:10 +02:00
|
|
|
profiles.default = {
|
2024-08-16 05:38:11 +02:00
|
|
|
extensions = with firefox-addons.packages.${pkgs.system}; [
|
|
|
|
yomitan
|
|
|
|
];
|
|
|
|
|
2024-08-13 22:24:10 +02:00
|
|
|
search = {
|
|
|
|
force = true;
|
|
|
|
default = "Mullvad";
|
|
|
|
privateDefault = "Mullvad";
|
|
|
|
|
|
|
|
engines = {
|
|
|
|
Mullvad = {
|
2024-08-15 17:22:07 +02:00
|
|
|
urls = [ { template = "https://leta.mullvad.net/?q={searchTerms}"; } ];
|
2024-08-13 22:24:10 +02:00
|
|
|
icon = "${pkgs.mullvad-vpn}/share/icons/hicolor/32x32/apps/mullvad-vpn.png";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
2024-08-16 05:55:57 +02:00
|
|
|
|
|
|
|
settings = {
|
|
|
|
"extensions.autoDisableScopes" = 0;
|
|
|
|
};
|
2024-08-13 22:24:10 +02:00
|
|
|
};
|
|
|
|
|
2023-06-17 02:15:45 +02:00
|
|
|
settings = {
|
|
|
|
"middlemouse.paste" = false;
|
|
|
|
|
|
|
|
"browser.download.useDownloadDir" = true;
|
|
|
|
"browser.tabs.insertAfterCurrent" = true;
|
2024-03-30 17:24:47 +01:00
|
|
|
"browser.tabs.warnOnClose" = true;
|
2023-06-17 02:15:45 +02:00
|
|
|
"browser.toolbars.bookmarks.visibility" = "never";
|
2023-06-25 15:15:01 +02:00
|
|
|
"browser.quitShortcut.disabled" = true;
|
2024-05-20 16:42:42 +02:00
|
|
|
"browser.sessionstore.restore_pinned_tabs_on_demand" = true;
|
2024-05-20 17:06:12 +02:00
|
|
|
|
2024-05-20 16:41:21 +02:00
|
|
|
"browser.urlbar.suggest.bookmark" = false;
|
2024-05-20 17:06:12 +02:00
|
|
|
"browser.urlbar.suggest.engines" = false;
|
2023-07-26 18:12:03 +02:00
|
|
|
"browser.urlbar.suggest.history" = false;
|
2024-05-20 17:52:45 +02:00
|
|
|
"browser.urlbar.suggest.openpage" = false;
|
2024-05-19 20:31:36 +02:00
|
|
|
"browser.urlbar.suggest.topsites" = false;
|
2024-08-13 22:28:57 +02:00
|
|
|
"browser.urlbar.trimHttps" = true;
|
2023-06-17 02:15:45 +02:00
|
|
|
|
|
|
|
"sidebar.position_start" = false;
|
|
|
|
"findbar.highlightAll" = true;
|
2024-05-19 20:32:52 +02:00
|
|
|
|
|
|
|
"xpinstall.signatures.required" = false;
|
2024-07-21 19:27:54 +02:00
|
|
|
|
|
|
|
"toolkit.legacyUserProfileCustomizations.stylesheets" = true;
|
2023-06-17 02:15:45 +02:00
|
|
|
};
|
|
|
|
};
|
2024-08-13 23:13:47 +02:00
|
|
|
|
|
|
|
home.file = {
|
|
|
|
".librewolf/default/chrome/userChrome.css".source = "${friendlyfox}/userChrome.css";
|
|
|
|
".librewolf/default/chrome/userContent.css".source = "${friendlyfox}/userContent.css";
|
|
|
|
};
|
2023-06-17 02:15:45 +02:00
|
|
|
}
|