From 9582a6299ce3f9e3eb75c522657d12f096ab4fce Mon Sep 17 00:00:00 2001 From: Kai Moritz <kai@juplo.de> Date: Tue, 5 Jul 2016 10:58:21 +0200 Subject: [PATCH] Variable "menu" in "sections" umbenannt und Section-Handling vereinfacht --- dist/thymeleaf/templates/layout.html | 4 ++-- dist/thymeleaf/templates/variables.json | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/dist/thymeleaf/templates/layout.html b/dist/thymeleaf/templates/layout.html index 0fb2b014..2ff02556 100644 --- a/dist/thymeleaf/templates/layout.html +++ b/dist/thymeleaf/templates/layout.html @@ -111,8 +111,8 @@ <h1 class="nav">Navigation</h1> <h2 class="nav menu">Section-Menu</h2> <ul id="menu" class="cf"> - <li class="m blog" th:each="entry : ${menu}" th:class="'m ' + ${entry.key}"> - <a href="../blog.html" th:href="@{/__${entry.key}__.html}" class="m" th:class="${('/' + entry.key + '.html') == section.uri} ? 'm selected' : 'm'" th:text="${entry.value}">Blog</a> + <li class="m blog" th:each="entry : ${sections}" th:class="'m ' + ${entry.key}"> + <a href="../blog.html" th:href="@{${entry.value.uri}}" class="m" th:class="${entry.value.uri == section.uri} ? 'm selected' : 'm'" th:text="${entry.value.name}">Blog</a> </li> <!--/*--> <li class="m projects"><a href="../projects" class="m selected">Projects</a></li> diff --git a/dist/thymeleaf/templates/variables.json b/dist/thymeleaf/templates/variables.json index 2825cbe6..8b192f53 100644 --- a/dist/thymeleaf/templates/variables.json +++ b/dist/thymeleaf/templates/variables.json @@ -136,10 +136,10 @@ { "uri": "/projects/typo.html", "name": "Typography" } ] }, - "menu": { - "blog": "Blog", - "projects": "Projects", - "about": "About" + "sections": { + "blog": { "name": "Blog", "uri": "/blog.html" }, + "projects": { "name": "Projects", "uri": "/projects.html" }, + "about": { "name": "About", "uri": "/about.html" } }, "submenu": { "#": { "name": "hibernate4-maven-plugin" }, -- 2.20.1