Files
quincy/modules/home/notifications.nix
Brandon Lucas 58e4232f2f Initial commit: Nomarchy NixOS configuration
An opinionated NixOS configuration with Hyprland, featuring:

- Modular flake-based architecture
- Parameterized user configuration (username, timezone, locale, etc.)
- Classical/antiquity theme with Thomas Cole wallpapers
- Full Hyprland setup with waybar, rofi, swaync
- Custom utility scripts (screenshots, screen recording, WiFi QR)
- Neovim with LSP support
- Interactive installer for existing NixOS systems
- ISO builder for fresh installations

Flake outputs:
- nixosConfigurations.example - Test configuration
- nixosConfigurations.installer - ISO installer
- packages.iso - Bootable ISO image
- apps.default - Interactive installer
- lib.mkHost - Host builder function
- templates.default - Starter template

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-15 02:44:33 -05:00

229 lines
4.8 KiB
Nix

# SwayNotificationCenter configuration
{
config,
lib,
pkgs,
...
}: {
services.swaync = {
enable = true;
settings = {
positionX = "right";
positionY = "top";
layer = "overlay";
control-center-layer = "top";
layer-shell = true;
cssPriority = "application";
control-center-margin-top = 10;
control-center-margin-bottom = 10;
control-center-margin-right = 10;
control-center-margin-left = 10;
notification-icon-size = 64;
notification-body-image-height = 100;
notification-body-image-width = 200;
timeout = 10;
timeout-low = 5;
timeout-critical = 0;
fit-to-screen = true;
control-center-width = 400;
control-center-height = 600;
notification-window-width = 400;
keyboard-shortcuts = true;
image-visibility = "when-available";
transition-time = 200;
hide-on-clear = false;
hide-on-action = true;
script-fail-notify = true;
widgets = [
"inhibitors"
"title"
"dnd"
"notifications"
"mpris"
];
widget-config = {
inhibitors = {
text = "Inhibitors";
button-text = "Clear All";
clear-all-button = true;
};
title = {
text = "Notifications";
clear-all-button = true;
button-text = "Clear All";
};
dnd = {
text = "Do Not Disturb";
};
mpris = {
image-size = 96;
image-radius = 12;
};
};
};
style = ''
* {
font-family: "JetBrainsMono Nerd Font Mono";
font-size: 13px;
}
.notification-row {
outline: none;
}
.notification-row:focus,
.notification-row:hover {
background: rgba(139, 90, 43, 0.15);
}
.notification {
border-radius: 12px;
margin: 6px;
box-shadow: 0 0 0 1px rgba(139, 90, 43, 0.4);
padding: 0;
background: rgba(26, 22, 17, 0.95);
}
.notification-content {
background: transparent;
padding: 10px;
border-radius: 12px;
}
.close-button {
background: rgba(166, 61, 64, 0.6);
color: #d4c4a8;
text-shadow: none;
padding: 0;
border-radius: 100%;
margin-top: 10px;
margin-right: 10px;
box-shadow: none;
border: none;
min-width: 24px;
min-height: 24px;
}
.close-button:hover {
box-shadow: none;
background: rgba(166, 61, 64, 0.9);
}
.notification-default-action,
.notification-action {
padding: 4px;
margin: 0;
box-shadow: none;
background: transparent;
border: none;
color: #d4c4a8;
}
.notification-default-action:hover,
.notification-action:hover {
background: rgba(139, 90, 43, 0.2);
}
.summary {
font-size: 14px;
font-weight: bold;
color: #d4a857;
}
.body {
font-size: 13px;
color: #d4c4a8;
}
.control-center {
background: rgba(26, 22, 17, 0.95);
border: 2px solid rgba(139, 90, 43, 0.6);
border-radius: 12px;
}
.control-center-list {
background: transparent;
}
.control-center-list-placeholder {
opacity: 0.5;
}
.floating-notifications {
background: transparent;
}
.blank-window {
background: alpha(black, 0.1);
}
.widget-title {
margin: 8px;
font-size: 1.2em;
color: #d4a857;
}
.widget-title > button {
font-size: 0.9em;
color: #d4c4a8;
background: rgba(139, 90, 43, 0.3);
border: none;
border-radius: 8px;
padding: 4px 12px;
}
.widget-title > button:hover {
background: rgba(139, 90, 43, 0.5);
}
.widget-dnd {
margin: 8px;
padding: 4px;
background: transparent;
}
.widget-dnd > switch {
background: rgba(92, 83, 70, 0.6);
border-radius: 12px;
}
.widget-dnd > switch:checked {
background: rgba(212, 168, 87, 0.6);
}
.widget-dnd > switch slider {
background: #d4c4a8;
border-radius: 12px;
}
.widget-mpris {
background: rgba(45, 38, 32, 0.85);
border-radius: 12px;
margin: 8px;
padding: 8px;
}
.widget-mpris-player {
padding: 8px;
}
.widget-mpris-title {
font-weight: bold;
font-size: 1.1em;
color: #d4a857;
}
.widget-mpris-subtitle {
font-size: 0.9em;
color: #8b7355;
}
.widget-inhibitors {
margin: 8px;
padding: 4px;
background: transparent;
}
'';
};
}