Remove one level of indent from a block. Preserve lazily indented blocks by only removing indent from indented lines.
(self, block: str)
| 339 | return fn_blocks |
| 340 | |
| 341 | def detab(self, block: str) -> str: |
| 342 | """ Remove one level of indent from a block. |
| 343 | |
| 344 | Preserve lazily indented blocks by only removing indent from indented lines. |
| 345 | """ |
| 346 | lines = block.split('\n') |
| 347 | for i, line in enumerate(lines): |
| 348 | if line.startswith(' '*4): |
| 349 | lines[i] = line[4:] |
| 350 | return '\n'.join(lines) |
| 351 | |
| 352 | |
| 353 | class FootnoteInlineProcessor(InlineProcessor): |
no outgoing calls
no test coverage detected