Skip to content
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]: requestDisallowInterceptTouchEvent broken #3326

Closed
swey opened this issue Jan 17, 2024 · 1 comment · Fixed by #3333
Closed

[Bug]: requestDisallowInterceptTouchEvent broken #3326

swey opened this issue Jan 17, 2024 · 1 comment · Fixed by #3333
Labels
bug 🪲 Something isn't working

Comments

@swey
Copy link

swey commented Jan 17, 2024

Mapbox Implementation

Mapbox

Mapbox Version

10.16.1

Platform

Android

@rnmapbox/maps version

10.1.6

Standalone component to reproduce

import React from 'react';
import {
  MapView
} from '@rnmapbox/maps';

class BugReport extends React.Component {
  render() {
    return (
      <MapView style={{flex: 1}} requestDisallowInterceptTouchEvent={true}>
      </MapView>
    );
  }
}

Observed behavior and steps to reproduce

A runtime error occurs as soon requestDisallowInterceptTouchEvent is set.
Screenshot_1705501458

Expected behavior

No response

Notes / preliminary analysis

No response

Additional links and references

No response

@VolkerLieber
Copy link
Contributor

A temporal workaround is to use the onDidFinishLoadingMap callback:

<Mapbox.MapView
	ref={mapRef}
	onDidFinishLoadingMap={() => {
		mapRef.current?.setNativeProps({
			requestDisallowInterceptTouchEvent: true,
		});
	}}
/>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🪲 Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants