Skip to content

Instantly share code, notes, and snippets.

@gazambuja
Created November 18, 2019 12:34
Show Gist options
  • Save gazambuja/c50acb629614d484201c2ea922de6691 to your computer and use it in GitHub Desktop.
Save gazambuja/c50acb629614d484201c2ea922de6691 to your computer and use it in GitHub Desktop.
//Enable two page view in google docs
var newWidth = document.getElementsByClassName('kix-zoomdocumentplugin-outer')[0].style.width.replace('px','') *2 +10 +'px';
document.getElementsByClassName("kix-paginateddocumentplugin")[0].style.width = newWidth;
var pages = document.getElementsByClassName("kix-page");
for (var i = 0; i < pages.length; i++) {
if(i==0) {
pages[0].parentNode.width = newWidth;
}
pages[i].style.float = "left";
}
@samsong
Copy link

samsong commented Mar 12, 2022

confirm does not work. can someone find the new element name for: kix-zoomdocumentplugin-outer

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment