Closed shshaw closed 3 months ago
That CodeMirror try example does run and seems to somewhat highlight the Stylus code as expected.
However, the problem does exist there where I cannot type any newline characters with the Return/Enter key. If I paste in code with newlines, that all works as expected, but I still cannot add any.
Other languages work fine.
This is a video of me running that CodeMirror Try example, hitting return in multiple scenarios, and not getting any new lines inserted.
https://github.com/user-attachments/assets/594f4fa1-f395-40bc-a11d-0dff578eafbe
Ah, I see. It crashes, but on Firefox a new line was created anyway, so I didn't see the issue. On Chrome indeed that prevents enter from doing anything. Attached patch should help.
That seems to have fixed it. Thanks!
Describe the issue
When using the Stylus Legacy Mode, hitting "enter" for a new line produces this error.
I'd post a reproduction, but I can't seem to get Stylus to load via the
@codemirror/language-data
package in codemirror.net/try as it produces this error:Browser and platform
No response
Reproduction link
No response