feat(behaviours): Layer Locking (&llck/&layer_lock) behaviour
This PR implements the layer locking behaviour (&llck / &layer_lock) that allows to lock currently active layer(s). It is possible to lock multiple activated layers at once, which allows this to work nicely with conditional layers.
Manual testing I performed:
- [x] locking a layer
- [x] locking a conditional layer
Added an automated test which is also included in this PR. Documentation section for the new behaviour have also been added.
PR check-list
- [x] Branch has a clean commit history
- [x] Additional tests are included, if changing behaviors/core code that is testable.
- [x] Proper Copyright + License headers added to applicable files (Generally, we stick to "The ZMK Contributors" for copyrights to help avoid churn when files get edited)
- [x] Pre-commit used to check formatting of files, commit messages, etc.
- [x] Includes any necessary documentation changes.
It seems this is the same or similar to #1984 and #2717
It seems this is the same or similar to #1984 and #2717
Yep, I raised this PR as it seems #1984 needs some more changes (I'm not implying mine doesn't 🙂), just worried that last changes were pushed about a year ago IIRC). #2717 is slightly different (but serves the same purpose it seems): it adds locking property to the layer behaviours. Regardless of which PR will be chosen I am quite keen to see layer locking in upstream.
Closing as #2717 is now in main.