Fix range calculation in MD033/no-inline-html during re-parse of tabbed content.

This commit is contained in:
David Anson 2023-01-21 18:57:09 -08:00
parent 48a92d41a4
commit c53df8b720
7 changed files with 65 additions and 6 deletions

View file

@ -4953,11 +4953,13 @@ module.exports = {
var options = {
"extensions": [{
"disable": {
"null": ["htmlFlow"]
"null": ["codeIndented", "htmlFlow"]
}
}]
};
var flowTokens = parse(token.text, options);
// Use lines instead of token.text for accurate columns
var lines = params.lines.slice(token.startLine - 1, token.endLine).join("\n");
var flowTokens = parse(lines, options);
pending.push([token.startLine - 1, flowTokens]);
}
}