Current Live Preview
Code block didn’t display properly with review mode.
problem 1. If I apply code block in an indent format, the vertical line position will be placed at a wrong place.
problem 2. if I write a long code in the code block, the display of the second line of the code will be start without indent, which is unacceptble for reading.
problem 3.The background color of the code block is at wrong place. It should be indented.
#sfgsdf run sudo sh cuda_11.3.0_465.19.01_linux.run fgsdfgsdfgsdfgsdfgdfgsdfgsdfgsdfgsdfgsdfgsdfgsdfgsdfgsdfgsdfgdsfg
In a note, enter the following:
* Here is a list item ```text Here is a code block within that list item ```
I’d expect to see the code block rendered in the editor in a way that makes it clear the block is nested inside in the list, i.e. in a manner consistent with the preview view, which gets this right.
The code block is rendered with a background that isn’t indented, making it appear that the code block is a top-level item which happens to contain code where every line is indented.
Here’s a screenshot of the preview view getting the rendering right:
Here’s a similar bug report: Syntax highlighting is broken for block quotes in bulleted lists — but I think it’s probably a different case.
I have this issue as well! Using Windows 10 on Obsidian 0.6.7.
i agree, maybe what the editor can do is that detect that code block is being indented and keep the indentation until the closing backticks.
anyway, here’s my workaround to make it looks more in place (in case it helps u). i wrote the code block without bullet, and then just indent it (as many time as the bullet depth (first level - one tab, 2nd level - two tab)
Is there any way to track the progress, a roadmap or anything similar?
Any plan for this? Typora dont have such issue, it makes me want to use Typora instead
I use Typora as default “open with” for md files, this way I can directly open in Typora from Obsidian
I also see this. Its a minor nuisance, but would be nice if it could get fixed.
Here’s a code block that i’ve indented with either 4 spaces or a tab.
The code block in Live Preview extends to the left edge of the page, but is indented properly when in normal Preview mode