mirror of
https://github.com/danog/telegram-tt.git
synced 2024-11-30 04:39:00 +01:00
Media Viewer: Fix scrolling caption (#1916)
This commit is contained in:
parent
cf2fdc7219
commit
53e87868fa
@ -321,6 +321,12 @@ export function captureEvents(element: HTMLElement, options: CaptureOptions) {
|
||||
|
||||
function onWheel(e: WheelEvent) {
|
||||
if (!options.onZoom && !options.onDrag) return;
|
||||
if (options.excludedClosestSelector && (
|
||||
(e.target as HTMLElement).matches(options.excludedClosestSelector)
|
||||
|| (e.target as HTMLElement).closest(options.excludedClosestSelector)
|
||||
)) {
|
||||
return;
|
||||
}
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
if (!hasMoved) {
|
||||
|
Loading…
Reference in New Issue
Block a user