-
Notifications
You must be signed in to change notification settings - Fork 15
fix: prevent kb input lock in the active KVM session #2994
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
f71b49f to
a73d15b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR fixes keyboard input locking in active KVM sessions by implementing event interception at the document level. The solution prevents the KVM toolkit from capturing keyboard events when users are typing in input fields, textareas, or other editable elements.
Key changes:
- Implemented lifecycle hooks and keyboard event listeners to intercept events before KVM captures them
- Added logic to detect focused input elements and stop event propagation when appropriate
- Added comprehensive unit tests covering various input element types and scenarios
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| src/app/devices/kvm/kvm.component.ts | Added keyboard event interception logic using capture phase listeners and cleanup in lifecycle hooks |
| src/app/devices/kvm/kvm.component.spec.ts | Added comprehensive test suite verifying keyboard event handling across different input element types |
- Added keyboard event listener in ngOnInit and handle the events in handleKeyboardEventCapture method - Added a new handleKeyboardEventCapture method to stop event propagation if the KVM session is active and if an input element has focus - Added event listener cleanup in ngOnDestroy() to prevent memory leaks - Added unit tests to verify the new functionality and ensure that keyboard events are properly handled when the KVM session is active
a73d15b to
8eba757
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please check the review comments from copilot. Apart from this w.r.t Angular code can't provide much feedback.
In the PR description please do mention the version of sample-ui through which you have reproduced this issue.
## [3.50.2](v3.50.1...v3.50.2) (2025-11-28) ### Bug Fixes * prevent kb input lock in the active KVM session ([#2994](#2994)) ([925b7b5](925b7b5))
|
🎉 This PR is included in version 3.50.2 🎉 The release is available on:
Your semantic-release bot 📦🚀 |
PR Checklist
What are you changing?
Anything the reviewer should know when reviewing this PR?
This is to resolve the #2591
The issue was reproduced in the main branch with the git commit ID: 696cd47
The solution fix was built on top of the above commit.
If the there are associated PRs in other repositories, please link them here (i.e. device-management-toolkit/repo#365 )