updated menu

This commit is contained in:
Benjamin Jones 2020-08-16 11:52:49 +02:00
parent a5e1be9465
commit 245112c463
4 changed files with 89 additions and 40 deletions

View File

@ -1,19 +1,49 @@
- about:
en:
name: call for participants
name: about
url: /about
fr:
name: à propos
url: /a-propos
- participate:
- conference:
en:
name: submit a proposal
url: "/how-to-participate"
name: ReclimFutures conference 2020
fr:
name: soumettre une proposition
url: /participer
name: ReclimFutures conference 2020
items:
- program:
en:
name: program
url: "/rf2020/program"
fr:
name: programme
url: /rf2020/programme
- participants:
en:
name: participants
url: "/rf2020/participants"
fr:
name: participants
url: /rf2020/participants
- donate:
colour: red
en:
name: donate
url: "/donate"
fr:
name: faire un don
url: /donate
# - participate:
# en:
# name: submit a proposal
# url: "/how-to-participate"
# fr:
# name: soumettre une proposition
# url: /participer
# - attend:
# en:

View File

@ -19,6 +19,7 @@
<link rel="icon" type="image/png" sizes="16x16" href="{{ site.baseurl }}/assets/favicons/favicon-16x16.png">
<link rel="apple-touch-icon" sizes="180x180" href="{{ site.baseurl }}/assets/favicons/apple-touch-icon.png">
<link rel="manifest" href="{{ site.baseurl }}/assets/favicons/site.webmanifest">
<link rel="icon" href="{{ site.baseurl }}/assets/favicons/svg-favi.svg">
<link rel="mask-icon" href="{{ site.baseurl }}/assets/favicons/safari-pinned-tab.svg" color="#5bbad5">
<meta name="msapplication-TileColor" content="#0ddfe7">

View File

@ -1,7 +1,7 @@
{% assign posts=site.posts | where:"ref", page.ref | sort: 'lang' %}
{% assign newpages=site.pages | where:"ref", page.ref | sort: 'lang' %}
<div class="nav-group">
{% if posts.size > 1 %}
{% for post in posts %}
{% if post.lang != page.lang %}
@ -34,5 +34,6 @@
<a href="{{ site.baseurl }}/" class="lang lang--{{ page.lang }}">{{ include.en-text }} </a>
<span class="poop">{{ site.data.menu[page.ref]}}</span>
{% endif %}
</div>

View File

@ -2,13 +2,30 @@
<nav>
<div class="menu">
{% for item in site.data.menu %}
{% if item.items %}
<div class="nav-group">
<a class="nav-link">{{ item[page.lang].name }}</a>
{% for sublink in item.items %}
{% if page.lang == 'en' %}
<a class="nav-link" href="{{ site.baseurl | append: item[page.lang].url }}">{{ item[page.lang].name }}</a>
<a class="sub-nav-link" href="{{ site.baseurl | append: sublink[page.lang].url }}" style=" color: {{ sublink.colour }}">{{ sublink[page.lang].name }}</a>
{% else %}
<a class="nav-link" href="{{ site.baseurl }}/{{ page.lang | append: item[page.lang].url }}">{{ item[page.lang].name }}</a>
<a class="sub-nav-link" href="{{ site.baseurl }}/{{ page.lang | append: sublink[page.lang].url }}">{{ sublink[page.lang].name }}</a>
{% endif %}
{% endfor %}
</div>
{% else %}
{% if page.lang == 'en' %}
<div class="nav-group">
<a class="nav-link" href="{{ site.baseurl | append: item[page.lang].url }}">{{ item[page.lang].name }}</a>
</div>
{% else %}
<div class="nav-group">
<a class="nav-link" href="{{ site.baseurl }}/{{ page.lang | append: item[page.lang].url }}">{{ item[page.lang].name }}</a>
</div>
{% endif %}
{% endif %}
{% endfor %}
{% include common/lang-selector.html en-text="/english" fr-text="/français" %}
</div>
</nav>