aboutsummaryrefslogtreecommitdiff
path: root/plugins/base
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/base')
-rw-r--r--plugins/base/src/main/kotlin/renderers/html/HtmlRenderer.kt5
-rw-r--r--plugins/base/src/main/kotlin/renderers/html/NavigationPage.kt1
2 files changed, 5 insertions, 1 deletions
diff --git a/plugins/base/src/main/kotlin/renderers/html/HtmlRenderer.kt b/plugins/base/src/main/kotlin/renderers/html/HtmlRenderer.kt
index 74bc6fea..aaa9c0a4 100644
--- a/plugins/base/src/main/kotlin/renderers/html/HtmlRenderer.kt
+++ b/plugins/base/src/main/kotlin/renderers/html/HtmlRenderer.kt
@@ -202,7 +202,10 @@ open class HtmlRenderer(
private fun PageNode.root(path: String) = locationProvider.resolveRoot(this) + path
override fun buildPage(page: ContentPage, content: (FlowContent, ContentPage) -> Unit): String =
- buildHtml(page, page.embeddedResources) { content(this, page) }
+ buildHtml(page, page.embeddedResources) {
+ attributes["pageIds"] = page.dri.toList()[0].toString()
+ content(this, page)
+ }
open fun buildHtml(page: PageNode, resources: List<String>, content: FlowContent.() -> Unit) =
createHTML().html {
diff --git a/plugins/base/src/main/kotlin/renderers/html/NavigationPage.kt b/plugins/base/src/main/kotlin/renderers/html/NavigationPage.kt
index ad574769..4b90cc8a 100644
--- a/plugins/base/src/main/kotlin/renderers/html/NavigationPage.kt
+++ b/plugins/base/src/main/kotlin/renderers/html/NavigationPage.kt
@@ -23,6 +23,7 @@ class NavigationPage(val root: NavigationNode) : RendererSpecificPage {
with(renderer) {
div("sideMenuPart") {
id = navId
+ attributes["pageId"] = node.dri.toString()
div("overview") {
buildLink(node.dri, node.platforms) { +node.name }
if (node.children.isNotEmpty()) {