x

Scrollbars being created on Google Docs iFrame

I've read through many posts, and still can't seem to get this right.  Here is the code i've inserted into my html block:

<div class="googledoc-responsive">
<iframe src="https://docs.google.com/spreadsheets/d/1BQxqbxMUDiUJJtYkEVZq3UwEWNzFuk5LzOGPNXxY0Xg/pubhtml?gid=571588927&amp;range=A1Smiley Very Happy14&amp;chrome=false&amp;single=true&amp;headers=false" overflow="hidden" width="300" height="350" frameborder="0" scrolling="no" allowfullscreen=""></iframe>
</div>


and here is the CSS I've inserted in the theme's main.less section:

.googledoc-responsive{
    overflow:hidden;
    padding-bottom:75%;
	padding-top:35px;
    position:relative;
    height:0;
	background: #000000;
	overflow:hidden;
}
.googledoc-responsive iframe{
    left:0;
    top:0;
    height:320;
    width:284;
    position:absolute;
	background: #000000;
}

and yet, when I view on mobile, scrollbars still magically appear.  Any thoughts?image

2,432 Views
Message 1 of 2
Report
1 REPLY 1
Square

Just a guess, but the content of the iframe probably has a min-width which is set larger than your defined width for mobile.

2,421 Views
Message 3 of 2
Report
This thread has been archived and locked. Please start a new thread if you would like to continue the conversation.