1
1
mirror of https://github.com/xplosionmind/quitsocialmedia.club.git synced 2024-12-28 17:10:01 +01:00
quitsocialmedia.club/_includes/header.html

81 lines
4.9 KiB
HTML

<script src="https://code.jquery.com/jquery-3.5.0.min.js" integrity="sha256-xNzN2a4ltkB44Mc/Jz3pT4iU1cmeR0FkXs4pru/JxaQ=" crossorigin="anonymous"></script>
<script>
(function($) { // Begin jQuery
$(function() { // DOM ready
// If a link has a dropdown, add sub menu toggle.
$('nav ul li a:not(:only-child)').click(function(e) {
$(this).siblings('.nav-dropdown').toggle();
// Close one dropdown when selecting another
$('.nav-dropdown').not($(this).siblings()).hide();
e.stopPropagation();
});
// Clicking away from dropdown will remove the dropdown class
$('html').click(function() {
$('.nav-dropdown').hide();
});
// Toggle open and close nav styles on click
$('#nav-toggle').click(function() {
$('nav ul').slideToggle();
});
// Hamburger to X toggle
$('#nav-toggle').on('click', function() {
this.classList.toggle('active');
});
}); // end DOM ready
})(jQuery); // end jQuery
</script>
<body>
{% case include.lang %}
{% when 'it' %}
<section class="navigation">
<div class="nav-container">
<nav>
<div class="nav-mobile"><a id="nav-toggle" href="#!"><span></span></a></div>
<ul class="nav-list">
<li><a href="/it/home">Home</a></li>
<!-- <li><a href="/it/about">About</a></li> -->
<!-- <li><a href="/it/news">News</a></li> -->
<li><a href="/it/manifesto">Manifesto</a></li>
<li><a href="#!"><svg width="30" height="30" enable-background="new 0 0 512 512" version="1.1" viewBox="0 0 30 30" xmlns="http://www.w3.org/2000/svg"><g transform="matrix(.0573 0 0 .0573 .344 .295)" style="fill:var(--primary);stroke-width:17.5"><path d="m384 63c35.8 0 65 29.2 65 65 0 8.28 6.72 15 15 15s15-6.72 15-15c0-52.4-42.6-95-95-95-8.28 0-15 6.72-15 15s6.72 15 15 15z"/><path d="m128 449c-35.8 0-65-29.2-65-65 0-8.28-6.72-15-15-15s-15 6.72-15 15c0 52.4 42.6 95 95 95 8.28 0 15-6.72 15-15s-6.72-15-15-15z"/><path d="m149 231-7.25 21.7c-2.09 6.29-7.95 10.3-14.2 10.3-10.2 0-17.5-10-14.2-19.7l48-144c2.04-6.13 7.77-10.3 14.2-10.3s12.2 4.13 14.2 10.3l24.6 73.8c37.8-28.2 83.6-42.2 130-40.4-19-76.1-87.9-133-170-133-96.5 0-175 78.5-175 175 0 81.9 56.5 151 133 170-1.53-39.5 8.38-79.1 29.5-114z"/><path d="m337 163c-96.4 0-175 78.2-175 175s78.2 175 175 175 175-78.2 175-175-78.2-175-175-175zm-55.6 241c-6.46 5.2-15.9 4.11-21.1-2.34-5.18-6.47-4.13-15.9 2.34-21.1 22.9-18.3 31.2-59.5 33.6-85.3h-24.2c-8.28 0-15-6.72-15-15s6.72-15 15-15h40c8.28 0 15 6.72 15 15 0 3.56-0.52 87.6-45.6 124zm119-68.7h-17v73c0 8.28-6.72 15-15 15s-15-6.72-15-15v-144c0-8.28 6.72-15 15-15s15 6.72 15 15v41h17c8.28 0 15 6.72 15 15s-6.72 15-15 15z"/><path d="m159 201h33c-2.79-8.36 0.261 0.797-16.5-49.6z"/></g></svg></a>
<ul class="nav-dropdown">
{% for cosa in site.pages %}
{% if cosa.ref == page.ref %}
<li>
<a href="{{ cosa.url }}" class="{{ cosa.lang }}">{{ cosa.lang }}</a>
</li>
{% endif %}
{% endfor %}
</ul>
</li>
</ul>
</nav>
</div>
</section>
{% else %}
<section class="navigation">
<div class="nav-container">
<nav>
<div class="nav-mobile"><a id="nav-toggle" href="#!"><span></span></a></div>
<ul class="nav-list">
<li><a href="/home">Home</a></li>
<!-- <li><a href="/about">About</a></li> -->
<!-- <li><a href="/news">News</a></li> -->
<li><a href="/manifesto">Manifesto</a></li>
<li><a href="#!"><svg width="30" height="30" enable-background="new 0 0 512 512" version="1.1" viewBox="0 0 30 30" xmlns="http://www.w3.org/2000/svg"><g transform="matrix(.0573 0 0 .0573 .344 .295)" style="fill:var(--primary);stroke-width:17.5"><path d="m384 63c35.8 0 65 29.2 65 65 0 8.28 6.72 15 15 15s15-6.72 15-15c0-52.4-42.6-95-95-95-8.28 0-15 6.72-15 15s6.72 15 15 15z"/><path d="m128 449c-35.8 0-65-29.2-65-65 0-8.28-6.72-15-15-15s-15 6.72-15 15c0 52.4 42.6 95 95 95 8.28 0 15-6.72 15-15s-6.72-15-15-15z"/><path d="m149 231-7.25 21.7c-2.09 6.29-7.95 10.3-14.2 10.3-10.2 0-17.5-10-14.2-19.7l48-144c2.04-6.13 7.77-10.3 14.2-10.3s12.2 4.13 14.2 10.3l24.6 73.8c37.8-28.2 83.6-42.2 130-40.4-19-76.1-87.9-133-170-133-96.5 0-175 78.5-175 175 0 81.9 56.5 151 133 170-1.53-39.5 8.38-79.1 29.5-114z"/><path d="m337 163c-96.4 0-175 78.2-175 175s78.2 175 175 175 175-78.2 175-175-78.2-175-175-175zm-55.6 241c-6.46 5.2-15.9 4.11-21.1-2.34-5.18-6.47-4.13-15.9 2.34-21.1 22.9-18.3 31.2-59.5 33.6-85.3h-24.2c-8.28 0-15-6.72-15-15s6.72-15 15-15h40c8.28 0 15 6.72 15 15 0 3.56-0.52 87.6-45.6 124zm119-68.7h-17v73c0 8.28-6.72 15-15 15s-15-6.72-15-15v-144c0-8.28 6.72-15 15-15s15 6.72 15 15v41h17c8.28 0 15 6.72 15 15s-6.72 15-15 15z"/><path d="m159 201h33c-2.79-8.36 0.261 0.797-16.5-49.6z"/></g></svg></a>
<ul class="nav-dropdown">
{% for cosa in site.pages %}
{% if cosa.ref == page.ref %}
<li>
<a href="{{ cosa.url }}" class="{{ cosa.lang }}">{{ cosa.lang }}</a>
</li>
{% endif %}
{% endfor %}
</ul>
</li>
</ul>
</nav>
</div>
</section>
{% endcase %}
</body>