WIP
authorKai Moritz <kai@juplo.de>
Mon, 6 May 2019 20:12:29 +0000 (22:12 +0200)
committerKai Moritz <kai@juplo.de>
Mon, 6 May 2019 20:12:29 +0000 (22:12 +0200)
src/main/resources/META-INF/maven/site.vm

index b5a3ca1..cabe610 100644 (file)
     th:replace="~{/templates/layout.html :: layout(
       uri='$sitePath$alignedFileName',
       json='MERGE:
-{
-  &quot;_names&quot;:{#set($sep = "")#foreach($page in $pages)$sep&quot;$sitePath$page.uri&quot;:&quot;$page.name&quot;#set($sep = ",")#end},
-  &quot;_childs&quot;:{#set($sep = "")#foreach($page in $pages)
-    #if(!$page.childs.isEmpty())$sep&quot;$sitePath$page.uri&quot;:[#set($csep = "")#foreach($child in $page.childs.entrySet())
-      $csep&quot;$sitePath$child.key&quot;#set($csep = ",")
-      #end]#set($sep = ",")
-    #end
-  #end},
-  &quot;_crumbs&quot;:{#set($sep = "")#foreach($page in $pages)
-    $sep&quot;$sitePath$page.uri&quot;:[#set($csep = "")
-      #if($siteCrumbs)$siteCrumbs#set($csep = ",")#end
-      #foreach($crumb in $page.crumbs)
-      $csep&quot;$sitePath$crumb.uri&quot;#set($csep = ",")
-      #end]#set($sep = ",")
-    #end}
-}
+      {
+        &quot;_names&quot;: {
+          #set($sep = "")
+          #foreach($page in $pages)
+            $sep
+            &quot;$sitePath$page.uri&quot;: &quot;$page.name&quot;
+            #set($sep = ",")
+          #end
+        },
+        &quot;_childs&quot;: {
+          #set($sep = "")
+          #foreach($page in $pages)
+            #if(!$page.childs.isEmpty())
+              $sep
+              &quot;$sitePath$page.uri&quot;: [
+                #set($csep = "")
+                #foreach($child in $page.childs.entrySet())
+                  $csep
+                  &quot;$sitePath$child.key&quot;
+                  #set($csep = ",")
+                #end
+              ]
+              #set($sep = ",")
+            #end
+          #end
+        },
+        &quot;_crumbs&quot;: {
+          #set($sep = "")
+          #foreach($page in $pages)
+            $sep
+            &quot;$sitePath$page.uri&quot;: [
+              #set($csep = "")
+              #if($siteCrumbs)
+                $siteCrumbs
+                #set($csep = ",")
+              #end
+              #foreach($crumb in $page.crumbs)
+                $csep
+                &quot;$sitePath$crumb.uri&quot;
+                #set($csep = ",")
+              #end
+            ]
+            #set($sep = ",")
+          #end
+        }
+      }
       ')}"
     >
   <head>