From b2663070490d6ad31a0e7ba7ae80d16dbde43aef Mon Sep 17 00:00:00 2001 From: vmishenev Date: Sat, 25 Sep 2021 02:15:22 +0300 Subject: Fix adding new custom stylesheets in submodules (#2168) --- plugins/base/src/main/kotlin/renderers/html/htmlPreprocessors.kt | 2 ++ 1 file changed, 2 insertions(+) (limited to 'plugins/base/src/main/kotlin/renderers/html/htmlPreprocessors.kt') diff --git a/plugins/base/src/main/kotlin/renderers/html/htmlPreprocessors.kt b/plugins/base/src/main/kotlin/renderers/html/htmlPreprocessors.kt index 665ae730..43526dc3 100644 --- a/plugins/base/src/main/kotlin/renderers/html/htmlPreprocessors.kt +++ b/plugins/base/src/main/kotlin/renderers/html/htmlPreprocessors.kt @@ -76,6 +76,8 @@ class CustomResourceInstaller(val dokkaContext: DokkaContext) : PageTransformer val customResourcesPaths = (customAssets + customStylesheets).map { it.name }.toSet() val withEmbeddedResources = input.transformContentPagesTree { it.modified(embeddedResources = it.embeddedResources + customResourcesPaths) } + if(dokkaContext.configuration.delayTemplateSubstitution) + return withEmbeddedResources val (currentResources, otherPages) = withEmbeddedResources.children.partition { it is RendererSpecificResourcePage } return input.modified(children = otherPages + currentResources.filterNot { it.name in customResourcesPaths } + customAssets + customStylesheets) } -- cgit