diff options
author | BarkingBad <32793002+BarkingBad@users.noreply.github.com> | 2019-12-13 14:01:25 +0100 |
---|---|---|
committer | Kamil Doległo <kamilok1965@interia.pl> | 2019-12-13 14:02:13 +0100 |
commit | dd017a44ed7baae83f4f09a92d9691231f424eaa (patch) | |
tree | ad9a7b6634ff4e4ead43122b13b0fb6dcdfcea85 /plugins | |
parent | 0900b0f1c3a593301a6229ce93a23b8228771d24 (diff) | |
download | dokka-dd017a44ed7baae83f4f09a92d9691231f424eaa.tar.gz dokka-dd017a44ed7baae83f4f09a92d9691231f424eaa.tar.bz2 dokka-dd017a44ed7baae83f4f09a92d9691231f424eaa.zip |
Add abstract structure for MD/HTML comments and MD parser
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/mathjax/src/main/kotlin/MathjaxPlugin.kt | 2 | ||||
-rw-r--r-- | plugins/xml/src/main/kotlin/XmlPlugin.kt | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/plugins/mathjax/src/main/kotlin/MathjaxPlugin.kt b/plugins/mathjax/src/main/kotlin/MathjaxPlugin.kt index 0c8bd654..ff3e83a3 100644 --- a/plugins/mathjax/src/main/kotlin/MathjaxPlugin.kt +++ b/plugins/mathjax/src/main/kotlin/MathjaxPlugin.kt @@ -28,7 +28,7 @@ object MathjaxTransformer : PageNodeTransformer { private val PageNode.isNeedingMathjax - get() = documentationNode?.platformInfo + get() = documentable?.platformInfo ?.flatMap { it.docTag?.children?.toList().orEmpty() } .orEmpty() .any { it.text == ANNOTATION } diff --git a/plugins/xml/src/main/kotlin/XmlPlugin.kt b/plugins/xml/src/main/kotlin/XmlPlugin.kt index 64d52b82..961a6387 100644 --- a/plugins/xml/src/main/kotlin/XmlPlugin.kt +++ b/plugins/xml/src/main/kotlin/XmlPlugin.kt @@ -1,7 +1,7 @@ package org.jetbrains.dokka.xml import org.jetbrains.dokka.CoreExtensions -import org.jetbrains.dokka.model.DocumentationNode +import org.jetbrains.dokka.model.Documentable import org.jetbrains.dokka.model.dfs import org.jetbrains.dokka.pages.* import org.jetbrains.dokka.plugability.DokkaContext @@ -26,12 +26,12 @@ object XmlTransformer : PageNodeTransformer { if (node !is ClassPageNode) node else { val refs = - node.documentationNode?.extra?.filterIsInstance<XMLMega>()?.filter { it.key == "@attr ref" } + node.documentable?.extra?.filterIsInstance<XMLMega>()?.filter { it.key == "@attr ref" } .orEmpty() - val elementsToAdd = mutableListOf<DocumentationNode>() + val elementsToAdd = mutableListOf<Documentable>() refs.forEach { ref -> - input.documentationNode?.dfs { it.dri == ref.dri }?.let { elementsToAdd.add(it) } + input.documentable?.dfs { it.dri == ref.dri }?.let { elementsToAdd.add(it) } } val platformData = node.platforms().toSet() val refTable = DefaultPageContentBuilder.group( |