Skip to content

Commit

Permalink
When rendering the preview for Antora, automatically switch to highli…
Browse files Browse the repository at this point in the history
…ght.js syntax highlighting (#1736)
  • Loading branch information
ahus1 committed Dec 20, 2024
1 parent b5c91f7 commit f837bc7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ This document provides a high-level view of the changes introduced by release.
=== 0.43.5

- Update docs and templates to recommend an absolute path for the `pdf-themesdir` (#1750)
- When rendering the preview for Antora, automatically switch to highlight.js syntax highlighting (#1736)

=== 0.43.4

Expand Down
3 changes: 3 additions & 0 deletions src/main/java/org/asciidoc/intellij/AsciiDocWrapper.java
Original file line number Diff line number Diff line change
Expand Up @@ -1051,6 +1051,9 @@ public static Collection<AttributeDeclaration> populateAntoraAttributes(@NotNull
antoraModuleDir) {
Collection<AttributeDeclaration> result = new ArrayList<>();
if (antoraModuleDir != null) {
// Antora uses hightlight.js as the default. Making it soft-set so it can be overwritten when needed
result.add(new AsciiDocAttributeDeclarationDummy("source-highlighter", "highlight.js", true));

result.addAll(collectAntoraAttributes(antoraModuleDir, project));

VirtualFile baseDir = LocalFileSystem.getInstance().findFileByIoFile(fileBaseDir);
Expand Down

0 comments on commit f837bc7

Please sign in to comment.