Compare commits

..
Author SHA1 Message Date
johannes 5e98cd90d1 feat: add zotero 2026-09-17 19:56:15 +02:00
johannes 8be610fbdd feat: complete quickshell redesign 2026-09-17 19:56:15 +02:00
johannes 5245f4aaf2 feat: add ponytail skills 2026-09-17 19:56:15 +02:00
johannes 7a728b0386 chore: remove dead config code 2026-09-17 19:56:15 +02:00
johannes f1b9a427b7 feat: add npm global bin 2026-09-17 19:56:15 +02:00
johannes b08b0816f4 fix: quickshell bar spacing 2026-09-17 19:56:15 +02:00
johannes 3edf76b4c7 feat: add mago php toolchain 2026-09-17 19:56:15 +02:00
johannes 1cd41873e4 fix: keymap issue with aerospace 2026-09-17 19:56:15 +02:00
johannes 7c87f32901 feat: add tldr 2026-09-17 19:56:15 +02:00
johannes 23625ead4d feat: add new skills 2026-09-17 19:56:15 +02:00
johannes d85ed26311 feat: update bar 2026-09-17 19:56:15 +02:00
johannes aacd799004 feat: wip sddm theme 2026-09-17 19:56:15 +02:00
johannes 02cacf165a feat: add quickshell lock screen 2026-09-17 19:56:15 +02:00
johannesandClaude Sonnet 5 e6f6b5f09c feat: colorful multi-accent quickshell design system
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01A8TNMgnEa7Kia5Wcz2kyDx
2026-09-17 19:56:15 +02:00
johannes 2e8389d75c feat: add cpu + temp + ram to bar 2026-09-17 19:56:15 +02:00
johannesandClaude Sonnet 5 ace2860e7a feat: wallpaper-driven theming + native wallpaper picker
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_013ZYoSQwwYWhJHLX6VBCGnF
2026-09-17 19:56:15 +02:00
johannes 0537615b96 feat: add store links for claude skills 2026-09-17 19:56:15 +02:00
johannes afa7d5db96 feat: make right bar side dependant on devices 2026-09-17 19:56:15 +02:00
johannes 91c28f5b37 fix: no apps in app launcher 2026-09-17 19:56:15 +02:00
johannes d701049c3f feat: add btop cuda support 2026-09-17 19:56:15 +02:00
johannes 7283104551 feat: add easyeffects for linux 2026-09-17 19:56:15 +02:00
johannes 9ca3b15764 feat: add power menu & clipboard 2026-09-17 19:56:15 +02:00
johannes 6d583b4616 feat: cleanup 2026-09-17 19:56:15 +02:00
johannes 99abeabe75 feat: update osd for volume 2026-09-17 19:56:15 +02:00
johannes ab09d46e66 feat: redesign quickshell menus 2026-09-17 19:56:15 +02:00
johannes f15d5bb6ac chore: bump versions 2026-09-17 19:35:19 +02:00
johannes be976926f8 feat: add devenv 2026-09-17 17:14:09 +02:00
33 changed files with 1596 additions and 487 deletions

No files matched your search

+14 -1
View File
@@ -1,3 +1,16 @@
result result
hyprland-gui.lua mutable_config/zed/prompts/*
.DS_Store
# Devenv
.devenv*
devenv.local.nix
devenv.local.yaml
# direnv
.direnv
# pre-commit
.pre-commit-config.yaml
+1 -1
View File
@@ -103,7 +103,7 @@ source $"($nu.cache-dir)/starship.nu"
source $"($nu.cache-dir)/carapace.nu" source $"($nu.cache-dir)/carapace.nu"
source $"($nu.cache-dir)/zoxide.nu" source $"($nu.cache-dir)/zoxide.nu"
source $"($nu.cache-dir)/atuin.nu" source $"($nu.cache-dir)/atuin.nu"
source $"($nu.cache-dir)/mise.nu" source $"($nu.cache-dir)/devenv.nu"
#-------- #--------
# Scripts # Scripts
+1 -6
View File
@@ -32,12 +32,7 @@ if (which zoxide | is-not-empty) { zoxide init nushell | save -f $"($nu.cache-di
if (which atuin | is-not-empty) { atuin init nu | save -f $"($nu.cache-dir)/atuin.nu" } else { "" | save -f $"($nu.cache-dir)/atuin.nu" } if (which atuin | is-not-empty) { atuin init nu | save -f $"($nu.cache-dir)/atuin.nu" } else { "" | save -f $"($nu.cache-dir)/atuin.nu" }
$env.CARAPACE_BRIDGES = 'zsh,fish,bash,inshellisense' $env.CARAPACE_BRIDGES = 'zsh,fish,bash,inshellisense'
if (which carapace | is-not-empty) { ^carapace _carapace nushell | str replace '$env.config = $current' '$env.config = ($env.config? | default {} | merge $current)' | save -f $"($nu.cache-dir)/carapace.nu" } else { "" | save -f $"($nu.cache-dir)/carapace.nu" } if (which carapace | is-not-empty) { ^carapace _carapace nushell | str replace '$env.config = $current' '$env.config = ($env.config? | default {} | merge $current)' | save -f $"($nu.cache-dir)/carapace.nu" } else { "" | save -f $"($nu.cache-dir)/carapace.nu" }
if (which devenv | is-not-empty) { devenv hook nu | save -f $"($nu.cache-dir)/devenv.nu" } else { "" | save -f $"($nu.cache-dir)/devenv.nu" }
if (which mise | is-not-empty) {
mise activate nu | save -f $"($nu.cache-dir)/mise.nu"
} else {
"" | save -f $"($nu.cache-dir)/mise.nu"
}
# Deduplicate PATH at the end # Deduplicate PATH at the end
$env.PATH = ($env.PATH | uniq) $env.PATH = ($env.PATH | uniq)
+42 -17
View File
@@ -13,6 +13,13 @@ def hex-byte [] {
$"0x($in)" | into int $"0x($in)" | into int
} }
def to-hex-byte [n: int] {
let digits = "0123456789abcdef"
let hi = ($n // 16)
let lo = ($n mod 16)
$"($digits | str substring $hi..$hi)($digits | str substring $lo..$lo)"
}
def rgb-to-hsl [rgb: record<r: int, g: int, b: int>] { def rgb-to-hsl [rgb: record<r: int, g: int, b: int>] {
let r = $rgb.r / 255 let r = $rgb.r / 255
let g = $rgb.g / 255 let g = $rgb.g / 255
@@ -130,9 +137,25 @@ def pick-accents [flavor: string, swatches: list, want: int, min_sep: float] {
$chosen_names $chosen_names
} }
def container-tint [hex: string] { def blend-hex [a: string, b: string, ratio: float] {
# accent-tinted, ~14% opacity - a soft fill for badges/containers # Opaque RGB interpolation - neo-brutalist surfaces are solid blocks, never
$"#24($hex | str substring 1..)" # alpha blends, so "muted container" colors are baked as real flat hex.
let ar = ($a | str substring 1..2 | hex-byte)
let ag = ($a | str substring 3..4 | hex-byte)
let ab = ($a | str substring 5..6 | hex-byte)
let br = ($b | str substring 1..2 | hex-byte)
let bg = ($b | str substring 3..4 | hex-byte)
let bb = ($b | str substring 5..6 | hex-byte)
let mix = {|x, y| (($x * (1 - $ratio)) + ($y * $ratio)) | math round | into int }
let r = (to-hex-byte (do $mix $ar $br))
let g = (to-hex-byte (do $mix $ag $bg))
let b2 = (to-hex-byte (do $mix $ab $bb))
$"#($r)($g)($b2)"
}
def container-tint [base: string, accent: string] {
# Opaque muted tile: ~30% accent blended into the base surface, no alpha.
blend-hex $base $accent 0.3
} }
def write-theme-colors [flavor: string, accent_names: list] { def write-theme-colors [flavor: string, accent_names: list] {
@@ -141,37 +164,39 @@ def write-theme-colors [flavor: string, accent_names: list] {
let secondary = ($p.accents | get $accent_names.1) let secondary = ($p.accents | get $accent_names.1)
let tertiary = ($p.accents | get $accent_names.2) let tertiary = ($p.accents | get $accent_names.2)
let info = $p.accents.sapphire let info = $p.accents.sapphire
let border = $"#1a($primary | str substring 1..)" # accent-tinted, ~10% opacity
let colors = [ let colors = [
$" property color background: \"#e6($p.crust | str substring 1..)\"" $" property color background: \"($p.base)\""
$" property color surface: \"#cc($p.mantle | str substring 1..)\"" $" property color surface: \"($p.mantle)\""
$" property color surfaceHover: \"#f2($p.surface0 | str substring 1..)\"" $" property color surfaceHover: \"($p.surface0)\""
$" property color overlay: \"#60($p.crust | str substring 1..)\"" $" property color overlay: \"#cc($p.crust | str substring 1..)\""
""
$" property color crust: \"($p.crust)\""
$" property color outlineVariant: \"($p.surface1)\""
"" ""
$" property color primary: \"($primary)\"" $" property color primary: \"($primary)\""
$" property color secondary: \"($secondary)\"" $" property color secondary: \"($secondary)\""
$" property color tertiary: \"($tertiary)\"" $" property color tertiary: \"($tertiary)\""
$" property color accent: \"($primary)\"" $" property color accent: \"($primary)\""
"" ""
$" property color primaryContainer: \"(container-tint $primary)\"" $" property color primaryContainer: \"(container-tint $p.surface0 $primary)\""
$" property color secondaryContainer: \"(container-tint $secondary)\"" $" property color secondaryContainer: \"(container-tint $p.surface0 $secondary)\""
$" property color tertiaryContainer: \"(container-tint $tertiary)\"" $" property color tertiaryContainer: \"(container-tint $p.surface0 $tertiary)\""
"" ""
$" property color alert: \"($p.red)\"" $" property color alert: \"($p.red)\""
$" property color alertContainer: \"(container-tint $p.red)\"" $" property color alertContainer: \"(container-tint $p.surface0 $p.red)\""
$" property color success: \"($p.green)\"" $" property color success: \"($p.green)\""
$" property color successContainer: \"(container-tint $p.green)\"" $" property color successContainer: \"(container-tint $p.surface0 $p.green)\""
$" property color warning: \"($p.yellow)\"" $" property color warning: \"($p.yellow)\""
$" property color warningContainer: \"(container-tint $p.yellow)\"" $" property color warningContainer: \"(container-tint $p.surface0 $p.yellow)\""
$" property color info: \"($info)\"" $" property color info: \"($info)\""
$" property color infoContainer: \"(container-tint $info)\"" $" property color infoContainer: \"(container-tint $p.surface0 $info)\""
"" ""
$" property color text: \"($p.text)\"" $" property color text: \"($p.text)\""
$" property color textMuted: \"($p.subtext0)\"" $" property color textMuted: \"($p.subtext0)\""
$" property color textOnAccent: \"#e6($p.crust | str substring 1..)\"" $" property color textOnAccent: \"($p.crust)\""
"" ""
$" property color border: \"($border)\"" $" property color border: \"($p.crust)\""
] ]
let theme_path = $"($env.HOME)/.config/quickshell/components/Shared/Theme.qml" let theme_path = $"($env.HOME)/.config/quickshell/components/Shared/Theme.qml"
+65
View File
@@ -0,0 +1,65 @@
{
"nodes": {
"devenv": {
"locked": {
"dir": "src/modules",
"lastModified": 1789480904,
"narHash": "sha256-anHWHTkxI7423/eUroN9Rc4+H8VIGyIUWq/hV1egBDQ=",
"owner": "cachix",
"repo": "devenv",
"rev": "0fd5e6d3a9b2ae6f10205a3e95e0ca58d526c5a6",
"type": "github"
},
"original": {
"dir": "src/modules",
"owner": "cachix",
"repo": "devenv",
"type": "github"
}
},
"nixpkgs": {
"inputs": {
"nixpkgs-src": "nixpkgs-src"
},
"locked": {
"lastModified": 1789506231,
"narHash": "sha256-vNkJbtmqyBfFhn/HnzQo4ROuoyYWuy/allqTfJb4kMY=",
"owner": "cachix",
"repo": "devenv-nixpkgs",
"rev": "c2f38fe7f9e04d9aadd354d380f2bd40531d9737",
"type": "github"
},
"original": {
"owner": "cachix",
"ref": "rolling",
"repo": "devenv-nixpkgs",
"type": "github"
}
},
"nixpkgs-src": {
"flake": false,
"locked": {
"lastModified": 1789370336,
"narHash": "sha256-6RSEDHIWQtesQKWSu5qRai8L2h4KgCgMEfJHstW99G4=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "c7def046b9a883d46974757852106483d741586f",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixpkgs-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"root": {
"inputs": {
"devenv": "devenv",
"nixpkgs": "nixpkgs"
}
}
},
"root": "root",
"version": 7
}
+11
View File
@@ -0,0 +1,11 @@
{ pkgs, lib, config, inputs, ... }:
{
packages = [ pkgs.git ];
# https://devenv.sh/git-hooks/
# git-hooks.hooks.shellcheck.enable = true;
# See full reference at https://devenv.sh/reference/options/
}
+6
View File
@@ -0,0 +1,6 @@
# yaml-language-server: $schema=https://devenv.sh/devenv.schema.json
inputs:
nixpkgs:
url: github:cachix/devenv-nixpkgs/rolling
allow_unfree: true
Generated
+87 -78
View File
@@ -30,11 +30,11 @@
"nixpkgs": "nixpkgs" "nixpkgs": "nixpkgs"
}, },
"locked": { "locked": {
"lastModified": 1786855262, "lastModified": 1789646089,
"narHash": "sha256-mMgM6dKcrpZ0sBrlnYU4EoV1JzWjIP8faWPllFXhW8g=", "narHash": "sha256-UyDDTYPZCAY188ya/qGFIu6FRRO8nqdUmYHkTkRg2/Y=",
"owner": "chaotic-cx", "owner": "chaotic-cx",
"repo": "nyx", "repo": "nyx",
"rev": "651d55cfb9ae62189ce078ad35161043490c1a96", "rev": "ecc8cad9bbbad5d2eb38f354c90f39daf92626a5",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -66,24 +66,6 @@
"type": "github" "type": "github"
} }
}, },
"flake-parts": {
"inputs": {
"nixpkgs-lib": "nixpkgs-lib"
},
"locked": {
"lastModified": 1785627969,
"narHash": "sha256-4dtXQk/NMePegK/nWp5NSeuZKLATItOq61lpEvmXqGw=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "427bf4bd9435fdf21321c8cc628c24efc14c0f7a",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "flake-parts",
"type": "github"
}
},
"flake-schemas": { "flake-schemas": {
"locked": { "locked": {
"lastModified": 1780327564, "lastModified": 1780327564,
@@ -127,11 +109,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1786719456, "lastModified": 1789482455,
"narHash": "sha256-B74DLQs/VjlqyhnnX3tguWwghqJHWSJX30TKZuAljIg=", "narHash": "sha256-pD3qVlQ4mUCFoTWrYtxecpSitQMsgJvJIN0FUIDZoEU=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "83b7606dcf44abe3a94b86e8bb2b3355d22e8797", "rev": "efa3ccb4c3cc90d832eab232976379058fa75aa3",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -147,11 +129,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1784789275, "lastModified": 1789652175,
"narHash": "sha256-cgRTWuG+u1tBPhm01JrId2k0Bni09phVJ1Q0BZlRd7M=", "narHash": "sha256-OVgwnH7e/GlJRscTPXnJ8wwy6Mh+hk0MedEw360o8U8=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "3b0e6bbd65869af1beadf5963a99befc179d209f", "rev": "f2785222a14e90f8c5ad2ff62474ce88453c3421",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -160,6 +142,28 @@
"type": "github" "type": "github"
} }
}, },
"home-manager_4": {
"inputs": {
"nixpkgs": [
"nixcord",
"nixpkgs"
]
},
"locked": {
"lastModified": 1789267039,
"narHash": "sha256-LWiBv9yAYFi2LPbUhDGHPGKYskJQjj2fw12OlyO1uQo=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "ec172013fa62135f58fb58dd17ae9651e8f39727",
"type": "github"
},
"original": {
"owner": "nix-community",
"ref": "release-26.05",
"repo": "home-manager",
"type": "github"
}
},
"hyprmod": { "hyprmod": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@@ -167,11 +171,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1787208859, "lastModified": 1787844471,
"narHash": "sha256-f8ygnyOlwXGfM31+GB+B8y7TYDShyzHKuPo1ww+uxtQ=", "narHash": "sha256-AKnBFjkZs4UGZqMT3yIkaCdpvM2fVccU1dVuK5AVZBk=",
"owner": "BlueManCZ", "owner": "BlueManCZ",
"repo": "hyprmod", "repo": "hyprmod",
"rev": "bf5b55a9a89d7eab5a6d6947743de9dcb1cacd4a", "rev": "ffd47d804d8996cf3852dbb7ca1c949c424a57fb",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -180,19 +184,42 @@
"type": "github" "type": "github"
} }
}, },
"nix-darwin": {
"inputs": {
"nixpkgs": [
"nixcord",
"nixpkgs"
]
},
"locked": {
"lastModified": 1783744694,
"narHash": "sha256-2cp6N3rrwnGYLTx9l6N+NI+kwrCWxvJUbj5WJhvB29A=",
"owner": "nix-darwin",
"repo": "nix-darwin",
"rev": "c3e90c89649b07d1a96e4b9dd6cd0d6e44b91a74",
"type": "github"
},
"original": {
"owner": "nix-darwin",
"ref": "nix-darwin-26.05",
"repo": "nix-darwin",
"type": "github"
}
},
"nixcord": { "nixcord": {
"inputs": { "inputs": {
"flake-parts": "flake-parts", "home-manager": "home-manager_4",
"nix-darwin": "nix-darwin",
"nixpkgs": "nixpkgs_2", "nixpkgs": "nixpkgs_2",
"nixpkgs-nixcord": "nixpkgs-nixcord", "nixpkgs-nixcord": "nixpkgs-nixcord",
"treefmt-nix": "treefmt-nix" "treefmt-nix": "treefmt-nix"
}, },
"locked": { "locked": {
"lastModified": 1786878900, "lastModified": 1789635917,
"narHash": "sha256-Q2Ed3e0TvgP6vNp6j6Lw8ReObARjl3TQgMWr1uutOjs=", "narHash": "sha256-o8AQKmjmTE/wWZ1eTTzCSG9ZUzWUq71ChL0nCycW1bI=",
"owner": "kaylorben", "owner": "kaylorben",
"repo": "nixcord", "repo": "nixcord",
"rev": "c2739f4f45543aad98ec0b0bb27975fb2ff55455", "rev": "65485f4b335e9a0e8a77d88a1595c70341919ac3",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -203,42 +230,24 @@
}, },
"nixpkgs": { "nixpkgs": {
"locked": { "locked": {
"lastModified": 1786599213, "lastModified": 1789426278,
"narHash": "sha256-yNJd40f11EzXBjSByCB7IPpeFFAdeoSKKM67dGkfFoU=", "narHash": "sha256-LMzzTWExGdJ1S8U3IP5egkZEtyMswAwYowTAxIlkEZs=",
"owner": "NixOS", "rev": "efe6f071ede9d21c37462d2d6682d5e670099684",
"repo": "nixpkgs", "type": "tarball",
"rev": "0e251e24a4f24e036a084b6b4b2d2491af4167f4", "url": "https://releases.nixos.org/nixos/unstable/nixos-26.11pre1074086.efe6f071ede9/nixexprs.tar.zst"
"type": "github"
}, },
"original": { "original": {
"owner": "NixOS", "type": "tarball",
"ref": "nixos-unstable", "url": "https://channels.nixos.org/nixos-unstable/nixexprs.tar.zst"
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs-lib": {
"locked": {
"lastModified": 1785031560,
"narHash": "sha256-OmshNvn2vupOFpYinLUu+1Dnpu4n7Q5N3ggGVNHpkUI=",
"owner": "nix-community",
"repo": "nixpkgs.lib",
"rev": "0e79af5e3d4dcfcd676ab5ba3f95d2e3352e078c",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "nixpkgs.lib",
"type": "github"
} }
}, },
"nixpkgs-nixcord": { "nixpkgs-nixcord": {
"locked": { "locked": {
"lastModified": 1786711500, "lastModified": 1789459628,
"narHash": "sha256-QvnceIGTBeDvDd9oCn+GvdsnkquliuwbVgpiRH68qaQ=", "narHash": "sha256-JOaadoI/IC9qEvwlnjwAhwdcWkCDqEeOJ+cOtUH/8RQ=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "02e08985a27c65ffd33d434eeb2e660a2e4dc84d", "rev": "b67c7a60c3732edd4b947a7df8af06215851a614",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -250,11 +259,11 @@
}, },
"nixpkgs_2": { "nixpkgs_2": {
"locked": { "locked": {
"lastModified": 1786711500, "lastModified": 1789459628,
"narHash": "sha256-QvnceIGTBeDvDd9oCn+GvdsnkquliuwbVgpiRH68qaQ=", "narHash": "sha256-JOaadoI/IC9qEvwlnjwAhwdcWkCDqEeOJ+cOtUH/8RQ=",
"owner": "NixOS", "owner": "NixOS",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "02e08985a27c65ffd33d434eeb2e660a2e4dc84d", "rev": "b67c7a60c3732edd4b947a7df8af06215851a614",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -266,11 +275,11 @@
}, },
"nixpkgs_3": { "nixpkgs_3": {
"locked": { "locked": {
"lastModified": 1784497964, "lastModified": 1789546076,
"narHash": "sha256-vlHUuqAcbcH2RKmHbPiuQzbv1pnzzavXnI62RD0bqCU=", "narHash": "sha256-zVxLZiSnmaaPLwnhj7pwmqe3axBg/C6nG5JZsJMh2g4=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "241313f4e8e508cb9b13278c2b0fa25b9ca27163", "rev": "b1b875982b17dabde9b4a37f3e229e74913e6db3",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -282,11 +291,11 @@
}, },
"nixpkgs_4": { "nixpkgs_4": {
"locked": { "locked": {
"lastModified": 1787360063, "lastModified": 1789149629,
"narHash": "sha256-95aJfHyQTLWslCXFVNB0odgmVkpdmDezQwTg9mhqV1E=", "narHash": "sha256-eQUZVehWLDBbpBR2rq6DnuRee1ULT6Y675RhsYDSjYI=",
"rev": "2c423e03bbafcff28bfadc6781a4a8257f205cb5", "rev": "eaad089433ca2bb662274377d33df3d0e51ef28b",
"type": "tarball", "type": "tarball",
"url": "https://releases.nixos.org/nixos/unstable/nixos-26.11pre1059570.2c423e03bbaf/nixexprs.tar.xz" "url": "https://releases.nixos.org/nixos/unstable/nixos-26.11pre1072397.eaad089433ca/nixexprs.tar.xz"
}, },
"original": { "original": {
"type": "tarball", "type": "tarball",
@@ -310,11 +319,11 @@
"systems": "systems_2" "systems": "systems_2"
}, },
"locked": { "locked": {
"lastModified": 1787460061, "lastModified": 1789291406,
"narHash": "sha256-r2FJY01jRVhrZIKPdhQ3QFYsAz3wjilWTMSSH7VMOeo=", "narHash": "sha256-lfZ7yAaTZMuAzOSLjJ7ivrKIFk0E11koWTVgkWSXwuE=",
"owner": "Gerg-L", "owner": "Gerg-L",
"repo": "spicetify-nix", "repo": "spicetify-nix",
"rev": "a8adfd6f9f341dd586d5c06dda3bbfa21c6014e7", "rev": "09eed5c95105aada9ffabd4c7eb6b345dc4ba66f",
"type": "github" "type": "github"
}, },
"original": { "original": {
@@ -361,11 +370,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1785945821, "lastModified": 1786901030,
"narHash": "sha256-NLSyTCW4K4ofhNBllt3omPasm6QpralXH1DBZOc91Dw=", "narHash": "sha256-WSFCsDSE5ffgD2MqzkM2CYjeFiKhRF/dJUN8uedb6YE=",
"owner": "numtide", "owner": "numtide",
"repo": "treefmt-nix", "repo": "treefmt-nix",
"rev": "ae7910970dddc408fe6ab1c8e4b277bb21d72dc0", "rev": "27b3b12a8e6375f28ebe122f07d230ca5459bbfa",
"type": "github" "type": "github"
}, },
"original": { "original": {
+1
View File
@@ -61,6 +61,7 @@
jellytui jellytui
tlrc tlrc
mago mago
zotero
] ++ lib.optionals pkgs.stdenv.hostPlatform.isLinux [ ] ++ lib.optionals pkgs.stdenv.hostPlatform.isLinux [
owncloud-client owncloud-client
wl-clipboard wl-clipboard
+4 -7
View File
@@ -78,7 +78,7 @@ hl.config({
gaps_out = 20, gaps_out = 20,
border_size = 2, border_size = 2,
col = { col = {
active_border = "rgb(f38ba8)", active_border = "rgb(cba6f7)",
inactive_border = "rgb(45475a)", inactive_border = "rgb(45475a)",
}, },
resize_on_border = false, resize_on_border = false,
@@ -86,15 +86,11 @@ hl.config({
layout = "dwindle", layout = "dwindle",
}, },
decoration = { decoration = {
rounding = 2, rounding = 0,
rounding_power = 2,
active_opacity = 1.0, active_opacity = 1.0,
inactive_opacity = 0.9, inactive_opacity = 0.9,
shadow = { shadow = {
enabled = true, enabled = false,
range = 4,
render_power = 3,
color = "rgba(1a1a1aee)",
}, },
blur = { blur = {
enabled = true, enabled = true,
@@ -178,6 +174,7 @@ hl.bind(mainMod .. " + E", hl.dsp.exec_cmd(fileManager))
hl.bind(mainMod .. " + H", hl.dsp.window.float({ action = "toggle" })) hl.bind(mainMod .. " + H", hl.dsp.window.float({ action = "toggle" }))
hl.bind(mainMod .. " + Space", hl.dsp.exec_cmd(menu)) hl.bind(mainMod .. " + Space", hl.dsp.exec_cmd(menu))
hl.bind(mainMod .. " + V", hl.dsp.exec_cmd("quickshell ipc call clipboardManager toggle")) hl.bind(mainMod .. " + V", hl.dsp.exec_cmd("quickshell ipc call clipboardManager toggle"))
hl.bind(mainMod .. " + A", hl.dsp.exec_cmd("quickshell ipc call quickSettings toggle"))
hl.bind(mainMod .. " + P", hl.dsp.window.pseudo()) hl.bind(mainMod .. " + P", hl.dsp.window.pseudo())
hl.bind(mainMod .. " + F", hl.dsp.window.fullscreen({ action = "toggle" })) hl.bind(mainMod .. " + F", hl.dsp.window.fullscreen({ action = "toggle" }))
hl.bind(mainMod .. " + L", hl.dsp.exec_cmd(lock)) hl.bind(mainMod .. " + L", hl.dsp.exec_cmd(lock))
@@ -106,8 +106,9 @@ PanelWindow {
delegate: Rectangle { delegate: Rectangle {
width: 24 width: 24
height: 24 height: 24
radius: Theme.geometry.radiusTiny
color: modelData.active ? Theme.colors.primary : Theme.colors.surfaceHover color: modelData.active ? Theme.colors.primary : Theme.colors.surfaceHover
border.width: Theme.geometry.borderWidth
border.color: Theme.colors.crust
Behavior on color { ColorAnimation { duration: Theme.animation.durationFast } } Behavior on color { ColorAnimation { duration: Theme.animation.durationFast } }
@@ -235,6 +236,17 @@ PanelWindow {
: "No battery" : "No battery"
visible: battery.isPresent visible: battery.isPresent
} }
TrayIcon {
glyph: "⚙" // gear (U+2699)
active: barWindow.rootState.quickSettingsOpen
tint: Theme.colors.primary
tooltip: "Quick Settings (SUPER+A)"
onClicked: {
barWindow.rootState.quickSettingsOpen = !barWindow.rootState.quickSettingsOpen;
if (barWindow.rootState.quickSettingsOpen) barWindow.rootState.closeOtherOverlays("quickSettings");
}
}
} }
property QtObject battery: UPower.displayDevice property QtObject battery: UPower.displayDevice
@@ -460,16 +472,16 @@ PanelWindow {
property string tooltip: "" property string tooltip: ""
property bool active: false property bool active: false
property color tint: Theme.colors.primary property color tint: Theme.colors.primary
signal clicked()
width: 24 width: 24
height: 24 height: 24
Rectangle { Rectangle {
anchors.fill: parent anchors.fill: parent
radius: Theme.geometry.radiusTiny color: hoverArea.containsMouse ? Theme.colors.surfaceHover : "transparent"
color: hoverArea.containsMouse border.width: trayIcon.active ? Theme.geometry.borderWidth : 0
? Theme.colors.surfaceHover border.color: trayIcon.tint
: (trayIcon.active ? Qt.alpha(trayIcon.tint, 0.15) : "transparent")
Behavior on color { ColorAnimation { duration: Theme.animation.durationFast } } Behavior on color { ColorAnimation { duration: Theme.animation.durationFast } }
@@ -488,6 +500,7 @@ PanelWindow {
id: hoverArea id: hoverArea
anchors.fill: parent anchors.fill: parent
hoverEnabled: true hoverEnabled: true
cursorShape: Qt.PointingHandCursor
onEntered: { onEntered: {
if (trayIcon.tooltip.length > 0) { if (trayIcon.tooltip.length > 0) {
// Anchor on the icon's horizontal center; the tooltip // Anchor on the icon's horizontal center; the tooltip
@@ -497,6 +510,7 @@ PanelWindow {
} }
} }
onExited: barWindow.hideTooltip() onExited: barWindow.hideTooltip()
onClicked: trayIcon.clicked()
} }
} }
} }
@@ -46,7 +46,7 @@ PanelWindow {
tint: Theme.colors.secondary tint: Theme.colors.secondary
glow: true glow: true
Behavior on scale { SpringAnimation { spring: Theme.motion.springSoft.spring; damping: Theme.motion.springSoft.damping } } Behavior on scale { NumberAnimation { duration: Theme.animation.durationFast; easing.type: Easing.OutCubic } }
Behavior on opacity { NumberAnimation { duration: Theme.animation.durationFast } } Behavior on opacity { NumberAnimation { duration: Theme.animation.durationFast } }
Behavior on height { NumberAnimation { duration: Theme.animation.durationFast; easing.type: Easing.OutCubic } } Behavior on height { NumberAnimation { duration: Theme.animation.durationFast; easing.type: Easing.OutCubic } }
@@ -157,7 +157,7 @@ PanelWindow {
Text { Text {
text: model.content text: model.content
color: Theme.colors.text color: clipRow.selected ? Theme.colors.textOnAccent : Theme.colors.text
font.family: Theme.font.family font.family: Theme.font.family
font.pixelSize: Theme.type.label font.pixelSize: Theme.type.label
anchors.left: parent.left anchors.left: parent.left
@@ -46,6 +46,7 @@ PanelWindow {
} }
} }
readonly property int titleBarHeight: 28
readonly property int headerHeight: 50 readonly property int headerHeight: 50
readonly property int footerHeight: 24 readonly property int footerHeight: 24
readonly property int emptyStateHeight: 40 readonly property int emptyStateHeight: 40
@@ -94,7 +95,8 @@ PanelWindow {
// Sized appropriately for a 2560x1440 screen // Sized appropriately for a 2560x1440 screen
width: 800 width: 800
height: Math.min(600, height: Math.min(600,
headerHeight + Theme.geometry.spacing titleBarHeight + Theme.geometry.spacing
+ headerHeight + Theme.geometry.spacing
+ (appModel.count > 0 ? appList.contentHeight : emptyStateHeight) + Theme.geometry.spacing + (appModel.count > 0 ? appList.contentHeight : emptyStateHeight) + Theme.geometry.spacing
+ footerHeight + footerHeight
+ Theme.geometry.padding * 2) + Theme.geometry.padding * 2)
@@ -102,7 +104,7 @@ PanelWindow {
tint: Theme.colors.primary tint: Theme.colors.primary
glow: true glow: true
Behavior on scale { SpringAnimation { spring: Theme.motion.springSoft.spring; damping: Theme.motion.springSoft.damping } } Behavior on scale { NumberAnimation { duration: Theme.animation.durationFast; easing.type: Easing.OutCubic } }
Behavior on opacity { NumberAnimation { duration: Theme.animation.durationFast } } Behavior on opacity { NumberAnimation { duration: Theme.animation.durationFast } }
Behavior on height { NumberAnimation { duration: Theme.animation.durationFast; easing.type: Easing.OutCubic } } Behavior on height { NumberAnimation { duration: Theme.animation.durationFast; easing.type: Easing.OutCubic } }
@@ -118,11 +120,49 @@ PanelWindow {
anchors.margins: Theme.geometry.padding anchors.margins: Theme.geometry.padding
spacing: Theme.geometry.spacing spacing: Theme.geometry.spacing
Item {
width: parent.width
height: paletteWindow.titleBarHeight
Row {
anchors.left: parent.left
anchors.verticalCenter: parent.verticalCenter
spacing: Theme.geometry.spacing / 2
Rectangle {
width: 10
height: 10
anchors.verticalCenter: parent.verticalCenter
color: Theme.colors.primary
border.width: Theme.geometry.borderWidth
border.color: Theme.colors.crust
}
Text {
text: "QUICKSHELL :: APP_ROFI_MODAL [WAYLAND]"
color: Theme.colors.textMuted
font.family: Theme.font.family
font.bold: true
font.pixelSize: Theme.type.caption
}
}
Text {
anchors.right: parent.right
anchors.verticalCenter: parent.verticalCenter
text: "[ESC] Close"
color: Theme.colors.textMuted
font.family: Theme.font.family
font.pixelSize: Theme.type.caption
}
}
TextField { TextField {
id: searchInput id: searchInput
width: parent.width width: parent.width
height: paletteWindow.headerHeight height: paletteWindow.headerHeight
placeholder: "Search apps..." placeholder: "Search apps..."
prefix: "❯"
onVisibleChanged: { onVisibleChanged: {
if (visible) focusInput(); if (visible) focusInput();
@@ -255,6 +295,7 @@ PanelWindow {
model: ListModel { id: appModel } model: ListModel { id: appModel }
delegate: ListRow { delegate: ListRow {
id: appRow
width: appList.width width: appList.width
selected: ListView.isCurrentItem selected: ListView.isCurrentItem
accent: model.isLastUsed ? Theme.colors.secondary : Theme.colors.primary accent: model.isLastUsed ? Theme.colors.secondary : Theme.colors.primary
@@ -277,7 +318,6 @@ PanelWindow {
Rectangle { Rectangle {
anchors.fill: parent anchors.fill: parent
color: Theme.colors.primary color: Theme.colors.primary
radius: 12
visible: parent.status === Image.Error || parent.status === Image.Null || model.iconName === "" visible: parent.status === Image.Error || parent.status === Image.Null || model.iconName === ""
Text { Text {
@@ -292,7 +332,7 @@ PanelWindow {
Text { Text {
text: model.appName text: model.appName
color: Theme.colors.text color: appRow.selected ? Theme.colors.textOnAccent : Theme.colors.text
font.family: Theme.font.family font.family: Theme.font.family
font.pixelSize: Theme.type.label font.pixelSize: Theme.type.label
anchors.left: appIcon.right anchors.left: appIcon.right
@@ -304,14 +344,42 @@ PanelWindow {
} }
} }
HintBar { Item {
width: parent.width width: parent.width
height: paletteWindow.footerHeight height: paletteWindow.footerHeight
hints: [
{ key: "↑↓", label: "Navigate" }, HintBar {
{ key: "↵", label: "Launch" }, anchors.left: parent.left
{ key: "Esc", label: "Close" } anchors.verticalCenter: parent.verticalCenter
] hints: [
{ key: "↑↓", label: "Navigate" },
{ key: "↵", label: "Launch" },
{ key: "Esc", label: "Close" }
]
}
Row {
anchors.right: parent.right
anchors.verticalCenter: parent.verticalCenter
spacing: Theme.geometry.spacing / 2
Rectangle {
width: 8
height: 8
anchors.verticalCenter: parent.verticalCenter
color: Theme.colors.tertiary
border.width: Theme.geometry.borderWidth
border.color: Theme.colors.crust
}
Text {
text: "HYPR_IPC OK"
color: Theme.colors.text
font.family: Theme.font.family
font.bold: true
font.pixelSize: Theme.type.caption
}
}
} }
} }
@@ -1,6 +1,7 @@
import QtQuick import QtQuick
import Quickshell import Quickshell
import Quickshell.Wayland import Quickshell.Wayland
import Quickshell.Io
import Quickshell.Services.Pam import Quickshell.Services.Pam
import Quickshell.Services.UPower import Quickshell.Services.UPower
import "../Shared" import "../Shared"
@@ -92,6 +93,68 @@ WlSessionLock {
precision: SystemClock.Seconds precision: SystemClock.Seconds
} }
property string hostLabel: "localhost"
Process {
id: hostnameProcess
command: ["hostname"]
running: true
stdout: StdioCollector {
onStreamFinished: lockSurface.hostLabel = this.text.trim()
}
}
// Top telemetry strip
Item {
anchors.top: parent.top
anchors.left: parent.left
anchors.right: parent.right
anchors.margins: Theme.geometry.spacing * 2
height: 28
Row {
anchors.left: parent.left
anchors.verticalCenter: parent.verticalCenter
spacing: Theme.geometry.spacing
Pill {
tint: Theme.colors.success
Rectangle { width: 6; height: 6; anchors.verticalCenter: parent.verticalCenter; color: Theme.colors.success }
Text {
text: Quickshell.env("USER") + " // " + lockSurface.hostLabel
color: Theme.colors.text
font.family: Theme.font.family
font.pixelSize: Theme.type.caption
font.bold: true
}
}
Pill {
tint: Theme.colors.outlineVariant
Text {
text: "WAYLAND_0 [HYPRLAND]"
color: Theme.colors.textMuted
font.family: Theme.font.family
font.pixelSize: Theme.type.caption
}
}
}
Pill {
anchors.right: parent.right
anchors.verticalCenter: parent.verticalCenter
tint: Theme.colors.primary
glow: true
Text {
text: "PAM::SECURED"
color: Theme.colors.primary
font.family: Theme.font.family
font.bold: true
font.pixelSize: Theme.type.caption
}
}
}
Column { Column {
anchors.centerIn: parent anchors.centerIn: parent
spacing: Theme.geometry.spacing * 3 spacing: Theme.geometry.spacing * 3
@@ -182,6 +245,8 @@ WlSessionLock {
id: passwordField id: passwordField
width: parent.width width: parent.width
placeholder: "Password" placeholder: "Password"
prefix: "❯"
passwordCharacter: "■"
echoMode: sessionLock.responseVisible ? TextInput.Normal : TextInput.Password echoMode: sessionLock.responseVisible ? TextInput.Normal : TextInput.Password
onVisibleChanged: { if (visible) focusInput(); } onVisibleChanged: { if (visible) focusInput(); }
@@ -191,6 +256,10 @@ WlSessionLock {
authCtx.respond(sessionLock.password); authCtx.respond(sessionLock.password);
sessionLock.awaitingResponse = false; sessionLock.awaitingResponse = false;
} }
onEscapePressed: {
passwordField.text = "";
sessionLock.errorText = "";
}
} }
} }
@@ -205,7 +274,10 @@ WlSessionLock {
HintBar { HintBar {
anchors.horizontalCenter: parent.horizontalCenter anchors.horizontalCenter: parent.horizontalCenter
hints: [ { key: "↵", label: "Unlock" } ] hints: [
{ key: "↵", label: "Unlock" },
{ key: "Esc", label: "Clear" }
]
} }
} }
} }
@@ -8,12 +8,15 @@ PanelWindow {
id: logoutWindow id: logoutWindow
property QtObject rootState property QtObject rootState
property int currentIndex: 2 // Default to Logout in the middle property int currentIndex: 2 // Default to Logout in the middle
// Destructive actions (Reboot/Shutdown) require a second confirmation
// before executing - selecting them the first time just arms them.
property int armedIndex: -1
property var actions: [ property var actions: [
{ cmd: "loginctl lock-session" }, { cmd: "loginctl lock-session", key: "L", label: "Lock", sub: "loginctl lock-session", destructive: false },
{ cmd: "systemctl suspend" }, { cmd: "loginctl terminate-user $USER", key: "E", label: "Logout", sub: "loginctl terminate-user", destructive: false },
{ cmd: "loginctl terminate-user $USER" }, { cmd: "systemctl suspend", key: "U", label: "Suspend", sub: "systemctl suspend", destructive: false },
{ cmd: "systemctl reboot" }, { cmd: "systemctl reboot", key: "R", label: "Reboot", sub: "systemctl reboot", destructive: true },
{ cmd: "systemctl poweroff" } { cmd: "systemctl poweroff", key: "S", label: "Shutdown", sub: "systemctl poweroff", destructive: true }
] ]
visible: rootState.logoutMenuOpen visible: rootState.logoutMenuOpen
@@ -24,7 +27,7 @@ PanelWindow {
left: true left: true
right: true right: true
} }
exclusiveZone: 0 exclusiveZone: 0
color: "transparent" color: "transparent"
@@ -39,74 +42,101 @@ PanelWindow {
Rectangle { Rectangle {
anchors.fill: parent anchors.fill: parent
color: Theme.colors.overlay // Full screen dim/blur color: Theme.colors.overlay // Full screen dim
Behavior on opacity { NumberAnimation { duration: Theme.animation.durationNormal } } Behavior on opacity { NumberAnimation { duration: Theme.animation.durationNormal } }
opacity: rootState.logoutMenuOpen ? 1 : 0 opacity: rootState.logoutMenuOpen ? 1 : 0
MouseArea { MouseArea {
anchors.fill: parent anchors.fill: parent
onClicked: rootState.logoutMenuOpen = false onClicked: rootState.logoutMenuOpen = false
} }
Item { Surface {
id: container id: container
width: buttonRow.width width: modalColumn.width + Theme.geometry.padding * 2
height: buttonRow.height height: modalColumn.height + Theme.geometry.padding * 2
anchors.centerIn: parent anchors.centerIn: parent
tint: Theme.colors.primary
glow: true
Behavior on scale { SpringAnimation { spring: Theme.motion.springSoft.spring; damping: Theme.motion.springSoft.damping } } Behavior on scale { NumberAnimation { duration: Theme.animation.durationFast; easing.type: Easing.OutCubic } }
Row { MouseArea {
id: buttonRow anchors.fill: parent
spacing: Theme.geometry.spacing * 3
// Lock
LogoutButton {
icon: ""
label: "Lock"
isSelected: logoutWindow.currentIndex === 0
onClicked: executeAction(logoutWindow.actions[0].cmd)
onHovered: logoutWindow.currentIndex = 0
} }
// Suspend Column {
LogoutButton { id: modalColumn
icon: "" anchors.centerIn: parent
label: "Suspend" spacing: Theme.geometry.spacing
isSelected: logoutWindow.currentIndex === 1
onClicked: executeAction(logoutWindow.actions[1].cmd) // Title strip
onHovered: logoutWindow.currentIndex = 1 Item {
width: buttonRow.width
height: 24
Row {
anchors.left: parent.left
anchors.verticalCenter: parent.verticalCenter
spacing: Theme.geometry.spacing / 2
Rectangle {
width: 10
height: 10
anchors.verticalCenter: parent.verticalCenter
color: Theme.colors.primary
border.width: Theme.geometry.borderWidth
border.color: Theme.colors.crust
}
Text {
text: "[SYSTEM // POWER MANAGEMENT]"
color: Theme.colors.text
font.family: Theme.font.family
font.bold: true
font.pixelSize: Theme.type.caption
}
}
Text {
anchors.right: parent.right
anchors.verticalCenter: parent.verticalCenter
text: logoutWindow.armedIndex >= 0 ? "LATCH: ARMED" : "LATCH: IDLE"
color: logoutWindow.armedIndex >= 0 ? Theme.colors.alert : Theme.colors.textMuted
font.family: Theme.font.family
font.bold: true
font.pixelSize: Theme.type.caption
}
}
Row {
id: buttonRow
spacing: Theme.geometry.spacing * 2
Repeater {
model: logoutWindow.actions
delegate: LogoutButton {
action: modelData
index: model.index
isSelected: logoutWindow.currentIndex === model.index
isArmed: logoutWindow.armedIndex === model.index
onClicked: logoutWindow.select(model.index)
onHovered: logoutWindow.currentIndex = model.index
}
}
}
HintBar {
anchors.horizontalCenter: parent.horizontalCenter
hints: [
{ key: "L/E/U/R/S", label: "Select" },
{ key: "↵", label: "Confirm" },
{ key: "Esc", label: "Abort" }
]
}
} }
// Logout
LogoutButton {
icon: ""
label: "Logout"
isSelected: logoutWindow.currentIndex === 2
onClicked: executeAction(logoutWindow.actions[2].cmd)
onHovered: logoutWindow.currentIndex = 2
}
// Reboot
LogoutButton {
icon: ""
label: "Reboot"
isSelected: logoutWindow.currentIndex === 3
onClicked: executeAction(logoutWindow.actions[3].cmd)
onHovered: logoutWindow.currentIndex = 3
}
// Poweroff
LogoutButton {
icon: ""
label: "Shutdown"
isDestructive: true
isSelected: logoutWindow.currentIndex === 4
onClicked: executeAction(logoutWindow.actions[4].cmd)
onHovered: logoutWindow.currentIndex = 4
}
}
} }
} }
@@ -114,30 +144,43 @@ PanelWindow {
Item { Item {
anchors.fill: parent anchors.fill: parent
focus: true focus: true
Keys.onEscapePressed: (event) => { Keys.onEscapePressed: (event) => {
rootState.logoutMenuOpen = false; if (logoutWindow.armedIndex >= 0) {
logoutWindow.armedIndex = -1;
} else {
rootState.logoutMenuOpen = false;
}
event.accepted = true; event.accepted = true;
} }
Keys.onLeftPressed: (event) => { Keys.onLeftPressed: (event) => {
if (logoutWindow.currentIndex > 0) { if (logoutWindow.currentIndex > 0) logoutWindow.currentIndex--;
logoutWindow.currentIndex--; logoutWindow.armedIndex = -1;
}
event.accepted = true; event.accepted = true;
} }
Keys.onRightPressed: (event) => { Keys.onRightPressed: (event) => {
if (logoutWindow.currentIndex < 4) { if (logoutWindow.currentIndex < logoutWindow.actions.length - 1) logoutWindow.currentIndex++;
logoutWindow.currentIndex++; logoutWindow.armedIndex = -1;
}
event.accepted = true; event.accepted = true;
} }
Keys.onReturnPressed: (event) => { Keys.onReturnPressed: (event) => {
executeAction(logoutWindow.actions[logoutWindow.currentIndex].cmd); logoutWindow.select(logoutWindow.currentIndex);
event.accepted = true; event.accepted = true;
} }
Keys.onPressed: (event) => {
for (let i = 0; i < logoutWindow.actions.length; i++) {
if (event.text.toUpperCase() === logoutWindow.actions[i].key) {
logoutWindow.currentIndex = i;
logoutWindow.select(i);
event.accepted = true;
return;
}
}
}
} }
Process { Process {
@@ -145,9 +188,19 @@ PanelWindow {
running: false running: false
} }
function executeAction(cmd) { // Non-destructive actions execute immediately. Destructive ones
actionProcess.command = ["bash", "-c", cmd]; // (Reboot/Shutdown) arm on first selection and only execute once armed
// and selected again - the "dual-stage confirmation / latch" from the
// power-menu design.
function select(index) {
let action = logoutWindow.actions[index];
if (action.destructive && logoutWindow.armedIndex !== index) {
logoutWindow.armedIndex = index;
return;
}
actionProcess.command = ["bash", "-c", action.cmd];
actionProcess.running = true; actionProcess.running = true;
logoutWindow.armedIndex = -1;
rootState.logoutMenuOpen = false; rootState.logoutMenuOpen = false;
} }
@@ -155,50 +208,89 @@ PanelWindow {
if (visible) { if (visible) {
container.scale = 1.0; container.scale = 1.0;
logoutWindow.currentIndex = 2; // Reset to center logoutWindow.currentIndex = 2; // Reset to center
logoutWindow.armedIndex = -1;
} else { } else {
container.scale = 0.95; container.scale = 0.95;
} }
} }
// Inline component for the big buttons // Inline component for the big power-action tiles.
component LogoutButton: Surface { component LogoutButton: Surface {
property string icon: "" id: button
property string label: "" property var action
property bool isDestructive: false property int index: 0
property bool isSelected: false property bool isSelected: false
property bool isArmed: false
signal clicked() signal clicked()
signal hovered() signal hovered()
width: 120 readonly property color actionColor: isArmed ? Theme.colors.alert
height: 120 : action.destructive ? Theme.colors.alert
color: Theme.colors.surface : Theme.colors.primary
tint: isSelected ? (isDestructive ? Theme.colors.alert : Theme.colors.primary) : Theme.colors.border
border.width: isSelected ? 2 : 1
glow: isSelected
Behavior on scale { SpringAnimation { spring: Theme.motion.springSnappy.spring; damping: Theme.motion.springSnappy.damping } } width: 128
scale: isSelected ? 1.05 : 1.0 height: 128
color: isSelected ? Theme.colors.surfaceHover : Theme.colors.surface
tint: isSelected || isArmed ? actionColor : Theme.colors.border
glow: isSelected || isArmed
pressed: hoverArea.pressed
Column { Column {
anchors.centerIn: parent anchors.centerIn: parent
spacing: Theme.geometry.spacing spacing: Theme.geometry.spacing / 2
Text { Row {
text: parent.parent.icon
font.family: Theme.font.family
font.pixelSize: 36
anchors.horizontalCenter: parent.horizontalCenter anchors.horizontalCenter: parent.horizontalCenter
color: parent.parent.isSelected ? parent.parent.tint : Theme.colors.text spacing: Theme.geometry.spacing / 2
Rectangle {
width: 16
height: 16
anchors.verticalCenter: parent.verticalCenter
color: button.isArmed ? Theme.colors.alert : "transparent"
border.width: Theme.geometry.borderWidth
border.color: Theme.colors.crust
Text {
anchors.centerIn: parent
text: button.action.key
font.family: Theme.font.family
font.bold: true
font.pixelSize: 10
color: button.isArmed ? Theme.colors.textOnAccent : Theme.colors.text
}
}
Text {
anchors.verticalCenter: parent.verticalCenter
text: button.isArmed ? "ARMED" : ("#0" + (button.index + 1))
font.family: Theme.font.family
font.bold: true
font.pixelSize: Theme.type.caption
color: button.isArmed ? Theme.colors.alert : Theme.colors.textMuted
}
} }
Text { Text {
text: parent.parent.label text: button.action.label
font.family: Theme.font.family font.family: Theme.font.headlineFamily
font.pixelSize: 16 font.pixelSize: 16
font.bold: true font.bold: true
font.capitalization: Font.AllUppercase
color: Theme.colors.text color: Theme.colors.text
anchors.horizontalCenter: parent.horizontalCenter anchors.horizontalCenter: parent.horizontalCenter
} }
Text {
text: button.action.sub
font.family: Theme.font.family
font.pixelSize: 9
color: button.action.destructive ? Theme.colors.alert : Theme.colors.textMuted
width: button.width - Theme.geometry.spacing * 2
horizontalAlignment: Text.AlignHCenter
wrapMode: Text.WordWrap
anchors.horizontalCenter: parent.horizontalCenter
}
} }
MouseArea { MouseArea {
@@ -206,8 +298,8 @@ PanelWindow {
anchors.fill: parent anchors.fill: parent
hoverEnabled: true hoverEnabled: true
cursorShape: Qt.PointingHandCursor cursorShape: Qt.PointingHandCursor
onEntered: parent.hovered() onEntered: button.hovered()
onClicked: parent.clicked() onClicked: button.clicked()
} }
} }
} }
@@ -6,6 +6,7 @@ import "../Shared"
PanelWindow { PanelWindow {
id: notifWindow id: notifWindow
property QtObject rootState
anchors { anchors {
top: true top: true
@@ -35,6 +36,12 @@ PanelWindow {
onNotification: notification => { onNotification: notification => {
notification.tracked = true; notification.tracked = true;
// Do Not Disturb: the notification is still tracked/available
// to whatever reads NotificationServer directly, just not
// surfaced as a toast.
if (notifWindow.rootState && notifWindow.rootState.dndEnabled) return;
toastModel.insert(0, { toastModel.insert(0, {
notifObj: notification, notifObj: notification,
appName: notification.appName, appName: notification.appName,
@@ -101,76 +108,88 @@ PanelWindow {
Repeater { Repeater {
model: toastModel model: toastModel
delegate: Rectangle { delegate: Surface {
id: toast id: toast
width: list.width width: list.width
height: content.implicitHeight + Theme.geometry.padding * 2 height: 20 + content.implicitHeight
radius: Theme.geometry.radiusMedium color: Theme.colors.surface
color: Qt.alpha(notifWindow.colorFor(model.urgency), 0.15) tint: notifWindow.colorFor(model.urgency)
border.color: Qt.alpha(notifWindow.colorFor(model.urgency), 0.3) glow: model.urgency === NotificationUrgency.Critical
border.width: 1
Behavior on opacity { NumberAnimation { duration: Theme.animation.durationNormal } } Behavior on opacity { NumberAnimation { duration: Theme.animation.durationNormal } }
Row { Column {
id: content anchors.fill: parent
anchors.left: parent.left
anchors.right: parent.right
anchors.verticalCenter: parent.verticalCenter
anchors.margins: Theme.geometry.padding
spacing: Theme.geometry.spacing
// Solid accent header strip
Rectangle { Rectangle {
width: 16 width: parent.width
height: 16 height: 20
radius: 8
color: notifWindow.colorFor(model.urgency) color: notifWindow.colorFor(model.urgency)
anchors.top: parent.top
anchors.topMargin: 2
}
Column {
width: content.width - 16 - Theme.geometry.spacing - closeIcon.width - Theme.geometry.spacing
spacing: 2
Text { Text {
text: model.summary && model.summary.length > 0 ? model.summary : model.appName anchors.left: parent.left
anchors.leftMargin: Theme.geometry.spacing
anchors.verticalCenter: parent.verticalCenter
text: notifWindow.labelFor(model.urgency).toUpperCase() + " :: " + model.appName
font.family: Theme.font.family font.family: Theme.font.family
font.pixelSize: 12
font.bold: true font.bold: true
color: notifWindow.colorFor(model.urgency) font.pixelSize: Theme.type.caption
width: parent.width color: Theme.colors.textOnAccent
elide: Text.ElideRight
}
Text {
visible: model.body && model.body.length > 0
text: model.body
font.family: Theme.font.family
font.pixelSize: 12
color: Theme.colors.text
width: parent.width
wrapMode: Text.WordWrap
maximumLineCount: 3
elide: Text.ElideRight
} }
} }
Text { Row {
id: closeIcon id: content
text: "" width: parent.width
color: Theme.colors.textMuted leftPadding: Theme.geometry.padding
font.family: Theme.font.family rightPadding: Theme.geometry.padding
font.pixelSize: 12 topPadding: Theme.geometry.spacing
anchors.top: parent.top bottomPadding: Theme.geometry.spacing
spacing: Theme.geometry.spacing
MouseArea { Column {
anchors.fill: parent width: content.width - content.leftPadding - content.rightPadding - closeIcon.width - Theme.geometry.spacing
anchors.margins: -6 spacing: 2
cursorShape: Qt.PointingHandCursor
onClicked: { Text {
model.notifObj.dismiss(); text: model.summary && model.summary.length > 0 ? model.summary : model.appName
toastModel.remove(index); font.family: Theme.font.family
font.pixelSize: 12
font.bold: true
color: Theme.colors.text
width: parent.width
elide: Text.ElideRight
}
Text {
visible: model.body && model.body.length > 0
text: model.body
font.family: Theme.font.family
font.pixelSize: 12
color: Theme.colors.textMuted
width: parent.width
wrapMode: Text.WordWrap
maximumLineCount: 3
elide: Text.ElideRight
}
}
Text {
id: closeIcon
text: "✕"
color: Theme.colors.textMuted
font.family: Theme.font.family
font.pixelSize: 12
MouseArea {
anchors.fill: parent
anchors.margins: -6
cursorShape: Qt.PointingHandCursor
onClicked: {
model.notifObj.dismiss();
toastModel.remove(index);
}
} }
} }
} }
@@ -43,8 +43,8 @@ PanelWindow {
Behavior on margins.bottom { Behavior on margins.bottom {
NumberAnimation { NumberAnimation {
duration: Theme.animation.durationNormal duration: Theme.animation.durationFast
easing.type: Easing.OutBack easing.type: Easing.OutCubic
} }
} }
@@ -80,7 +80,6 @@ PanelWindow {
width: 300 width: 300
height: 60 height: 60
anchors.centerIn: parent anchors.centerIn: parent
radius: Theme.geometry.pillRadius
tint: osdWindow.levelColor tint: osdWindow.levelColor
glow: true glow: true
@@ -0,0 +1,589 @@
import QtQuick
import Quickshell
import Quickshell.Wayland
import Quickshell.Io
import Quickshell.Services.Pipewire
import Quickshell.Services.Mpris
import Quickshell.Networking
import Quickshell.Bluetooth
import "../Shared"
PanelWindow {
id: qsWindow
property QtObject rootState
readonly property int panelWidth: 380
visible: rootState.quickSettingsOpen
// Spans the whole screen (like the other overlays) purely so the
// click-outside-to-close MouseArea below has somewhere to catch clicks -
// the visible chrome is just the anchored `panel` Surface in the corner.
anchors { top: true; bottom: true; left: true; right: true }
exclusiveZone: 0
color: "transparent"
WlrLayershell.layer: WlrLayer.Overlay
WlrLayershell.namespace: "quickshell-quicksettings"
WlrLayershell.keyboardFocus: WlrKeyboardFocus.Exclusive
// --- Host / uptime ---
property string hostLabel: "localhost"
property string uptimeLabel: ""
Process {
id: hostnameProcess
command: ["hostname"]
running: qsWindow.visible
stdout: StdioCollector { onStreamFinished: qsWindow.hostLabel = this.text.trim() }
}
Process {
id: uptimeProcess
command: ["bash", "-c", "uptime -p | sed 's/^up //'"]
running: qsWindow.visible
stdout: StdioCollector { onStreamFinished: qsWindow.uptimeLabel = this.text.trim() }
}
// --- Brightness (polled only while the panel is open) ---
property real brightnessLevel: 0.5
Timer {
interval: 1000
running: qsWindow.visible
repeat: true
triggeredOnStart: true
onTriggered: brightnessProcess.restart()
}
Process {
id: brightnessProcess
command: ["bash", "-c", "brightnessctl -m 2>/dev/null | awk -F, '{print $4}' | tr -d '%'"]
running: false
function restart() { running = false; running = true; }
stdout: StdioCollector {
onStreamFinished: {
let val = parseInt(this.text);
if (!isNaN(val)) qsWindow.brightnessLevel = val / 100.0;
}
}
}
Process {
id: setBrightnessProcess
running: false
function set(pct) { command = ["brightnessctl", "set", pct + "%"]; running = false; running = true; }
}
// --- Volume (live Pipewire binding) ---
property QtObject sink: Pipewire.defaultAudioSink
property bool sinkReady: sink !== null && sink.ready && sink.audio !== null
property real volumeLevel: sinkReady ? sink.audio.volume : 0.0
// --- Audio sinks (all real hardware/software sinks, for the routing list) ---
readonly property var sinkNodes: Pipewire.nodes.values.filter(n => n.isSink && !n.isStream)
PwObjectTracker {
objects: qsWindow.sinkNodes
}
// --- Wi-Fi / Bluetooth status ---
function wifiNetworkName() {
let devices = Networking.devices ? Networking.devices.values : [];
for (const d of devices) {
if (d.type === DeviceType.Wifi && d.networks) {
for (const n of d.networks.values) if (n.connected) return n.name;
}
}
return "";
}
function bluetoothDeviceName() {
let adapter = Bluetooth.defaultAdapter;
if (!adapter || !adapter.devices) return "";
for (const d of adapter.devices.values) if (d.connected) return d.name || d.deviceName;
return "";
}
// --- Night light: only wire the toggle to a binary that's actually installed ---
property string nightLightBinary: ""
property bool nightLightOn: false
Process {
id: nightLightDetect
command: ["bash", "-c", "command -v gammastep || command -v wlsunset || true"]
running: true
stdout: StdioCollector { onStreamFinished: qsWindow.nightLightBinary = this.text.trim() }
}
Process {
id: nightLightProcess
running: false
function toggle() {
if (qsWindow.nightLightBinary.length === 0) return;
if (qsWindow.nightLightOn) {
command = ["pkill", "-f", qsWindow.nightLightBinary];
} else {
command = [qsWindow.nightLightBinary];
}
running = false;
running = true;
qsWindow.nightLightOn = !qsWindow.nightLightOn;
}
}
// --- Media player (first available MPRIS source) ---
readonly property var player: Mpris.players.values.length > 0 ? Mpris.players.values[0] : null
MouseArea {
anchors.fill: parent
onClicked: rootState.quickSettingsOpen = false
}
Item {
anchors.fill: parent
focus: qsWindow.visible
Keys.onEscapePressed: (event) => { rootState.quickSettingsOpen = false; event.accepted = true; }
}
Surface {
id: panel
anchors.top: parent.top
anchors.right: parent.right
anchors.topMargin: 12
anchors.rightMargin: 12
width: qsWindow.panelWidth
height: content.implicitHeight + Theme.geometry.padding * 2
tint: Theme.colors.primary
glow: true
MouseArea { anchors.fill: parent } // absorb clicks so they don't fall through to the backdrop
Column {
id: content
anchors.left: parent.left
anchors.right: parent.right
anchors.top: parent.top
anchors.margins: Theme.geometry.padding
spacing: Theme.geometry.spacing * 1.5
// --- Header ---
Item {
width: parent.width
height: 44
Row {
anchors.left: parent.left
anchors.verticalCenter: parent.verticalCenter
spacing: Theme.geometry.spacing
Rectangle {
width: 44
height: 44
color: Theme.colors.surfaceHover
border.width: Theme.geometry.borderWidth
border.color: Theme.colors.crust
Text {
anchors.centerIn: parent
text: Quickshell.env("USER").charAt(0).toUpperCase()
font.family: Theme.font.headlineFamily
font.bold: true
font.pixelSize: 20
color: Theme.colors.primary
}
}
Column {
anchors.verticalCenter: parent.verticalCenter
spacing: 2
Text {
text: Quickshell.env("USER") + "@" + qsWindow.hostLabel
color: Theme.colors.text
font.family: Theme.font.family
font.bold: true
font.pixelSize: Theme.type.label
}
Text {
text: "UP " + qsWindow.uptimeLabel
color: Theme.colors.textMuted
font.family: Theme.font.family
font.pixelSize: Theme.type.caption
}
}
}
Rectangle {
anchors.right: parent.right
anchors.verticalCenter: parent.verticalCenter
width: 28
height: 28
color: "transparent"
border.width: Theme.geometry.borderWidth
border.color: Theme.colors.alert
Text {
anchors.centerIn: parent
text: "PWR"
color: Theme.colors.alert
font.family: Theme.font.family
font.bold: true
font.pixelSize: 9
}
MouseArea {
anchors.fill: parent
cursorShape: Qt.PointingHandCursor
onClicked: {
rootState.quickSettingsOpen = false;
rootState.logoutMenuOpen = true;
}
}
}
}
// --- 2x2 toggle grid ---
Grid {
width: parent.width
columns: 2
rowSpacing: Theme.geometry.spacing
columnSpacing: Theme.geometry.spacing
ToggleTile {
label: "Wi-Fi"
sub: on ? (qsWindow.wifiNetworkName() || "Connected") : "Disabled"
on: Networking.wifiEnabled
accent: Theme.colors.primary
onToggledSwitch: Networking.wifiEnabled = !Networking.wifiEnabled
}
ToggleTile {
label: "Bluetooth"
sub: on ? (qsWindow.bluetoothDeviceName() || "On") : "Disabled"
on: Bluetooth.defaultAdapter ? Bluetooth.defaultAdapter.enabled : false
accent: Theme.colors.secondary
onToggledSwitch: {
if (Bluetooth.defaultAdapter) Bluetooth.defaultAdapter.enabled = !Bluetooth.defaultAdapter.enabled;
}
}
ToggleTile {
label: "Do Not Disturb"
sub: on ? "Notifications Off" : "Notifications On"
on: rootState.dndEnabled
accent: Theme.colors.warning
onToggledSwitch: rootState.dndEnabled = !rootState.dndEnabled
}
ToggleTile {
label: "Night Light"
sub: qsWindow.nightLightBinary.length === 0 ? "Unavailable" : (on ? "Enabled" : "Disabled")
on: qsWindow.nightLightOn
enabled: qsWindow.nightLightBinary.length > 0
accent: Theme.colors.tertiary
onToggledSwitch: nightLightProcess.toggle()
}
}
// --- Sliders ---
Column {
width: parent.width
spacing: Theme.geometry.spacing
Column {
width: parent.width
spacing: Theme.geometry.spacing / 2
Item {
width: parent.width
height: 16
Text {
anchors.left: parent.left
text: "OUTPUT LEVEL"
color: Theme.colors.textMuted
font.family: Theme.font.family
font.bold: true
font.pixelSize: Theme.type.caption
}
Text {
anchors.right: parent.right
text: Math.round(qsWindow.volumeLevel * 100) + "%"
color: Theme.colors.text
font.family: Theme.font.family
font.bold: true
font.pixelSize: Theme.type.caption
}
}
MouseArea {
width: parent.width
height: 16
function apply(mx) {
if (!qsWindow.sinkReady) return;
qsWindow.sink.audio.volume = Math.max(0, Math.min(1, mx / width));
}
onPressed: (mouse) => apply(mouse.x)
onPositionChanged: (mouse) => { if (pressed) apply(mouse.x); }
ProgressBar {
anchors.verticalCenter: parent.verticalCenter
width: parent.width
value: qsWindow.volumeLevel
fillColor: Theme.colors.secondary
}
}
}
Column {
width: parent.width
spacing: Theme.geometry.spacing / 2
Item {
width: parent.width
height: 16
Text {
anchors.left: parent.left
text: "BRIGHTNESS"
color: Theme.colors.textMuted
font.family: Theme.font.family
font.bold: true
font.pixelSize: Theme.type.caption
}
Text {
anchors.right: parent.right
text: Math.round(qsWindow.brightnessLevel * 100) + "%"
color: Theme.colors.text
font.family: Theme.font.family
font.bold: true
font.pixelSize: Theme.type.caption
}
}
MouseArea {
width: parent.width
height: 16
function apply(mx) {
let pct = Math.round(Math.max(0, Math.min(1, mx / width)) * 100);
qsWindow.brightnessLevel = pct / 100.0;
setBrightnessProcess.set(pct);
}
onPressed: (mouse) => apply(mouse.x)
onPositionChanged: (mouse) => { if (pressed) apply(mouse.x); }
ProgressBar {
anchors.verticalCenter: parent.verticalCenter
width: parent.width
value: qsWindow.brightnessLevel
fillColor: Theme.colors.primary
}
}
}
}
// --- Audio sink routing ---
Column {
width: parent.width
spacing: Theme.geometry.spacing / 2
visible: qsWindow.sinkNodes.length > 0
Repeater {
model: qsWindow.sinkNodes
delegate: ListRow {
width: parent.width
accent: Theme.colors.primary
selected: qsWindow.sink !== null && modelData.id === qsWindow.sink.id
onClicked: Pipewire.preferredDefaultAudioSink = modelData
Text {
anchors.left: parent.left
anchors.verticalCenter: parent.verticalCenter
anchors.right: statusChip.left
anchors.rightMargin: Theme.geometry.spacing
text: modelData.description || modelData.name
color: (qsWindow.sink !== null && modelData.id === qsWindow.sink.id) ? Theme.colors.textOnAccent : Theme.colors.text
font.family: Theme.font.family
font.pixelSize: Theme.type.caption
elide: Text.ElideRight
}
Text {
id: statusChip
anchors.right: parent.right
anchors.verticalCenter: parent.verticalCenter
text: (qsWindow.sink !== null && modelData.id === qsWindow.sink.id) ? "DEFAULT" : ""
color: Theme.colors.textOnAccent
font.family: Theme.font.family
font.bold: true
font.pixelSize: Theme.type.caption
}
}
}
}
// --- Media player ---
Surface {
width: parent.width
height: 96
visible: qsWindow.player !== null
color: Theme.colors.surface
tint: Theme.colors.tertiary
Column {
anchors.fill: parent
anchors.margins: Theme.geometry.spacing
spacing: Theme.geometry.spacing / 2
Row {
width: parent.width
spacing: Theme.geometry.spacing
Text {
text: "♪"
color: Theme.colors.tertiary
font.family: Theme.font.family
font.pixelSize: 18
}
Column {
anchors.verticalCenter: parent.verticalCenter
Text {
text: qsWindow.player ? qsWindow.player.trackTitle : ""
color: Theme.colors.text
font.family: Theme.font.family
font.bold: true
font.pixelSize: Theme.type.caption
elide: Text.ElideRight
width: 260
}
Text {
text: qsWindow.player ? qsWindow.player.trackArtist : ""
color: Theme.colors.textMuted
font.family: Theme.font.family
font.pixelSize: Theme.type.caption
elide: Text.ElideRight
width: 260
}
}
}
ProgressBar {
width: parent.width
value: (qsWindow.player && qsWindow.player.length > 0) ? qsWindow.player.position / qsWindow.player.length : 0
fillColor: Theme.colors.tertiary
}
Row {
anchors.horizontalCenter: parent.horizontalCenter
spacing: Theme.geometry.spacing * 1.5
Text {
text: "◀"
color: Theme.colors.text
font.family: Theme.font.family
font.pixelSize: 14
MouseArea { anchors.fill: parent; anchors.margins: -6; cursorShape: Qt.PointingHandCursor; onClicked: qsWindow.player && qsWindow.player.previous() }
}
Text {
text: (qsWindow.player && qsWindow.player.isPlaying) ? "II" : "▶"
color: Theme.colors.tertiary
font.family: Theme.font.family
font.bold: true
font.pixelSize: 14
MouseArea { anchors.fill: parent; anchors.margins: -6; cursorShape: Qt.PointingHandCursor; onClicked: qsWindow.player && qsWindow.player.togglePlaying() }
}
Text {
text: "▶"
color: Theme.colors.text
font.family: Theme.font.family
font.pixelSize: 14
MouseArea { anchors.fill: parent; anchors.margins: -6; cursorShape: Qt.PointingHandCursor; onClicked: qsWindow.player && qsWindow.player.next() }
}
}
}
}
// --- Footer ---
Row {
width: parent.width
spacing: Theme.geometry.spacing / 2
Rectangle {
width: 8
height: 8
anchors.verticalCenter: parent.verticalCenter
color: Theme.colors.success
border.width: Theme.geometry.borderWidth
border.color: Theme.colors.crust
}
Text {
text: "STATUS: OK"
color: Theme.colors.textMuted
font.family: Theme.font.family
font.bold: true
font.pixelSize: Theme.type.caption
}
}
}
}
// Inline component for a 2x2 toggle tile.
component ToggleTile: Surface {
id: tile
property string label: ""
property string sub: ""
property bool on: false
property color accent: Theme.colors.primary
signal toggledSwitch()
width: (qsWindow.panelWidth - Theme.geometry.padding * 2 - Theme.geometry.spacing) / 2
height: 68
color: Theme.colors.surface
tint: on ? accent : Theme.colors.border
glow: on
opacity: enabled ? 1.0 : 0.5
Item {
anchors.fill: parent
anchors.margins: Theme.geometry.spacing
Column {
anchors.left: parent.left
anchors.right: toggleSwitch.left
anchors.rightMargin: Theme.geometry.spacing / 2
anchors.verticalCenter: parent.verticalCenter
spacing: 2
Text {
text: tile.label
color: Theme.colors.text
font.family: Theme.font.headlineFamily
font.bold: true
font.pixelSize: Theme.type.body
}
Text {
text: tile.sub
color: Theme.colors.textMuted
font.family: Theme.font.family
font.pixelSize: Theme.type.caption
elide: Text.ElideRight
width: parent.width
}
}
ToggleSwitch {
id: toggleSwitch
anchors.right: parent.right
anchors.verticalCenter: parent.verticalCenter
checked: tile.on
onColor: tile.accent
onToggled: tile.toggledSwitch()
}
}
}
}
@@ -1,8 +1,7 @@
import QtQuick import QtQuick
import QtQuick.Effects
import "." import "."
Rectangle { Surface {
id: button id: button
// "primary" | "secondary" | "accent" | "destructive" | "success" | "warning" | "info" // "primary" | "secondary" | "accent" | "destructive" | "success" | "warning" | "info"
@@ -13,7 +12,7 @@ Rectangle {
// primary and accent are the same color (Theme.colors.primary === .accent); // primary and accent are the same color (Theme.colors.primary === .accent);
// kept as separate variant names for call-site clarity. // kept as separate variant names for call-site clarity.
readonly property bool filled: variant === "primary" || variant === "accent" readonly property bool filled: variant === "primary" || variant === "accent"
readonly property color tint: variant === "accent" ? Theme.colors.accent readonly property color variantColor: variant === "accent" ? Theme.colors.accent
: variant === "destructive" ? Theme.colors.alert : variant === "destructive" ? Theme.colors.alert
: variant === "success" ? Theme.colors.success : variant === "success" ? Theme.colors.success
: variant === "warning" ? Theme.colors.warning : variant === "warning" ? Theme.colors.warning
@@ -22,35 +21,27 @@ Rectangle {
implicitWidth: label.implicitWidth + Theme.geometry.padding * 2 implicitWidth: label.implicitWidth + Theme.geometry.padding * 2
implicitHeight: label.implicitHeight + Theme.geometry.padding implicitHeight: label.implicitHeight + Theme.geometry.padding
width: implicitWidth
height: implicitHeight
radius: Theme.geometry.radiusSmall
color: filled color: filled
? (mouseArea.pressed ? Qt.darker(tint, 1.1) : tint) ? (mouseArea.containsMouse ? Qt.lighter(variantColor, 1.15) : variantColor)
: (mouseArea.containsMouse ? Qt.alpha(tint, 0.22) : Qt.alpha(tint, 0.15)) : (mouseArea.containsMouse ? Theme.colors.surfaceHover : Theme.colors.surface)
border.width: filled ? 0 : 1 tint: variantColor
border.color: Qt.alpha(tint, 0.3) glow: !filled && mouseArea.containsMouse
pressed: mouseArea.pressed
layer.enabled: filled
layer.effect: MultiEffect {
shadowEnabled: true
shadowColor: button.tint
shadowOpacity: Theme.elevation.medium.opacity
shadowBlur: Theme.elevation.medium.blur
shadowVerticalOffset: 2
}
Behavior on color { ColorAnimation { duration: Theme.animation.durationFast } } Behavior on color { ColorAnimation { duration: Theme.animation.durationFast } }
Behavior on scale { SpringAnimation { spring: Theme.motion.springSnappy.spring; damping: Theme.motion.springSnappy.damping } }
scale: mouseArea.pressed ? 0.97 : 1.0
Text { Text {
id: label id: label
anchors.centerIn: parent anchors.centerIn: parent
text: button.text text: button.text
font.family: Theme.font.family font.family: Theme.font.headlineFamily
font.pixelSize: 13 font.pixelSize: 14
font.bold: true font.bold: true
color: button.filled ? Theme.colors.background : button.tint font.capitalization: Font.AllUppercase
color: button.filled ? Theme.colors.textOnAccent : button.variantColor
} }
MouseArea { MouseArea {
@@ -0,0 +1,36 @@
import QtQuick
import "."
// 18x18 square checkbox with a 10x10 solid core when checked, per
// DESIGN.md's Checkboxes spec.
Item {
id: box
// Controlled component - see ToggleSwitch.qml.
property bool checked: false
signal toggled()
implicitWidth: 18
implicitHeight: 18
Rectangle {
anchors.fill: parent
color: Theme.colors.surface
border.width: Theme.geometry.borderWidth
border.color: Theme.colors.crust
Rectangle {
width: 10
height: 10
anchors.centerIn: parent
color: Theme.colors.primary
visible: box.checked
}
}
MouseArea {
anchors.fill: parent
cursorShape: Qt.PointingHandCursor
onClicked: box.toggled()
}
}
@@ -14,7 +14,7 @@ Rectangle {
radius: Theme.geometry.radiusMedium radius: Theme.geometry.radiusMedium
color: Theme.colors.background color: Theme.colors.background
border.color: Theme.colors.border border.color: Theme.colors.border
border.width: 1 border.width: Theme.geometry.borderWidth
height: column.implicitHeight + Theme.geometry.spacing height: column.implicitHeight + Theme.geometry.spacing
function openAt(px, py) { function openAt(px, py) {
@@ -1,7 +1,7 @@
import QtQuick import QtQuick
import "." import "."
// Row of "key label" keyboard hints shown under launcher-style overlays, // Row of "[KEY] label" keyboard hints shown under launcher-style overlays,
// e.g. [ [↑↓, "Navigate"], ["↵", "Launch"], ["Esc", "Close"] ]. // e.g. [ [↑↓, "Navigate"], ["↵", "Launch"], ["Esc", "Close"] ].
Row { Row {
id: hintBar id: hintBar
@@ -16,12 +16,16 @@ Row {
delegate: Row { delegate: Row {
spacing: Theme.geometry.spacing / 2 spacing: Theme.geometry.spacing / 2
Text { Pill {
text: modelData.key tint: Theme.colors.outlineVariant
color: Theme.colors.textMuted
font.family: Theme.font.family Text {
font.bold: true text: "[" + modelData.key + "]"
font.pixelSize: Theme.type.caption color: Theme.colors.text
font.family: Theme.font.family
font.bold: true
font.pixelSize: Theme.type.caption
}
} }
Text { Text {
@@ -29,6 +33,7 @@ Row {
color: Theme.colors.textMuted color: Theme.colors.textMuted
font.family: Theme.font.family font.family: Theme.font.family
font.pixelSize: Theme.type.caption font.pixelSize: Theme.type.caption
anchors.verticalCenter: parent.verticalCenter
} }
} }
} }
@@ -1,8 +1,8 @@
import QtQuick import QtQuick
import "." import "."
// Selectable list row: a colored left accent bar plus a tinted background // Selectable list row: solid accent fill + crust text when selected (not a
// when current, shared by CommandPalette and ClipboardManager so both // soft tint), shared by CommandPalette and ClipboardManager so both
// launchers read as the same design language. // launchers read as the same design language.
Rectangle { Rectangle {
id: row id: row
@@ -16,25 +16,20 @@ Rectangle {
signal entered() signal entered()
height: 40 height: 40
radius: Theme.geometry.radiusTiny color: selected ? accent : (hovered ? Theme.colors.surfaceHover : "transparent")
color: selected ? Qt.alpha(accent, 0.16) : "transparent" border.width: selected ? Theme.geometry.borderWidth : 0
border.color: Theme.colors.crust
Behavior on color { ColorAnimation { duration: Theme.animation.durationFast } } Behavior on color { ColorAnimation { duration: Theme.animation.durationFast } }
Rectangle { Rectangle {
width: 3 width: 4
height: parent.height - 10 height: parent.height
anchors.verticalCenter: parent.verticalCenter
anchors.left: parent.left anchors.left: parent.left
radius: 2 color: Theme.colors.crust
color: row.accent visible: row.selected
opacity: row.selected ? 1 : 0
Behavior on opacity { NumberAnimation { duration: Theme.animation.durationFast } }
} }
// Declared before contentItem so any interactive child placed in
// `content` (e.g. a hover delete button) stacks on top and can
// intercept clicks before they fall through to this row-wide handler.
MouseArea { MouseArea {
id: rowMouse id: rowMouse
anchors.fill: parent anchors.fill: parent
@@ -47,7 +42,9 @@ Rectangle {
Item { Item {
id: contentItem id: contentItem
anchors.fill: parent anchors.fill: parent
anchors.leftMargin: Theme.geometry.padding + 4 anchors.leftMargin: Theme.geometry.padding + ((row.selected || row.hovered) ? 8 : 4)
anchors.rightMargin: Theme.geometry.padding anchors.rightMargin: Theme.geometry.padding
Behavior on anchors.leftMargin { NumberAnimation { duration: Theme.animation.durationFast; easing.type: Easing.Linear } }
} }
} }
@@ -1,54 +1,46 @@
import QtQuick import QtQuick
import QtQuick.Effects
import "." import "."
// Bar-style pill chrome: rounded surface, border, optional colored glow. // Status chip / telemetry badge: sharp corners, 2px border, a tight 2px
// Children are centered in an internal Row - place them directly as this // offset shadow (deliberately smaller than Surface's, per DESIGN.md's
// component's children, same as putting them in a Row. // "Status Chips & Telemetry Badges" spec). Children are centered in an
Rectangle { // internal Row - place them directly as this component's children, same as
// putting them in a Row.
Item {
id: pill id: pill
property color tint: Theme.colors.border property color tint: Theme.colors.outlineVariant
property bool glow: false property bool glow: false
// How strongly `tint` is mixed into the base surface color, so each
// pill reads as its own tinted background instead of one flat surface
// color with only the border/glow varying.
property real tintStrength: 0.35
default property alias content: contentRow.data default property alias content: contentRow.data
function blend(base, mix, amount) { readonly property color edgeColor: glow ? tint : Theme.colors.crust
return Qt.rgba( readonly property int offset: 2
base.r + (mix.r - base.r) * amount,
base.g + (mix.g - base.g) * amount,
base.b + (mix.b - base.b) * amount,
base.a
);
}
implicitWidth: contentRow.implicitWidth + Theme.geometry.padding * 2 implicitWidth: contentRow.implicitWidth + Theme.geometry.padding * 2 + offset
implicitHeight: contentRow.implicitHeight + Theme.geometry.padding implicitHeight: contentRow.implicitHeight + Theme.geometry.spacing + offset
height: implicitHeight height: implicitHeight
radius: Theme.geometry.pillRadius
color: blend(Theme.colors.surface, tint, tintStrength)
border.color: tint
border.width: 1
Behavior on color { ColorAnimation { duration: Theme.animation.durationNormal } } Rectangle {
x: pill.offset
Behavior on border.color { ColorAnimation { duration: Theme.animation.durationFast } } y: pill.offset
width: pill.width - pill.offset
layer.enabled: glow height: pill.height - pill.offset
layer.effect: MultiEffect { color: pill.edgeColor
shadowEnabled: true
shadowColor: pill.tint
shadowOpacity: Theme.elevation.low.opacity
shadowBlur: Theme.elevation.low.blur
shadowVerticalOffset: 1
} }
Row { Rectangle {
id: contentRow width: pill.width - pill.offset
anchors.centerIn: parent height: pill.height - pill.offset
spacing: Theme.geometry.spacing color: Theme.colors.surface
border.width: Theme.geometry.borderWidth
border.color: pill.edgeColor
Behavior on border.color { ColorAnimation { duration: Theme.animation.durationFast } }
Row {
id: contentRow
anchors.centerIn: parent
spacing: Theme.geometry.spacing
}
} }
} }
@@ -1,25 +1,28 @@
import QtQuick import QtQuick
import "." import "."
// Colored fill bar for OSD volume/brightness and similar level readouts. // Sharp-cornered track+fill for OSD volume/brightness and similar level
// readouts, and the base for slider-style controls in Quick Settings.
Item { Item {
id: bar id: bar
property real value: 0 // 0..1 property real value: 0 // 0..1
property color fillColor: Theme.colors.primary property color fillColor: Theme.colors.primary
height: 8 height: 10
Rectangle { Rectangle {
anchors.fill: parent anchors.fill: parent
color: Theme.colors.surfaceHover color: Theme.colors.surfaceHover
radius: height / 2 border.width: Theme.geometry.borderWidth
border.color: Theme.colors.crust
clip: true clip: true
Rectangle { Rectangle {
width: parent.width * Math.max(0, Math.min(1, bar.value)) width: Math.max(0, parent.width * Math.max(0, Math.min(1, bar.value)) - parent.border.width * 2)
height: parent.height height: parent.height - parent.border.width * 2
radius: parent.radius x: parent.border.width
y: parent.border.width
color: bar.fillColor color: bar.fillColor
Behavior on width { NumberAnimation { duration: Theme.animation.durationFast } } Behavior on width { NumberAnimation { duration: Theme.animation.durationFast } }
@@ -1,26 +1,47 @@
import QtQuick import QtQuick
import QtQuick.Effects
import "." import "."
// Base panel/card chrome shared by menus, pickers, and dialogs: rounded // Base panel/card chrome shared by menus, pickers, and dialogs: sharp
// background, border, optional colored glow. // corners, a solid 2px border, and a hard offset "shadow" - a flat duplicate
Rectangle { // rectangle displaced down-right, never blurred. `glow` switches the border
// and shadow from the default crust to `tint` (DESIGN.md's "Focused /
// Active" state, also used for danger/selected emphasis). `pressed`
// collapses the shadow and slides the face onto it - the mechanical
// depression press effect. Children declared on a Surface instance attach
// to the face, not the outer Item, so they translate together with it.
Item {
id: surface id: surface
property color tint: Theme.colors.border default property alias content: face.data
property alias color: face.color
property color tint: Theme.colors.primary
property bool glow: false property bool glow: false
property bool pressed: false
radius: Theme.geometry.radiusMedium readonly property int offset: glow ? Theme.elevation.high : Theme.elevation.low
color: Theme.colors.background readonly property color edgeColor: glow ? tint : Theme.colors.crust
border.color: tint
border.width: 1
layer.enabled: glow Rectangle {
layer.effect: MultiEffect { id: shadow
shadowEnabled: true x: surface.offset
shadowColor: surface.tint y: surface.offset
shadowOpacity: Theme.elevation.medium.opacity width: surface.width
shadowBlur: Theme.elevation.medium.blur height: surface.height
shadowVerticalOffset: 2 color: surface.edgeColor
visible: !surface.pressed
}
Rectangle {
id: face
x: surface.pressed ? surface.offset : 0
y: surface.pressed ? surface.offset : 0
width: surface.width
height: surface.height
color: Theme.colors.background
border.width: Theme.geometry.borderWidth
border.color: surface.edgeColor
Behavior on x { NumberAnimation { duration: Theme.animation.durationFast; easing.type: Easing.Linear } }
Behavior on y { NumberAnimation { duration: Theme.animation.durationFast; easing.type: Easing.Linear } }
} }
} }
@@ -1,17 +1,18 @@
import QtQuick import QtQuick
import QtQuick.Effects
import "." import "."
// Search/filter input with an animated focus border + glow, shared by // Search/filter input with a hard focus border + shadow, shared by
// CommandPalette and ClipboardManager. Navigation is exposed as signals // CommandPalette and ClipboardManager. Navigation is exposed as signals
// (rather than exposing the inner TextInput's Keys handlers directly) so // (rather than exposing the inner TextInput's Keys handlers directly) so
// each caller can wire up its own list navigation. // each caller can wire up its own list navigation.
Rectangle { Item {
id: field id: field
property alias text: input.text property alias text: input.text
property alias echoMode: input.echoMode property alias echoMode: input.echoMode
property alias passwordCharacter: input.passwordCharacter
property string placeholder: "" property string placeholder: ""
property string prefix: ""
signal escapePressed() signal escapePressed()
signal upPressed() signal upPressed()
@@ -21,6 +22,12 @@ Rectangle {
function focusInput() { input.forceActiveFocus(); } function focusInput() { input.forceActiveFocus(); }
readonly property bool focused: input.activeFocus
readonly property color edgeColor: focused ? Theme.colors.primary : Theme.colors.crust
readonly property int offset: focused ? Theme.elevation.high : Theme.elevation.low
height: 50
// The layer-shell surface only gets real keyboard focus from the // The layer-shell surface only gets real keyboard focus from the
// compositor asynchronously after it's first mapped, so a single // compositor asynchronously after it's first mapped, so a single
// forceActiveFocus() call right on visible-toggle can silently lose // forceActiveFocus() call right on visible-toggle can silently lose
@@ -34,51 +41,70 @@ Rectangle {
onTriggered: input.forceActiveFocus() onTriggered: input.forceActiveFocus()
} }
height: 50 Rectangle {
color: Theme.colors.surface x: field.offset
radius: Theme.geometry.radiusSmall y: field.offset
border.width: 1 width: field.width
border.color: input.activeFocus ? Theme.colors.primary : Theme.colors.border height: field.height
color: field.edgeColor
Behavior on border.color { ColorAnimation { duration: Theme.animation.durationFast } }
layer.enabled: input.activeFocus
layer.effect: MultiEffect {
shadowEnabled: true
shadowColor: Theme.colors.primary
shadowOpacity: Theme.elevation.low.opacity
shadowBlur: Theme.elevation.low.blur
shadowHorizontalOffset: 0
shadowVerticalOffset: 0
} }
TextInput { Rectangle {
id: input width: field.width
anchors.fill: parent height: field.height
anchors.margins: Theme.geometry.padding color: Theme.colors.surface
verticalAlignment: TextInput.AlignVCenter border.width: Theme.geometry.borderWidth
font.family: Theme.font.family border.color: field.edgeColor
font.pixelSize: 18
color: Theme.colors.text Behavior on border.color { ColorAnimation { duration: Theme.animation.durationFast } }
clip: true
Text { Text {
text: field.placeholder id: prefixText
color: Theme.colors.textMuted text: field.prefix
visible: field.prefix.length > 0
color: Theme.colors.secondary
font.family: Theme.font.family font.family: Theme.font.family
font.bold: true
font.pixelSize: 18 font.pixelSize: 18
anchors.left: parent.left
anchors.leftMargin: Theme.geometry.padding
anchors.verticalCenter: parent.verticalCenter anchors.verticalCenter: parent.verticalCenter
visible: input.text.length === 0
} }
Keys.onEscapePressed: (event) => { field.escapePressed(); event.accepted = true; } TextInput {
Keys.onUpPressed: (event) => { field.upPressed(); event.accepted = true; } id: input
Keys.onDownPressed: (event) => { field.downPressed(); event.accepted = true; } anchors.fill: parent
Keys.onReturnPressed: (event) => { field.returnPressed(); event.accepted = true; } anchors.margins: Theme.geometry.padding
Keys.onPressed: (event) => { anchors.leftMargin: field.prefix.length > 0 ? prefixText.width + Theme.geometry.padding + Theme.geometry.spacing / 2 : Theme.geometry.padding
if (event.key === Qt.Key_Delete || (event.key === Qt.Key_Backspace && input.text.length === 0)) { verticalAlignment: TextInput.AlignVCenter
field.deleteRequested(); font.family: Theme.font.family
event.accepted = true; font.pixelSize: 18
color: Theme.colors.text
clip: true
cursorDelegate: Rectangle {
width: 9
color: Theme.colors.primary
}
Text {
text: field.placeholder
color: Theme.colors.textMuted
font.family: Theme.font.family
font.pixelSize: 18
anchors.verticalCenter: parent.verticalCenter
visible: input.text.length === 0
}
Keys.onEscapePressed: (event) => { field.escapePressed(); event.accepted = true; }
Keys.onUpPressed: (event) => { field.upPressed(); event.accepted = true; }
Keys.onDownPressed: (event) => { field.downPressed(); event.accepted = true; }
Keys.onReturnPressed: (event) => { field.returnPressed(); event.accepted = true; }
Keys.onPressed: (event) => {
if (event.key === Qt.Key_Delete || (event.key === Qt.Key_Backspace && input.text.length === 0)) {
field.deleteRequested();
event.accepted = true;
}
} }
} }
} }
@@ -5,61 +5,70 @@ QtObject {
id: theme id: theme
// Regenerated by wallpaper-theme.nu on every wallpaper change - don't // Regenerated by wallpaper-theme.nu on every wallpaper change - don't
// hand-edit between these markers, it gets overwritten. // hand-edit between these markers, it gets overwritten. Colors are
// always opaque (no alpha blending) per the neo-brutalist system: solid
// blocks, no soft/translucent surfaces. `overlay` is the one exception
// (a full-screen dimming scrim, not a card surface).
// GENERATED:COLORS:BEGIN // GENERATED:COLORS:BEGIN
property QtObject colors: QtObject { property QtObject colors: QtObject {
property color background: "#e611111b" property color background: "#1e1e2e"
property color surface: "#cc181825" property color surface: "#181825"
property color surfaceHover: "#f2313244" property color surfaceHover: "#313244"
property color overlay: "#6011111b" property color overlay: "#cc11111b"
property color primary: "#74c7ec" property color crust: "#11111b"
property color outlineVariant: "#45475a"
property color primary: "#eba0ac"
property color secondary: "#cba6f7" property color secondary: "#cba6f7"
property color tertiary: "#a6e3a1" property color tertiary: "#f2cdcd"
property color accent: "#74c7ec" property color accent: "#eba0ac"
property color primaryContainer: "#2474c7ec" property color primaryContainer: "#695363"
property color secondaryContainer: "#24cba6f7" property color secondaryContainer: "#5f557a"
property color tertiaryContainer: "#24a6e3a1" property color tertiaryContainer: "#6b616d"
property color alert: "#f38ba8" property color alert: "#f38ba8"
property color alertContainer: "#24f38ba8" property color alertContainer: "#6b4d62"
property color success: "#a6e3a1" property color success: "#a6e3a1"
property color successContainer: "#24a6e3a1" property color successContainer: "#546760"
property color warning: "#f9e2af" property color warning: "#f9e2af"
property color warningContainer: "#24f9e2af" property color warningContainer: "#6d6764"
property color info: "#74c7ec" property color info: "#74c7ec"
property color infoContainer: "#2474c7ec" property color infoContainer: "#455f76"
property color text: "#cdd6f4" property color text: "#cdd6f4"
property color textMuted: "#a6adc8" property color textMuted: "#a6adc8"
property color textOnAccent: "#e611111b" property color textOnAccent: "#11111b"
property color border: "#1a74c7ec" property color border: "#11111b"
} }
// GENERATED:COLORS:END // GENERATED:COLORS:END
property QtObject geometry: QtObject { property QtObject geometry: QtObject {
property int radiusTiny: 6 property int radiusTiny: 0
property int radiusSmall: 8 property int radiusSmall: 0
property int radiusMedium: 10 property int radiusMedium: 0
property int pillRadius: 100 property int pillRadius: 0
property int padding: 12 property int padding: 12
property int spacing: 8 property int spacing: 8
property int borderWidth: 2
} }
property QtObject animation: QtObject { property QtObject animation: QtObject {
property int durationFast: 150 property int durationFast: 100
property int durationNormal: 250 property int durationNormal: 150
property int durationSlow: 400 property int durationSlow: 250
} }
// Named spring presets, so call sites stop hand-rolling // Hard offset-shadow steps (px), replacing the old blur/glow elevation
// `SpringAnimation { spring: 4; damping: 0.3 }` with slightly different // system. No blur, ever - depth comes from a flat displaced duplicate
// numbers each time. // rectangle. `high` is used for the focused/active accent-colored
property QtObject motion: QtObject { // variant; `overlay` for big floating surfaces (launcher, modals).
property QtObject springSnappy: QtObject { property real spring: 4; property real damping: 0.3 } property QtObject elevation: QtObject {
property QtObject springSoft: QtObject { property real spring: 3; property real damping: 0.2 } property int low: 4
property int high: 6
property int overlay: 8
} }
// Type scale. Family stays fixed - this is only about size/weight steps. // Type scale. Family stays fixed - this is only about size/weight steps.
@@ -77,15 +86,8 @@ QtObject {
property int large: 24 property int large: 24
} }
// Named shadow presets for MultiEffect glows, keyed by how prominent the
// glow should read (e.g. hover vs. focus vs. an always-on active state).
property QtObject elevation: QtObject {
property QtObject low: QtObject { property real blur: 0.4; property real opacity: 0.35 }
property QtObject medium: QtObject { property real blur: 0.6; property real opacity: 0.5 }
property QtObject high: QtObject { property real blur: 0.8; property real opacity: 0.65 }
}
property QtObject font: QtObject { property QtObject font: QtObject {
property string family: "JetBrainsMono Nerd Font" property string family: "JetBrainsMono Nerd Font"
property string headlineFamily: "Plus Jakarta Sans"
} }
} }
@@ -0,0 +1,44 @@
import QtQuick
import "."
// Rectangular tray + square thumb toggle, per DESIGN.md: 36x20 tray, 12x12
// thumb that translates (never curves) between two hard-stop positions.
Item {
id: toggle
// Controlled component: clicking never mutates `checked` itself, it
// only requests a change via `toggled()` - the caller owns the real
// state (usually a live system property) and rebinds `checked` to it.
property bool checked: false
property color onColor: Theme.colors.success
signal toggled()
implicitWidth: 36
implicitHeight: 20
Rectangle {
anchors.fill: parent
color: toggle.checked ? toggle.onColor : Theme.colors.surface
border.width: Theme.geometry.borderWidth
border.color: Theme.colors.crust
Behavior on color { ColorAnimation { duration: Theme.animation.durationFast } }
Rectangle {
id: thumb
width: 12
height: 12
y: (parent.height - height) / 2
x: toggle.checked ? parent.width - width - 4 : 4
color: Theme.colors.crust
Behavior on x { NumberAnimation { duration: Theme.animation.durationFast; easing.type: Easing.Linear } }
}
}
MouseArea {
anchors.fill: parent
cursorShape: Qt.PointingHandCursor
onClicked: toggle.toggled()
}
}
@@ -11,7 +11,7 @@ Rectangle {
radius: Theme.geometry.radiusMedium radius: Theme.geometry.radiusMedium
color: Theme.colors.background color: Theme.colors.background
border.color: Theme.colors.border border.color: Theme.colors.border
border.width: 1 border.width: Theme.geometry.borderWidth
width: label.implicitWidth + Theme.geometry.padding * 2 width: label.implicitWidth + Theme.geometry.padding * 2
height: label.implicitHeight + Theme.geometry.padding height: label.implicitHeight + Theme.geometry.padding
@@ -9,3 +9,5 @@ Tooltip 1.0 Tooltip.qml
Showcase 1.0 Showcase.qml Showcase 1.0 Showcase.qml
ListRow 1.0 ListRow.qml ListRow 1.0 ListRow.qml
HintBar 1.0 HintBar.qml HintBar 1.0 HintBar.qml
ToggleSwitch 1.0 ToggleSwitch.qml
Checkbox 1.0 Checkbox.qml
@@ -121,7 +121,6 @@ PanelWindow {
height: isCurrent ? 320 : 200 height: isCurrent ? 320 : 200
color: Theme.colors.surface color: Theme.colors.surface
tint: delegateRoot.isCurrent ? Theme.colors.primary : Theme.colors.border tint: delegateRoot.isCurrent ? Theme.colors.primary : Theme.colors.border
border.width: delegateRoot.isCurrent ? 2 : 1
opacity: delegateRoot.isCurrent ? 1.0 : 0.5 opacity: delegateRoot.isCurrent ? 1.0 : 0.5
glow: delegateRoot.isCurrent glow: delegateRoot.isCurrent
clip: true clip: true
+33 -17
View File
@@ -11,6 +11,7 @@ import "components/ClipboardManager"
import "components/Notifications" import "components/Notifications"
import "components/WallpaperPicker" import "components/WallpaperPicker"
import "components/LockScreen" import "components/LockScreen"
import "components/QuickSettings"
ShellRoot { ShellRoot {
id: root id: root
@@ -20,15 +21,26 @@ ShellRoot {
property bool logoutMenuOpen: false property bool logoutMenuOpen: false
property bool clipboardManagerOpen: false property bool clipboardManagerOpen: false
property bool wallpaperPickerOpen: false property bool wallpaperPickerOpen: false
property bool quickSettingsOpen: false
property bool dndEnabled: false
// Only one overlay is ever open at once - closing every other one is
// simpler and less error-prone than each toggle() hand-listing its
// siblings (which is how this used to work, and reliably went stale
// every time a new overlay was added).
function closeOtherOverlays(keepOpen) {
if (keepOpen !== "commandPalette") commandPaletteOpen = false;
if (keepOpen !== "logoutMenu") logoutMenuOpen = false;
if (keepOpen !== "clipboardManager") clipboardManagerOpen = false;
if (keepOpen !== "wallpaperPicker") wallpaperPickerOpen = false;
if (keepOpen !== "quickSettings") quickSettingsOpen = false;
}
IpcHandler { IpcHandler {
target: "commandPalette" target: "commandPalette"
function toggle() { function toggle() {
commandPaletteOpen = !commandPaletteOpen; commandPaletteOpen = !commandPaletteOpen;
if (commandPaletteOpen) { if (commandPaletteOpen) closeOtherOverlays("commandPalette");
logoutMenuOpen = false;
clipboardManagerOpen = false;
}
} }
} }
@@ -36,10 +48,7 @@ ShellRoot {
target: "logoutMenu" target: "logoutMenu"
function toggle() { function toggle() {
logoutMenuOpen = !logoutMenuOpen; logoutMenuOpen = !logoutMenuOpen;
if (logoutMenuOpen) { if (logoutMenuOpen) closeOtherOverlays("logoutMenu");
commandPaletteOpen = false;
clipboardManagerOpen = false;
}
} }
} }
@@ -47,10 +56,15 @@ ShellRoot {
target: "clipboardManager" target: "clipboardManager"
function toggle() { function toggle() {
clipboardManagerOpen = !clipboardManagerOpen; clipboardManagerOpen = !clipboardManagerOpen;
if (clipboardManagerOpen) { if (clipboardManagerOpen) closeOtherOverlays("clipboardManager");
commandPaletteOpen = false; }
logoutMenuOpen = false; }
}
IpcHandler {
target: "quickSettings"
function toggle() {
quickSettingsOpen = !quickSettingsOpen;
if (quickSettingsOpen) closeOtherOverlays("quickSettings");
} }
} }
@@ -68,11 +82,7 @@ ShellRoot {
target: "wallpaperSwitcher" target: "wallpaperSwitcher"
function open() { function open() {
wallpaperPickerOpen = !wallpaperPickerOpen; wallpaperPickerOpen = !wallpaperPickerOpen;
if (wallpaperPickerOpen) { if (wallpaperPickerOpen) closeOtherOverlays("wallpaperPicker");
commandPaletteOpen = false;
logoutMenuOpen = false;
clipboardManagerOpen = false;
}
} }
function random() { function random() {
randomWallpaperProcess.running = false; randomWallpaperProcess.running = false;
@@ -117,6 +127,12 @@ ShellRoot {
Notifications { Notifications {
id: notifications id: notifications
rootState: root
}
QuickSettings {
id: quickSettings
rootState: root
} }
WallpaperPicker { WallpaperPicker {