What's wrong with this entry?
Anonymous. No account, no email.
What: Keyboard event handlers can now stop event propagation to other handlers using event.stopImmediatePropagation().
How to use:
// For developers building on Claude Code's UI framework
useInput((input, key, event) => {
if (input === 'q' && shouldQuit) {
event.stopImmediatePropagation(); // Prevent other handlers from running
handleQuit();
}
});
Details:
- Third parameter added to keyboard event handlers containing the event object
- Enables priority-based event handling for modal dialogs, focus management, and vim-mode implementations
- Backward compatible - existing handlers with 2 parameters continue to work
- Implements DOM-style event propagation patterns
- Evidence: New
VO1event class at line 71066,B11base class withstopImmediatePropagation()at line 69922, and updated callback signature inQT9()at line 71693 in pretty-v2.0.24.js