From 9d4fd6197b719f01def1b5844a989ebf7fba8bc9 Mon Sep 17 00:00:00 2001 From: Karol Lewandowski Date: Fri, 22 Nov 2024 08:42:45 +0100 Subject: [PATCH] generate_descriptor_pages.main.kts: Fix rendering deprecated attribute information --- .github/scripts/generate_descriptor_pages.main.kts | 10 ++++------ .../plugin_structure/plugin_configuration_file.md | 3 ++- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/.github/scripts/generate_descriptor_pages.main.kts b/.github/scripts/generate_descriptor_pages.main.kts index 3aa485910..ed7ecfeaf 100755 --- a/.github/scripts/generate_descriptor_pages.main.kts +++ b/.github/scripts/generate_descriptor_pages.main.kts @@ -314,17 +314,15 @@ fun StringBuilder.appendAttributeDeprecationInfo(attribute: Attribute) { val deprecatedSince = attribute.deprecatedSince val deprecationNote = attribute.deprecationNote if (deprecatedSince != null || deprecationNote != null) { - if (deprecatedSince != null) { - append("**_Deprecated since ${deprecatedSince}_**".indentLines(4)) - } else { - append("**_Deprecated_**") - } + append( + (if (deprecatedSince != null) "**_Deprecated since ${deprecatedSince}_**" else "**_Deprecated_**").indentLines(2) + ) if (deprecationNote != null) { val noteWithoutLineBreaks = deprecationNote.replace('\n', ' ') append(": $noteWithoutLineBreaks") } + appendLine() } - append("") } fun StringBuilder.appendChildren(parent: Element, parentPath: String) { diff --git a/topics/basics/plugin_structure/plugin_configuration_file.md b/topics/basics/plugin_structure/plugin_configuration_file.md index dd444f749..dbdced904 100644 --- a/topics/basics/plugin_structure/plugin_configuration_file.md +++ b/topics/basics/plugin_structure/plugin_configuration_file.md @@ -1179,7 +1179,8 @@ Attributes - `ref` _(**required**)_
The ID of the action to add to a group. - `id` _(optional)_
-**_Deprecated_**: Use `ref` instead. + **_Deprecated_**: Use `ref` instead. + The ID of the action to add to a group. Children