theme works but not as default but urgh

This commit is contained in:
twoneis 2025-03-01 21:11:37 +01:00
parent da1bd71d73
commit f0af00e1c2
4 changed files with 21 additions and 8 deletions

View file

@ -2,13 +2,21 @@
runCommand, runCommand,
akkoma-frontends, akkoma-frontends,
xorg, xorg,
jq,
}: }:
runCommand "akkoma-fe" { runCommand "akkoma_fe" {
nativeBuildInputs = [xorg.lndir]; nativeBuildInputs = [xorg.lndir jq];
} '' } ''
mkdir $out mkdir $out
lndir ${akkoma-frontends.akkoma-fe} $out lndir ${akkoma-frontends.akkoma-fe} $out
rm $out/static/styles.json rm $out/static/styles.json
cp ${./styles.json} $out/static/styles.json cp ${./styles.json} $out/static/styles.json
rm $out/static/config.json
jq -s add ${akkoma-frontends.akkoma-fe}/static/config.json ${./config.json} > $out/static/config.json
cp ${../../icons/favicon/favicon.png} $out/static/logo.png
cp ${./rosepine.json} $out/static/themes/rosepine.json
'' ''

4
modules/fedi/config.json Normal file
View file

@ -0,0 +1,4 @@
{
"theme": "rosepine",
"logo": "/static/logo.png"
}

View file

@ -14,13 +14,12 @@
blobhaj = pkgs.callPackage ./blobhaj.nix {}; blobhaj = pkgs.callPackage ./blobhaj.nix {};
blobhajFlags = pkgs.callPackage ./blobhajFlags.nix {}; blobhajFlags = pkgs.callPackage ./blobhajFlags.nix {};
favicon = pkgs.callPackage ./favicon.nix {}; favicon = pkgs.callPackage ./favicon.nix {};
rosepine = pkgs.writeText "rosepine.json" ./rosepine.json;
in in
mkIf conf.fedi.enable { mkIf conf.fedi.enable {
services.akkoma = { services.akkoma = {
enable = true; enable = true;
frontends.primary = { frontends.primary = {
name = "akkoma-fe"; name = "akkoma_fe";
ref = "stable"; ref = "stable";
package = akkoma-fe; package = akkoma-fe;
}; };
@ -35,7 +34,8 @@ in
":frontend_configurations" = { ":frontend_configurations" = {
"akkoma_fe" = { "akkoma_fe" = {
loog = "/static/favicon.png"; theme = "rosepine";
logo = "/static/logo.png";
}; };
}; };
@ -132,7 +132,7 @@ in
"emoji/blobhajFlags" = blobhajFlags; "emoji/blobhajFlags" = blobhajFlags;
"static/favicon.png" = favicon; "static/favicon.png" = favicon;
"static/themes/rosepine" = rosepine; "static/logo.png" = favicon;
"favicon.png" = favicon; "favicon.png" = favicon;
}; };
nginx = { nginx = {

View file

@ -1,6 +1,7 @@
{ {
"_pleroma_theme_version": 2, "_pleroma_theme_version": 2,
"theme": { "name": "rosepine",
"source": {
"themeEngineVersion": 3, "themeEngineVersion": 3,
"shadows": { "shadows": {
"panel": [ "panel": [
@ -563,4 +564,4 @@
"attachment": "8" "attachment": "8"
} }
} }
} }