mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/CodeMirror
synced 2024-11-30 17:04:14 +00:00
75f5c9b2be
The highlightSpecialChars() should act mostly identical to CM5. An example is the soft hyphen (U+00AD). These are highlighted as a red dot because they are non-printable characters. The i18n may seem like overkill, but CM6 would otherwise actually print the same message in plain English and without a way to localize it. Per request at T181677, we also highlight non-breaking space and the narrow non-breaking space. These are shown as a faint gray dot, to match CM6's highlightWhiteSpace() extension. That extension isn't used here because it would also highlight normal spaces, which we don't want. Bug: T181677 Change-Id: Iac1a8cf78e4cd0a27abc917f4b70bdfbaf86252a
31 lines
595 B
Plaintext
31 lines
595 B
Plaintext
@import 'mediawiki.mixins';
|
|
|
|
/* TODO: Remove styles below following CM6 upgrade, or move them to ext.CodeMirror.v6.WikiEditor.less */
|
|
|
|
.mw-editfont-monospace,
|
|
.mw-editfont-sans-serif,
|
|
.mw-editfont-serif {
|
|
.CodeMirror {
|
|
// Don't let CodeMirror set the font to monospace if it's set on an ancestor.
|
|
// See T245568
|
|
font-family: inherit;
|
|
}
|
|
}
|
|
|
|
.wikiEditor-ui .CodeMirror {
|
|
line-height: 1.5em;
|
|
padding: 0.1em;
|
|
clear: both;
|
|
box-sizing: border-box;
|
|
|
|
pre,
|
|
.CodeMirror-lines {
|
|
padding: 0;
|
|
}
|
|
}
|
|
|
|
.wikiEditor-ui-toolbar {
|
|
// Increase z-index to be above codemirror scrollbar
|
|
z-index: 7;
|
|
}
|