{vencord,vesktop}: fonts (#840)
Closes: https://github.com/danth/stylix/issues/829 Link: https://github.com/danth/stylix/pull/840 Reviewed-by: NAHO <90870942+trueNAHO@users.noreply.github.com>
This commit is contained in:
parent
ff8ce4f3d2
commit
be606eaa87
2 changed files with 32 additions and 12 deletions
|
|
@ -1,9 +1,19 @@
|
||||||
{ config, lib, ... }:
|
{ config, lib, ... }:
|
||||||
let
|
let
|
||||||
themeFile = config.lib.stylix.colors {
|
themeText =
|
||||||
template = ./template.mustache;
|
builtins.readFile (
|
||||||
extension = ".css";
|
config.lib.stylix.colors {
|
||||||
};
|
template = ./template.mustache;
|
||||||
|
extension = ".css";
|
||||||
|
}
|
||||||
|
)
|
||||||
|
+ ''
|
||||||
|
:root {
|
||||||
|
--font-primary: ${config.stylix.fonts.sansSerif.name};
|
||||||
|
--font-display: ${config.stylix.fonts.sansSerif.name};
|
||||||
|
--font-code: ${config.stylix.fonts.monospace.name};
|
||||||
|
}
|
||||||
|
'';
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
options.stylix.targets.vencord.enable =
|
options.stylix.targets.vencord.enable =
|
||||||
|
|
@ -12,6 +22,6 @@ in
|
||||||
config =
|
config =
|
||||||
lib.mkIf (config.stylix.enable && config.stylix.targets.vencord.enable)
|
lib.mkIf (config.stylix.enable && config.stylix.targets.vencord.enable)
|
||||||
{
|
{
|
||||||
xdg.configFile."Vencord/themes/stylix.theme.css".source = themeFile;
|
xdg.configFile."Vencord/themes/stylix.theme.css".text = themeText;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5,10 +5,20 @@
|
||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
let
|
let
|
||||||
themeFile = config.lib.stylix.colors {
|
themeText =
|
||||||
template = ../vencord/template.mustache;
|
builtins.readFile (
|
||||||
extension = ".css";
|
config.lib.stylix.colors {
|
||||||
};
|
template = ../vencord/template.mustache;
|
||||||
|
extension = ".css";
|
||||||
|
}
|
||||||
|
)
|
||||||
|
+ ''
|
||||||
|
:root {
|
||||||
|
--font-primary: ${config.stylix.fonts.sansSerif.name};
|
||||||
|
--font-display: ${config.stylix.fonts.sansSerif.name};
|
||||||
|
--font-code: ${config.stylix.fonts.monospace.name};
|
||||||
|
}
|
||||||
|
'';
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
options.stylix.targets.vesktop.enable =
|
options.stylix.targets.vesktop.enable =
|
||||||
|
|
@ -19,12 +29,12 @@ in
|
||||||
(
|
(
|
||||||
lib.mkMerge [
|
lib.mkMerge [
|
||||||
(lib.mkIf pkgs.stdenv.hostPlatform.isLinux {
|
(lib.mkIf pkgs.stdenv.hostPlatform.isLinux {
|
||||||
xdg.configFile."vesktop/themes/stylix.theme.css".source = themeFile;
|
xdg.configFile."vesktop/themes/stylix.theme.css".text = themeText;
|
||||||
})
|
})
|
||||||
|
|
||||||
(lib.mkIf pkgs.stdenv.hostPlatform.isDarwin {
|
(lib.mkIf pkgs.stdenv.hostPlatform.isDarwin {
|
||||||
home.file."Library/Application Support/vesktop/themes/stylix.theme.css".source =
|
home.file."Library/Application Support/vesktop/themes/stylix.theme.css".text =
|
||||||
themeFile;
|
themeText;
|
||||||
})
|
})
|
||||||
]
|
]
|
||||||
);
|
);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue