diff --git a/src/contexts/folding_range.ts b/src/contexts/folding_range.ts index 93e1169..1b19baf 100644 --- a/src/contexts/folding_range.ts +++ b/src/contexts/folding_range.ts @@ -100,7 +100,7 @@ export default class FoldingRangeContext { // Process block. if (line.startsWith('@end ')) { if (verbatim) continue; - const name = line.substring(5); + const name = line.substring(5).trimRight(); name === 'verbatim' && (verbatim = true); closingBlocks.push({ name: name, line: idx }); continue;