jekyll-theme-pirati 8.1.0 → 8.4.0

This diff has not been reviewed by any users.
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 36af05f7dada0b1bd73b5d669832b2971d505be7f73ca6202142b1e53390f938
4
- data.tar.gz: a96935836900ec028757ee40ec6515c3e8bee10048508d4c42a83dda79649bc4
3
+ metadata.gz: 2dbfde991de21ef4a5db73761ddb4b85fd4c69d497e47fe959fdd8263d87814d
4
+ data.tar.gz: d381268cc7b5b24169e514528dee49421e88ee41addfa558c3a6ded0e6b06a5b
5
5
  SHA512:
6
- metadata.gz: 3bd8dd3bf90e9285322d0f3d33df1f3594321abc08ef8fb97f5056d4637cfd8a9e7e6629b527eb3e0a82d1c3547c9c29100366cebc1d3a0499b84b2e989bbdfb
7
- data.tar.gz: 6552a452d352a5693fdfd988d69199fb7e64f30e350a33e488f9f53ac4b3c896d2b2c4e26f055aeff3bc49e39616788050d58ddb56eb7bc946cd9925b904a380
6
+ metadata.gz: 060feea377f69bb7c95d613cc2b7ff4fafc2d5da0dc540db8cd0facebf85ede0edec0b5b7bfeaa611c0763d4d5043791f642716cda969662e3c54cec74a3f2ef
7
+ data.tar.gz: 466bb391e754273f024fbe8e2c247bb113dae35f8947f28c49e7caa3453dbe29a72de6f4637bc4e71c797f645a854b1cf973be3a55017c225f2f5d8be23ebb65
data/README.md CHANGED
@@ -106,6 +106,12 @@ To use it fully, provide `heroImg` in the person markdown file.
106
106
 
107
107
  These will show as the [emphasized variant in black](https://styleguide.pir-test.eu/latest/?p=viewall-molecules-article-card).
108
108
 
109
+ #### Organizations can personalise their onboard and donate links in header and footer
110
+
111
+ Set `organization.donateLink` (defaults to dary.pirati.cz) and
112
+ `organization.onboardingLink` (defaults to nalodeni.pirati.cz) in the Jekyll
113
+ config.
114
+
109
115
 
110
116
  ### Backwards incompatible changes
111
117
 
@@ -22,12 +22,19 @@
22
22
  <a href="{{ include.candidatePage.url|relative_url }}">{% include people/fullname.html person=include.candidatePage %}</a>
23
23
  </h1>
24
24
  {% if include.candidatePage.mail %}
25
- <a href="mailto:{{ include.candidatePage.mail }}" class="block font-light mb-4">{{ include.candidatePage.mail }}</a>
25
+ <a href="mailto:{{ include.candidatePage.mail }}" class="block candidate-card__bio-item mb-4">{{ include.candidatePage.mail }}</a>
26
+ {% endif %}
27
+ <h2 class=" candidate-card__bio-item">{{ include.candidate.profession }}</h2>
28
+ {% if include.candidate.city %}
29
+ <h2 class="head-allcaps-4xs mt-4">
30
+ {{ include.candidate.city }}
31
+ </h2>
26
32
  {% endif %}
27
- <h2 class="head-allcaps-4xs md:head-allcaps-3xs">{{ include.candidate.profession }}</h2>
28
33
  </div>
29
34
  <div class="candidate-card__affiliation">
30
- {% if include.candidate.age %}<div>{{ include.candidate.age }} let</div>{% endif %}
35
+ {% if include.candidate.age %}
36
+ <div>{{ include.candidate.age }} let</div>
37
+ {% endif %}
31
38
 
32
39
  {% if include.candidate.partyUid %}
33
40
  {% include party.html uid=include.candidate.partyUid %}
@@ -37,11 +44,13 @@
37
44
  {% if include.candidate.description %}
38
45
  <p class="font-light text-sm leading-snug italic mb-4 hidden md:block">{{ include.candidate.description }}</p>
39
46
  {% endif %}
40
- {% if include.candidatePage %}
41
- <div class="social-icon-group space-x-2">
42
- {% include social-icons.html profiles=include.candidatePage.profiles %}
43
- </div>
44
- {% endif %}
47
+ {% unless include.hideSocialProfiles %}
48
+ {% if include.candidatePage %}
49
+ <div class="social-icon-group space-x-2">
50
+ {% include social-icons.html profiles=include.candidatePage.profiles %}
51
+ </div>
52
+ {% endif %}
53
+ {% endunless %}
45
54
  </div>
46
55
  </div>
47
56
  </div>
@@ -0,0 +1,21 @@
1
+ {% if include.bgImg %}
2
+ {% if site.mediaStorage %}
3
+ {% capture imgBgPath %}https://a.pirati.cz/{{ site.mediaStorage }}/img/{{ include.bgImg }}{% endcapture %}
4
+ {% else %}
5
+ {% capture imgBgPath %}{% asset '{{ include.bgImg }}' @path %}{% endcapture %}
6
+ {% assign imgBgPath = imgBgPath | absolute_url %}
7
+ {% endif %}
8
+ {% endif %}
9
+
10
+ {% if include.mainContent %}
11
+ {% capture mainContent %}{{ include.mainContent }}{% endcapture %}
12
+ {% else %}
13
+ {% capture mainContent %}
14
+ {% if include.candidateListNumber %}
15
+ <div class="flag bg-violet-400 text-white head-alt-base mb-6">Volte č. {{ include.candidateListNumber }}</div>
16
+ {% endif %}
17
+ <h1 class="head-alt-md md:head-alt-xl">{{ page.title }}</h1>
18
+ {% endcapture %}
19
+ {% endif %}
20
+
21
+ {% include hero/advanced.html img=include.img bgImg=imgBgPath mainContent=mainContent subContent=include.subContent contentClass="content-block" imgClass="h-32 lg:h-80 lg:m-auto hidden md:block" %}
@@ -33,7 +33,7 @@
33
33
  {% endif %}
34
34
  </div>
35
35
  <div class="flex flex-col md:flex-row lg:flex-col lg:items-end space-y-2 md:space-y-0 md:space-x-2 lg:space-x-0 lg:space-y-2">
36
- <a href="https://dary.pirati.cz" rel="noopener noreferrer" target="_blank" class="btn btn--icon btn--cyan-200 btn--hoveractive text-lg btn--fullwidth sm:btn--autowidth">
36
+ <a href="{{ site.organization.donateLink | default: 'https://dary.pirati.cz' }}" rel="noopener noreferrer" target="_blank" class="btn btn--icon btn--cyan-200 btn--hoveractive text-lg btn--fullwidth sm:btn--autowidth">
37
37
  <div class="btn__body-wrap">
38
38
  <div class="btn__body ">Přispěj</div>
39
39
  <div class="btn__icon ">
@@ -42,7 +42,7 @@
42
42
  </div>
43
43
  </a>
44
44
 
45
- <a href="https://nalodeni.pirati.cz" rel="noopener noreferrer" target="_blank" class="btn btn--icon btn--blue-300 btn--hoveractive text-lg btn--fullwidth sm:btn--autowidth">
45
+ <a href="{{ site.organization.onboardingLink | default: 'https://nalodeni.pirati.cz' }}" rel="noopener noreferrer" target="_blank" class="btn btn--icon btn--blue-300 btn--hoveractive text-lg btn--fullwidth sm:btn--autowidth">
46
46
  <div class="btn__body-wrap">
47
47
  <div class="btn__body ">Naloď se</div>
48
48
  <div class="btn__icon ">
@@ -44,7 +44,7 @@
44
44
  {% endif %}
45
45
  </div>
46
46
  <div v-if="show || isLgScreenSize" class="navbar__actions navbar__section navbar__section--expandable container-padding--zero lg:container-padding--auto self-start flex flex-col sm:flex-row lg:flex-col sm:space-x-4 space-y-2 sm:space-y-0 lg:space-y-2 xl:flex-row xl:space-x-2 xl:space-y-0">
47
- <a href="https://dary.pirati.cz" rel="noopener noreferrer" target="_blank" class="btn btn--icon btn--cyan-200 btn--hoveractive btn--condensed btn--fullwidth md:btn--autowidth lg:text-sm xl:text-base">
47
+ <a href="{{ site.organization.donateLink | default: 'https://dary.pirati.cz' }}" rel="noopener noreferrer" target="_blank" class="btn btn--icon btn--cyan-200 btn--hoveractive btn--condensed btn--fullwidth md:btn--autowidth lg:text-sm xl:text-base">
48
48
  <div class="btn__body-wrap">
49
49
  <div class="btn__body ">Přispěj</div>
50
50
  <div class="btn__icon ">
@@ -52,7 +52,7 @@
52
52
  </div>
53
53
  </div>
54
54
  </a>
55
- <a href="https://nalodeni.pirati.cz" rel="noopener noreferrer" target="_blank" class="btn btn--icon btn--blue-300 btn--hoveractive btn--condensed btn--fullwidth md:btn--autowidth lg:text-sm xl:text-base">
55
+ <a href="{{ site.organization.onboardingLink | default: 'https://nalodeni.pirati.cz' }}" rel="noopener noreferrer" target="_blank" class="btn btn--icon btn--blue-300 btn--hoveractive btn--condensed btn--fullwidth md:btn--autowidth lg:text-sm xl:text-base">
56
56
  <div class="btn__body-wrap">
57
57
  <div class="btn__body ">Naloď se</div>
58
58
  <div class="btn__icon ">
@@ -1,10 +1,12 @@
1
1
  {% capture label %}
2
2
  {% if include.label %}{{ include.label }}{% elsif include.item.name %}{{ include.item.name }}{% else %}{{ include.item.title }}{% endif %}
3
3
  {% endcapture %}
4
- {% if include.item.url contains 'http' %}
5
- {% assign url = include.item.url %}
6
- {% else %}
7
- {% assign url = include.item.url | relative_url %}
4
+ {% if include.item.url %}
5
+ {% if include.item.url contains 'http' %}
6
+ {% assign url = include.item.url %}
7
+ {% else %}
8
+ {% assign url = include.item.url | relative_url %}
9
+ {% endif %}
8
10
  {% endif %}
9
11
  {% capture avatarClass %}
10
12
  badge__avatar {% if include.avatarClass %}{{ include.avatarClass }}{% else %}avatar--sm{% endif %}
@@ -35,7 +37,11 @@
35
37
 
36
38
  <div class="badge__body">
37
39
  <h2 class="{% if include.headlineClass %}{{ include.headlineClass }}{% else %}head-heavy-2xs{% endif %} badge__title">
38
- <a href="{{ url }}" title="{{ label }}" class="content-block--nostyle">{{ label }}</a>
40
+ {% if url %}
41
+ <a href="{{ url }}" title="{{ label }}" class="content-block--nostyle">{{ label }}</a>
42
+ {% else %}
43
+ {{ label }}
44
+ {% endif %}
39
45
  </h2>
40
46
 
41
47
  {% unless include.showDescription == false %}
@@ -1,14 +1,16 @@
1
1
 
2
- <div class="content-block">
3
- <h2>Lidé</h2>
4
- </div>
2
+ <div class="hidden lg:block">
3
+ <div class="content-block">
4
+ <h2>Lidé</h2>
5
+ </div>
5
6
 
6
- <div class="space-y-4">
7
- {% assign persons = site.people | sample:3 %}
8
- {% for person in persons %}
9
- {% include people/profile-badge.html item=person style='card' showContactInfo=false %}
10
- {% endfor %}
11
- </div>
7
+ <div class="space-y-4">
8
+ {% assign persons = site.people | sample:3 %}
9
+ {% for person in persons %}
10
+ {% include people/profile-badge.html item=person style='card' showContactInfo=false %}
11
+ {% endfor %}
12
+ </div>
12
13
 
13
- {% capture href %}{% if peopleCol.root %}{{ peopleCol.root }}{% else %}{{ '/lide/' | relative_url }}{% endif %}{% endcapture %}
14
- {% include buttons/icon.html icon="ico--chevron-right" class="btn--violet-500 btn--fullwidth btn--hoveractive pt-4" cta="Poznejte celý náš tým" href=href %}
14
+ {% capture href %}{% if peopleCol.root %}{{ peopleCol.root }}{% else %}{{ '/lide/' | relative_url }}{% endif %}{% endcapture %}
15
+ {% include buttons/icon.html icon="ico--chevron-right" class="btn--violet-500 btn--fullwidth btn--hoveractive pt-4" cta="Poznejte celý náš tým" href=href %}
16
+ </div>
@@ -51,7 +51,7 @@
51
51
  <h2>Asistenti</h2>
52
52
  <div class="space-y-4 mt-4">
53
53
  {% for asistent in page.asistenti %}
54
- {% include people/profile-badge.html class="badge--condensed" item=asistent description=asistent.position %}
54
+ {% include people/profile-badge.html class="badge--condensed" item=asistent description=asistent.position hideAvatar=true %}
55
55
  {% endfor %}
56
56
  </div>
57
57
  {% endif %}
@@ -15,33 +15,23 @@ layout: default
15
15
  {% endif %}
16
16
  {% endif %}
17
17
 
18
- {% if page.heroBgImg %}
19
- {% if site.mediaStorage %}
20
- {% capture imgBgPath %}https://a.pirati.cz/{{ site.mediaStorage }}/img/{{ page.heroBgImg }}{% endcapture %}
21
- {% else %}
22
- {% capture imgBgPath %}{% asset '{{ page.heroBgImg }}' @path %}{% endcapture %}
23
- {% assign imgBgPath = imgBgPath | absolute_url %}
24
- {% endif %}
25
- {% endif %}
26
18
 
27
19
  <div class="__js-root">
28
- <ui-view-provider inline-template :initial="{candidates: true, program: false}" v-slot="{ isCurrentView, toggleView }">
20
+ <ui-view-provider inline-template :initial="{kandidati: true, program: false}" :sync-location="true" location-param="pohled" v-slot="{ isCurrentView, showView }">
29
21
  <main>
30
- {% capture mainContent %}
31
- {% if candidates.number %}
32
- <div class="flag bg-violet-400 text-white head-alt-base mb-6">Volte č. {{ candidates.number }}</div>
33
- {% endif %}
34
- <h1 class="head-alt-md md:head-alt-xl">{{ page.title }}</h1>
35
- {% endcapture %}
36
- {% include hero/advanced.html img=page.img bgImg=imgBgPath mainContent=mainContent subContent=content contentClass="content-block" imgClass="h-32 lg:h-80 lg:m-auto hidden md:block" %}
22
+ {% comment %} Support for customized elections header content. {% endcomment %}
23
+ {% if page.customizeHeader %}
24
+ {{ content }}
25
+ {% else %}
26
+ {% include elections-header.html img=page.img bgImg=page.heroBgImg subContent=content candidateListNumber=candidates.number %}
27
+ {% endif %}
37
28
 
38
29
  <div class="container container--default pt-8 {% unless group.subLinks %}pb-8{% endunless %} lg:py-24">
39
-
40
30
  {% if programCategories.size > 0 %}
41
31
  <div class="text-center">
42
32
  <div class="switch">
43
- <a @click="toggleView('candidates')" class="switch__item" :class="{'switch__item--active': isCurrentView('candidates')}">Kandidáti</a>
44
- <a @click="toggleView('program')" class="switch__item" :class="{'switch__item--active': isCurrentView('program')}">Program</a>
33
+ <a @click="showView('kandidati')" class="switch__item" :class="{'switch__item--active': isCurrentView('kandidati')}">Kandidáti</a>
34
+ <a @click="showView('program')" class="switch__item" :class="{'switch__item--active': isCurrentView('program')}">Program</a>
45
35
  </div>
46
36
  </div>
47
37
 
@@ -77,13 +67,13 @@ layout: default
77
67
  </template>
78
68
  {% endif %}
79
69
 
80
- <template v-if="isCurrentView('candidates')">
70
+ <template v-if="isCurrentView('kandidati')">
81
71
  <h1 class="head-alt-md text-center py-8 lg:pt-24 lg:pb-8">{{ candidates.title }}</h1>
82
72
 
83
73
  {% assign leaderCandidate = site.people | where: "uid", candidates.leader.uid | first %}
84
74
 
85
75
  <div class="candidate-card-list grid-cols-1 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-4">
86
- {% include candidate-badge.html candidate=candidates.leader candidatePage=leaderCandidate rank=1 wrapperClass="candidate-card__wrapper sm:candidate-card-list__item-wrapper md:candidate-card-list__item-wrapper--border" %}
76
+ {% include candidate-badge.html candidate=candidates.leader candidatePage=leaderCandidate rank=1 wrapperClass="candidate-card__wrapper sm:candidate-card-list__item-wrapper md:candidate-card-list__item-wrapper--border" hideSocialProfiles=page.hideCandidateSocialProfiles %}
87
77
 
88
78
  {% if candidates.head.size %}
89
79
  {% for candidate in candidates.head %}
@@ -101,8 +91,7 @@ layout: default
101
91
  {% capture classes %}candidate-card__wrapper sm:candidate-card-list__item-wrapper sm:candidate-card-list__item-wrapper--noborder md:candidate-card-list__item-wrapper--border lg:candidate-card-list__item-wrapper--noborder{% endcapture %}
102
92
  {% endif %}
103
93
 
104
- {% include candidate-badge.html candidate=candidate candidatePage=candidatePage leader=false rank=candidateRank wrapperClass=classes %}
105
-
94
+ {% include candidate-badge.html candidate=candidate candidatePage=candidatePage leader=false rank=candidateRank wrapperClass=classes hideSocialProfiles=page.hideCandidateSocialProfiles %}
106
95
  {% endfor %}
107
96
  {% endif %}
108
97
  </div>
@@ -139,8 +128,8 @@ layout: default
139
128
  <{% if candidatePage %}a href="{{ candidatePage.url }}"{% else %}div{% endif %} class="candidate-table-row">
140
129
  <div class="candidate-table-row__position head-allcaps-heavy-2xs text-right">{{ candidateRank }}</div>
141
130
  {% include avatar.html class="avatar--sm candidate-table-row__avatar" src=img alt=candidate.name %}
142
- <div class="candidate-table-row__name head-heavy-2xs font-bold">{% if candidatePage %}{{ candidatePage.name }}{% else %}{{ candidate.name }}{% endif %}</div>
143
- <div class="candidate-table-row__bio head-allcaps-3xs">{% if candidate.age %}{{ candidate.age }} let{% endif %}{% if candidate.age and candidate.profession %}, {{ candidate.profession }}{% endif %}</div>
131
+ <div class="candidate-table-row__name head-heavy-2xs font-bold">{% if candidatePage %}{% include people/fullname.html person=candidatePage plain=true %}{% else %}{{ candidate.name }}{% endif %}</div>
132
+ <div class="candidate-table-row__bio font-condensed">{% if candidate.age %}{{ candidate.age }} let{% endif %}{% if candidate.profession %}{% if candidate.age %}, {% endif %}{{ candidate.profession }}{% endif %}{% if candidate.city %}{% if candidate.profession or candidate.age %}, {% endif %}{{ candidate.city }}{% endif %}</div>
144
133
  {% if candidate.partyUid %}
145
134
  <div class="candidate-table-row__affiliation">
146
135
  {% include party.html uid=candidate.partyUid %}
@@ -24,7 +24,7 @@ layout: default
24
24
  include hero/simple.html
25
25
  headline=personName
26
26
  description=page.profession
27
- headlineClass="text-center lg:text-left mx-auto"
27
+ headlineClass="text-center lg:text-left mx-auto lg:mx-0"
28
28
  descriptionClass="max-w-xl mx-auto text-center lg:text-left"
29
29
  heroSpacing="pt-16 pb-24 lg:pt-32 pb-24"
30
30
  class="candidate-detail__hero"
@@ -41,8 +41,6 @@ layout: default
41
41
  </section>
42
42
  <section class="lg:w-2/5 xl:w-1/3 pt-8 lg:pt-0 order-first lg:order-last candidate-detail__sidebar">
43
43
  {% include right-bar/rbar.html %}
44
- <!-- Mobile divider -->
45
- <hr class="block lg:hidden" />
46
44
  </section>
47
45
  </div>
48
46
  </main>
metadata CHANGED
@@ -1,15 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-theme-pirati
3
3
  version: !ruby/object:Gem::Version
4
- version: 8.1.0
4
+ version: 8.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jitka Novotná
8
8
  - Filip Vařecha
9
- autorequire:
9
+ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2020-07-13 00:00:00.000000000 Z
12
+ date: 2020-08-02 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: jekyll
@@ -53,7 +53,7 @@ dependencies:
53
53
  - - "~>"
54
54
  - !ruby/object:Gem::Version
55
55
  version: '10.0'
56
- description:
56
+ description:
57
57
  email:
58
58
  - jitka@ucw.cz
59
59
  - filip.varecha@pirati.cz
@@ -87,6 +87,7 @@ files:
87
87
  - _includes/contacts/summary-table.html
88
88
  - _includes/countdown.html
89
89
  - _includes/disqus_comments.html
90
+ - _includes/elections-header.html
90
91
  - _includes/footer.html
91
92
  - _includes/google-analytics.html
92
93
  - _includes/head-custom.html
@@ -302,7 +303,7 @@ homepage: https://github.com/pirati-web/jekyll-theme-pirati#readme
302
303
  licenses:
303
304
  - MIT
304
305
  metadata: {}
305
- post_install_message:
306
+ post_install_message:
306
307
  rdoc_options: []
307
308
  require_paths:
308
309
  - lib
@@ -317,9 +318,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
317
318
  - !ruby/object:Gem::Version
318
319
  version: '0'
319
320
  requirements: []
320
- rubyforge_project:
321
+ rubyforge_project:
321
322
  rubygems_version: 2.7.6
322
- signing_key:
323
+ signing_key:
323
324
  specification_version: 4
324
325
  summary: Basic theme for Czech pirate party
325
326
  test_files: []