Skip to content

Commit

Permalink
Use a parametrized macro
Browse files Browse the repository at this point in the history
  • Loading branch information
keymap-editor[bot] authored Mar 6, 2024
1 parent 4ad253d commit c95ca26
Showing 1 changed file with 13 additions and 23 deletions.
36 changes: 13 additions & 23 deletions config/helix.keymap
Original file line number Diff line number Diff line change
Expand Up @@ -4,25 +4,15 @@

/ {
macros {
NBT_PP: NBT_PP {
compatible = "zmk,behavior-macro";
#binding-cells = <0>;
bindings = <&bt BT_NXT &kp C_PLAY_PAUSE &bt BT_PRV>;
label = "NBT_PP";
};

NBT_PRV: NBT_PRV {
compatible = "zmk,behavior-macro";
#binding-cells = <0>;
bindings = <&bt BT_NXT &kp K_FORWARD &bt BT_PRV>;
label = "NBT_PRV";
};
MO_NBT_KP: MO_NBT_KP {
compatible = "zmk,behavior-macro-one-param";
#binding-cells = <1>;
bindings =
<&bt BT_NXT>,
<&macro_wait_time 30>,
<&macro_param_1to1 &kp MACRO_PLACEHOLDER &bt BT_PRV>;

NBT_FWD: NBT_FWD {
compatible = "zmk,behavior-macro";
#binding-cells = <0>;
bindings = <&bt BT_NXT &kp K_FORWARD &bt BT_PRV>;
label = "NBT_FWD";
label = "MO_NBT_KP";
};
};

Expand Down Expand Up @@ -53,11 +43,11 @@

layer_2 {
bindings = <
&trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans
&trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans
&trans &trans &trans &NBT_PP &NBT_PP &NBT_FWD &trans &trans &trans &trans &trans &trans
&trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans
&trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans
&trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans
&trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans
&trans &trans &trans &MO_NBT_KP K_PREVIOUS &MO_NBT_KP C_PLAY_PAUSE &MO_NBT_KP K_FORWARD &trans &trans &trans &trans &trans &trans
&trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans
&trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans &trans
>;
};
};
Expand Down

0 comments on commit c95ca26

Please sign in to comment.