Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why does CSS styling distort my Google maps zooming?

Here is a working version

http://jsfiddle.net/tH78C/

Here is a broken version (Zooming widget is no longer properly displayed) with Bootstrap styling

http://jsfiddle.net/3sjAU/

Why does it break?

like image 806
Hoa Avatar asked May 02 '12 04:05

Hoa


2 Answers

You can also fix this for individual maps e.g.:

.googleMapContainer img {
    max-width: none !important;
}
like image 66
wtds Avatar answered Oct 12 '22 23:10

wtds


In the Bootstrap.css line 69 max-width: 100%; is causing the issue.

img {
max-width: 100%; <--
vertical-align: middle;
border: 0;
-ms-interpolation-mode: bicubic;
}

You can remove it and if needed again just specify a new class .newclass {max-width:100%} and add it to the image.

like image 26
luke2012 Avatar answered Oct 12 '22 23:10

luke2012