Skip to content

fix(dataZoom): keep slider handle label visible when mouse stays over handle after drag end - #21722

Open
waterWang wants to merge 1 commit into
apache:masterfrom
waterWang:fix/datazoom-slider-label-disappear-on-unclick
Open

fix(dataZoom): keep slider handle label visible when mouse stays over handle after drag end#21722
waterWang wants to merge 1 commit into
apache:masterfrom
waterWang:fix/datazoom-slider-label-disappear-on-unclick

Conversation

@waterWang

Copy link
Copy Markdown

Fixes #20178

Problem

When dragging a dataZoom slider handle and releasing the mouse without moving it away (i.e. the mouse stays over the handle), the handle's label disappears even though the pointer is still over the handle.

Root cause

During a drag, the handle's onmouseout can fire (the pointer briefly leaves the handle hit area as it moves), which sets SliderZoomView._isOverDataInfoTriggerArea = false. On dragend, _onDragEnd() checks that flag and, because it is false, calls _showDataInfo(false) which hides the label — even though the mouse is still sitting over the handle.

Fix

Accept the dragend event in _onDragEnd(e). When the flag is false, only hide the label if the drag did not end on a handle or the move zone. If the drag released over a handle / move zone, keep the label visible so it matches the "mouse is still over the handle" expectation.

This also forwards the event from _onActualMoveZoneDragEnd so the move-zone drag path behaves the same way.

@echarts-bot

echarts-bot Bot commented Aug 10, 2026

Copy link
Copy Markdown

Thanks for your contribution!
The community will review it ASAP. In the meanwhile, please checkout the coding standard and Wiki about How to make a pull request.

Please DO NOT commit the files in dist, i18n, and ssr/client/dist folders in a non-release pull request. These folders are for release use only.

To reviewers: If this PR is going to be described in the changelog in the future release, please make sure this PR has one of the following labels: PR: doc ready, PR: awaiting doc, PR: doc unchanged

This message is shown because the PR description doesn't contain the document related template.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug] Datazoom label disappear after unclick

1 participant