diff --git a/main/models.py b/main/models.py index 957682da9cb5abc56e320c74d1ec81cb88d700b2..01849262bceb5e31134b1cab3e51f9a8fab46b25 100644 --- a/main/models.py +++ b/main/models.py @@ -575,7 +575,7 @@ class MainPersonPage(ExtendedMetadataPageMixin, SubpageMixin, MetadataPageMixin, people = StreamField( [("people_group", blocks.PeopleGroupBlock(label="Seznam osob"))], - verbose_name="Lidé", + verbose_name="Další lidé", blank=True, ) diff --git a/main/static/main/css/styles.css b/main/static/main/css/styles.css index aaaff8161980f09679dc4f96bfe7aa425ae9383f..1df39cbcb5573c6c996829c60785c147b88f9095 100644 --- a/main/static/main/css/styles.css +++ b/main/static/main/css/styles.css @@ -2667,7 +2667,7 @@ p{ .contact-box{ display: flex; - height: 20rem; + height: auto; flex-direction: column; align-items: center; justify-content: space-between; @@ -4499,6 +4499,10 @@ a.icon-link:hover span{ margin-bottom: 3rem; } + .xl\:mr-4{ + margin-right: 1rem; + } + .xl\:mb-0{ margin-bottom: 0px; } diff --git a/main/styleguide/source/_patterns/molecules/articles/article-carousel-item.mustache b/main/styleguide/source/_patterns/molecules/articles/article-carousel-item.mustache index 5ff4053bae2432488d6f50ce9c7c0bfa9abbe7da..b6f8605e7f98dd56a4d9006d0cee46eb09a9a143 100644 --- a/main/styleguide/source/_patterns/molecules/articles/article-carousel-item.mustache +++ b/main/styleguide/source/_patterns/molecules/articles/article-carousel-item.mustache @@ -1,13 +1,17 @@ <div> <div class="flex max-w-md items-start xl:mr-2"> + <a href="#" class="mr-4"> <img src="https://i.picsum.photos/id/523/132/132.jpg?hmac=XjW7KxLZNbta7gMDNvldHNGwA9XyxpjBFUGkJqrMR4o" alt="" - class="w-16 xl:w-36 mr-4"> + class="w-16 xl:w-36"> + </a> <div class="flex flex-col justify-between items-start"> <span class="text-green-500 mb-2">23.2.2022</span> - <h4 class="font-alt leading-5 text-base uppercase lg:text-base mb-2"> - Komentář Lukáše Koláříka: Kriminalita ve virtuálním prostoru není imaginární, - ale skutečná. Jak nenaletět internetovým šmejdům? - </h4> + <a href="#"> + <h4 class="font-alt leading-5 text-base uppercase lg:text-base mb-2"> + Komentář Lukáše Koláříka: Kriminalita ve virtuálním prostoru není imaginární, + ale skutečná. Jak nenaletět internetovým šmejdům? + </h4> + </a> {{> atoms-button-animated(btn-text: "Zjistit více") }} </div> </div> diff --git a/main/styleguide/source/_patterns/molecules/articles/main-article-preview.mustache b/main/styleguide/source/_patterns/molecules/articles/main-article-preview.mustache index fc4a8cb461ce0f96d200e0dc40876875018fce14..9d2c39e800ff6a219e4123efe5d37ed030d40f9b 100644 --- a/main/styleguide/source/_patterns/molecules/articles/main-article-preview.mustache +++ b/main/styleguide/source/_patterns/molecules/articles/main-article-preview.mustache @@ -1,10 +1,12 @@ <div class="flex flex-wrap mb-5 lg:mb-10"> + <a href="#"> <img src="https://i.picsum.photos/id/361/576/576.jpg?hmac=kb62KiZkyDuigb46DUJQd7QvQM6LfYFolTdIMwEqei4" alt="" class="lg:max-w-lg lg:mr-11 h-fit"> + </a> <div class="flex flex-col max-w-xl items-start"> <span class="text-green-500 head-3xl mt-10 mb-4 lg:mb-8">2.3.2022</span> - <h5 class="head-4xl mb-5 lg:mb-10">Senátoři vyzvali k ukončení veřejné podpory firmám z Ruska - a Běloruska, vkteré neodsoudí akt vojenské agrese na Ukrajině</h5> + <a href="#" class="head-4xl mb-5 lg:mb-10">Senátoři vyzvali k ukončení veřejné podpory firmám z Ruska + a Běloruska, vkteré neodsoudí akt vojenské agrese na Ukrajině</a> <p class="leading-6 mb-4 lg:mb-8"> Senát chce v souvislosti s ruskou agresí zabránit některým firmám z Ruska a Běloruska čerpat dotace z prostředků rozpočtu České republiky. diff --git a/main/styleguide/source/_patterns/molecules/articles/person-article-preview.mustache b/main/styleguide/source/_patterns/molecules/articles/person-article-preview.mustache index 9f5089225483b07c71d445a9049ccf0b15549460..7b10b8bcc9ab9f61daefabe819a692e326ae1f9a 100644 --- a/main/styleguide/source/_patterns/molecules/articles/person-article-preview.mustache +++ b/main/styleguide/source/_patterns/molecules/articles/person-article-preview.mustache @@ -1,11 +1,13 @@ <div class="flex flex-col justify-between items-start mb-9"> - <div class="flex font-bold mb-4 text-xs text-white uppercase"> - <span class="bg-green-500 mr-1 px-1">Duben 2022</span> - <span class="bg-violet-600 mr-1 px-1">#ENERGETIKA</span> + <div class="flex flex-wrap font-bold mb-4 text-xs text-white uppercase"> + <span class="mb-1 bg-green-500 mr-1 px-1">Duben 2022</span> + <span class="mb-1 bg-violet-600 mr-1 px-1">#ENERGETIKA</span> </div> - <h4 class="head-3xl mb-4"> - Ukončili jsme povinné přimíchávání biopaliv první generace do pohonných hmot - </h4> + <a href="#"> + <h4 class="head-3xl mb-4"> + Ukončili jsme povinné přimíchávání biopaliv první generace do pohonných hmot + </h4> + </a> <p class="mb-6"> Povinné přimíchávání biopaliv do benzínu a nafty jsme chtěli zcela zrušit už v minulém volebním období. Tehdy jsme zabránili zvýšení podílu biosložky, diff --git a/main/styleguide/source/_patterns/molecules/box-link.mustache b/main/styleguide/source/_patterns/molecules/box-link.mustache index fa3596f21efe54779a5bd83f4cfce7c1a565e274..89617063fa523239f9d87c0a8f60eba705f73087 100644 --- a/main/styleguide/source/_patterns/molecules/box-link.mustache +++ b/main/styleguide/source/_patterns/molecules/box-link.mustache @@ -2,5 +2,5 @@ <img src="https://i.picsum.photos/id/865/90/100.jpg?hmac=0E2Zv4lGASwKCcZxquMc_v2Y3Rg68gw21euyRQ1bu80" alt="" class="mb-8 max-w-20 max-h-20"> <h5 class="head-4xl mb-8">naloď se k pirátům</h5> - {{> atoms-button-animated(btn-text: "Přidat se k nám") }} + {{> atoms-button-animated(btn-text: "Přidat se k nám" classes="shrink-0") }} </div> diff --git a/main/styleguide/source/_patterns/molecules/how-we-work/work-article-preview.mustache b/main/styleguide/source/_patterns/molecules/how-we-work/work-article-preview.mustache index 4011e5265175b81d16b70a249546586ff53571ee..76bbdf35e9c5de9b5adc7d217d42512397b99bf1 100644 --- a/main/styleguide/source/_patterns/molecules/how-we-work/work-article-preview.mustache +++ b/main/styleguide/source/_patterns/molecules/how-we-work/work-article-preview.mustache @@ -1,7 +1,11 @@ <div class="p-7 flex flex-col max-w-xl border border-grey-150 mb-8"> - <img src="https://i.picsum.photos/id/689/576/281.jpg?hmac=yIwOFV185zFy4fwVE3lF1UDqLDAm_bpLr9LZprQ26eo" alt="" - class="mb-7"> - <h2 class="head-2xl mb-4">Konec mezinárodní ostudy. Evropská komise uzavřela řízení o střetu zájmů</h2> + <a href="#"> + <img src="https://i.picsum.photos/id/689/576/281.jpg?hmac=yIwOFV185zFy4fwVE3lF1UDqLDAm_bpLr9LZprQ26eo" alt="" + class="mb-7 w-full"> + </a> + <a href="#"> + <h2 class="head-2xl mb-4">Konec mezinárodní ostudy. Evropská komise uzavřela řízení o střetu zájmů</h2> + </a> <div class="flex font-bold mb-4 text-xs text-white uppercase"> <span class="bg-green-500 mr-1 p-2">Duben 2022</span> <span class="bg-violet-600 mr-1 p-2">#ENERGETIKA</span> diff --git a/main/styleguide/source/css/molecules/contact_box.pcss b/main/styleguide/source/css/molecules/contact_box.pcss index 7923617dff2ddc19ca73b0630964aaf7cdf5c4f0..0ace8621e134db116f404fa4ad19a57513c2c303 100644 --- a/main/styleguide/source/css/molecules/contact_box.pcss +++ b/main/styleguide/source/css/molecules/contact_box.pcss @@ -1,4 +1,4 @@ .contact-box { - @apply border border-grey-100 flex flex-col h-80 items-center justify-between px-16 py-8 text-center; + @apply border border-grey-100 flex flex-col h-auto min-h-80 items-center justify-between px-16 py-8 text-center; width: 280px; } diff --git a/main/templates/main/blocks/news_block.html b/main/templates/main/blocks/news_block.html index 0dc78b4893a57681d22f287ba9574efe34287ec1..128ad14fac4d1128f154cfc83baf114e5c86a121 100644 --- a/main/templates/main/blocks/news_block.html +++ b/main/templates/main/blocks/news_block.html @@ -8,10 +8,14 @@ {% if article_main %} <div class="flex flex-wrap mb-5 lg:mb-10"> {% image article_main.image original as article_img %} - <img src="{{ article_img.url }}" draggable="false" alt="" class="lg:max-w-lg lg:mr-11 h-fit"> + <a href="{{ article_main.url }}"> + <img src="{{ article_img.url }}" draggable="false" alt="" class="lg:max-w-lg lg:mr-11 h-fit"> + </a> <div class="flex flex-col max-w-xl items-start"> <span class="text-green-500 head-3xl mt-10 mb-4 lg:mb-8">{{ article_main.date }}</span> - <h5 class="head-4xl mb-5 lg:mb-10">{{ article_main.title }}</h5> + <a href="{{ article_main.url }}"> + <h4 class="head-4xl mb-5 lg:mb-10">{{ article_main.title }}</h4> + </a> <p class="leading-6 mb-4 lg:mb-8">{{ article_main.perex }}</p> {% include 'main/includes/button_animated.html' with btn_link=article_main.url btn_text="Číst dále" %} </div> diff --git a/main/templates/main/includes/article_carousel_item.html b/main/templates/main/includes/article_carousel_item.html index e63da73a8eb25779e226661f951de015b634da08..f7073ad4ee077228523aa24d90a1e157f22a00e3 100644 --- a/main/templates/main/includes/article_carousel_item.html +++ b/main/templates/main/includes/article_carousel_item.html @@ -3,14 +3,16 @@ <div> <div class="flex max-w-md items-start xl:mr-2"> {% image article_item.image fill-128x128 as image %} + <a href="{{ article_item.url }}" class="mr-4"> <img src="{{ image.url }}" alt="" - class="w-16 xl:w-36 mr-4"> + class="w-16 xl:w-36"> + </a> <div class="flex flex-col justify-between items-start"> <span class="text-green-500 mb-2">{{ article_item.date | date }}</span> - <h4 class="font-alt leading-5 text-base uppercase lg:text-base mb-2"> + <a href="{{ article_item.url }}" class="font-alt leading-5 text-base uppercase lg:text-base mb-2"> {{ article_item.title }} - </h4> + </a> {% include 'main/includes/button_animated.html' with btn_link=article_item.url btn_text="Zjistit více" %} </div> </div> diff --git a/main/templates/main/includes/person_article_preview.html b/main/templates/main/includes/person_article_preview.html index 8ce9b4be40d9836f6e66f2f55760b14cb7d40403..0a3b272e10050205d901106610e95d3d01e46a11 100644 --- a/main/templates/main/includes/person_article_preview.html +++ b/main/templates/main/includes/person_article_preview.html @@ -1,14 +1,16 @@ {% for article_page in article_data_list %} <div class="flex flex-col justify-between items-start mb-9"> - <div class="flex font-bold mb-4 text-xs text-white uppercase"> - <span class="bg-green-500 mr-1 px-1">{{ article_page.date }}</span> + <div class="flex flex-wrap font-bold mb-4 text-xs text-white uppercase"> + <span class="mb-1 bg-green-500 mr-1 px-1">{{ article_page.date }}</span> {% for tag in article_page.tags.all %} - <span class="bg-violet-600 mr-1 px-1">{{ tag }}</span> + <span class="bg-violet-600 mb-1 mr-1 px-1">{{ tag }}</span> {% endfor %} </div> - <h4 class="head-3xl mb-4"> - {{ article_page.title }} - </h4> + <a href="{{ article_page.url }}"> + <h4 class="head-3xl mb-4"> + {{ article_page.title }} + </h4> + </a> <p class="mb-6"> {{ article_page.perex }} </p> diff --git a/main/templates/main/includes/work_article_preview.html b/main/templates/main/includes/work_article_preview.html index 47c4a79e4b1c4ec78020194a6c5af86fcd8716cf..84aa4959ce3fc82da4a2ff9e09833b643acd12ed 100644 --- a/main/templates/main/includes/work_article_preview.html +++ b/main/templates/main/includes/work_article_preview.html @@ -2,13 +2,17 @@ <div class="p-7 flex flex-col max-w-xl border border-grey-150 mb-8"> {% image article_page.image max-500x500 as image %} - <img - src='{{ image.url }}' alt="" - class="mb-7" - > - <h2 class="head-2xl mb-4"> - {{ article_page.title }} - </h2> + <a href="{{ article_page.url }}"> + <img + src='{{ image.url }}' alt="" + class="mb-7 w-full" + > + </a> + <a href="{{ article_page.url }}"> + <h2 class="head-2xl mb-4"> + {{ article_page.title }} + </h2> + </a> <div class="flex font-bold mb-4 text-xs text-white uppercase"> <span class="bg-green-500 mr-1 p-2">{{ article_page.date }}</span> {% for tag in article_page.tags.all %} diff --git a/main/templates/main/main_article_page.html b/main/templates/main/main_article_page.html index 7fa3eee772b1e147223b7ee1d725abc6966b929f..587e956ce3c8f2f12ef19d4ce6fe6fac160954c2 100644 --- a/main/templates/main/main_article_page.html +++ b/main/templates/main/main_article_page.html @@ -11,9 +11,7 @@ <div class="grid-container mb-2 lg:mb-12 relative"> <div class="grid-left-side h-full bg-grey-150 left-tab"> <div class="p-6 flex flex-wrap flex-row items-center justify-between xl:items-start xl:flex-col"> - {% if page.author %} - <span class="font-bold 3xl:text-xl">AUTOR ČLÁNKU: <br> {{ page.author }}</span><br> - {% endif %} + <span class="font-bold 3xl:text-xl">AUTOR ČLÁNKU: <br> {% firstof page.author_page.title page.author '' %}</span><br> <div class="flex flex-row static bottom-0 xl:absolute sm:bottom-5"> {% for social in page.author_page.social_links %} <a href="{{ social.value.link }}" class="flex hover:no-underline"> diff --git a/main/templates/main/main_articles_page.html b/main/templates/main/main_articles_page.html index 468d7d0cfff0cb39668f117d280b7dbc7aeabc05..ba40e551f09b409dbbf07974d47b75bb9238c758 100644 --- a/main/templates/main/main_articles_page.html +++ b/main/templates/main/main_articles_page.html @@ -88,6 +88,7 @@ </section> </template> </ui-view-provider> + {% include "main/includes/newsletter_section.html" %} </div> </main> diff --git a/main/templates/main/main_contact_page.html b/main/templates/main/main_contact_page.html index 67239920da779340dbc8d2007a3493e7abe7e9cc..32fefa7f48015d153e4881c7f5656c382ee7913b 100644 --- a/main/templates/main/main_contact_page.html +++ b/main/templates/main/main_contact_page.html @@ -42,27 +42,22 @@ <h2 class="head-4xl mb-5"> Další kontakty </h2> - <div class="flex flex-wrap gap-4 justify-center md:justify-start"> + <div class="flex flex-wrap gap-4 justify-center md:justify-start"> {% for contact_block in page.contact_boxes %} <div class="contact-box"> - <div> - <div class="h-16 mx-auto w-16 mb-3"> + <div> {% image contact_block.value.image fill-150x150 as contact_box_image %} - <img src="{{ contact_box_image.url }}" alt="{{ contact_block.title }}"> - </div> - <h3 class="font-alt mb-3 text-xl"> - {{ contact_block.value.title }} - </h3> - <p> - {{ contact_block.value.subtitle }} - </p> + <img src="{{ contact_box_image.url }}" alt="{{ contact_block.title }}" + class="h-16 mx-auto w-16 mb-3"> + <h3 class="font-alt mb-3 text-xl"> + {{ contact_block.value.title }} + </h3> + <p> + {{ contact_block.value.subtitle }} + </p> </div> - <a href="{{ contact_block.value.button_link }}" class="btn btn__slide__wrap"> - <span class="btn bg-black text-white w-32">{{ contact_block.value.button_text }}</span> - <span class="btn bg-blue-300 text-white w-32">{{ contact_block.value.button_text }}</span> - </a> + {% include 'main/includes/button_animated.html' with btn_link=contact_block.value.button_link btn_text=contact_block.value.button_text extra_classes="shrink-0" %} </div> - {% endfor %} </div> </section> @@ -95,7 +90,8 @@ </span> {% if contact_person_box.value.person %} <span>{{ contact_person_box.value.person.phone|default_if_none:'' }}</span> - <span class="text-turquoise-500">{{ contact_person_box.value.person.email|default_if_none:'' }}</span> + <span + class="text-turquoise-500">{{ contact_person_box.value.person.email|default_if_none:'' }}</span> {% endif %} </div> </div> diff --git a/main/templates/main/main_people_page.html b/main/templates/main/main_people_page.html index 1144a6f4bdbea55496fdf31dcacb300dd77240f7..526a6b870a20be7f25f5eb457babbddd0a35728d 100644 --- a/main/templates/main/main_people_page.html +++ b/main/templates/main/main_people_page.html @@ -45,7 +45,6 @@ </ui-view-provider> </div> </div> - - {% include 'main/includes/newsletter_section.html' %} </main> + {% include 'main/includes/newsletter_section.html' %} {% endblock content %} diff --git a/main/templates/main/main_person_page.html b/main/templates/main/main_person_page.html index a73c030a915f725ee2fe4d409dfac706c308cab4..b5291e32c86aedcc87fa97b61b5f20af89d674ab 100644 --- a/main/templates/main/main_person_page.html +++ b/main/templates/main/main_person_page.html @@ -15,25 +15,31 @@ {{ page.perex }} </p> <p class="mb-5"> - {{ paga.text|richtext }} + {{ page.text|richtext }} </p> </article> </div> <div class="grid-right-side mb-8 xl:mb-0"> - <div class="bg-grey-100 flex flex-col justify-center mb-1 px-7 py-4 xl:py-9"> - <div class="flex mb-2"> - <i class="ico--envelope mr-2"></i> - <a href="mailto:{{ page.email }}" class="text-turquoise-500 underline"> - {{ page.email }} - </a> - </div> - <div class="flex"> - <i class="ico--phone mr-2"></i> - <a href="tel:{{ page.phone }}"> - {{ page.phone }} - </a> + {% if page.email or page.phone %} + <div class="bg-grey-100 flex flex-col justify-center mb-1 px-7 py-4 xl:py-9"> + {% if page.email %} + <div class="flex mb-2"> + <i class="ico--envelope mr-2"></i> + <a href="mailto:{{ page.email }}" class="text-turquoise-500 underline"> + {{ page.email }} + </a> + </div> + {% endif %} + {% if page.phone %} + <div class="flex"> + <i class="ico--phone mr-2"></i> + <a href="tel:{{ page.phone }}"> + {{ page.phone }} + </a> + </div> + {% endif %} </div> - </div> + {% endif %} {% if page.social_links %} <div class="bg-grey-100 flex flex-col justify-center px-7 py-4 xl:py-9"> {% for social_block in page.social_links %} @@ -57,7 +63,7 @@ </h2> <div class="__js-root twitter-carousel-root"> <ui-twitter-carousel> - {% for tweet in page.tweet_list %} + {% for tweet in tweet_list %} <div class="w-full flex max-w-xs"> <div class="mb-5 p-4 flex flex-col items-center text-center border border-grey-100 sm:mb-0"> <div class="flex flex-row sm:flex-col items-center"> @@ -76,7 +82,7 @@ </div> </div> {% endfor %} - </ui-twitter-carousel> + <ui-twitter-carousel> </div> </div> </section> diff --git a/main/templates/main/main_program_page.html b/main/templates/main/main_program_page.html index ffe8c90116be898483363b8b0852707567bc3bf6..fe0013d89e2b83bb467ed9d4b906243cf961d2eb 100644 --- a/main/templates/main/main_program_page.html +++ b/main/templates/main/main_program_page.html @@ -53,6 +53,6 @@ </ui-view-provider> </div> </div> - {% include 'main/includes/newsletter_section.html' %} </main> + {% include 'main/includes/newsletter_section.html' %} {% endblock %}