diff --git a/FluentTerminal.Client/src/index.html b/FluentTerminal.Client/src/index.html index 7e7895ab..265890cf 100644 --- a/FluentTerminal.Client/src/index.html +++ b/FluentTerminal.Client/src/index.html @@ -5,6 +5,7 @@ +
diff --git a/FluentTerminal.Client/src/index.js b/FluentTerminal.Client/src/index.js index 6a0c3e7a..1796233e 100644 --- a/FluentTerminal.Client/src/index.js +++ b/FluentTerminal.Client/src/index.js @@ -145,14 +145,11 @@ function changeOptions(options) { } function setScrollBarStyle(scrollBarStyle) { - if (scrollBarStyle == 'hidden') { - document.getElementById('terminal-container').style['-ms-overflow-style'] = 'none'; - } else if (scrollBarStyle == 'autoHiding') { - document.getElementById('terminal-container').style['-ms-overflow-style'] = '-ms-autohiding-scrollbar'; - } else if (scrollBarStyle == 'visible') { - document.getElementById('terminal-container').style['-ms-overflow-style'] = 'scrollbar'; + switch (scrollBarStyle) { + case 'hidden': return terminalContainer.style['-ms-overflow-style'] = 'none'; + case 'autoHiding': return terminalContainer.style['-ms-overflow-style'] = '-ms-autohiding-scrollbar'; + case 'visible': return terminalContainer.style['-ms-overflow-style'] = 'scrollbar'; } - } function setPadding(padding) { diff --git a/FluentTerminal.Client/src/style.css b/FluentTerminal.Client/src/style.css index bef21dbe..0bf1fa4b 100644 --- a/FluentTerminal.Client/src/style.css +++ b/FluentTerminal.Client/src/style.css @@ -5,11 +5,19 @@ html, body { background: transparent; height: 100%; - } + width: 100%; + overflow: hidden; + -ms-content-zooming: none; +} #terminal-container { width: 100%; height: 100%; + /* re-enable scrolling only in the xterm container */ + overflow-y: auto; + overflow-x: hidden; + touch-action: pan-y; + -ms-touch-action: pan-y; } .xterm .xterm-viewport {