question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Responsive maps are not responsive

See original GitHub issue

Describe/explain the bug The map components (geo) do not seem to be responsive, even though they imply they are, in their name. This applies to all, ResponsiveGeoMap, ResponsiveGeoMapCanvas, ResponsiveChoropleth and ResponsiveChoroplethCanvas.

There is a projectionScale property that scales the map, but the component is not automatically responsive.

To Reproduce

  1. Go to https://nivo.rocks/choropleth/
  2. Resize your browser
  3. Notice that the map does not actually resize

Expected behavior Map should scale when the container’s size updates.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

4reactions
LuzanFcommented, Dec 22, 2020

@plouc I found interesting d3 method: projection.fitextent, the question is how can I use it with Nivo

0reactions
plouccommented, Dec 22, 2020

@LuzanF the chart disappearing sounds like a bug, do you think you could reproduce this in codesandbox for example?

The doc use a config with some custom controls, but I think this would be way too complicated for most case, you could use a state and native range controls for example.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to make a Google Maps responsive and non responsive
Step 1 Go to Add or Edit Map and leave the Map width column blank to make the map responsive. Step 2 click...
Read more >
5 Ways to Add Responsive Google Maps to Your Website
However, Google Maps are not responsive by default, which means it doesn't automatically resize based on the device screen size.
Read more >
How to Implement Responsive Image Maps in Your HTML5 ...
Image maps, however, are not natively responsive. That means that if the image scale needs adjustments due to a browser's window being ......
Read more >
How to Embed Google Maps in your Website Responsively ...
The embedded map is non-responsive. What it means is if you open the page on a device other than your desktop computer, the...
Read more >
Why is responsive image map plugins not working?
I have an image with a map on it, to make clickable elements. The image is responsive, to fit different screen widths. When...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found