forked from kofal.net/zmk
feat: Allow layer behaviors to "lock" layers on (#2717)
* refactor(core)!: Allow layer behaviors to "lock" layers on Co-authored-by: Cem Aksoylar <caksoylar@users.noreply.github.com> * docs: Added documentation note on locking layers Co-authored-by: Cem Aksoylar <caksoylar@users.noreply.github.com> --------- Co-authored-by: Cem Aksoylar <caksoylar@users.noreply.github.com>
This commit is contained in:
@@ -15,6 +15,7 @@
|
||||
compatible = "zmk,behavior-to-layer";
|
||||
#binding-cells = <1>;
|
||||
display-name = "To Layer";
|
||||
locking;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
compatible = "zmk,behavior-toggle-layer";
|
||||
#binding-cells = <1>;
|
||||
display-name = "Toggle Layer";
|
||||
locking;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
@@ -6,3 +6,8 @@ description: Momentary layer on press/release behavior
|
||||
compatible: "zmk,behavior-momentary-layer"
|
||||
|
||||
include: one_param.yaml
|
||||
|
||||
properties:
|
||||
locking:
|
||||
type: boolean
|
||||
description: Whether to "lock" the layer active, preventing behaviors without the "locking" property from deactivating the layer
|
||||
|
||||
@@ -6,3 +6,8 @@ description: To Layer
|
||||
compatible: "zmk,behavior-to-layer"
|
||||
|
||||
include: one_param.yaml
|
||||
|
||||
properties:
|
||||
locking:
|
||||
type: boolean
|
||||
description: Whether to "lock" the layer active, preventing behaviors without the "locking" property from deactivating the layer
|
||||
|
||||
@@ -10,9 +10,11 @@ include: one_param.yaml
|
||||
properties:
|
||||
toggle-mode:
|
||||
type: string
|
||||
required: false
|
||||
default: "flip"
|
||||
enum:
|
||||
- "on"
|
||||
- "off"
|
||||
- "flip"
|
||||
locking:
|
||||
type: boolean
|
||||
description: Whether to "lock" the layer active, preventing behaviors without the "locking" property from deactivating the layer
|
||||
|
||||
Reference in New Issue
Block a user