Fix indentation drift for indented code blocks in list items (#19990)
Co-authored-by: fisker <lionkay@gmail.com>
This commit is contained in:
1 parent
60600efbb6
commit
018faacfdb
5 files changed
+74
-3
No files matched your search
@@ -0,0 +1,47 @@
|
||||
// Jest Snapshot v1, https://jestjs.io/docs/snapshot-testing
|
||||
|
||||
exports[`indented-code-block.md - {"tabWidth":4} format 1`] = `
|
||||
====================================options=====================================
|
||||
parsers: ["markdown", "mdx"]
|
||||
tabWidth: 4
|
||||
printWidth: 80 (default) |
|
||||
=====================================input======================================
|
||||
- [x] task item
|
||||
|
||||
indented code
|
||||
|
||||
- unordered item
|
||||
|
||||
indented code
|
||||
|
||||
- outer item
|
||||
|
||||
- nested item
|
||||
|
||||
indented code
|
||||
|
||||
- item with extra code indentation
|
||||
|
||||
indented code
|
||||
|
||||
=====================================output=====================================
|
||||
- [x] task item
|
||||
|
||||
indented code
|
||||
|
||||
- unordered item
|
||||
|
||||
indented code
|
||||
|
||||
- outer item
|
||||
|
||||
- nested item
|
||||
|
||||
indented code
|
||||
|
||||
- item with extra code indentation
|
||||
|
||||
indented code
|
||||
|
||||
================================================================================
|
||||
`;
|
||||
@@ -0,0 +1 @@
|
||||
runFormatTest(import.meta, ["markdown", "mdx"], { tabWidth: 4 });
|
||||
@@ -0,0 +1,17 @@
|
||||
- [x] task item
|
||||
|
||||
indented code
|
||||
|
||||
- unordered item
|
||||
|
||||
indented code
|
||||
|
||||
- outer item
|
||||
|
||||
- nested item
|
||||
|
||||
indented code
|
||||
|
||||
- item with extra code indentation
|
||||
|
||||
indented code
|
||||
Reference in new issue
Block a user