diff --git a/config/tree.go b/config/tree.go index ef21787..fdd0665 100644 --- a/config/tree.go +++ b/config/tree.go @@ -44,7 +44,7 @@ func cleanUpMapValue(v interface{}) interface{} { return cleanUpInterfaceArray(v) case map[interface{}]interface{}: return cleanUpInterfaceMap(v) - case string: + case string, bool, int, int8, int16, int32, int64, float32, float64: return v default: return fmt.Sprintf("%v", v) diff --git a/test.rest b/test.rest index 25443dd..b04dee0 100644 --- a/test.rest +++ b/test.rest @@ -1,6 +1,6 @@ GET https://mark2web.basiscms.de/api/collections/get/mark2webBlog ?sort[date]=-1 - &limit=1 + &limit=101 &token=89ff216524093123bf7a0a10f7b273 ### diff --git a/website/content/config.yml b/website/content/config.yml index 5a994f7..71b7749 100644 --- a/website/content/config.yml +++ b/website/content/config.yml @@ -11,6 +11,6 @@ Markdown: ChromaStyle: monokai Data: - debug: True + debug: False matomoSiteId: 89 token: 89ff216524093123bf7a0a10f7b273 # cockpit api token \ No newline at end of file diff --git a/website/content/de/01_Navigation/03_Benutzung/01_Ordnerstruktur/README.md b/website/content/de/01_Navigation/03_Benutzung/01_Ordnerstruktur/README.md index 55b71b0..501d8cf 100644 --- a/website/content/de/01_Navigation/03_Benutzung/01_Ordnerstruktur/README.md +++ b/website/content/de/01_Navigation/03_Benutzung/01_Ordnerstruktur/README.md @@ -1,5 +1,6 @@ --- Data: + background: /img/folder.jpg slider: - img: /img/folder.jpg diff --git a/website/content/de/01_Navigation/03_Benutzung/02_Konfiguration/README.md b/website/content/de/01_Navigation/03_Benutzung/02_Konfiguration/README.md index 24cc00d..f243e05 100644 --- a/website/content/de/01_Navigation/03_Benutzung/02_Konfiguration/README.md +++ b/website/content/de/01_Navigation/03_Benutzung/02_Konfiguration/README.md @@ -1,5 +1,6 @@ --- Data: + background: /img/wire.jpg slider: - img: /img/wire.jpg diff --git a/website/content/de/01_Navigation/03_Benutzung/03_Inhalte/README.md b/website/content/de/01_Navigation/03_Benutzung/03_Inhalte/README.md index f0f3384..5f6d624 100644 --- a/website/content/de/01_Navigation/03_Benutzung/03_Inhalte/README.md +++ b/website/content/de/01_Navigation/03_Benutzung/03_Inhalte/README.md @@ -1,5 +1,6 @@ --- Data: + background: /img/write.jpg slider: - img: /img/write.jpg diff --git a/website/content/de/01_Navigation/03_Benutzung/04_Templates/README.md b/website/content/de/01_Navigation/03_Benutzung/04_Templates/README.md index a9bb385..ab49ee5 100644 --- a/website/content/de/01_Navigation/03_Benutzung/04_Templates/README.md +++ b/website/content/de/01_Navigation/03_Benutzung/04_Templates/README.md @@ -1,5 +1,6 @@ --- Data: + background: /img/design.jpg slider: - img: /img/design.jpg diff --git a/website/templates/base.html b/website/templates/base.html index 64eb001..4a0a56c 100755 --- a/website/templates/base.html +++ b/website/templates/base.html @@ -31,11 +31,11 @@ <header id="header"> <div class="container"> - <div class="logo" {% if not Data.slider %}style="max-width: 400px;"{% endif %}> + <div class="logo" {% if not Data.slider and not Data.details.slider %}style="max-width: 400px;"{% endif %}> <a href="{{ "/"|relative_path }}"> <picture> <source media="(max-width: 768px)" srcset="project-files/img/logo_text.png"> - <img src="project-files/img/logo{% if not Data.slider %}_text{% endif %}.png" alt="mark2web Logo"> + <img src="project-files/img/logo{% if not Data.slider and not Data.details.slider %}_text{% endif %}.png" alt="mark2web Logo"> </picture> </a> </div> @@ -52,6 +52,7 @@ <!-- ========== Slider ========== --> <section class="slider white_arrows" data-dots="true" data-arrows="true"> + {% block slider %} {% for sl in Data.slider %} <div class="slide"> <img @@ -62,6 +63,7 @@ alt="{{ sl.alt }}" style="opacity:{{ sl.opacity|default:1 }}"> </div> {% endfor %} + {% endblock slider %} </section> <!-- ========== Navigation ========== --> @@ -124,7 +126,7 @@ <pre>{{ Data|json:"pretty" }}</pre> <h3>NavMap</h3> - <pre>{{ NavMap|json: "pretty" }}</pre> + <pre>{{ NavMap|json:"pretty" }}</pre> {% endif %} diff --git a/website/templates/base_blog_details.html b/website/templates/base_blog_details.html index 00d298f..7d91348 100644 --- a/website/templates/base_blog_details.html +++ b/website/templates/base_blog_details.html @@ -6,6 +6,21 @@ <meta name="keywords" content="{{ Meta.Keywords }}" /> {% endblock meta %} +{% if Data.details.slider %} + {% block slider %} + {% for sl in Data.details.slider %} + <div class="slide"> + <img + src="{{ "https://mark2web.basiscms.de"|add:sl.path|image_process:"p=fill,w=1440,h=600,q=60" }}" + srcset="{{ "https://mark2web.basiscms.de"|add:sl.path|image_process:"p=fill,w=768,h=384,q=60" }} 768w, + {{ "https://mark2web.basiscms.de"|add:sl.path|image_process:"p=fill,w=1440,h=600,q=60" }} 1440w, + {{ "https://mark2web.basiscms.de"|add:sl.path|image_process:"p=fill,w=1920,h=800,q=60" }} 1920w" + alt="{{ sl.meta.title }}"> + </div> + {% endfor %} + {% endblock slider %} +{% endif %} + {% block part0 %} <h1> {{ Data.details.title }}