Artanis/pagedown

Converter allows for headings up to h6, but sanitizer removes anything after h3.

Closed this issue · 0 comments

What steps will reproduce the problem?
1. var converter = Markdown.getSanitizingConverter();
2. converter.makeHtml( '#h4-header')
3. the text 'h4-header' is returned.

What is the expected output? What do you see instead?
I expected '<h4>h4-header</h4>' to be returned

What version of the product are you using? On what operating system?
Latest version, OS X 10.7


Please provide any additional information below.

The issue is that on line 23 of Markdown-Sanitizer.js a whitelist is declared 
that only allows h tags up to h3.  However, line 747 of the 
Markdown-Converter.js allows h1-h6. Adding h4-h6 to the whitelist fixed the 
issues.

Original issue reported on code.google.com by dmar...@groupon.com on 5 Jul 2012 at 4:52

  • Merged into: #29