Update lib/ace/mode/markdown_highlight_rules.js
catch both text and "#" as token value for Atx style heading. todo: handle Setext style heading as well.
This commit is contained in:
parent
760f19dfc9
commit
bbd705cd69
1 changed files with 2 additions and 2 deletions
|
|
@ -77,9 +77,9 @@ var MarkdownHighlightRules = function() {
|
||||||
regex: "^\\-+(?=\\s*$)"
|
regex: "^\\-+(?=\\s*$)"
|
||||||
}, { // header
|
}, { // header
|
||||||
token : function(value) {
|
token : function(value) {
|
||||||
return "markup.heading." + value.length;
|
return "markup.heading." + value.match(/#/g).length;
|
||||||
},
|
},
|
||||||
regex : "^#{1,6}"
|
regex : "^#{1,6}.+$"
|
||||||
}, github_embed("(?:javascript|js)", "js-"),
|
}, github_embed("(?:javascript|js)", "js-"),
|
||||||
github_embed("xml", "xml-"),
|
github_embed("xml", "xml-"),
|
||||||
github_embed("html", "html-"),
|
github_embed("html", "html-"),
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue