feat: now using flex for the 11ty-nav

This commit is contained in:
Laureηt 2021-10-08 18:32:15 +02:00
parent a5ca24deeb
commit 51ebee945e
No known key found for this signature in database
GPG key ID: D88C6B294FD40994
6 changed files with 15 additions and 23 deletions

View file

@ -1,6 +1,5 @@
const pluginNavigation = require("@11ty/eleventy-navigation")
const htmlmin = require("html-minifier");
const markdownIt = require("markdown-it");
const markdownItAttrs = require('markdown-it-attrs');
const options = {

4
.vscode/launch.json vendored
View file

@ -4,9 +4,9 @@
{
"type": "node",
"request": "launch",
"name": "Launch via NPM",
"name": "Serve the website",
"console": "integratedTerminal",
"runtimeExecutable": "npm",
"runtimeExecutable": "yarn",
"runtimeArgs": [
"run",
"start"

View file

@ -6,7 +6,7 @@
"scripts": {
"watch:sass": "sass --no-source-map --watch src/scss:_site/css",
"watch:eleventy": "eleventy --serve",
"build:sass": "sass --no-source-map src/scss:_site/css",
"build:sass": "sass --no-source-map --style compressed src/scss:_site/css",
"build:eleventy": "ELEVENTY_ENV=prod eleventy",
"start": "npm-run-all build:sass --parallel watch:*",
"build": "npm-run-all build:sass build:eleventy"

View file

@ -23,8 +23,12 @@ username: Laureηt
<i class="blink" style="display:inline;">_</i>
</header>
<nav id="11ty-nav" role="navigation">
{{ collections.all | eleventyNavigation | eleventyNavigationToHtml | safe }}
<nav role="navigation">
<div class="11ty-nav">
{% for entry in collections.all | eleventyNavigation %}
<a href="{{ entry.url | url }}">{{ entry.title }}</a>
{% endfor %}
</div>
<hr>
</nav>

View file

@ -4,7 +4,13 @@ hr {
}
nav {
div {
display: flex;
gap: 1rem;
}
hr {
margin: 0.5rem 0 2rem 0;
visibility: visible;
}
}

View file

@ -85,23 +85,6 @@ video {
margin: 0 auto;
}
nav {
ul {
list-style: none;
padding: 0;
margin: 1em 0 0 0;
li {
display: inline;
margin-right: .5em;
}
}
hr {
margin: 0.5rem 0 2rem 0;
}
}
@media only screen and (max-width: 64rem) {
body {
width: calc(100% - 4rem);