From 8809ae6952b682e0a7c9372986ec1563818917dd Mon Sep 17 00:00:00 2001 From: "lina.wolf" Date: Sat, 20 Sep 2025 08:56:40 +0200 Subject: [PATCH 1/3] [BUGFIC] Remove duplicated admonition titles resolves: https://github.com/TYPO3-Documentation/render-guides/issues/1030 --- .../resources/template/body/admonition.html.twig | 2 -- .../tests/admonitions/expected/index.html | 12 ++++++------ .../tests/markdown/admonitions/expected/README.html | 11 +++++++++++ .../tests/markdown/admonitions/input/README.md | 4 ++++ .../markdown/{ => admonitions}/input/guides.xml | 0 .../markdown/{ => readme}/expected/README.html | 0 .../tests/markdown/{ => readme}/input/README.md | 0 .../tests/markdown/readme/input/guides.xml | 13 +++++++++++++ 8 files changed, 34 insertions(+), 8 deletions(-) create mode 100644 tests/Integration/tests/markdown/admonitions/expected/README.html create mode 100644 tests/Integration/tests/markdown/admonitions/input/README.md rename tests/Integration/tests/markdown/{ => admonitions}/input/guides.xml (100%) rename tests/Integration/tests/markdown/{ => readme}/expected/README.html (100%) rename tests/Integration/tests/markdown/{ => readme}/input/README.md (100%) create mode 100644 tests/Integration/tests/markdown/readme/input/guides.xml diff --git a/packages/typo3-docs-theme/resources/template/body/admonition.html.twig b/packages/typo3-docs-theme/resources/template/body/admonition.html.twig index 262bb19b4..25d8c951c 100644 --- a/packages/typo3-docs-theme/resources/template/body/admonition.html.twig +++ b/packages/typo3-docs-theme/resources/template/body/admonition.html.twig @@ -24,8 +24,6 @@ {% if titleOfSeverity %}

{{ titleOfSeverity }}

{% elseif title and isTitled %}

{{ renderNode(title) }}

{% endif %} - {% if title and not isTitled %}

{{ renderNode(title) }}

- {% endif %} {{ renderNode(node) }} diff --git a/tests/Integration/tests/admonitions/expected/index.html b/tests/Integration/tests/admonitions/expected/index.html index f290c6f0c..efe5443d1 100644 --- a/tests/Integration/tests/admonitions/expected/index.html +++ b/tests/Integration/tests/admonitions/expected/index.html @@ -1,6 +1,6 @@
-

Admonitions: Tip, Note, Warning, See also, etc 

+

Admonitions: Tip, Note, Warning, See also, etc

-

Note 

+

Note

-

Tip 

+

Tip

-

Attention 

+

Attention

- From b36f062aa876e6eaa24bcbe627037935052a35fd Mon Sep 17 00:00:00 2001 From: "lina.wolf" Date: Sat, 20 Sep 2025 09:20:25 +0200 Subject: [PATCH 3/3] [BUGFIX] Remove duplicated admonition titles resolves: https://github.com/TYPO3-Documentation/render-guides/issues/1030 --- .../tests/admonitions/expected/index.html | 13 ++++++------- .../expected/README.html | 0 .../{admonitions => md-admonitions}/input/README.md | 0 .../input/guides.xml | 0 4 files changed, 6 insertions(+), 7 deletions(-) rename tests/Integration/tests/markdown/{admonitions => md-admonitions}/expected/README.html (100%) rename tests/Integration/tests/markdown/{admonitions => md-admonitions}/input/README.md (100%) rename tests/Integration/tests/markdown/{admonitions => md-admonitions}/input/guides.xml (100%) diff --git a/tests/Integration/tests/admonitions/expected/index.html b/tests/Integration/tests/admonitions/expected/index.html index efe5443d1..0779cc284 100644 --- a/tests/Integration/tests/admonitions/expected/index.html +++ b/tests/Integration/tests/admonitions/expected/index.html @@ -1,6 +1,6 @@
-

Admonitions: Tip, Note, Warning, See also, etc

+

Admonitions: Tip, Note, Warning, See also, etc 

-

Note

+

Note 

-

Tip

+

Tip 

-

Warning

+

Warning 

-

Attention

+

Attention