From 66c9ef99816708cb1ffedd3ec37e5622bf823c20 Mon Sep 17 00:00:00 2001 From: Michael Williamson Date: Thu, 13 Jun 2024 11:52:30 +0100 Subject: Support style mapping for highlights --- lib/document-to-html.js | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'lib/document-to-html.js') diff --git a/lib/document-to-html.js b/lib/document-to-html.js index 32e8b03..bd845f6 100644 --- a/lib/document-to-html.js +++ b/lib/document-to-html.js @@ -127,6 +127,12 @@ function DocumentConversion(options, comments) { return convertElements(run.children, messages, options); }; var paths = []; + if (run.highlight !== null) { + var path = findHtmlPath({type: "highlight", color: run.highlight}); + if (path) { + paths.push(path); + } + } if (run.isSmallCaps) { paths.push(findHtmlPathForRunProperty("smallCaps")); } -- cgit v1.2.3