Skip to content

Commit

Permalink
fix: Incorrect cursor position when resizing (#257)
Browse files Browse the repository at this point in the history
  • Loading branch information
CPunisher authored Jan 29, 2023
1 parent dd15281 commit f41d84a
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions packages/bytemd/src/editor.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -369,6 +369,14 @@
editor && editor.focus()
})
}

if (v === 'write') {
tick().then(() => {
// https://github.com/bytedance/bytemd/issues/232
// https://github.com/codemirror/codemirror5/issues/3270
editor && editor.setSize(null, null)
})
}
}}
on:click={(e) => {
switch (e.detail) {
Expand Down

0 comments on commit f41d84a

Please sign in to comment.