From 9be7ac19b3ad38c80c78f39443eb2f55b3b699c6 Mon Sep 17 00:00:00 2001 From: Marcin Aman Date: Sat, 21 Aug 2021 14:50:55 +0200 Subject: Make briefs contain first paragraph as in spec, resolve issues with i.e. (#2048) * Make briefs contain first paragraph as in spec, resolve issues with i.e. * Html and the end --- .../base/src/main/kotlin/translators/psi/parsers/JavadocParser.kt | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'plugins/base/src/main/kotlin/translators/psi/parsers') diff --git a/plugins/base/src/main/kotlin/translators/psi/parsers/JavadocParser.kt b/plugins/base/src/main/kotlin/translators/psi/parsers/JavadocParser.kt index 9cb362cb..8583edf7 100644 --- a/plugins/base/src/main/kotlin/translators/psi/parsers/JavadocParser.kt +++ b/plugins/base/src/main/kotlin/translators/psi/parsers/JavadocParser.kt @@ -22,9 +22,7 @@ import org.jetbrains.kotlin.idea.util.CommentSaver.Companion.tokenType import org.jetbrains.kotlin.psi.psiUtil.getNextSiblingIgnoringWhitespace import org.jetbrains.kotlin.psi.psiUtil.siblings import org.jsoup.Jsoup -import org.jsoup.nodes.Element -import org.jsoup.nodes.Node -import org.jsoup.nodes.TextNode +import org.jsoup.nodes.* import java.util.* import org.jetbrains.dokka.utilities.htmlEscape @@ -414,6 +412,7 @@ class JavadocParser( } else { node.wholeText.parseHtmlEncodedWithNormalisedSpaces(renderWhiteCharactersAsSpaces = true) }).orEmpty() + is Comment -> listOf(Text(body = node.outerHtml(), params = DocTag.contentTypeParam("html"))) is Element -> createBlock(node, keepFormatting) else -> emptyList() } -- cgit