diff --git a/src/Editor.tsx b/src/Editor.tsx index 41162a3..f09671e 100644 --- a/src/Editor.tsx +++ b/src/Editor.tsx @@ -102,4 +102,5 @@ const basicSetup: Extension = [ keymap.of([...closeBracketsKeymap, ...defaultKeymap, ...searchKeymap, ...historyKeymap]), mathPlugin(), placeholder('0.1 + 0.2 = 0.3'), + EditorView.lineWrapping, ] diff --git a/src/index.css b/src/index.css index cd221f8..9951f14 100644 --- a/src/index.css +++ b/src/index.css @@ -10,6 +10,7 @@ body { max-width: 800px; margin: auto; height: 100vh; + padding: 12px; } #root, @@ -22,10 +23,6 @@ body { outline: none; } -.cm-scroller { - margin-right: -14px; -} - .math-result { color: rgb(80, 80, 80); margin-left: 8px; @@ -66,7 +63,7 @@ body { font-family: monospace; font-size: 14px; cursor: pointer; - margin: 8px 0; + margin-bottom: 8px; transition: all 0.2s ease; font-weight: 600; }