Tag intersections.
[wolnelektury.git] / src / catalogue / templates / catalogue / 2022 / author_detail.html
1 {% extends '2022/base.html' %}
2 {% load catalogue_tags %}
3
4 {% load choose_cites from social_tags %}
5
6
7 {% block breadcrumbs %}
8   <a href="/katalog/"><span>Katalog</span></a>
9   <a href="{{ tags.0.get_absolute_catalogue_url }}"><span>{{ tags.0.get_category_display|title }}</span></a>
10 {% endblock %}
11
12 {% block main %}
13     <div class="l-section">
14       <div class="l-author__header">
15         {% if tags.0.photo %}
16           <figure>
17             <img src="{{ tags.0.photo.url }}" alt="{{ tags.0.name }}">
18           </figure>
19         {% endif %}
20         <h1>{{ tags.0.name }}</h1>
21       </div>
22     </div>
23
24     <div class="l-section">
25       <div class="l-books__header">
26         <div class="l-books__input">
27           <i class="icon icon-filter"></i>
28           <input type="text" placeholder="filtry, tytuł" class="quick-filter" data-for="book-list" data-filters="with-filter">
29           <div class="filter-container">
30             {% for tag in tags %}
31               {% if forloop.counter > 1 %}
32                 <span class="filter">
33                   <a href="{{ tag.get_absolute_url }}">{{ tag }}</a>
34                   <a href="{% catalogue_url 'books' tags -tag %}">✖</a>
35                 </span>
36               {% endif %}
37             {% endfor %}
38           </div>
39
40           </span>
41         </div>
42         <div class="l-books__sorting">
43              <span>Sortuj:</span>
44              <div>
45              <button data-order="data-pop">najpopularniejsze</button>
46              <button class="is-active">alfabetycznie</button>
47              <!--button>chronologicznie</button-->
48              </div>
49              </div>
50       </div>
51     </div>
52     <div class="l-author with-filter">
53
54       <div class="row">
55         <h2>{% nice_title_from_tags tags categories %}</h2>
56         <div class="filter-container">
57           {% for tag in suggest %}
58             <span class="filter">
59               <a href="{% catalogue_url 'books' tags tag %}">{{ tag }}</a>
60             </span>
61           {% endfor %}
62         </div>
63       </div>
64     </div>
65
66     <div class="l-section l-section--col">
67       <div class="l-books__grid" id="book-list">
68         {% for book in object_list %}
69           {% include "catalogue/2022/book_box.html" %}
70         {% endfor %}
71       </div>
72     </div>
73
74     <section class="l-section">
75       <div class="l-author">
76         {% with author=tags.0 %}
77           {% include 'catalogue/2022/author_box.html' %}
78         {% endwith %}
79         {% choose_cites 3 author=tags.0 as cites %}
80         {% if cites %}
81         <div class="row">
82           <div class="l-author__quotes">
83             <div class="l-author__quotes__slider">
84
85               {% for fragment in cites %}
86                 <div class="l-author__quotes__slider__item">
87                   {% include "catalogue/2022/fragment_box.html" %}
88                 </div>
89               {% endfor %}
90
91             </div>
92           </div>
93         </div>
94         {% endif %}
95       </div>
96     </section>
97 {% endblock %}