Skip to content
Snippets Groups Projects
Commit 34d0a748 authored by marihachi's avatar marihachi
Browse files

implement syntax: hashtag

parent 5e275d3a
No related branches found
No related tags found
No related merge requests found
......@@ -42,7 +42,7 @@ inline
/ inlineCode
/ mathInline
// / mention
// / hashtag
/ hashtag
// / url
// / link
/ customEmoji
......@@ -253,6 +253,26 @@ mathInline
}
// inline: hashtag
hashtag
= "#" content:hashtag_content
{
return createTree('hashtag', { hashtag: content });
}
hashtag_content
= (![\s!"#$%&'*+,\-./:;<=>?@\\^_`{|}~【】<>] (hashtag_bracket / hashtag_char))+ { return text(); }
hashtag_bracket
= "(" hashtag_content* ")"
/ "[" hashtag_content* "]"
/ "「" hashtag_content* "」"
hashtag_char
= ![()\[\]「」] CHAR
// inline: custom emoji
customEmoji
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment