diff --git a/content/rezept/klassisch/contents.lr b/content/rezept/klassisch/contents.lr index d09be94..04cd930 100644 --- a/content/rezept/klassisch/contents.lr +++ b/content/rezept/klassisch/contents.lr @@ -2,10 +2,7 @@ title: klassischer Waffelteig --- author: L3D --- -body: - -Der klassischer Waffelteig ist zu finden auf: -[rezept.yaml](rezept.yaml) +body: --- pub_date: 2021-07-19 --- diff --git a/content/rezept/klassisch/rezept.yaml/contents.lr b/content/rezept/klassisch/rezept.yaml/contents.lr index 9e2d013..521b62d 100644 --- a/content/rezept/klassisch/rezept.yaml/contents.lr +++ b/content/rezept/klassisch/rezept.yaml/contents.lr @@ -56,8 +56,12 @@ notes: ##### flow_notes ##### note: Statt Eier sollte man, wenn möglich, Vollei verwenden +----- +html: ##### flow_notes ##### -note: Eier nicht im Orginalkaton lagern +note: Eier möglichst nicht im Orginalkaton lagern +----- +html: ---- substitutions: #### flow_ingredients #### @@ -82,6 +86,8 @@ notes: ##### flow_notes ##### note: 1l Vollei entspricht 20 Eiern +----- +html: ---- substitutions: #### flow_ingredients #### @@ -176,6 +182,8 @@ notes: note: Backpulver vergrößert das Volumen des Teigs +----- +html: yes ---- substitutions: #### flow_ingredients #### @@ -200,6 +208,8 @@ notes: ##### flow_notes ##### note: Wenn möglich Frischmilch verwenden +----- +html: no ---- substitutions: #### flow_ingredients #### @@ -267,6 +277,8 @@ notes: ###### flow_notes ###### note: Alternativ zu Sprudel kann auch fast jedes andere Kohlensäurehaltige Getränk verwendet werden. +------ +html: #### flow_ingredients #### ingredient: Rum ---- @@ -280,6 +292,8 @@ notes: ##### flow_notes ##### note: optional +----- +html: yes ---- substitutions: #### flow_ingredients #### @@ -382,3 +396,5 @@ notes: ##### flow_notes ##### note: Waffeln optional zB. mit Puderzucker und Apfelmus verzieren. +----- +html: diff --git a/flowblocks/flow_notes.ini b/flowblocks/flow_notes.ini index 0e5aef4..7d807f0 100644 --- a/flowblocks/flow_notes.ini +++ b/flowblocks/flow_notes.ini @@ -3,5 +3,11 @@ name = Notizen und Details button_label = Notizen und Details [fields.note] -label = Notiz +label = Notiz zur Zutat type = string +width = 3/4 + +[fields.html] +type = boolean +width = 1/4 +label = hide in HTML version diff --git a/models/rezept-post.ini b/models/rezept-post.ini index b77a7b2..e3c4963 100644 --- a/models/rezept-post.ini +++ b/models/rezept-post.ini @@ -26,11 +26,12 @@ width = 1/2 [fields.orf] label = Render from Open Recepie Format -description = Render recepie with data from the ORF childpage +description = Render recepie with data from the ORF childpage. (create/open childpage and follow instruction for more) type = boolean [fields.body] -label = Body +label = Rezept Body +description = Freitextfeld für weitere Angaben zum Rezept type = markdown [fields.weight] diff --git a/templates/macros/rezept.html b/templates/macros/rezept.html index 90eca1e..943214f 100644 --- a/templates/macros/rezept.html +++ b/templates/macros/rezept.html @@ -1,18 +1,5 @@ {%- macro render_rezept_post(post, from_index=false, section_class='-odd') -%} {{- '\n ' -}}
- {{- '\n ' -}}
- {{- '\n ' -}}
- {%- if from_index -%} - {{- '\n ' -}}

{{ post.title }}

- {%- else -%} - {{- '\n ' -}}

{{ post.title }}

- {% endif %} - {{- '\n ' -}}
- {{- '\n ' -}} - {{- '\n ' -}}
- {{- '\n ' -}}
{%- if post.orf | default(false) -%} {#- Render recepie based on open recipe format @@ -29,11 +16,9 @@ {%- endif -%} {%- endif -%} {%- endfor -%} + {%- include "macros/rezept_body.html" -%} + {%- else -%} + {%- include "macros/rezept_body.html" -%} {%- endif %} - {{- '\n ' -}}
- {{- '\n ' -}}
- {{- '\n ' -}} {{- post.body -}} - {{- '\n ' -}}
- {{- '\n ' -}}
{{- '\n ' -}}
{%- endmacro -%} diff --git a/templates/macros/rezept_body.html b/templates/macros/rezept_body.html new file mode 100644 index 0000000..8e7f376 --- /dev/null +++ b/templates/macros/rezept_body.html @@ -0,0 +1,10 @@ +{#- + Render post.body +-#} +{%- if post.body is defined and post.body != "" -%} + {{- '\n ' -}}
+ {{- '\n ' -}}
+ {{- '\n ' -}} {{- post.body -}} + {{- '\n ' -}}
+ {{- '\n ' -}}
+{%- endif -%} diff --git a/templates/rezept-post.html b/templates/rezept-post.html index 2da46da..6ed221c 100644 --- a/templates/rezept-post.html +++ b/templates/rezept-post.html @@ -1,18 +1,18 @@ -{% extends "header_slim.html" %} -{% from "macros/rezept.html" import render_rezept_post %} +{%- extends "header_slim.html" -%} +{%- from "macros/rezept.html" import render_rezept_post -%} {%- block title -%}{{ this.title }}{%- endblock -%} {%- block meta_description -%} {%- if this.meta_description is defined and this.meta_description != "" -%} - {{ this.meta_description }} + {{- this.meta_description -}} {%- else -%} C3WOC {%- endif -%} {%- endblock -%} -{% block body %} -
-
-

{{ this.title }}

-
-
- {{ render_rezept_post(this) }} -{% endblock %} +{%- block body -%} + + {{- render_rezept_post(this) -}} + + {#- + LINK zu Gesundheitsamt / Hygienehinweise... + -#} +{%- endblock -%} diff --git a/templates/zutaten/zutat_notes.html b/templates/zutaten/zutat_notes.html index 26bf02a..ca47d86 100644 --- a/templates/zutaten/zutat_notes.html +++ b/templates/zutaten/zutat_notes.html @@ -36,16 +36,45 @@ {%- if ing.notes is defined and ing.notes != "" -%} {%- if ing.notes.blocks != [] -%} {%- for nde in ing.notes.blocks -%} - {%- if loop.index == 1 -%} - {{- '\n ' -}}

Notiz zu {{ ing.ingredient }}:

- {{- '\n ' -}} {%- endif -%} {%- endif -%} {%- endif -%}