razor
razor copied to clipboard
Git diff utilizes older Razor editor resulting in C# background color showing through
Ultimately this issue embodies a bigger ask to allow "misc" Razor files in the new Razor editor.
Picture from VS issue:
VS Issue where this was originally reported: https://developercommunity.visualstudio.com/t/Razor-editor-not-respecting-code-backgro/1574754
More reports:
- https://developercommunity.visualstudio.com/t/Razor-syntax-highlighting-does-not-work-/1576862
- https://developercommunity.visualstudio.com/t/Razor-Code-Background-Color:-Cannot-impl/1578592
- https://developercommunity.visualstudio.com/t/Color-experience-of-Git-Changes-;HEAD-/1590694
@NTaylorMullen judging by your first line you've already imagined a fix here, can you share?
@NTaylorMullen judging by your first line you've already imagined a fix here, can you share?
So it'd be a bigger task where we'd hijack "loose" Razor files (ones not associated with a project) and allow our editor to run on those with a reasonable set of defaults. This would in turn result in consistent colorization among both sides. Alternatively we could also add "git diff" aware logic where we only swap the left hand side of the diff to the new editor if the right hand side is the new editor, in such an instance we'd also inherit the project information over. Latter would be a harder implementation most likely where the prior would be a bigger discussion on implications (for instance we'd indirectly change the default editor for .NET Framework Razor files).
Of note: This is not a Razor or LSP specific thing. Roslyn (with LSP off) also experiences color differences:
Does that change your prioritization preferences @NTaylorMullen?
Does that change your prioritization preferences @NTaylorMullen?
Ah as from being a 'candidate' to backlog? If so, I don't think so only because the old/new Razor editor are a bit more jarring