Fix for theme breaking embedded Google Maps

Posted in: Newspaper
Post count: 5

It took me a while to figure out why the map layer and icons of Google Maps (generated via the API, not displayed within an iframe) were not rendering in the Newspaper theme.

They were actually rendering in pages, but not in posts. I discovered this is happening because line 32139 in style.css sets the default opacity of all images to transparent:

body.td-animation-stack-type0 .td-animation-stack .entry-thumb,
body.td-animation-stack-type0 .post img {
opacity: 0;
}

To overcome this problem, in the div container for your Google Map, create a custom style to set images to the default opacity:

.post #map-container img { /* fix for theme breaking map images by setting opacity of all images to 0*/
opacity: 1 !important;
}

I hope this helps someone else.

Post count: 22421

Hello,
Thank you for this solution. The opacity is added by the loading animation (lazyload) if you remove this option, the opacity will be 1 for all images.

Post count: 5

I’d like to keep lazyload so I’ll maintain my workaround. But this is good to know, thanks!

Viewing 3 posts - 1 through 3 (of 3 total)
The forum ‘Newspaper’ is closed to new topics and replies.