diff --git a/common-theme/layouts/shortcodes/objectives.html b/common-theme/layouts/shortcodes/objectives.html new file mode 100644 index 000000000..8da019712 --- /dev/null +++ b/common-theme/layouts/shortcodes/objectives.html @@ -0,0 +1,11 @@ +{{ $items := slice }} +{{ $objectives := split .Inner "\n" }} +{{ range $objectives }} + {{ $objective := replace . "- [ ] " "" }} + {{ if ne (trim $objective " ") "" }} + {{ $items = $items | append $objective }} + {{ end }} +{{ end }} +{{ with $items }} + {{ partial "objectives/block" . }} +{{ end }} diff --git a/common-theme/layouts/shortcodes/tasks.html b/common-theme/layouts/shortcodes/tasks.html new file mode 100644 index 000000000..111f4f624 --- /dev/null +++ b/common-theme/layouts/shortcodes/tasks.html @@ -0,0 +1,12 @@ +{{ $items := slice }} +{{ $objectives := split .Inner "\n" }} +{{ range $objectives }} + {{ $objective := replace . "- [ ] " "" }} + {{ if ne (trim $objective " ") "" }} + {{ $items = $items | append $objective }} + {{ end }} +{{ end }} +{{ with $items }} + {{ partial "objectives/block" . }} +{{ end }} +