From 585178984228a9c2e5bd2af9b675094ac6e3fa46 Mon Sep 17 00:00:00 2001 From: Krzysztof Romanowski Date: Thu, 26 Nov 2020 13:05:20 +0100 Subject: Fixes from scala3doc (#1630) * Fix problem with ordering in Java api * HtmlRender allow to render html code directly from String --- plugins/base/src/main/kotlin/renderers/html/HtmlRenderer.kt | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'plugins') diff --git a/plugins/base/src/main/kotlin/renderers/html/HtmlRenderer.kt b/plugins/base/src/main/kotlin/renderers/html/HtmlRenderer.kt index d943fefb..9fbecad3 100644 --- a/plugins/base/src/main/kotlin/renderers/html/HtmlRenderer.kt +++ b/plugins/base/src/main/kotlin/renderers/html/HtmlRenderer.kt @@ -141,6 +141,11 @@ open class HtmlRenderer( } } + fun FlowContent.withHtml(content: String): Unit = when (this){ + is HTMLTag -> unsafe { +content } + else -> div { unsafe { +content } } + } + override fun FlowContent.buildPlatformDependent( content: PlatformHintedContent, pageContext: ContentPage, -- cgit