refactor(recording): name Waybar icon

This commit is contained in:
2026-10-11 19:47:42 -04:00
parent c50a2c77e8
commit 12304a0951

View File

@@ -6,8 +6,7 @@
}:
# Keybound screen recording: pick a region, then toggle a video-only capture.
let
glyph = code: builtins.fromJSON ''"\u${code}"'';
recordingIcon = builtins.fromJSON ''"\uf03d"'';
# A single key both starts and stops.
# A running wf-recorder is stopped with SIGINT so it finalises the file.
@@ -35,7 +34,7 @@ let
# Empty text collapses the widget when idle, so it shows nothing until then.
recordingStatus = pkgs.writeShellScript "waybar-recording-status" ''
if ${lib.getExe' pkgs.procps "pgrep"} -x wf-recorder >/dev/null; then
printf '{"text":"${glyph "f03d"}","tooltip":"Recording","class":"recording"}\n'
printf '{"text":"${recordingIcon}","tooltip":"Recording","class":"recording"}\n'
else
printf '{"text":"","class":"idle"}\n'
fi