From 2e5f7ddd3a6e52b3c3f10cf900b68026da0e28ea Mon Sep 17 00:00:00 2001 From: zeripath Date: Sat, 24 Jul 2021 05:21:51 +0100 Subject: [PATCH] Make Mermaid.js limit configurable (#16519) * Make Mermaid.js limit configurable Add `MERMAID_MAX_SOURCE_CHARACTERS` to `[markup]` settings to make the maximum size of a mermaid render configurable. Fix #16513 Signed-off-by: Andrew Thornton * fixup! Make Mermaid.js limit configurable * Update custom/conf/app.example.ini Co-authored-by: silverwind * Update docs/content/doc/advanced/config-cheat-sheet.en-us.md Co-authored-by: silverwind Co-authored-by: silverwind Co-authored-by: Lunny Xiao --- doc/advanced/config-cheat-sheet.en-us.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/doc/advanced/config-cheat-sheet.en-us.md b/doc/advanced/config-cheat-sheet.en-us.md index a8000945..41dd0b70 100644 --- a/doc/advanced/config-cheat-sheet.en-us.md +++ b/doc/advanced/config-cheat-sheet.en-us.md @@ -882,6 +882,8 @@ NB: You must have `DISABLE_ROUTER_LOG` set to `false` for this option to take ef ## Markup (`markup`) +- `MERMAID_MAX_SOURCE_CHARACTERS`: **5000**: Set the maximum size of a Mermaid source. (Set to -1 to disable) + Gitea can support Markup using external tools. The example below will add a markup named `asciidoc`. ```ini