Skip to content

Plantuml not rendering in Readme only in Issues and Wiki  #19110

Closed
@lukaskwkw

Description

@lukaskwkw

Gitea Version

1.16.4

Git Version

2.30.2

Operating System

Windows 11

How are you running Gitea?

Docker image

Database

PostgreSQL

Can you reproduce the bug on the Gitea demo site?

No

Log Gist

No response

Description

PlantUML rendering is only working in Issues & Wiki. Not in README.md files.

I.e. using code in README.md

```plantuml
@startuml
Bob -> Alice : hello
@enduml
```

will generate <code> block with language-plantuml class but won't render any content in if body

{{if .RequireHighlightJS}}
nothing here
{{end}}

I was able to workaround this by adding PageIsViewCode condition into if statement from docs example:
https://docs.gitea.io/en-us/customizing-gitea/#example-plantuml

{{if or .PageIsViewCode .RequireHighlightJS}}

It might be similar to #12307

Screenshots

with single RequireHighlightJS condition
obraz
with addtional PageIsViewCode condition
obraz

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions