Zh OpenStreetMap feature to correct refresh map size when display on tabs

Hi.

In some cases you want to display maps on tabs. And if you show in on inactive tab and when click on it, you can get map with incorrect map size.

The other case – when you show it on first tab (correctly) but change to the other tab and change browser window (for example maximize). In this case you can also get wrong size.

Look at result image

To fix it.

Just create Override

On Map tab enter your tab selector (ID or class).

Select Invalidate Type

  • One time – the container will be invalidated only on first time when you display map (show tab with map)
  • Always – the container will be invalidated each time you display map (show tab with map)

Case Always you can use in case your map is not correctly displayed every time you change browser window with not active tab with map.

Different ways to display map on tab have different cases – in one case you need to use Always, in the other case it is correctly displayed every time, and in the other – just only in initial display.

After that just go to map details, on tab “Advanced options” select your new override.

Leave a Reply

Your email address will not be published. Required fields are marked *