Fix many random layout issues, making blog default view
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Yarmo Mackenbach 2020-06-13 22:34:57 +02:00
parent 6210dc70c9
commit ebaaaa1963
16 changed files with 506 additions and 264 deletions

View File

@ -9,6 +9,7 @@ $router = new AltoRouter();
// Router mapping // Router mapping
$router->map('GET', '/', function() {}, 'home'); $router->map('GET', '/', function() {}, 'home');
$router->map('GET', '/about', function() {}, 'about');
$router->map('GET', '/rss', function() {}, 'rss'); $router->map('GET', '/rss', function() {}, 'rss');
$router->map('GET', '/rss.xml', function() {}, 'rss-xml'); $router->map('GET', '/rss.xml', function() {}, 'rss-xml');
$router->map('GET', '/rss/all', function() {}, 'rss-all'); $router->map('GET', '/rss/all', function() {}, 'rss-all');
@ -51,7 +52,12 @@ $variables = [
// If we are dealing with the home page // If we are dealing with the home page
if ($match['name'] == 'home') { if ($match['name'] == 'home') {
$variables['icons'] = getIcons(); $variables['posts'] = getBlogPosts($variables['params']);
// $variables['icons'] = getIcons();
}
// If we are dealing with the about page
if ($match['name'] == 'about') {
} }
// If we are dealing with the rss feed // If we are dealing with the rss feed
@ -170,6 +176,12 @@ if ($environment === 'production') {
// Phug::displayFile('index', $variables, $options); // Phug::displayFile('index', $variables, $options);
break; break;
case 'about':
// Phug optimizer
\Phug\Optimizer::call('displayFile', ['about', $variables], $options);
// Phug::displayFile('index', $variables, $options);
break;
case 'rss': case 'rss':
case 'rss-xml': case 'rss-xml':
case 'rss-all': case 'rss-all':
@ -246,6 +258,10 @@ if(is_array($match) && is_callable($match['target'])) {
Phug::displayFile('index', $variables, $options); Phug::displayFile('index', $variables, $options);
break; break;
case 'about':
Phug::displayFile('about', $variables, $options);
break;
case 'rss': case 'rss':
case 'rss-xml': case 'rss-xml':
case 'rss-all': case 'rss-all':

View File

@ -148,7 +148,7 @@ header.h-card {
.h-card .header-image { .h-card .header-image {
flex: 1; flex: 1;
flex-basis: auto; flex-basis: auto;
margin: 8px 0; margin: 8px 32px 8px 0;
text-align: center; text-align: center;
} }
.h-card .header-description { .h-card .header-description {
@ -156,7 +156,7 @@ header.h-card {
flex-basis: auto; flex-basis: auto;
/* min-width: 360px; */ /* min-width: 360px; */
margin: 8px 0; margin: 8px 0;
text-align: center; /* text-align: center; */
} }
.h-card .profile-picture { .h-card .profile-picture {
max-width: 160px; max-width: 160px;
@ -251,11 +251,14 @@ table.music th:nth-child(3) {
margin: 2em 0 0; margin: 2em 0 0;
} }
.longform_list__item { .longform_list__item {
margin: 1em 0 0; margin: 2em 0 0;
font-family: 'Lora', Georgia, Times, serif;
}
.longform_list__item a {
display: inline-block;
margin: 4px 0;
font-size: 1.3em;
} }
/* .longform_list__item a {
font-size: 1.4em;
} */
.longform__header { .longform__header {
font-size: 0.9em; font-size: 0.9em;

160
views/about.pug Normal file
View File

@ -0,0 +1,160 @@
extends layout
block content
header
p
| Back to:
a(href="/") blog
h1
| About Me
main
p
| Go to:
a(href="/") blog
| |
a(href="/notes") notes
| |
a(href="/foss") FOSS
| |
a(href="/projects") projects
| |
a(href="/music") music
| |
a(href="/pgp") PGP
| |
a(href="/contact") contact
h2 >> About me
h3 Principles
ul
li The internet needs to be decentralized
li
a(href="https://publiccode.eu/") Public money? Public code!
li Open science benefits society
li Code documentation is essential
li
| Remove
a(href="https://en.wikipedia.org/wiki/Big_Four_tech_companies") GAFAM
| from once's life
h3 Interests
ul
li Advancing and democratizing science
li Building and maintaining a homelab
li Statistics, machine learning
li Writing decent code
li Making music
li Halo universe
li Podcasts
h3 Languages (spoken, written, read)
ul
li Dutch (native)
li English (+++)
li French (+++)
li Portuguese (+)
h2 >> Science
p I have finished a PhD project in the field of Neurosciences. My research focused on the neuronal basis of directional hearing.
h3 Skills
ul
li
i In vivo
| electrophysiology
li Histology
li Behavioral techniques
li Programming & data analysis
li Database management (SQL & NoSQL)
h3 Work experience
.wrapper-table
table.work-experience
thead
tr
th Years
th Name
th Location
tbody
tr
td 2015-2019
td PhD in Neurosciences
td Erasmus MC, Rotterdam, The Netherlands
h3 Academic record
.wrapper-table
table.academic-record
thead
tr
th Years
th Name
th Location
tbody
tr
td 2010-2013
td Bachelor Biology
td Université Victor Segalen, Bordeaux, France
tr
td 2013-2015
td Master Neurosciences & Neuropsychopharmacology
td Université Victor Segalen, Bordeaux, France
tr
td 2013-2015
td Master Cellular & Molecular Biology
td Universidade de Coimbra, Portugal
tr
td 2015-2019
td PhD in Neurosciences
td Erasmus MC, Rotterdam, The Netherlands
h3 Publications
.wrapper-table
table.publications
thead
tr
th Years
th Authors
th Title
tbody
tr
td 2017
td Arnau Busquets-Garcia, [...], Giovanni Marsicano
td
a(href="https://www.nature.com/articles/mp20174") Pregnenolone blocks cannabinoid-induced acute psychotic-like states in mice
h2 >> Programming
h3 Languages used
ul
li Matlab / Octave
li Python
li R
li HTML / JS / (S)CSS
li PHP / NodeJS
li SQL / NoSQL (cypher)
h3 Experience (science)
ul
li Data visualisation
li Fourier / signal processing
li Circular statistics
li Machine learning
h3 Experience (hobbies)
ul
li Homelab / self-hosting
li Web design
li Raspberry Pi / Arduino
li Home automation
h3 Open source contributions
p
| Go to:
a(href="/foss") FOSS
h2 >> Music
p
| Go to:
a(href="/music") music

180
views/about0.pug Normal file
View File

@ -0,0 +1,180 @@
extends layout
block content
header.h-card
.header-image
img(src="/static/img/profile.png", alt="Yarmo's profile picture").profile-picture.u-photo
.header-description
h1
| I'm
a(href="https://yarmo.eu", rel="me", title="yarmo.eu").u-url.u-uid
span.p-name Yarmo Mackenbach
| (
a(href="https://pronoun.is/he").u-pronoun he/him/his
| )
p.p-note
| Finished a PhD in <span class="p-category">Neurosciences</span>.<br>
| Enjoys <span class="p-category">programming</span> and <span class="p-category">making music</span>.<br>
| Advocates for <span class="p-category">FOSS</span> and <span class="p-category">online privacy</span>.
p
a(href="mailto:yarmo@qivro.xyz", rel="me", title="Email").u-email Email
| &mdash;
a(href="xmpp:yarmo@qivro.xyz", rel="me", title="XMPP").u-xmpp XMPP
| &mdash;
a(href="https://fosstodon.org/@yarmo", rel="me", title="Fediverse").u-url Fediverse
| &mdash;
a(href="https://git.yarmo.eu/yarmo", rel="me", title="Gitea").u-url Gitea
| &mdash;
a(href="/9F0048AC0B23301E1F77E994909F6BD6F80F485D.asc", download="/9F0048AC0B23301E1F77E994909F6BD6F80F485D.asc", rel="pgpkey publickey authn", type="text/plain", title="PGP public key") PGP
main
p
| Go to:
a(href="/") blog
| |
a(href="/notes") notes
| |
a(href="/foss") FOSS
| |
a(href="/projects") projects
| |
a(href="/music") music
| |
a(href="/pgp") PGP
| |
a(href="/contact") contact
h2 &gt;&gt; About me
h3 Principles
ul
li The internet needs to be decentralized
li
a(href="https://publiccode.eu/") Public money? Public code!
li Open science benefits society
li Code documentation is essential
li
| Remove
a(href="https://en.wikipedia.org/wiki/Big_Four_tech_companies") GAFAM
| from once's life
h3 Interests
ul
li Advancing and democratizing science
li Building and maintaining a homelab
li Statistics, machine learning
li Writing decent code
li Making music
li Halo universe
li Podcasts
h3 Languages (spoken, written, read)
ul
li Dutch (native)
li English (+++)
li French (+++)
li Portuguese (+)
h2 &gt;&gt; Science
p I have finished a PhD project in the field of Neurosciences. My research focused on the neuronal basis of directional hearing.
h3 Skills
ul
li
i In vivo
| electrophysiology
li Histology
li Behavioral techniques
li Programming &amp; data analysis
li Database management (SQL &amp; NoSQL)
h3 Work experience
.wrapper-table
table.work-experience
thead
tr
th Years
th Name
th Location
tbody
tr
td 2015-2019
td PhD in Neurosciences
td Erasmus MC, Rotterdam, The Netherlands
h3 Academic record
.wrapper-table
table.academic-record
thead
tr
th Years
th Name
th Location
tbody
tr
td 2010-2013
td Bachelor Biology
td Université Victor Segalen, Bordeaux, France
tr
td 2013-2015
td Master Neurosciences &amp; Neuropsychopharmacology
td Université Victor Segalen, Bordeaux, France
tr
td 2013-2015
td Master Cellular &amp; Molecular Biology
td Universidade de Coimbra, Portugal
tr
td 2015-2019
td PhD in Neurosciences
td Erasmus MC, Rotterdam, The Netherlands
h3 Publications
.wrapper-table
table.publications
thead
tr
th Years
th Authors
th Title
tbody
tr
td 2017
td Arnau Busquets-Garcia, [...], Giovanni Marsicano
td
a(href="https://www.nature.com/articles/mp20174") Pregnenolone blocks cannabinoid-induced acute psychotic-like states in mice
h2 &gt;&gt; Programming
h3 Languages used
ul
li Matlab / Octave
li Python
li R
li HTML / JS / (S)CSS
li PHP / NodeJS
li SQL / NoSQL (cypher)
h3 Experience (science)
ul
li Data visualisation
li Fourier / signal processing
li Circular statistics
li Machine learning
h3 Experience (hobbies)
ul
li Homelab / self-hosting
li Web design
li Raspberry Pi / Arduino
li Home automation
h3 Open source contributions
p
| Go to:
a(href="/foss") FOSS
h2 &gt;&gt; Music
p
| Go to:
a(href="/music") music

View File

@ -5,10 +5,15 @@ mixin entry($item)
p !{$item['week']} &gt;&gt; !{$item['artist']} - !{$item['title']} (!{$item['year']}) p !{$item['week']} &gt;&gt; !{$item['artist']} - !{$item['title']} (!{$item['year']})
block content block content
header
p p
| Back to: | Back to:
a(href="/") yarmo.eu a(href="/about") about me
| &gt;
a(href="/music") music
h1 Yarmo's Album Of The Week h1 Yarmo's Album Of The Week
main
.list .list
each $item in $albums each $item in $albums
+entry($item) +entry($item)

View File

@ -1,12 +1,12 @@
extends layout extends layout
block content block content
.longform header
p p
| Back to: | Back to:
a(href="/") yarmo.eu a(href="/") blog
| >
a(href="/blog") blog article.longform
h1 !{$post['title']} h1 !{$post['title']}
p.longform__header Posted on !{$post['date_formatted']} by !{$post['author']} p.longform__header Posted on !{$post['date_formatted']} by !{$post['author']}
.longform__content .longform__content

View File

@ -4,10 +4,11 @@ block content
header header
p p
| Back to: | Back to:
a(href="/") yarmo.eu a(href="/about") about me
h1 h1
| Contact me | Contact me
main
h2 &gt;&gt; Online presence h2 &gt;&gt; Online presence
.wrapper-table .wrapper-table

View File

@ -12,10 +12,11 @@ block content
header header
p p
| Back to: | Back to:
a(href="/") yarmo.eu a(href="/about") about me
h1 h1
| FOSS | FOSS
main
h2 &gt;&gt; VCS accounts h2 &gt;&gt; VCS accounts
.wrapper-table .wrapper-table

View File

@ -1,5 +1,12 @@
extends layout extends layout
mixin entry($item)
.longform_list__item
p
a(href="{$item['urlrel']}") !{$item['title']}
br
| !{$item['date_formatted']}
block content block content
header.h-card header.h-card
.header-image .header-image
@ -17,172 +24,22 @@ block content
| Finished a PhD in <span class="p-category">Neurosciences</span>.<br> | Finished a PhD in <span class="p-category">Neurosciences</span>.<br>
| Enjoys <span class="p-category">programming</span> and <span class="p-category">making music</span>.<br> | Enjoys <span class="p-category">programming</span> and <span class="p-category">making music</span>.<br>
| Advocates for <span class="p-category">FOSS</span> and <span class="p-category">online privacy</span>. | Advocates for <span class="p-category">FOSS</span> and <span class="p-category">online privacy</span>.
p
a(href="mailto:yarmo@qivro.xyz", rel="me", title="Email").u-email Email
| &mdash;
a(href="xmpp:yarmo@qivro.xyz", rel="me", title="XMPP").u-xmpp XMPP
| &mdash;
a(href="https://fosstodon.org/@yarmo", rel="me", title="Fediverse").u-url Fediverse
| &mdash;
a(href="https://git.yarmo.eu/yarmo", rel="me", title="Gitea").u-url Gitea
| &mdash;
a(href="/9F0048AC0B23301E1F77E994909F6BD6F80F485D.asc", download="/9F0048AC0B23301E1F77E994909F6BD6F80F485D.asc", rel="pgpkey publickey authn", type="text/plain", title="PGP public key") PGP
main main
p p
| Go to: | Go to:
a(href="/blog") blog a(href="/about") about me
| |
a(href="/notes") notes
| |
a(href="/foss") FOSS
| |
a(href="/projects") projects
| |
a(href="/music") music
| |
a(href="/pgp") PGP
| |
a(href="/contact") contact
h2 &gt;&gt; Quick links .longform_list
p each $item in $posts
a(href="mailto:yarmo@qivro.xyz", rel="me", title="Email").u-email Email +entry($item)
| //
a(href="xmpp:yarmo@qivro.xyz", rel="me", title="XMPP").u-xmpp XMPP
| //
a(href="https://fosstodon.org/@yarmo", rel="me", title="Fediverse").u-url Fediverse
| //
a(href="https://git.yarmo.eu/yarmo", rel="me", title="Gitea").u-url Gitea
| //
a(href="https://gitlab.com/yarmo", rel="me", title="GitLab").u-url GitLab
| //
a(href="https://github.com/YarmoM", rel="me", title="Github").u-url Github
| //
a(href="/9F0048AC0B23301E1F77E994909F6BD6F80F485D.asc", download="/9F0048AC0B23301E1F77E994909F6BD6F80F485D.asc", rel="pgpkey publickey authn", type="text/plain", title="PGP public key") PGP
| //
a(href="/rss/all", title="RSS") RSS
h2 &gt;&gt; About me
h3 Principles
ul
li The internet needs to be decentralized
li
a(href="https://publiccode.eu/") Public money? Public code!
li Open science benefits society
li Code documentation is essential
li
| Remove
a(href="https://en.wikipedia.org/wiki/Big_Four_tech_companies") GAFAM
| from once's life
h3 Interests
ul
li Advancing and democratizing science
li Building and maintaining a homelab
li Statistics, machine learning
li Writing decent code
li Making music
li Halo universe
li Podcasts
h3 Languages (spoken, written, read)
ul
li Dutch (native)
li English (+++)
li French (+++)
li Portuguese (+)
h2 &gt;&gt; Science
p I have finished a PhD project in the field of Neurosciences. My research focused on the neuronal basis of directional hearing.
h3 Skills
ul
li
i In vivo
| electrophysiology
li Histology
li Behavioral techniques
li Programming &amp; data analysis
li Database management (SQL &amp; NoSQL)
h3 Work experience
.wrapper-table
table.work-experience
thead
tr
th Years
th Name
th Location
tbody
tr
td 2015-2019
td PhD in Neurosciences
td Erasmus MC, Rotterdam, The Netherlands
h3 Academic record
.wrapper-table
table.academic-record
thead
tr
th Years
th Name
th Location
tbody
tr
td 2010-2013
td Bachelor Biology
td Université Victor Segalen, Bordeaux, France
tr
td 2013-2015
td Master Neurosciences &amp; Neuropsychopharmacology
td Université Victor Segalen, Bordeaux, France
tr
td 2013-2015
td Master Cellular &amp; Molecular Biology
td Universidade de Coimbra, Portugal
tr
td 2015-2019
td PhD in Neurosciences
td Erasmus MC, Rotterdam, The Netherlands
h3 Publications
.wrapper-table
table.publications
thead
tr
th Years
th Authors
th Title
tbody
tr
td 2017
td Arnau Busquets-Garcia, [...], Giovanni Marsicano
td
a(href="https://www.nature.com/articles/mp20174") Pregnenolone blocks cannabinoid-induced acute psychotic-like states in mice
h2 &gt;&gt; Programming
h3 Languages used
ul
li Matlab / Octave
li Python
li R
li HTML / JS / (S)CSS
li PHP / NodeJS
li SQL / NoSQL (cypher)
h3 Experience (science)
ul
li Data visualisation
li Fourier / signal processing
li Circular statistics
li Machine learning
h3 Experience (hobbies)
ul
li Homelab / self-hosting
li Web design
li Raspberry Pi / Arduino
li Home automation
h3 Open source contributions
p
| Go to:
a(href="/foss") FOSS
h2 &gt;&gt; Music
p
| Go to:
a(href="/music") music

View File

@ -1,9 +1,10 @@
extends layout extends layout
block content block content
header
p p
| Back to: | Back to:
a(href="/") yarmo.eu a(href="/about") about me
h1 Yarmo's music h1 Yarmo's music
p p
| Go to: | Go to:
@ -11,6 +12,7 @@ block content
| | | |
a(href="/aotw") Album Of The Week a(href="/aotw") Album Of The Week
main
h3 Instruments h3 Instruments
ul ul
li Piano / keyboards li Piano / keyboards

View File

@ -3,14 +3,18 @@ extends layout
mixin entry($item) mixin entry($item)
.longform_list__item .longform_list__item
p p
| !{$item['date_formatted']} &gt;&gt; | !{$item['date_formatted']}
br
a(href="{$item['urlrel']}") !{$item['title']} a(href="{$item['urlrel']}") !{$item['title']}
block content block content
header
p p
| Back to: | Back to:
a(href="/") yarmo.eu a(href="/about") about me
h1 Yarmo's notes h1 Yarmo's notes
main
p p
| RSS feeds: | RSS feeds:
a(href="/rss/all") blog and notes a(href="/rss/all") blog and notes

View File

@ -1,12 +1,14 @@
extends layout extends layout
block content block content
.longform header
p p
| Back to: | Back to:
a(href="/") yarmo.eu a(href="/about") about me
| > | &gt;
a(href="/notes") notes a(href="/notes") notes
article.longform
h1 !{$post['title']} h1 !{$post['title']}
p.longform__header Posted on !{$post['date_formatted']} by !{$post['author']} p.longform__header Posted on !{$post['date_formatted']} by !{$post['author']}
.longform__content .longform__content

View File

@ -4,10 +4,11 @@ block content
header header
p p
| Back to: | Back to:
a(href="/") yarmo.eu a(href="/about") about me
h1 h1
| PGP public key | PGP public key
main
h3#pgp-signature Signature h3#pgp-signature Signature
p 9F0048AC0B23301E1F77E994909F6BD6F80F485D p 9F0048AC0B23301E1F77E994909F6BD6F80F485D

View File

@ -4,14 +4,17 @@ mixin entry($item)
.longform_list__item .longform_list__item
p p
a(href="{$item['urlrel']}") !{$item['title']} a(href="{$item['urlrel']}") !{$item['title']}
| (!{$item['status']}) br
| Status: !{$item['status']}
block content block content
header
p p
| Back to: | Back to:
a(href="/") yarmo.eu a(href="/about") about me
h1 Yarmo's projects h1 Yarmo's projects
main
.longform_list .longform_list
each $item in $projects each $item in $projects
+entry($item) +entry($item)

View File

@ -1,13 +1,15 @@
extends layout extends layout
block content block content
.longform header
p p
| Back to: | Back to:
a(href="/") yarmo.eu a(href="/about") about me
| > | &gt;
a(href="/projects") projects a(href="/projects") projects
h1 !{$project['title']} h1 !{$project['title']}
article.longform
p p
| Got an idea or a comment? | Got an idea or a comment?
a(href="/contact") Feel free to contact me! a(href="/contact") Feel free to contact me!

View File

@ -5,10 +5,15 @@ mixin entry($item)
p !{$item['artist']} - !{$item['title']} (!{$item['year']}) p !{$item['artist']} - !{$item['title']} (!{$item['year']})
block content block content
header
p p
| Back to: | Back to:
a(href="/") yarmo.eu a(href="/about") about me
| &gt;
a(href="/music") music
h1 Yarmo's vinyl collection h1 Yarmo's vinyl collection
main
.list .list
each $item in $albums each $item in $albums
+entry($item) +entry($item)