feat: add backlight support

This commit is contained in:
retrozinndev
2025-08-26 16:16:58 -03:00
parent 18cda23bac
commit e84f5f0bdf
4 changed files with 199 additions and 45 deletions
+2 -3
View File
@@ -10,13 +10,12 @@ import AstalHyprland from "gi://AstalHyprland";
const hyprland = AstalHyprland.get_default();
// Fix empty focused-client on opening a window on an empty workspace
hyprland.connect("client-added", () => hyprland.notify("focused-client"));
hyprland.connect("notify::clients", () => hyprland.notify("focused-client"));
export const FocusedClient = () => {
const focusedClient = createBinding(hyprland, "focusedClient");
return <Gtk.Box class={"focused-client"}
visible={variableToBoolean(createBinding(hyprland, "focusedClient"))}>
return <Gtk.Box class={"focused-client"} visible={variableToBoolean(focusedClient)}>
<With value={focusedClient}>
{(focusedClient) => focusedClient?.class && <Gtk.Box>
<Gtk.Image iconName={createBinding(focusedClient, "class").as((clss) =>