Commit Graph

17 Commits

Author SHA1 Message Date
felixzsh 44d9185bf9 docs: add combo mode GIF to the README 2026-08-12 11:42:22 -05:00
felixzsh fb7266153e docs: remove mouse capture form roadmap 2026-08-12 11:16:51 -05:00
felixzsh 0a4aa59ee1 feat: add combo mode with combo counter, score and escalating effects
A 'Combo mode' toggle turns the display into a game-style counter.
Chords containing a modifier (Super/Ctrl/Alt/Shift/Menu/AltGr) are
combos: they build a combo counter, apply a multiplier (x2 at 5, x3 at
10 ... x8 at 50) and escalate the effects. Plain characters and shifted
chars typed alone are hits: +10 score only, they never touch the combo
counter or its window. Scoring: hit = 10, combo = (20 + 15*(mods-1) +
5*(keys-1)) * multiplier.

Counted once per physical chord on the Lua's empty payload (release),
so the intermediate growing emits of a chord never double-count. The
banner (COMBO 12 x3 - 3,450) sits below the history for bottom
positions and above it for top positions, with a floating +N pop per
press. Effects scale with modifiers and chain length: banner pulse,
hue shift, screen shake (up to 5px), continuous hue cycling at 10+
combos and a constant subtle vibration at 20+. The combo resets after
comboWindowMs (2s) without a new combo; the score accumulates for the
shell session.

Also fixes the README Behavior section: the history bullet was never
applied (a failed multi-edit call), now restored alongside the combo
mode docs. Manifest bumped to 1.7.0.
2026-08-12 10:51:01 -05:00
felixzsh d6c608374c feat: add stacking history with fading older entries
The last historyCount combos (1-5, default 1) stack on screen instead
of vanishing: each new combo pushes the previous one down the stack and
every older entry fades step by step (entryOpacity gradient). The stack
direction follows the position by default — top positions grow downward
(newest on top), bottom positions grow upward (newest at the bottom
edge) — and is not configurable. The panel gains a History NumberField
for the count.

Middle positions (center-left/center-right/center-center) were removed
from the dropdown and any leftover config value is folded into the
bottom row. With lingerMs 0 entries never expire, so the stack keeps
the last few combos on screen until newer ones push them out.

Manifest bumped to 1.6.0.
2026-08-12 10:06:40 -05:00
felixzsh 076bef95f5 Add a Preview section with the screenshot to the README 2026-08-11 17:37:36 -05:00
felixzsh e7232840cb Add a Linger NumberField to the menu
Native qs.Ui.NumberField (SpinBox) for lingerMs: mouse wheel, +/- buttons
and typing, 0-10000ms in 500ms steps, writing config.json like Mode and
Position so the display updates live. 0 selects the always-show behavior
from the previous commit.
2026-08-11 16:23:34 -05:00
felixzsh a5c31aaef7 lingerMs 0 keeps the last combo on screen until the next key
The hide timer only starts (and only clears) when lingerMs > 0, so 0
means the last full combo stays visible until the next key replaces it
— the keyviz-video look, as an explicit opt-in rather than the previous
behavior where 0 hid instantly.
2026-08-11 16:23:00 -05:00
felixzsh a22c8eaa78 Replace the position buttons with a native Dropdown (9 placements)
The three Position buttons (Bottom/Top/Center) overlapped the label in
the menu's width. Use qs.Ui.Dropdown with the full 3x3 grid — top /
middle / bottom by left / center / right — the display panel already
positions all of them.
2026-08-11 15:45:40 -05:00
felixzsh 840e7c2e13 Point README folder references at the renamed repo 2026-08-11 15:25:34 -05:00
felixzsh cabdf1307c Treat key combinations as a unit (combos)
The display now only updates on key-down (the combo grows as you press)
and when the last key is released (the empty payload starts the linger
with the last full combo). Intermediate releases no longer shrink the
display, so the order you let go of a shortcut doesn't matter: Ctrl+Shift+N
stays Ctrl+Shift+N whether Ctrl, Shift, or N goes up first, and the 1s
linger shows the full combo instead of a partial release state. Matches
the keybinding-tutorial use case better than keyviz, which shrinks
key-by-key on spaced releases.
2026-08-11 14:57:45 -05:00
felixzsh f53d2553d6 Document the stale-component caveat after plugin updates 2026-08-11 14:18:05 -05:00
felixzsh ccce10d393 Document the new config location and why it lives outside the plugin dir 2026-08-11 13:42:24 -05:00
felixzsh c0d491db29 Document the bar menu and the enable/rescan note 2026-08-11 13:26:32 -05:00
felixzsh 1f532510a5 Make display options configurable via config.json
The panel reads config.json from its plugin folder (seeded with defaults
on first run, hot-reloaded on save): mode (all | bindings — the bindings
mode only shows combos with a modifier, ideal for keybinding tutorials),
position (keyviz-style alignment, bottom-center by default) and margin,
plus the existing lingerMs. Replaces the hardcoded bottom anchors with
x/y computed from position and margin.
2026-08-11 11:07:47 -05:00
felixzsh 7ab4d2f18d Linger on screen after release, keyviz-style
Previously the chips cleared the instant the keys were released, so the
120ms hide delay was invisible. Keep the last combo rendered for the
whole linger window and only clear it when the timer fires, so a quick
tap stays readable (keyviz keeps keys for lingerDurationMs, 5s by
default). Default 1000ms, tunable via lingerMs.
2026-08-11 10:52:54 -05:00
felixzsh 64e44c299b Rename plugin id to felixzsh.key-visualizer
omarchy plugin validate rejects the omarchy.* namespace: it is reserved
for first-party plugins. Use the third-party <user>.<name> convention.
2026-08-11 09:58:37 -05:00
felixzsh 96446661b3 Add install and usage docs 2026-08-11 09:53:48 -05:00