##// END OF EJS Templates
Remove $el_to_style from the widget javascript code; '' now defaults to this.$el...
Remove $el_to_style from the widget javascript code; '' now defaults to this.$el This seems to make it easiest to select the top-level element. An alternative is to use special syntax for top-level elements, like in https://github.com/ipython/ipython/pull/6185 This will be followed up by other fixes that let the user set specific common properties of different elements. This change also adds the .addBack() call, which means that nonempty selectors now apply to this.$el and its descendants, rather than just the descendants of this.$el.

File last commit:

r16912:30744239
r17420:69911d59
Show More
codemirror.less
57 lines | 2.0 KiB | text/x-less | LessCssLexer
/* The following gets added to the <head> if it is detected that the user has a
* monospace font with inconsistent normal/bold/italic height. See
* notebookmain.js. Such fonts will have keywords vertically offset with
* respect to the rest of the text. The user should select a better font.
* See: https://github.com/ipython/ipython/issues/1503
*
* .CodeMirror span {
* vertical-align: bottom;
* }
*/
.CodeMirror {
line-height: @code_line_height; /* Changed from 1em to our global default */
height: auto; /* Changed to auto to autogrow */
background: none; /* Changed from white to allow our bg to show through */
}
.CodeMirror-scroll {
/* The CodeMirror docs are a bit fuzzy on if overflow-y should be hidden or visible.*/
/* We have found that if it is visible, vertical scrollbars appear with font size changes.*/
overflow-y: hidden;
overflow-x: auto;
}
.CodeMirror-lines {
/* In CM2, this used to be 0.4em, but in CM3 it went to 4px. We need the em value because */
/* we have set a different line-height and want this to scale with that. */
padding: @code_padding;
}
.CodeMirror-linenumber {
// This is needed to fine tune the position of the line numbers because we use the 0.4em in @code_padding
// spacing in various places. Fine tuned to look right.
padding: 0 8px 0 4px;
}
.CodeMirror-gutters {
// This is needed because our cell has rounded corners, otherwise the gutter area square
// corner cuts into the rounded cell border.
border-bottom-left-radius: @border-radius-base;
border-top-left-radius: @border-radius-base;
}
.CodeMirror pre {
/* In CM3 this went to 4px from 0 in CM2. We need the 0 value because of how we size */
/* .CodeMirror-lines */
padding: 0;
border: 0;
.border-radius(0)
}
// FIXME: This is a horrible workaround for CodeMirror bug #2562.
// Let's try not to release 3.0 with this.
.CodeMirror-vscrollbar, .CodeMirror-hscrollbar {
display: none !important;
}