Thank you for reporting this!
I'm attaching a screenshots from before and after to illustrate the difference:
Screenshot comparison
Legacy editor: (CodeMirror 5; General > Advanced > Legacy Markdown editor):
New editor: (CodeMirror 6)
Development notes
- The 15px left-right margin is on the
.cm-content
element.- This comes from the use of
theme.marginLeft
intheme.ts
.
- This comes from the use of
- Each
.cm-line
has an additional2px
left-edge padding.- This also seems to be present in the upstream CodeMirror example editor.
- It should be possible to override in
theme.ts
.
Workarounds
- Re-enable the legacy editor
- Add the following custom CSS:
.CodeMirror .cm-line { padding-left: 0; } .CodeMirror .cm-content { margin-left: 0; margin-right: 0; }