-
-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
[grid] UI Liveview disconnect noVNC websocket when closing dialog #14598
Conversation
Signed-off-by: Viet Nguyen Duc <nguyenducviet4496@gmail.com>
PR Reviewer Guide 🔍Here are some key observations to aid the review process:
|
PR Code Suggestions ✨Explore these optional code suggestions:
|
CI Failure Feedback 🧐(Checks updated until commit 5295bea)
✨ CI feedback usage guide:The CI feedback tool (
In addition to being automatically triggered, the tool can also be invoked manually by commenting on a PR:
where Configuration options
See more information about the |
User description
Thanks for contributing to Selenium!
A PR well described will help maintainers to quickly review and merge it
Before submitting your PR, please check our contributing guidelines.
Avoid large PRs, help reviewers by making them as simple and short as possible.
Description
Motivation and Context
Fixes #12358
When clicking Close button to close Liveview dialog of a session. noVNC websocket keeps transferring data in the background
Before
After
Types of changes
Checklist
PR Type
Bug fix
Description
useImperativeHandle
andforwardRef
inLiveView
component to expose thedisconnect
method.RunningSessions
component to use a reference to theLiveView
component and ensure proper disconnection on dialog close.Changes walkthrough 📝
LiveView.tsx
Implement WebSocket disconnection on dialog close
javascript/grid-ui/src/components/LiveView/LiveView.tsx
useImperativeHandle
andforwardRef
to manage componentreferences.
disconnect
function to handle WebSocket disconnection.disconnect
is called on dialog close and password dialogclose.
RunningSessions.tsx
Manage LiveView component reference for disconnection
javascript/grid-ui/src/components/RunningSessions/RunningSessions.tsx
useRef
to manageLiveView
component reference.handleDialogClose
to ensure WebSocket disconnection.handleDialogClose
.