Skip to content
Snippets Groups Projects
Unverified Commit 283368c5 authored by Tom Wiesing's avatar Tom Wiesing
Browse files

Cleanup include tags

parent dcd18cb9
No related branches found
No related tags found
No related merge requests found
Showing
with 60 additions and 59 deletions
......@@ -3,5 +3,5 @@
{% endcomment %}
<li class="collection-item">
<a href="{{item.url}}" class="title">{{item.title}}</a>
<a href="{{include.item.url}}" class="title">{{include.item.title}}</a>
</li>
\ No newline at end of file
......@@ -2,7 +2,7 @@
Properly formats the date in yyyy[-mm] format.
Expects 'date' to be formatted as an argument.
{% endcomment %}
{% assign dateparts = date | split: "-" %}
{% assign dateparts = include.date | split: "-" %}
{% assign year = dateparts[0] %}
{% assign month = dateparts[1] %}
......
......@@ -28,9 +28,9 @@
{% for item in site.menu | sort:"menu_order" %}
{% if (item.folder or item.items) %}
{% include menu_sub.html %}
{% include menu_sub.html item=item %}
{% else %}
{% include menu_single.html %}
{% include menu_single.html item=item %}
{% endif %}
{% endfor %}
</ul>
\ No newline at end of file
......@@ -7,7 +7,7 @@
{% assign base_folder = page.url | split: '/' %}
{% assign base_folder = base_folder[1] %}
{% assign represents = item.active | split: '/' %}
{% assign represents = include.item.active | split: '/' %}
{% assign represents = represents[1] %}
{% if represents %}
......@@ -16,25 +16,25 @@
{% endif %}
{% endif %}
{% if page.url == item.url %}
{% if page.url == include.item.url %}
{% assign menu_active = true %}
{% endif %}
{% unless item.menu_hidden %}
{% unless include.item.menu_hidden %}
<li
{% if menu_active %}class="active"{% endif %}
{% if page.url == item.url %}class="active"{% endif %}
{% if page.url == include.item.url %}class="active"{% endif %}
>
{% if item.external %}
<a href="{{ item.url }}" target="_blank">
{% if include.item.external %}
<a href="{{ include.item.url }}" target="_blank">
{% else %}
<a href="{{ site.baseurl }}{{ item.url }}">
<a href="{{ site.baseurl }}{{ include.item.url }}">
{% endif %}
{% if item.menu_title %}
{{ item.menu_title }}
{% if include.item.menu_title %}
{{ include.item.menu_title }}
{% else %}
{{ item.title }}
{{ include.item.title }}
{% endif %}
</a>
</li>
......
......@@ -4,6 +4,8 @@
It also expects the global 'sorted_pages' argument.
{% endcomment %}
{% assign item = include.item %}
{% unless item.menu_hidden %}
{% assign base_folder = page.url | split: '/' %}
{% assign base_folder = base_folder[1] %}
......@@ -59,7 +61,7 @@
{% assign sub_components = item.url | split: '/' %}
{% unless item.hidden %}
{% if sub_components[1] == item_folder %}
{% include menu_single.html %}
{% include menu_single.html item=item %}
{% endif %}
{% endunless %}
{% endfor %}
......@@ -68,7 +70,7 @@
<!-- if we have items, iterate over them -->
{% if item.items %}
{% for item in item.items %}
{% include menu_single.html %}
{% include menu_single.html item=item %}
{% endfor %}
{% endif %}
</ul>
......
......@@ -3,6 +3,8 @@
Expects the default jekyll 'paginator' as argument.
{% endcomment %}
{% assign paginator = paginator %}
<ul class="pagination">
<!-- The previous page -->
......
......@@ -3,7 +3,7 @@
It expects the username of the person as the 'person' variable
{% endcomment %}
{% capture purl %}/people/{{person}}/{% endcapture %}
{% capture purl %}/people/{{include.person}}/{% endcapture %}
{% assign pp = site.pages | where: "url", purl | first %}
{% if pp %}
......@@ -15,6 +15,6 @@
</a>
{% else %}
<div class="chip">
{{person}}
{{include.person}}
</div>
{% endif %}
......@@ -3,6 +3,8 @@
Expects 'people' as an argument, representing the list of people to show.
{% endcomment %}
{% assign people = include.people %}
{% for role in site.roles %}
{% assign rollers = people | where: "role", role.id %}
......@@ -19,13 +21,11 @@
{% unless person.end_date %}
KWARCie since
{% endunless %}
{% assign date = person.start_date %}
{% include date.html %}
{% include date.html date=person.start_date %}
{% if person.end_date %}
&nbsp;-&nbsp;
{% assign date = person.end_date %}
{% include date.html %}
{% include date.html date=person.end_date %}
{% endif %}
{% endif %}
</p>
......
......@@ -4,12 +4,11 @@
{% endcomment %}
<li class="collection-item">
<a href="{{post.url}}" class="title">
{{post.title}} {{post.subtitle}}
<a href="{{include.post.url}}" class="title">
{{include.post.title}} {{include.post.subtitle}}
</a>
<div>
{% assign post = page %}
{% include post_meta.html %}
{% include post_meta.html post=include.post %}
</div>
</li>
\ No newline at end of file
......@@ -5,26 +5,29 @@
by
{% assign person = post.author %}
{% include people_chip.html %}
{% include people_chip.html person=include.post.author %}
on
<div class="chip">
{{ post.date | date_to_string }}
{% if include.post.date %}
{{ include.post.date | date_to_string }}
{% else %}
There is no date
{% endif %}
</div>
{% if post.location %}
{% if include.post.location %}
at
<div class="chip">
{{post.location}}
{{include.post.location}}
</div>
{% endif %}
in
{% for tag in post.tags %}
{% for tag in include.post.tags %}
<div class="chip">
{{tag}}
</div>
......
......@@ -2,6 +2,8 @@
Renders a link to a single project or system. Expects 'item' as a parameter.
{% endcomment %}
{% assign item = include.item %}
<li class="collection-item">
<a href="{{item.url}}" class="title">{{item.title}}</a>
{% if item.funding %} ({{item.funding}}) {% endif %}
......@@ -12,13 +14,11 @@
{% unless item.end_date %}
<b>started</b>
{% endunless %}
{% assign date = item.start_date %}
{% include date.html %}
{% include date.html date=item.start_date %}
{% if item.end_date %}
&nbsp;-&nbsp;
{% assign date = item.end_date %}
{% include date.html %}
{% include date.html date=item.end_date %}
{% endif %}
<br />
{% endif %}
......
......@@ -2,6 +2,8 @@
Renders the name of a single semester. Expects 'semester' as a parameter.
{% endcomment %}
{% assign semester = include.semester %}
<!-- check if we are a summer semester -->
{% assign nosummer = semester | remove: "SS" %}
{% unless nosummer == semester %}
......
......@@ -8,7 +8,7 @@ layout: default
<div class="card-content">
<span class="card-title">{{page.title}}</span>
{% for person in page.instructors %}
{% include people_chip.html %}
{% include people_chip.html person=person %}
{% endfor %}
<hr />
......@@ -17,7 +17,7 @@ layout: default
{% endif %}
{% for semester in page.semesters %}
{% include semester.html %}<br />
{% include semester.html semester=semester %}<br />
{% endfor %}
</div>
</div>
......
......@@ -24,13 +24,11 @@ layout: default
since
{% endunless %}
{% assign date = page.start_date %}
{% include date.html %}
{% include date.html date=page.start_date %}
{% if page.end_date %}
&nbsp;-&nbsp;
{% assign date = page.end_date %}
{% include date.html %}
{% include date.html date=page.end_date %}
{% endif %}
{% endif %}
......
......@@ -11,8 +11,7 @@ layout: default
</span>
{% if post.subtitle %}<h6>{{post.subtitle}}</h6>{% endif %}
{% assign post = page %}
{% include post_meta.html %}
{% include post_meta.html post=page %}
</div>
</div>
......
......@@ -13,14 +13,12 @@ layout: default
{% if page.start_date %}
<p>
<b>From:</b>
{% assign date = page.start_date %}
{% include date.html %}
{% include date.html date=page.start_date %}
{% if page.end_date %}
<br />
<b>To:</b>
{% assign date = page.end_date %}
{% include date.html %}
{% include date.html date=page.end_date %}
{% endif %}
</p>
<hr />
......@@ -56,7 +54,7 @@ layout: default
<!-- list all the people -->
{% for person in page.people %}
{% include people_chip.html %}
{% include people_chip.html person=person %}
{% assign needs_break = true %}
{% endfor %}
......
......@@ -13,14 +13,12 @@ layout: default
{% if page.start_date %}
<p>
<b>Start:</b>
{% assign date = page.start_date %}
{% include date.html %}
{% include date.html date=page.start_date %}
{% if page.end_date %}
<br />
<b>End:</b>
{% assign date = page.end_date %}
{% include date.html %}
{% include date.html date=page.end_date %}
{% endif %}
</p>
<hr />
......@@ -38,7 +36,7 @@ layout: default
{% endif %}
{% for person in page.people %}
{% include people_chip.html %}
{% include people_chip.html person=person %}
{% endfor %}
</div>
{% assign hasaction = false %}
......
......@@ -5,4 +5,4 @@ title: KWARC established at FAU
tags:
- Announcements
---
With Dennis Müller movint to Erlangen, we have (the beginnings of) a group presence at FAU. The Winter semester begins later this month with an AI course.
With Dennis Müller moving to Erlangen, we have (the beginnings of) a group presence at FAU. The Winter semester begins later this month with an AI course.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment