tangram-play
tangram-play copied to clipboard
Switching tabs sometimes causes the editor to be positioned incorrectly (Safari)
To recreate this:
- Open an import in a new file tab.
- In the original tab, place your cursor at the end of a word-wrapped line, where the "word" is force-wrapped because it is too long to break. For instance, the end of a long import URL.
- Switch to the other tab.
- Switch back to the original tab.
The CodeMirror-sizer
will be too wide, even after editor.refresh()
. This causes the editor pane to be offset by some quantity to the left.
The pane cannot be scrolled (and using a swipe gesture can ruin navigation state, which is worse), and it only resets if you place the cursor elsewhere and change tabs again.