From 94a893d9755b1602ac06516e747fe53a8d09adc2 Mon Sep 17 00:00:00 2001 From: Jonathan Frederic Date: Tue, 16 Dec 2014 14:27:34 -0800 Subject: [PATCH] Prevent terminal from scrolling --- IPython/html/static/base/less/variables.less | 1 + IPython/html/static/terminal/css/override.css | 7 +++++++ IPython/html/static/terminal/less/terminal.less | 2 +- IPython/html/templates/terminal.html | 5 +++++ 4 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 IPython/html/static/terminal/css/override.css diff --git a/IPython/html/static/base/less/variables.less b/IPython/html/static/base/less/variables.less index 195d10f44..d5a8f7785 100644 --- a/IPython/html/static/base/less/variables.less +++ b/IPython/html/static/base/less/variables.less @@ -41,5 +41,6 @@ label { // Our own global variables for all pages go here @global-shadow: 0px 0px 12px 1px rgba(87, 87, 87, 0.2); +@global-shadow-dark: 0px 0px 12px 1px rgba(87, 87, 87, 0.4); @page-header-padding: 20px; diff --git a/IPython/html/static/terminal/css/override.css b/IPython/html/static/terminal/css/override.css new file mode 100644 index 000000000..6d74111f7 --- /dev/null +++ b/IPython/html/static/terminal/css/override.css @@ -0,0 +1,7 @@ +/*This file contains any manual css for this page that needs to override the global styles. +This is only required when different pages style the same element differently. This is just +a hack to deal with our current css styles and no new styling should be added in this file.*/ + +body { + overflow: hidden; +} diff --git a/IPython/html/static/terminal/less/terminal.less b/IPython/html/static/terminal/less/terminal.less index 452fc49cc..0674b807a 100644 --- a/IPython/html/static/terminal/less/terminal.less +++ b/IPython/html/static/terminal/less/terminal.less @@ -4,7 +4,7 @@ color: white; background: black; border-radius: @border-radius-base; - box-shadow: 0px 4px 11px 0px gray; + .box-shadow(@global-shadow-dark); padding: @code_padding; &, dummy-screen { diff --git a/IPython/html/templates/terminal.html b/IPython/html/templates/terminal.html index c004d3465..2b77acb20 100644 --- a/IPython/html/templates/terminal.html +++ b/IPython/html/templates/terminal.html @@ -9,6 +9,11 @@ data-ws-path="{{ws_path}}" {% endblock %} +{% block stylesheet %} +{{super()}} + + +{% endblock %} {% block site %}