We are have a number of issues related to viewports, specifically when the viewport is less than the full document.
- Built-in browser search doesn’t find text that is clipped by the viewport (naturally), this leads to some inconsistent results and confusion for users. We can’t just use an editor extension for find because we have multiple editors on the page at once and users want to perform finds across all of them.
- Every once in a while (don’t have a repro case yet), we see to get into a state where the viewport stops updating as the document scrolls, leaving large blank areas on the page and a broken experience. This could be something on our side of course.
- Certain browser extensions don’t work right, like “Grammarly”, which I guess would depend on all of the editor contents being in the DOM.
I understand the motivation for the viewport feature, but it also doesn’t seem like the cases where we are running into this have editor content that is all that large, they usually are at most 200-300 lines of code.
It would be great if there were some controls over the viewport behavior, like the ability to set a minimum size in lines or characters. Is there already a way to do that? Browsing the code makes it seem like all the values are hard-coded.
-Wiltse Carpenter, Observable Inc.