refactor(hyprland): rename keybind action kind

This commit is contained in:
2026-10-10 14:27:52 -04:00
parent 2f9955dfb8
commit a84aa68274
2 changed files with 13 additions and 13 deletions

View File

@@ -17,7 +17,7 @@ let
key key
]; ];
action = { action = {
type = "focus"; kind = "focus";
inherit direction; inherit direction;
}; };
}; };
@@ -31,7 +31,7 @@ let
key key
]; ];
action = { action = {
type = "move-window"; kind = "move-window";
inherit direction; inherit direction;
}; };
}; };
@@ -57,7 +57,7 @@ let
key key
]; ];
action = { action = {
type = "resize-window"; kind = "resize-window";
inherit (delta) x y; inherit (delta) x y;
}; };
}; };
@@ -101,7 +101,7 @@ let
workspaceName workspaceName
]; ];
action = { action = {
type = "focus-workspace"; kind = "focus-workspace";
inherit workspace; inherit workspace;
}; };
}; };
@@ -115,7 +115,7 @@ let
workspaceName workspaceName
]; ];
action = { action = {
type = "move-to-workspace"; kind = "move-to-workspace";
inherit workspace; inherit workspace;
}; };
}; };
@@ -152,7 +152,7 @@ let
"focus-workspace" = "hl.dsp.focus(${toLua { inherit (action) workspace; }})"; "focus-workspace" = "hl.dsp.focus(${toLua { inherit (action) workspace; }})";
"move-to-workspace" = "hl.dsp.window.move(${toLua { inherit (action) workspace; }})"; "move-to-workspace" = "hl.dsp.window.move(${toLua { inherit (action) workspace; }})";
} }
.${action.type} .${action.kind}
); );
keybinds = lib.attrValues ( keybinds = lib.attrValues (
@@ -172,7 +172,7 @@ in
"Return" "Return"
]; ];
action = { action = {
type = "exec"; kind = "exec";
command = "ghostty"; command = "ghostty";
}; };
}; };
@@ -182,7 +182,7 @@ in
"SUPER" "SUPER"
"Space" "Space"
]; ];
action.type = "toggle-floating"; action.kind = "toggle-floating";
}; };
hyprland-fullscreen = { hyprland-fullscreen = {
@@ -190,7 +190,7 @@ in
"SUPER" "SUPER"
"F" "F"
]; ];
action.type = "fullscreen"; action.kind = "fullscreen";
}; };
hyprland-toggle-split = { hyprland-toggle-split = {
@@ -199,7 +199,7 @@ in
"T" "T"
]; ];
action = { action = {
type = "layout"; kind = "layout";
message = "togglesplit"; message = "togglesplit";
}; };
}; };
@@ -210,7 +210,7 @@ in
"SHIFT" "SHIFT"
"Q" "Q"
]; ];
action.type = "close-window"; action.kind = "close-window";
}; };
hyprland-kill-window = { hyprland-kill-window = {
@@ -219,7 +219,7 @@ in
"CTRL" "CTRL"
"Q" "Q"
]; ];
action.type = "kill-window"; action.kind = "kill-window";
}; };
} }
// directionalKeybinds // directionalKeybinds

View File

@@ -22,7 +22,7 @@
type = lib.types.submodule { type = lib.types.submodule {
freeformType = lib.types.attrsOf lib.types.anything; freeformType = lib.types.attrsOf lib.types.anything;
options.type = lib.mkOption { options.kind = lib.mkOption {
type = lib.types.enum [ type = lib.types.enum [
"exec" "exec"
"focus" "focus"