Skip to content
Snippets Groups Projects
Commit 7a36d986 authored by xaralis's avatar xaralis Committed by jan.bednarik
Browse files

fix(district,region): UI spacing and general fixes

parent c205dec3
No related branches found
No related tags found
2 merge requests!480Release,!476fix(district,region): UI spacing and general fixes
Pipeline #7780 passed
Showing
with 309 additions and 299 deletions
......@@ -204,10 +204,11 @@
{% block subheader %}{% endblock %}
<div class="container container--default {% block container_spacing %}py-8 lg:py-24{% endblock %}">
{% block container %}
<main class="container container--default {% block container_spacing %}py-8 lg:py-16{% endblock %}">
{% block content %}{% endblock %}
</div>
</main>
{% endblock%}
<footer class="footer bg-grey-700 text-white __js-root">
......
......@@ -2,7 +2,8 @@
{% image self.image width-356 as img %}
{% firstof self.page.url self.link as target_url %}
<article class="card card--hoveractive">
<article class="card">
<a href="{{ target_url }}">
<img src="{{ img.url }}" alt="{{ self.page.title }}" class="w-full h-48 object-cover">
</a>
......@@ -12,8 +13,8 @@
{{ self.title }}
</a>
</h1>
<p class="card-body-text">
<div class="card-body-text">
{{ self.text | default_if_none:'' | richtext }}
</p>
</div>
</div>
</article>
......@@ -2,7 +2,7 @@
<div class="mb-8">
{% if self.headline %}
<h1 class="head-alt-md md:head-alt-lg max-w-5xl mb-8">{{ self.headline }}</h1>
<h1 class="head-heavy-base mb-8">{{ self.headline }}</h1>
{% endif %}
<main>
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8">
......
<section>
<h2 class="head-heavy-base mb-4">
{{ self.group_title }}
</h2>
......@@ -6,3 +7,4 @@
{% include "shared/person_badge_snippet.html" with person_page=person_page.specific %}
{% endfor %}
</div>
</section>
......@@ -13,7 +13,7 @@
<div class="flex flex-col md:flex-row md:items-center">
<div class="inline-flex divide-x flex-grow">
<span class="pr-2">{{ page.date|date:"SHORT_DATE_FORMAT" }}</span>
<span class="pr-2">{{ page.date|date:"DATE_FORMAT" }}</span>
<span class="pl-2" itemprop="author" itemtype="http://schema.org/Person" itemscope="">
{% if page.author_page %}
<a href="{{ page.author_page.url }}" itemprop="name">{{ page.author }}</a>
......
{% extends "district/base.html" %}
{% block content %}
<main>
<header>
<h1 itemprop="headline" class="head-alt-md md:head-alt-lg max-w-5xl mb-8">{{ page.title }}</h1>
</header>
......@@ -13,5 +12,4 @@
</div>
{% include 'styleguide/2.3.x/pagination.html' with paginator=articles %}
</main>
{% endblock %}
......@@ -3,7 +3,7 @@
{% block subheader %}
{% image page.get_background_photo width-1920 as bg_img %}
<aside class="hero hero--image py-16 " style="--image-url: url({{ bg_img.url }})">
<header class="hero hero--image py-16 " style="--image-url: url({{ bg_img.url }})">
<div class="container container--default">
<h1 class="head-alt-md md:head-alt-lg max-w-2xl">
{{ page.title }}
......@@ -12,7 +12,7 @@
{{ page.perex }}
</h2>
</div>
</aside>
</header>
{% endblock %}
{% block container_spacing %}pt-8 lg:pb-16{% endblock %}
......@@ -53,5 +53,4 @@
</div>
</div>
</article>
{% endblock %}
{% extends "district/base.html" %}
{% load wagtailcore_tags wagtailimages_tags shared_filters %}
{% block container_spacing %}pt-8 pb-0 lg:py-16{% endblock %}
{% block content %}
<article class="space-y-8 lg:space-y-16">
<div class="lg:flex lg:mt-8 space-y-16 lg:space-y-0 lg:space-x-8 xl:space-x-16 mb-5">
<div class="lg:flex space-y-8 lg:space-y-0 lg:space-x-8 xl:space-x-16 mb-8 lg:mb-16">
<section class="lg:w-3/5 xl:w-2/3">
<header>
<h1 itemprop="headline" class="head-alt-md md:head-alt-lg max-w-5xl mb-8">{{ page.title }}</h1>
......@@ -29,7 +30,7 @@
</div>
</section>
<section class="lg:w-2/5 xl:w-1/3 lg:pt-0">
<section class="lg:w-2/5 xl:w-1/3">
<div class="lg:card lg:elevation-10">
<div class="lg:card__body content-block">
......@@ -86,5 +87,4 @@
</div>
{% include "shared/followus_snippet.html" %}
</article>
{% endblock %}
{% extends "district/base.html" %}
{% load wagtailcore_tags %}
{% block container_spacing %}pt-8 pb-0 lg:py-16{% endblock %}
{% block content %}
<section class="pt-8 lg:py-24">
<div class="mb-8 lg:mb-16">
<header>
<h1 itemprop="headline" class="head-alt-md md:head-alt-lg max-w-5xl mb-8">{{ page.title }}</h1>
</header>
{% for card_block in page.cards_content %}
{% include_block card_block %}
{% endfor %}
{% for block in page.content %}
<div class="content-block mb-8">
{% include_block block %}
</div>
{% endfor %}
</section>
</div>
{% include "shared/followus_snippet.html" %}
{% endblock %}
......@@ -2,8 +2,7 @@
{% load static wagtailcore_tags %}
{% block content %}
<main>
<article class="pt-8 lg:py-24">
<article>
<header>
<h1 itemprop="headline" class="head-alt-md md:head-alt-lg max-w-5xl mb-4">
{{ page.title }}
......@@ -49,5 +48,4 @@
</div>
</article>
</main>
{% endblock %}
......@@ -7,12 +7,11 @@
{% endfor %}
{% endblock subheader %}
{% block content %}
{% block container %}
<div class="__js-root">
<ui-view-provider
:initial="{candidates: true, program: false}" :sync-location="true" v-slot="{ isCurrentView, toggleView }"
>
<main>
<div class="container container--default pt-8 lg:py-24">
<div class="text-center">
<div class="switch">
......@@ -51,7 +50,7 @@
</div>
</template>
<div class="flex flex-col pt-8 lg:pt-24 lg:flex-row lg:space-x-8">
<div class="flex flex-col pt-8 lg:pt-16 lg:flex-row lg:space-x-8">
{% if page.strategy_page %}
<a
href="{{ page.strategy_page.url }}"
......@@ -70,8 +69,7 @@
</a>
</div>
</div>
</main>
</ui-view-provider>
</div>
{% endblock content %}
{% endblock %}
......@@ -7,8 +7,9 @@
{% endfor %}
{% endblock subheader %}
{% block container_spacing %}pt-8 lg:py-16{% endblock %}
{% block content %}
<main {% if page.subheader %}class="py-8 lg:py-16"{% endif %}>
<h2 class="head-alt-md md:head-alt-lg pb-4 lg:pb-8">
{{ page.articles_title }}
</h2>
......@@ -19,7 +20,7 @@
{% endfor %}
</div>
<div class="mb-8">
<div class="mb-8 lg:mb-16">
{% include "shared/more_articles_snippet.html" %}
</div>
......@@ -36,5 +37,4 @@
{% endif %}
{% include "shared/followus_snippet.html" %}
</main>
{% endblock %}
......@@ -8,13 +8,10 @@
</h1>
</header>
<main>
{% for block in page.content %}
{% include_block block %}
{% if not forloop.last %}
<hr class="hr--big">
{% endif %}
{% endfor %}
</main>
{% endblock %}
......@@ -17,7 +17,7 @@
</header>
{% endblock %}
{% block container_spacing %}py-8 lg:pb-24{% endblock %}
{% block container_spacing %}py-8 lg:pb-16{% endblock %}
{% block content %}
<main>
......
{% extends "district/base.html" %}
{% block content %}
<main>
<h1 class="head-alt-md md:head-alt-lg max-w-5xl mb-4 mt-5">
<h1 class="head-alt-md md:head-alt-lg max-w-5xl mb-4">
{% if tag %}{{ page.title }} "{{ tag.name }}"{% else %}Výběr z článků{% endif %}
</h1>
<div class="space-y-8">
<div class="article-card-list grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 gap-4 lg:gap-8">
{% for a in article_page_list %}
{% include "shared/article_preview.html" with article=a %}
......@@ -15,17 +14,19 @@
{% include 'styleguide/2.3.x/pagination.html' with paginator=article_page_list %}
<h2 class="mt-8 head-alt-base">Další štítky:</h2>
<div>
<h2 class="head-heavy-base mb-4">Další štítky</h2>
<div class="inline-block-nogap mt-4">
<nav class="inline-block-nogap">
{% for tag in tag_list %}
<a
href="{{ page.url }}?tag={{ tag.slug }}"
class="btn article-card__category-button btn--condensed text-sm font-light btn--grey-{% if tag.slug == request.GET.tag %}500{% else %}125{% endif %} btn--hoveractive"
class="btn btn--condensed font-light text-sm btn--grey-{% if tag.slug == request.GET.tag %}500{% else %}125{% endif %} btn--hoveractive mr-1 mb-1 inline-block"
>
<div class="btn__body ">{{ tag.name }} ({{ tag.count }})</div>
</a>
{% endfor %}
</nav>
</div>
</div>
</main>
{% endblock %}
......@@ -197,9 +197,12 @@
{% block subheader %}{% endblock %}
<div class="container {% block container_spacing %}py-8 lg:py-24{% endblock %}">
{% block container %}
<main class="container container--default {% block container_spacing %}py-8 lg:py-16{% endblock %}">
{% block content %}{% endblock %}
</div>
</main>
{% endblock%}
<footer class="footer bg-grey-700 text-white __js-root">
......
......@@ -2,7 +2,8 @@
{% image self.image width-356 as img %}
{% firstof self.page.url self.link as target_url %}
<article class="card card--hoveractive">
<article class="card">
<a href="{{ target_url }}">
<img src="{{ img.url }}" alt="{{ self.page.title }}" class="w-full h-48 object-cover">
</a>
......@@ -12,8 +13,8 @@
{{ self.title }}
</a>
</h1>
<p class="card-body-text">
<div class="card-body-text">
{{ self.text | default_if_none:'' | richtext }}
</p>
</div>
</div>
</article>
......@@ -2,7 +2,7 @@
<div class="mb-8">
{% if self.headline %}
<h1 class="head-alt-md md:head-alt-lg max-w-5xl mb-8">{{ self.headline }}</h1>
<h1 class="head-heavy-base mb-8">{{ self.headline }}</h1>
{% endif %}
<main>
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-8">
......
<section>
<h2 class="head-heavy-base mb-4">
{{ self.group_title }}
</h2>
......@@ -6,3 +7,4 @@
{% include "shared/person_badge_snippet.html" with person_page=person_page.specific %}
{% endfor %}
</div>
</section>
......@@ -13,7 +13,7 @@
<div class="flex flex-col md:flex-row md:items-center">
<div class="inline-flex divide-x flex-grow">
<span class="pr-2">{{ page.date|date:"SHORT_DATE_FORMAT" }}</span>
<span class="pr-2">{{ page.date|date:"DATE_FORMAT" }}</span>
<span class="pl-2" itemprop="author" itemtype="http://schema.org/Person" itemscope="">
{% if page.author_page %}
<a href="{{ page.author_page.url }}" itemprop="name">{{ page.author }}</a>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment