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

Define touch delegation areas #235

Open
frederikheld opened this issue Jun 2, 2024 · 0 comments
Open

Define touch delegation areas #235

frederikheld opened this issue Jun 2, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@frederikheld
Copy link

frederikheld commented Jun 2, 2024

Is your feature request related to a problem? Please describe.
I see that touch delegation is marked as WIP. I also feel that the plugin has issues with figuring out when to delegate touch (it often takes two consecutive taps to get one tap delegated to the map). I also see that empty divs that overlap the map will prevent touch delegation.

So here's my feature request:

Add an API that allows to delegate taps programmatically. This would allow to set listeners to HTML elements that can be patched through to the map without the need for any advanced magic to figure out if the touch should be delegated or not. This would also allow for more complex overlays.

Example:

Does this feature exist in the Google Maps SDK for android and iOS? Please link the documentation for this feature.

I don't know

Describe the solution you'd like

Be able to define HTMLElements as "delegate touch events to Google Maps layer".

Additional context

Example

Problem: Area with pink border is a container for the controls that won't delegate touch to the Google Map at all, not even in the empty areas. All other parts of the map don't react to taps immediately if the user clicked on one of the WebView components before.

Solutions: Overlay areas that should be delegated to the Google Map with invisible divs (in this example the red, green and blue areas). define those divs as "alway delegate touch events to Google Map".

example

@frederikheld frederikheld added the enhancement New feature or request label Jun 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant