From b94a7c88fc20baf101eee60d56a72066750fa00a Mon Sep 17 00:00:00 2001 From: OndraPetrzilka <ondra.petrzilka@gmail.com> Date: Wed, 24 Aug 2022 13:30:34 +0200 Subject: [PATCH] main_person_page template --- main/templates/main/main_person_page.html | 76 ++++++++++------------- 1 file changed, 32 insertions(+), 44 deletions(-) diff --git a/main/templates/main/main_person_page.html b/main/templates/main/main_person_page.html index 9119c3c9..ac12210f 100644 --- a/main/templates/main/main_person_page.html +++ b/main/templates/main/main_person_page.html @@ -3,12 +3,7 @@ {% block content %} <main role="main"> - - {# {{> organisms-header }}#} - {##} - {# {{> molecules-photo_header }}#} - - + {% include 'main/includes/layout/photo_page_header.html' %} <div class=""> <section class="grid-container person-grid-container"> <div class="grid-content leading-6"> @@ -18,48 +13,41 @@ </p> </article> </div> - <div class="grid-right-side mb-8 xl:mb-0"> + {% if page.email or page.phone %} + <div class="grid-right-side mb-8 xl:mb-0"> <div class="bg-grey-100 mb-1 px-7 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 mb-2"> - <i class="ico--phone mr-2"></i> - <a href="tel:+{{ page.phone }}"> - {{ page.phone }} - </a> - </div> - </div> - <div class="bg-grey-100 px-7 py-9"> - {% if page.facebook %} + {% if page.email %} <div class="flex mb-2"> - <i class="ico--facebook mr-2"></i> - <a href="{{ page.facebook }}"> - Facebook + <i class="ico--envelope mr-2"></i> + <a href="mailto:{{ page.email }}" class="text-turquoise-500 underline"> + {{ page.email }} </a> </div> {% endif %} - {% if page.twitter %} + {% if page.phone %} <div class="flex mb-2"> - <i class="ico--twitter mr-2"></i> - <a href="{{ page.twitter }}"> - Twitter + <i class="ico--phone mr-2"></i> + <a href="tel:+{{ page.phone }}"> + {{ page.phone }} </a> </div> {% endif %} - {% if page.instagram %} + </div> + {% endif %} + {% if page.social_links %} + <div class="bg-grey-100 px-7 py-9"> + + {% for social_block in page.social_links %} <div class="flex mb-2"> - <i class="ico--instagram mr-2"></i> - <a href="{{ page.instagram }}"> - Instagram + <i class="{{ social_block.value.icon }} mr-2"></i> + <a href="{{ social_block.value.link }}"> + {{ social_block.value.text }} </a> </div> - {% endif %} + {% endfor %} </div> - </div> + </div> + {% endif %} </section> </div> {% if not tweet_list.empty %} @@ -121,28 +109,28 @@ <h2 class="head-4xl text-left"> {{ people_group.value.title }} </h2> - {% for person in people_group %} + {% for person in people_group.value.person_list %} <div class="flex flex-wrap"> <div class="flex mb-16 person-box-medium"> <div class="shrink-0 mr-4"> - {% image people_group.value.profile_image max-300x300 as profile_image %} <img class="rounded-full shadow-sm w-20 mb-2 xl:w-44" - src="{{ profile_image.url }}" - alt=" {{ people_group.value.title }}" + src="{{ person.profile_image.url }}" + alt=" {{ person.title }}" > </div> <div class="flex flex-col justify-between py-4"> <div class="flex flex-col"> <h4 class="head-3xl"> - {{ people_group.value.title }} + {{ person.title }} </h4> <span - class="text-sm xl:text-base leading-6 mb-6">{{ people_group.value.position|default_if_none:"" }}</span> - </div> - <div> - {% include 'main/includes/button_animated.html' with btn_link=people_group.value.url btn_text="Detail" %} + class="text-sm xl:text-base leading-6 mb-6">{{ person.position|default_if_none:"" }}</span> + <div> + {% include 'main/includes/button_animated.html' with btn_link=person.url btn_text="Detail" %} + </div> </div> + </div> </div> {% endfor %} -- GitLab