styler malforms text in Visual Markdown mode #9079
Labels
bug
reproducible
rstudioapi
visual markdown
For bugs related to the new visual editor mode added for RMarkdown docs in the 1.4 release.
Milestone
Hi @kevinushey I originally opened the issue in
{styler}
, and have moved it to here at Lorenz' request.r-lib/styler#740 (comment)
I have copied the bulk of that post below. I can reproduce interactively, and have included a GIF of the behavior.
System details
Steps to reproduce the problem
Problem: In Visual Markdown mode, styling the active selection in a code-chunk appears to correctly style the code, but malforms it on the plain-text side.
Switching back into plain-text mode, the code will be "fixed", but if you "undo" you can see there is an intermediate format that is completely malformed and has lost some characters. Undo a second time will revert back to the original, unstyled format.
Reprex below, and note this works fine in non-visual editor mode.
Environment:
Quick recording
Describe the problem in detail
Problem: In Visual Markdown mode, styling the active selection in a code-chunk appears to correctly style the code, but malforms it on the plain-text side temporarily which persists unless swapping back and forth between plain text and visual mode.
Describe the behavior you expected
Expected that styling the code would organize the code according to the style guide, and that the code would be able to run even in Visual Markdown mode.
The text was updated successfully, but these errors were encountered: