This parameter allows to set key positions that will trigger hold-tap resolution only for the positions in the provided list. If hold-tap is interrupted by a key that is not in the list, it immediately is interpreted as a tap.
This is the relevant excerpt from my ZMK config:
#define LEFT_HAND_KEYS \
0 1 2 3 4 5 \
12 13 14 15 16 17 \
24 25 26 27 28 29
#define RIGHT_HAND_KEYS \
6 7 8 9 10 11 \
18 19 20 21 22 23 \
30 31 32 33 34 35
#define LEFT_THUMB_KEYS \
36 37 38
#define RIGHT_THUMB_KEYS \
39 40 41
lsht: left_shift_tap {
compatible = "zmk,behavior-hold-tap";
flavor = "balanced";
> hold-trigger-key-positions = <RIGHT_HAND_KEYS RIGHT_THUMB_KEYS>;
hold-trigger-on-release; // for combining HRMs
tapping-term-ms = <U_TAPPING_TERM>;
quick-tap-ms = <U_QUICK_TAP>;
#binding-cells = <2>;
bindings = <&kp>, <&kp>;
};
rsht: right_shift_tap {
compatible = "zmk,behavior-hold-tap";
flavor = "balanced";
> hold-trigger-key-positions = <LEFT_HAND_KEYS LEFT_THUMB_KEYS>;
hold-trigger-on-release; // for combining HRMs
tapping-term-ms = <U_TAPPING_TERM>;
quick-tap-ms = <U_QUICK_TAP>;
#binding-cells = <2>;
bindings = <&kp>, <&kp>;
};
So, when I hold a key with a bound right_shift_tap behavior (e.g. K in Qwerty) and immediately tap any key on the left half, it is immediately interpreted as Shift+Left-Side-Key. But, when I hold the right_shift_tap behavior key, and either tap or hold (interrupt) any key on the same right side, it is immediately interpreted as a tap, no delay. So, I can roll the keys on the same side without being afraid of triggering any combination, and no delay, as if the were no Hold-Tap keys.
hold-trigger-on-release helps combining mods on the same side, that is, delays the resolution of Hold-Tap keys held on the same side and with set hold-trigger-key-positions, till the end of the initial (of the one held first) Hold-Tap resolution.
I did not follow this thread, but from the look of it, it may be very similar to what your macro does, except that in ZMK it’s a core Hold-Tap feature, and in QMK, it is provided as a third-party lib that is integrated with hooks.
PS: In my ZMK config, I have separated Shift behaviors from other mods behaviors. Other mod behaviors are even more restricted:
rmt: right_mod_tap {
compatible = "zmk,behavior-hold-tap";
flavor = "balanced";
hold-trigger-key-positions = <LEFT_HAND_KEYS LEFT_THUMB_KEYS>;
hold-trigger-on-release; // for combining HRMs
tapping-term-ms = <U_TAPPING_TERM>;
quick-tap-ms = <U_QUICK_TAP>;
> require-prior-idle-ms = <U_STREAK_DECAY>;
#binding-cells = <2>;
bindings = <&kp>, <&kp>;
};
That is, U_STREAK_DECAY ms is required to pass after the last key press before any Hold-Tap resolution is even considered, so it’s a tap before they elapse.