From c48c8628f6c6938dd1c1c52a00521f6785e34706 Mon Sep 17 00:00:00 2001 From: zhaohuabing Date: Thu, 30 Jun 2022 13:31:56 +0800 Subject: support plantuml Signed-off-by: zhaohuabing --- README.md | 27 +++++++++++++++++++++++++++ images/plantuml.png | Bin 0 -> 6816 bytes layouts/partials/footer.html | 16 ++++++++++++++++ 3 files changed, 43 insertions(+) create mode 100644 images/plantuml.png diff --git a/README.md b/README.md index d01ed64..8b90996 100644 --- a/README.md +++ b/README.md @@ -243,6 +243,33 @@ Vimeo {{< vimeo 146022717 >}} ``` +### Plantuml + +Plantuml support can be enabled at site or page level by adding the following line in the config.yaml or page header. + +``` +plantuml: true +``` + +Then you can just put plantuml source code in markdown files and the picture will be generated automatically. + +An example: + +``` +```plantuml +@startuml +Alice -> Bob: Authentication Request +Bob --> Alice: Authentication Response + +Alice -> Bob: Another authentication Request +Alice <-- Bob: Another authentication Response +@enduml +``` +``` + +![screenshot](https://raw.githubusercontent.com/zhaohuabing/hugo-theme-cleanwhite/master/images/plantuml.png) + + ## Thanks Thanks for the great jobs of [huxblog Jekyll Theme](https://github.com/Huxpro/huxpro.github.io) and [Clean Blog Jekyll Theme](https://github.com/BlackrockDigital/startbootstrap-clean-blog-jekyll) which are the the two upstream projects CleanWhite Hugo theme is based on. diff --git a/images/plantuml.png b/images/plantuml.png new file mode 100644 index 0000000..4158771 Binary files /dev/null and b/images/plantuml.png differ diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html index f061726..281587e 100644 --- a/layouts/partials/footer.html +++ b/layouts/partials/footer.html @@ -430,3 +430,19 @@ {{ end }} +{{ if or .Page.Params.plantuml .Site.Params.plantuml }} + + + +{{ end }} -- cgit v1.2.3