{{ define "css" }}
  <link rel="stylesheet" href="/css/visibleIf.css" type="text/css" />
{{ end }}
<h1>Artikelgenerator</h1>
<article class="minmax">
<div style="flex-direction: row;">
{{ .Content }}
</div >
<noscript><p><b>Bitte aktiviere Javascript, sonst funktioniert der Generator nicht.</b></p></noscript>

<form id="myform" style="display: flex; flex-shrink: 0; flex-grow: 1; flex-direction: column; max-width: 950px; margin-top: 1rem;">
  {{ partial "orga/generator/partials/input_line" (dict "name" "title" "mandatory" "true") }}
  {{ partial "orga/generator/content" }}
  {{ partial "orga/generator/partials/categories_and_tags.html" (dict "name" "categories" "expanded" "true"  "new" "false") }}
  {{ partial "orga/generator/partials/expand" (dict "id" "Ist es ein Event?" "name" "isevent" "translation" "aufklappen" ) }}
  <div style="flex-direction: column; margin-left: 2rem;" class="visibleIf" data-visibleif-rule="isevent == 'true'">
    {{ partial "orga/generator/partials/input_line" (dict "name" "when" "mandatory" "false" "eg" "Montag, 13. September 2022, 19Uhr") }}
    {{ partial "orga/generator/partials/input_line" (dict "name" "price" "mandatory" "false" "eg" "3€ or free") }}
    {{ partial "orga/generator/partials/input_line" (dict "name" "registeremail" "mandatory" "false" "eg" "info@bunteshaus.de") }}
    {{ partial "orga/generator/partials/categories_and_tags.html" (dict "name" "events"  "new" "false") }}
  </div>
  {{ partial "orga/generator/partials/expand" (dict "id" "Verschiedenes" "name" "misc" "translation" "aufklappen" ) }}
  <div style="flex-direction: column; margin-left: 2rem;" class="visibleIf" data-visibleif-rule="misc == 'true'">
    {{ partial "orga/generator/partials/truefalse" (dict "name" "featured" "expanded" "true") }}
    {{ partial "orga/generator/partials/truefalse" (dict "name" "about" "expanded" "true") }}
    {{ partial "orga/generator/partials/categories_and_tags.html" (dict "name" "tags" "new" "true") }}
    <!-- {{ partial "orga/generator/partials/input_line" (dict "name" "covid" "mandatory" "false" "eg" "3G") }} -->
  </div>

  <div id='display' class="result" style="white-space: pre; display: none; background: var(--background-body); padding: .6rem 0 1rem 1rem;">
  </div>

  {{ partial "orga/generator/submit" }}

</form>


</article>
<script defer language="javascript" type="text/javascript"  src="{{ "/js/visibleIf.js" | urlize | relURL }}"></script>
<script defer language="javascript" type="text/javascript"  src="{{ "/js/generator.js" | urlize | relURL }}"></script>