-
Notifications
You must be signed in to change notification settings - Fork 678
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
[BUG] Slider 组件的 onMouseUp 事件触发时机 #2171
Labels
PR Welcome
Welcome pull request :)
Comments
zzc6332
changed the title
[BUG] <title>Slider 组件的 onMouseUp 事件触发
[BUG] Slider 组件的 onMouseUp 事件触发
Apr 15, 2024
zzc6332
changed the title
[BUG] Slider 组件的 onMouseUp 事件触发
[BUG] Slider 组件的 onMouseUp 事件触发时机
Apr 15, 2024
@DaiQiangReal need confirm |
是 Bug,我们准备修,但是最近人力比较紧张。。我们尽力排。也欢迎PR |
zzc6332
added a commit
to zzc6332/semi-design
that referenced
this issue
Apr 21, 2024
zzc6332
added a commit
to zzc6332/semi-design
that referenced
this issue
Apr 21, 2024
6 tasks
#2186 fixed |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Is there an existing issue for this?
Which Component
Slider
Semi Version
2.56.0
Current Behavior
表现一:Slider 组件初始状态下,除了 handle 之外的元素如果被鼠标 down,那么当鼠标 up 时均无法触发组件的 mouseup 事件(以下将某元素被 mousedown 之后发生的 mouseup 都描述为该元素触发了 mouseup 事件)。一旦 handle 触发了 mouseup 事件后,track、rail、wrapper 均可以触发 mouseup 事件。见如下 gif:
[更新] 刚刚发现,实际上是触发过一次组件的 onMouseUp 之后,页面上所有元素的 mouseup 事件都会触发组件 onMouseUp 的回调。见如下 gif:
表现二:如果存在多个 Slider 组件,那么当拖动其中一个 Slider 的 handle 时,如果鼠标离开了当前 Slider,且位于另一个 Slider 的 handle 上方释放时,被操作的 Slider 仍会处于被拖动状态。见如下 gif:
Expected Behavior
表现一:
Slider 组件的 mouseup 事件总是可以被所有组件元素触发,或者总是只能被 handle 触发。[更新]页面的其它元素不触发 onMouseUp。表现二:鼠标在任何地方被释放后都结束 Slider 的拖动状态。
Steps To Reproduce
任何时候都会出现。
ReproducibleCode
https://stackblitz.com/edit/vitejs-vite-t8agmi?file=src%2FApp.tsx
Environment
Anything else?
No response
The text was updated successfully, but these errors were encountered: