This commit is contained in:
Hadi 2024-03-12 14:20:08 +01:00
parent 55a602b481
commit 640ee6325b
9 changed files with 222 additions and 149 deletions

View File

@ -33,7 +33,7 @@
exec-once = [ exec-once = [
"swww init" "swww init"
"swww img /home/hadi/Nextcloud/wallpaper/Dim_12000x6000.png" "swww img /home/hadi/.config/wallpaper/default.png"
"hypridle" "hypridle"
]; ];
@ -106,7 +106,7 @@
gaps_out = 20; gaps_out = 20;
border_size = 2; border_size = 2;
"col.active_border" = "rgba(${config.theme.colors.primary-bg}ff)"; "col.active_border" = "rgba(${config.theme.colors.primary-bg}ff)";
"col.inactive_border" = "rgba(${config.theme.colors.color0}ee)"; "col.inactive_border" = "rgba(${config.theme.colors.color0}96)";
layout = "master"; layout = "master";
}; };

View File

@ -1,50 +1,78 @@
{ pkgs, ... }: { { pkgs, config, ... }: {
imports = [ ../variables/theme ];
home.packages = with pkgs; [ hyprlock ]; home.packages = with pkgs; [ hyprlock ];
xdg.configFile."hypr/hyprlock.conf".text = '' xdg.configFile."hypr/hyprlock.conf".text = ''
background { background {
monitor = monitor =
path = $HOME/Nextcloud/wallpaper/Dim_12000x6000.png path = $HOME/.config/wallpaper/default.png # only png supported for now
color = rgba(25, 20, 20, 1.0) color = rgb(${config.theme.colors.bg})
# all these options are taken from hyprland, see https://wiki.hyprland.org/Configuring/Variables/#blur for explanations # all these options are taken from hyprland, see https://wiki.hyprland.org/Configuring/Variables/#blur for explanations
blur_passes = 4 # 0 disables blurring blur_size = 4
blur_size = 2 blur_passes = 3 # 0 disables blurring
noise = 0.0117 noise = 0.0117
contrast = 0.8916 contrast = 1.3000 # Vibrant!!!
brightness = 0.8172 brightness = 0.8000
vibrancy = 0.1696 vibrancy = 0.2100
vibrancy_darkness = 0.0 vibrancy_darkness = 0.0
} }
input-field { input-field {
monitor = monitor =
size = 200, 50 size = 250, 50
outline_thickness = 1 outline_thickness = 3
dots_size = 0.2 # Scale of input-field height, 0.2 - 0.8 dots_size = 0.2 # Scale of input-field height, 0.2 - 0.8
dots_spacing = 0.15 # Scale of dots' absolute size, 0.0 - 1.0 dots_spacing = 0.64 # Scale of dots' absolute size, 0.0 - 1.0
dots_center = true dots_center = true
outer_color = rgb(000000) outer_color = rgb(${config.theme.colors.primary-bg})
inner_color = rgb(200, 200, 200) inner_color = rgb(${config.theme.colors.bg})
font_color = rgb(10, 10, 10) font_color = rgb(${config.theme.colors.fg})
fade_on_empty = true fade_on_empty = true
placeholder_text = <i>Input Password...</i> # Text rendered in the input box when it's empty. placeholder_text = <i>Password...</i> # Text rendered in the input box when it's empty.
hide_input = false hide_input = false
position = 0, -20 position = 0, 50
halign = center
valign = bottom
}
# Current time
label {
monitor =
text = cmd[update:1000] echo "<b><big> $(date +"%H:%M:%S") </big></b>"
color = rgb(${config.theme.colors.fg})
font_size = 64
font_family = ${config.theme.font}
position = 0, 16
halign = center halign = center
valign = center valign = center
} }
# User label
label { label {
monitor = monitor =
text = Enter your password to unlock text = Hey <span text_transform="capitalize" size="larger">$USER</span>
color = rgba(200, 200, 200, 1.0) color = rgb(${config.theme.colors.fg})
font_size = 25 font_size = 20
font_family = Noto Sans font_family = ${config.theme.font}
position = 0, 0
position = 0, 200
halign = center halign = center
valign = center valign = center
} }
# Type to unlock
label {
monitor =
text = Type to unlock!
color = rgb(${config.theme.colors.fg})
font_size = 16
font_family = ${config.theme.font}
position = 0, 30
halign = center
valign = bottom
}
''; '';
} }

View File

@ -1,82 +1,94 @@
{ { config, ... }: {
imports = [ ./duckduckgo-colorscheme.nix ];
programs.qutebrowser = { programs.qutebrowser = {
enable = true; enable = true;
searchEngines = { searchEngines = {
"DEFAULT" = "https://google.com/search?q={}"; "DEFAULT" = "https://duckduckgo.com/?q={}&ia=web";
"yt" = "https://youtube.com/results?search_query={}"; "d" = "https://duckduckgo.com/?q={}&ia=web";
"g" = "https://google.com/search?q={}";
"y" = "https://youtube.com/results?search_query={}";
"n" = "https://mynixos.com/search?q={}";
"nixo" = "https://search.nixos.org/options?channel=unstable&query={}"; "nixo" = "https://search.nixos.org/options?channel=unstable&query={}";
"nixp" = "https://search.nixos.org/packages?channel=unstable&query={}"; "nixp" = "https://search.nixos.org/packages?channel=unstable&query={}";
}; };
settings = { settings = {
url = {
default_page = "https://duckduckgo.com";
start_pages = [ "https://duckduckgo.com" ];
};
colors = { colors = {
tabs = { tabs = {
odd.bg = "#000000"; odd.bg = "#${config.theme.colors.bg}";
odd.fg = "#FFFFFF"; odd.fg = "#${config.theme.colors.fg}";
even.bg = "#000000"; even.bg = "#${config.theme.colors.bg}";
even.fg = "#FFFFFF"; even.fg = "#${config.theme.colors.fg}";
selected.odd.bg = "#101012"; selected.odd.bg = "#${config.theme.colors.primary-bg}";
selected.odd.fg = "#FFFFFF"; selected.odd.fg = "#${config.theme.colors.primary-fg}";
selected.even.bg = "#101012"; selected.even.bg = "#${config.theme.colors.primary-bg}";
selected.even.fg = "#FFFFFF"; selected.even.fg = "#${config.theme.colors.primary-fg}";
indicator.error = "#101012"; indicator.error = "#${config.theme.colors.color1}";
indicator.start = "#101012"; indicator.start = "#${config.theme.colors.alt-bg}";
indicator.stop = "#101012"; indicator.stop = "#${config.theme.colors.alt-bg}";
}; };
hints = { hints = {
bg = "#101012"; bg = "#${config.theme.colors.alt-bg}";
fg = "#FFFFFF"; fg = "#${config.theme.colors.alt-fg}";
match.fg = "#E2E2E2"; match.fg = "#${config.theme.colors.bg}";
}; };
completion = { completion = {
category.bg = "#101012"; category.bg = "#${config.theme.colors.bg}";
category.fg = "#FFFFFF"; category.fg = "#${config.theme.colors.fg}";
category.border.top = "#101012"; category.border.top = "#${config.theme.colors.bg}";
category.border.bottom = "#101012"; category.border.bottom = "#${config.theme.colors.bg}";
odd.bg = "#101012"; odd.bg = "#${config.theme.colors.bg}";
even.bg = "#101012"; even.bg = "#${config.theme.colors.bg}";
fg = [ "#FFFFFF" "#FFFFFF" "#FFFFFF" ]; fg = [ "#FFFFFF" "#FFFFFF" "#FFFFFF" ];
match.fg = "#FF0000"; match.fg = "#${config.theme.colors.primary-bg}";
item.selected.bg = "#FF0000"; item.selected.bg = "#${config.theme.colors.primary-bg}";
item.selected.border.top = "#FF0000"; item.selected.border.top = "#${config.theme.colors.primary-bg}";
item.selected.border.bottom = "#FF0000"; item.selected.border.bottom = "#${config.theme.colors.primary-bg}";
item.selected.fg = "#FBFBFB"; item.selected.fg = "#${config.theme.colors.primary-fg}";
item.selected.match.fg = "#FBFBFB"; item.selected.match.fg = "#${config.theme.colors.primary-fg}";
}; };
# statusbar = { statusbar = {
# normal.bg = colors.statusbar.bg; normal.bg = "#${config.theme.colors.bg}";
# normal.fg = colors.statusbar.fg; normal.fg = "#${config.theme.colors.fg}";
# private.bg = colors.statusbar.private.bg; private.bg = "#${config.theme.colors.bg}";
# private.fg = colors.statusbar.private.fg; private.fg = "#${config.theme.colors.fg}";
# command = { command = {
# bg = colors.statusbar.bg; bg = "#${config.theme.colors.alt-bg}";
# fg = colors.statusbar.fg; fg = "#${config.theme.colors.alt-fg}";
# private.bg = colors.statusbar.private.bg; private.bg = "#${config.theme.colors.alt-bg}";
# private.fg = colors.statusbar.private.fg; private.fg = "#${config.theme.colors.alt-fg}";
# }; };
# }; };
#
# messages = { messages = {
# info = { info = {
# bg = colors.statusbar.bg; bg = "#${config.theme.colors.alt-bg}";
# fg = colors.statusbar.fg; fg = "#${config.theme.colors.alt-fg}";
# border = colors.statusbar.bg; border = "#${config.theme.colors.alt-bg}";
# }; };
#
# error = { error = {
# bg = colors.messages.error.bg; bg = "#${config.theme.colors.color1}";
# fg = colors.messages.error.fg; fg = "#${config.theme.colors.alt-fg}";
# border = colors.messages.error.bg; border = "#${config.theme.colors.color1}";
# }; };
# }; };
}; };
completion = { completion = {
@ -147,12 +159,7 @@
close_mouse_button = "right"; close_mouse_button = "right";
}; };
url = { zoom.default = "100%";
default_page = "https://duckduckgo.com";
start_pages = [ "https://duckduckgo.com" ];
};
zoom.default = "130%";
}; };
keyMappings = { keyMappings = {

View File

@ -0,0 +1,37 @@
{ config, ... }: {
imports = [ ../variables/theme ];
xdg.configFile."duckduckgo-colorscheme.js".text = ''
// Cookies string for your theme
const cookie = '7=${config.theme.colors.bg}; j=${config.theme.colors.bg}; 9=${config.theme.colors.fg}; aa=${config.theme.colors.alt-fg}; 8=${config.theme.colors.color7}; x=${config.theme.colors.primary-bg}; 21=${config.theme.colors.alt-bg};';
// Converts cookie string into formatted JSON
const cookieToJSON = (cookieRaw) => {
const cookieJson = {};
const items = cookieRaw.split(/[ ,]+/);
items.forEach((item) => {
const parts = item.split('=');
cookieJson[parts[0]] = parts[1];
});
return cookieJson;
};
// Iterates over JSON, and adds to browser cookie store
const setCookies = (cookieJson) => {
Object.keys(cookieJson).forEach((key) => {
document.cookie = `''${key}=''${cookieJson [ key ]}`;
});
};
alert('The GitHub Dark theme will be applied.');
// Call set cookies, passing in formated cookie data
setCookies(cookieToJSON(cookie));
// All done, reload page for changes to take effect :)
location.reload();
'';
}

View File

@ -18,7 +18,7 @@
primary-fg = "000000"; primary-fg = "000000";
secondary-bg = "4928B8"; secondary-bg = "4928B8";
secondary-fg = "000000"; secondary-fg = "000000";
color0 = "414868"; color0 = "000000";
color1 = "f7768e"; color1 = "f7768e";
color2 = "73daca"; color2 = "73daca";
color3 = "e0af68"; color3 = "e0af68";

View File

@ -120,6 +120,7 @@
min-height: 0; min-height: 0;
font-family: "${config.theme.font}"; font-family: "${config.theme.font}";
color: #${config.theme.colors.fg}; color: #${config.theme.colors.fg};
font-weight: 700;
} }
window#waybar { window#waybar {

View File

@ -1,4 +1,7 @@
{ { config, ... }: {
imports = [ ../variables/theme ];
programs.wlogout = { programs.wlogout = {
enable = true; enable = true;
layout = [ layout = [
@ -41,78 +44,72 @@
]; ];
style = '' style = ''
* { * {
font-family: "Fira Sans Semibold"; font-family: "${config.theme.font}";
background-image: none; background-image: none;
transition: 20ms; transition: 20ms;
} }
window { window {
background-color: rgba(12, 12, 12, 0.5); background-color: rgba(12,12,12,0.5);
} }
button { button {
color: #FFFFFF; color: #${config.theme.colors.fg};
font-size:20px; font-size:20px;
background-repeat: no-repeat; background-repeat: no-repeat;
background-position: center; background-position: center;
background-size: 25%; background-size: 25%;
border-style: solid; border-style: solid;
background-color: rgba(12, 12, 12, 0.5); background-color: #${config.theme.colors.bg};
border: 3px solid #FFFFFF; border: ${
box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19); toString config.theme.border-size
} }px solid #${config.theme.colors.fg};
box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
}
button:focus, button:focus,
button:active, button:active {
button:hover { color: #${config.theme.colors.primary-fg};
color: #9978F8; background-color: #${config.theme.colors.primary-bg};
background-color: rgba(12, 12, 12, 0.8); border: 3px solid #${config.theme.colors.primary-bg};
border: 3px solid #9978F8; }
/*
-----------------------------------------------------
Buttons
-----------------------------------------------------
*/
#lock,#logout,#suspend,#hibernate,#shutdown,#reboot {
margin: 10px;
border-radius: ${toString config.theme.rounding}px;
} }
/*
-----------------------------------------------------
Buttons
-----------------------------------------------------
*/
#lock { #lock {
margin: 10px; background-image: image(url("icons/lock.png"));
border-radius: 20px;
background-image: image(url("icons/lock.png"));
} }
#logout { #logout {
margin: 10px; background-image: image(url("icons/logout.png"));
border-radius: 20px;
background-image: image(url("icons/logout.png"));
} }
#suspend { #suspend {
margin: 10px; background-image: image(url("icons/suspend.png"));
border-radius: 20px;
background-image: image(url("icons/suspend.png"));
} }
#hibernate { #hibernate {
margin: 10px; background-image: image(url("icons/hibernate.png"));
border-radius: 20px;
background-image: image(url("icons/hibernate.png"));
} }
#shutdown { #shutdown {
margin: 10px; background-image: image(url("icons/shutdown.png"));
border-radius: 20px;
background-image: image(url("icons/shutdown.png"));
} }
#reboot { #reboot {
margin: 10px; background-image: image(url("icons/reboot.png"));
border-radius: 20px;
background-image: image(url("icons/reboot.png"));
} }
''; '';
}; };

View File

@ -1,10 +1,13 @@
{ { config, ... }: {
imports = [ ../variables/theme ];
programs.wofi = { programs.wofi = {
enable = true; enable = true;
settings = { settings = {
allow_markup = true; allow_markup = true;
width = 250; width = 450;
show = "drun"; show = "drun";
prompt = "Apps"; prompt = "Apps";
normal_window = true; normal_window = true;
@ -34,15 +37,15 @@
/** ********** Fonts ********** **/ /** ********** Fonts ********** **/
* { * {
font-family: "SFProDisplay Nerd Font Bold", archcraft, sans-serif; font-family: "${config.theme.font}";
font-weight: 500;
font-size: 12px; font-size: 12px;
} }
#window { #window {
background-color: #0B0B13; background-color: #${config.theme.colors.alt-bg};
color: #D9E0EE; color: #${config.theme.colors.alt-fg};
border: 2px solid #1B1B23; border-radius: ${toString config.theme.rounding}px;
border-radius: 0px;
} }
#outer-box { #outer-box {
@ -50,8 +53,8 @@
} }
#input { #input {
background-color: #1B1B23; background-color: #${config.theme.colors.bg};
border: 0px solid #B4BEFE; border: 0px solid #${config.theme.colors.primary-bg};
padding: 8px 12px; padding: 8px 12px;
} }
@ -66,11 +69,11 @@
} }
#text { #text {
color: #D9E0EE; color: #${config.theme.colors.color7};
} }
#text:selected { #text:selected {
color: #0B0B13; color: #${config.theme.colors.fg};
} }
#entry { #entry {
@ -78,8 +81,8 @@
} }
#entry:selected { #entry:selected {
background-color: #B4BEFE; background-color: #${config.theme.colors.primary-bg};
color: #0B0B13; color: #${config.theme.colors.primary-fg};
} }
#unselected {} #unselected {}
@ -88,7 +91,7 @@
#input, #input,
#entry:selected { #entry:selected {
border-radius: 4px; border-radius: ${toString (config.theme.rounding - 10)}px;
} }
''; '';
}; };