Keyboard state tracking, modifier-aware key dispatch, and the responder chain for focus management.
The browser's native keyboard handling has two critical gaps:
keydown and keyup events tell you which key was pressed, but not which other keys are currently held.focus is element-level without a concept of a view hierarchy responder chain or tab-order routing between custom view containers.STRVCT addresses both:
SvKeyboard Singleton: Tracks global keyboard state and generates modifier-aware method names (e.g. onShiftAKeyDown, onAlternate_D_KeyDown).SvResponderDomView: Layers a responder chain on top of DOM focus to manage focus acquisition, loss, and Tab-key navigation through the view tree.When a key event fires, SvKeyboard generates a method name following the pattern:
on[Modifiers][KeyName]Key[Down|Up]onShiftAKeyDown(event)onAlternate_D_KeyDown(event) (toggles Developer Mode)onEnterKeyDown(event)onEscapeKeyDown(event)MetaLeft / MetaRight (onMetaKey...). Option key maps to Alternate (onAlternateKey...).Control (onControlKey...). Alt key maps to Alternate (onAlternateKey...).SvResponderDomView provides focus management methods across the view tree:
acceptsFirstResponder(): Returns true if the view can receive keyboard focus.becomeFirstResponder(): Acquires focus, updates styling, and calls willBecomeFirstResponder().releaseFirstResponder(): Releases focus and calls willReleaseFirstResponder().nextKeyView: References the next view in the tab order, enabling Tab key navigation across view inputs.