Commit 8ca7b339 authored by Konrad Mohrfeldt's avatar Konrad Mohrfeldt

add claim support. refs #495

parent 26749bfa
Pipeline #1210 failed with stage
in 56 seconds
......@@ -4,9 +4,10 @@ from django.contrib.sites import shortcuts
def settings(request):
return {
'STADTGESTALTEN_LOGO_URL': django.conf.settings.STADTGESTALTEN_LOGO_URL,
'STADTGESTALTEN_SHOW_HEADER': django.conf.settings.STADTGESTALTEN_SHOW_HEADER,
}
'STADTGESTALTEN_LOGO_URL': django.conf.settings.STADTGESTALTEN_LOGO_URL,
'STADTGESTALTEN_SHOW_HEADER': django.conf.settings.STADTGESTALTEN_SHOW_HEADER,
'STADTGESTALTEN_CLAIMS': getattr(django.conf.settings, 'STADTGESTALTEN_CLAIMS', [])
}
def site(request):
......
{% random STADTGESTALTEN_CLAIMS as claim %}
{% if claim %}
<div class="breadcrumb claim">
<i class="fa fa-bullhorn"></i>
<span>{{ claim }}</span>
</div>
{% endif %}
......@@ -10,11 +10,12 @@
<div class="wrap wrap-prefix">
<div class="container">
<div class="page-prefix">
<div class="breadcrumb">{% spaceless %}
<div class="breadcrumb {% if not STADTGESTALTEN_CLAIMS %}breadcrumb-visible{% endif %}">{% spaceless %}
{% block breadcrumb %}
{% include 'core/_page_breadcrumb.html' %}
{% endblock %}
{% endspaceless %}</div>
{% include 'core/_claim.html' %}
{% include 'stadt/_page_meta.html' %}
</div>
</div>
......
......@@ -70,3 +70,4 @@
@import "components/poll";
@import "components/search";
@import "components/chart";
@import "components/claim";
......@@ -7,7 +7,11 @@
white-space: nowrap;
border-radius: 2px;
&:empty {
&:not(.breadcrumb-visible):empty {
display: none;
}
&.breadcrumb-visible:empty {
visibility: hidden;
}
......
.claim {
display: inline-flex;
align-items: center;
i {
margin-right: 1rem;
}
.breadcrumb:not(:empty) + & {
display: none !important;
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment