Last active
April 16, 2018 11:30
-
-
Save timolehto/83e988b7b9b4243f33717cf82c6a332b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var isFullscreen = false | |
var originaWidths | |
function toggleFullscreen() { | |
let outerContainer = document.querySelector('#dialogueChat').style | |
let innerContainer = document.querySelector('#lekaneBanner_chatContentsContainer').style | |
if (isFullscreen) { | |
outerContainer.width = originalWidths.outerContainer | |
innerContainer.width = originalWidths.innerContainer | |
} else { | |
let outerContainer = document.querySelector('#dialogueChat').style | |
let innerContainer = document.querySelector('#lekaneBanner_chatContentsContainer').style | |
if (!originaWidths) { | |
originaWidths = { | |
outerContainer: outerContainer.width, | |
innerContainer: innerCongtainer.width | |
} | |
} | |
outerContainer.width = "90%" | |
innerContainer.width = "100%" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment