Remove all mustache config files

Nyxt now gets accentColour and font settings correctly
This commit is contained in:
Evie Litherland-Smith 2024-02-29 16:40:42 +00:00
parent d9eee524a9
commit 7c112e604f
2 changed files with 49 additions and 49 deletions

View file

@ -1,43 +0,0 @@
(define-configuration browser
((theme
(make-instance
'theme:theme
:dark-p t
:font-family "Iosevka Nerd Font"
:monospace-font-family "Iosevka Nerd Font"
:text-color "#{{base05-hex}}"
:text-color+ "#{{base05-hex}}"
:text-color- "#{{base05-hex}}"
:contrast-text-color "#{{base00-hex}}"
:background-color "#{{base00-hex}}"
:background-color+ "#{{base00-hex}}"
:background-color- "#{{base00-hex}}"
:on-background-color "#{{base05-hex}}"
:accent-color "#{{base0E-hex}}"
:accent-color+ "#{{base0E-hex}}"
:accent-color- "#{{base0E-hex}}"
:on-accent-color "#{{base00-hex}}"
:primary-color "#{{base0E-hex}}"
:primary-color+ "#{{base0E-hex}}"
:primary-color- "#{{base0E-hex}}"
:on-primary-color "#{{base00-hex}}"
:secondary-color "#{{base03-hex}}"
:secondary-color+ "#{{base03-hex}}"
:secondary-color- "#{{base03-hex}}"
:on-secondary-color "#{{base05-hex}}"
:warning-color "#{{base08-hex}}"
:warning-color+ "#{{base08-hex}}"
:warning-color- "#{{base08-hex}}"
:on-warning-color "#{{base00-hex}}"
:highlight-color "#{{base0A-hex}}"
:highlight-color+ "#{{base0A-hex}}"
:highlight-color- "#{{base0A-hex}}"
:on-highlight-color "#{{base00-hex}}"
:action-color "#{{base0D-hex}}"
:action-color+ "#{{base0D-hex}}"
:action-color- "#{{base0D-hex}}"
:on-action-color "#{{base00-hex}}"
:codeblock-color "#{{base01-hex}}"
:codeblock-color+ "#{{base01-hex}}"
:codeblock-color- "#{{base01-hex}}"
:on-codeblock-color "#{{base05-hex}}"))))

View file

@ -1,19 +1,62 @@
{ {
config, config,
pkgs, pkgs,
accentColour ? "base07",
... ...
}: { }: {
home.packages = [pkgs.nyxt]; home.packages = [pkgs.nyxt];
xdg = { xdg = {
configFile = { configFile = {
"nyxt/config.lisp".text = '' "nyxt/config.lisp".text = with config.stylix;
;; Import stylix theme with config.lib.stylix.colors.withHashtag; let
(nyxt::load-lisp "${config.lib.stylix.colors { accent = config.lib.stylix.colors.withHashtag.${accentColour};
template = ./default.mustache; in ''
extension = ".lisp";
}}")
;; Import custom configuration ;; Import custom configuration
(nyxt::load-lisp "${./config.lisp}") (nyxt::load-lisp "${./config.lisp}")
;; Custom theme using stylix
(define-configuration
browser
((theme (make-instance
'theme:theme
:dark-p t
:font-family "${fonts.sansSerif.name}"
:monospace-font-family "${fonts.monospace.name}"
:text-color "${base05}"
:text-color+ "${base05}"
:text-color- "${base05}"
:contrast-text-color "${base00}"
:background-color "${base00}"
:background-color+ "${base00}"
:background-color- "${base00}"
:on-background-color "${base05}"
:accent-color "${accent}"
:accent-color+ "${accent}"
:accent-color- "${accent}"
:on-accent-color "${base00}"
:primary-color "${accent}"
:primary-color+ "${accent}"
:primary-color- "${accent}"
:on-primary-color "${base00}"
:secondary-color "${base03}"
:secondary-color+ "${base03}"
:secondary-color- "${base03}"
:on-secondary-color "${base05}"
:warning-color "${base08}"
:warning-color+ "${base08}"
:warning-color- "${base08}"
:on-warning-color "${base00}"
:highlight-color "${base0A}"
:highlight-color+ "${base0A}"
:highlight-color- "${base0A}"
:on-highlight-color "${base00}"
:action-color "${base0D}"
:action-color+ "${base0D}"
:action-color- "${base0D}"
:on-action-color "${base00}"
:codeblock-color "${base01}"
:codeblock-color+ "${base01}"
:codeblock-color- "${base01}"
:on-codeblock-color "${base05}"))))
''; '';
}; };
dataFile."nyxt/bookmarks.lisp".source = ./bookmarks.lisp; dataFile."nyxt/bookmarks.lisp".source = ./bookmarks.lisp;