-
Notifications
You must be signed in to change notification settings - Fork 501
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
Height of Platform View type may not be set in full screen map web #795
Comments
seen this as well - reloading makes this go away for me. No idea how to fix it as of now. |
seen this as well. Also, reloading multiple times does not make it to go away for me. what I did:
forcing a unnecessary resize. However, it does work as expected after this - if you can live with the ugly resize. I dig up an issue with |
also this is how you get rid of the warnings with " Height of Platform View type" add
But this won't help you with the bug itself. The only solution I know for now is the resize trick. |
a pr for this seems to be in the works: mapbox/mapbox-gl-js#11310 So this will hopefully be fixed soonish, from the upstream. @metafounder are the changes required to Div related to the resizing bug or is this another issue? With the resize i would wait for new release from upstream - but if the warning would persist it would be great if you could create a PR for the style changes. |
Yes, I agree we need to wait for a fix in mapbox-gl-js. The changes in the Div are only related to the warning printed regarding height and width, so I can create a PR for this. |
@metafounder I tried the resize call you showed but I'm getting an error: |
you have to do this in (a fork of) this repo not in youe own dart code. The map that supports the resize is not exposed. |
hi @lukemadera , @felix-ht is right, that is what I did for now. Is messy, I know, but I take it that it's a temporary solution. Update: I will create the PR for the style changes mentioned above this week. |
Oh okay, it only works in a fork right now, thanks for explaining. So @felix-ht after your PR is merged will that expose the resize function? Or will it fix the underlying issue so we do not need to call resize at all? Thank you both! |
@lukemadera After the upstream release the resize will no longer be required and everything should just work. One option you try in the meantime is to use Version 2.4.0 as this bug was introduced with 2.5. |
Oh in index.html? I'm still on |
Using a local build of mapbox-gl-js does work better in chrome ( |
It still happens for me with Can we please expose the map resize function for now as a manual work around at least so I can consistently ensure the map is the correct size? @felix-ht |
This is an upstream issue introduced with 2.5 a fix was merged to master but has yet to be released |
I thought that as you said that earlier, but I have the issue in 2.4.x also, so it's not (only) an issue in 2.5.x |
@felix-ht any update on this? I've tried various mapbox js versions and still have the issue, e.g. https://landos.earthshot.eco/p/projec |
2.7 of mapbox js was just released - this should fix this issue: |
Awesome! On first few tries it seems to be working, thank you @felix-ht ! |
I managed to fix this by wrapping an iFrame with a div: ui.platformViewRegistry.registerViewFactory(iFrameId, (int viewId) { Note: I also had to add these to the iFrame: |
Size issue too here: #1008 (comment) |
when run example on web and open full screen map not fill all page and log is:
how to resolve it ?
The text was updated successfully, but these errors were encountered: