diff options
author | Andrzej Ratajczak <andrzej.ratajczak98@gmail.com> | 2020-05-04 13:53:10 +0200 |
---|---|---|
committer | Paweł Marks <Kordyjan@users.noreply.github.com> | 2020-05-26 11:32:03 +0200 |
commit | d47d386ad8c0ff4a2c3b9d5b4450a773bdcba2dc (patch) | |
tree | 364724f661349211f053ea80db1a7feb283f48ba /plugins/base/src/main/kotlin/transformers/pages/annotations | |
parent | b1e3033fca65ac1e8e312e51d2eed4f278ddb076 (diff) | |
download | dokka-d47d386ad8c0ff4a2c3b9d5b4450a773bdcba2dc.tar.gz dokka-d47d386ad8c0ff4a2c3b9d5b4450a773bdcba2dc.tar.bz2 dokka-d47d386ad8c0ff4a2c3b9d5b4450a773bdcba2dc.zip |
Enhance signature presentation. Support presetnation Java as Kotlin and Kotlin as Java. Refactor annotations creation from PSI/Descriptors. Add proper rendering of annotation signatures in both kotlin syntax and java syntax. Tests for annotations
Diffstat (limited to 'plugins/base/src/main/kotlin/transformers/pages/annotations')
-rw-r--r-- | plugins/base/src/main/kotlin/transformers/pages/annotations/DeprecatedStrikethroughTransformer.kt | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/plugins/base/src/main/kotlin/transformers/pages/annotations/DeprecatedStrikethroughTransformer.kt b/plugins/base/src/main/kotlin/transformers/pages/annotations/DeprecatedStrikethroughTransformer.kt index 55f01ad3..96e2c907 100644 --- a/plugins/base/src/main/kotlin/transformers/pages/annotations/DeprecatedStrikethroughTransformer.kt +++ b/plugins/base/src/main/kotlin/transformers/pages/annotations/DeprecatedStrikethroughTransformer.kt @@ -11,11 +11,11 @@ class DeprecatedStrikethroughTransformer(val context: DokkaContext) : PageTransf override fun invoke(input: RootPageNode): RootPageNode = input.transformContentPagesTree { contentPage -> if (contentPage.documentable?.isDeprecated() == true || contentPage.documentable?.hasDeprecatedChildren() == true) { val deprecatedDRIs = - contentPage.dri + - contentPage.documentable?.children - ?.filter { it.isDeprecated() } - ?.map { it.dri } - ?.toSet().orEmpty() + if (contentPage.documentable?.isDeprecated() == true) contentPage.dri else emptySet<DRI>() + + contentPage.documentable?.children + ?.filter { it.isDeprecated() } + ?.map { it.dri } + ?.toSet().orEmpty() contentPage.modified(content = contentPage.content.addStrikethroughToSignature(deprecatedDRIs)) } else { |