From 3047481420f215fb60b0380fa187975948ba54be Mon Sep 17 00:00:00 2001 From: Michael Williamson Date: Sun, 3 Jul 2016 20:17:04 +0100 Subject: Add comment reference document matcher --- lib/document-matchers.js | 1 + lib/style-reader.js | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/document-matchers.js b/lib/document-matchers.js index a9150e3..60bc65f 100644 --- a/lib/document-matchers.js +++ b/lib/document-matchers.js @@ -4,6 +4,7 @@ exports.bold = new Matcher("bold"); exports.italic = new Matcher("italic"); exports.underline = new Matcher("underline"); exports.strikethrough = new Matcher("strikethrough"); +exports.commentReference = new Matcher("comment-reference"); function paragraph(options) { diff --git a/lib/style-reader.js b/lib/style-reader.js index b5fb8ce..ab9a171 100644 --- a/lib/style-reader.js +++ b/lib/style-reader.js @@ -125,13 +125,15 @@ function documentMatcherRule() { var italic = identifierToConstant("i", documentMatchers.italic); var underline = identifierToConstant("u", documentMatchers.underline); var strikethrough = identifierToConstant("strike", documentMatchers.strikethrough); + var commentReference = identifierToConstant("comment-reference", documentMatchers.commentReference); return lop.rules.firstOf("element type", paragraphOrRun, bold, italic, underline, - strikethrough + strikethrough, + commentReference ); } -- cgit v1.2.3