From 99f849e58931a022209446469b12b0e924e3f067 Mon Sep 17 00:00:00 2001 From: wgroeneveld Date: Thu, 25 Mar 2021 20:58:19 +0100 Subject: [PATCH] do not rely on publishedFromNow but build it dynamically --- content/articles/reviews/sonic-mania.md | 2 ++ .../layouts/partials/reldate.html | 15 +++++++++++++++ .../layouts/partials/single-mentions.html | 3 ++- 3 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 themes/jefklak-creative-portfolio/layouts/partials/reldate.html diff --git a/content/articles/reviews/sonic-mania.md b/content/articles/reviews/sonic-mania.md index 0bd7d89..e04cd95 100644 --- a/content/articles/reviews/sonic-mania.md +++ b/content/articles/reviews/sonic-mania.md @@ -48,6 +48,8 @@ At least Whitehead managed to create a _proper_ classic 2D sonic game. SEGA was Sadly, the DLC, Sonic Mania Plus, is a bit of a letdown. I expected a few extra Zones to play through as I'm not a big fan of games within games. Sonic Mania Plus gives you a few extra playable fluffy characters, of which an armadillo that can stomp the ground, but they're mostly forgettable when I can play with Sonic, Tails or Knuckles. Luckily, they don't speak, like in the 3D games... Furthermore, other new additions such as Encore mode, left me yearning for more classic Sonic gameplay. Instead, I'm on a weird mission to "collect" my fluffy friends. The mode does start promising, with a tiny portion of Sonic 3's classic first Angel Fire island Zone. Just the music got me going - until I abruptly "finished" it 20 seconds later. Too good to be true. +Okay, fine. After the initial nostalgia wears off a bit - it won't be gone completely - the game can sometimes get on my nerves. Take Flying Battery Zone Act II for instance. Weather conditions cause Sonic to shift in directions. Combined with some upside-down loops around the ship, where I never know if I need to keep on pressing the `->` button when in reality going left, the _Game Over_ screen does come rather quickly, but perhaps not unexpectedly so. On other occasions in the same Zone, where I attack an airborne enemy but forget to take the knockback into account, Sonic suddenly falls off the edges. Fuck. Another _Game Over_ screen. Time to put the controller away before I start flinging it through the living room... + There _are_ [Sonic Mania 2 Rumors](https://www.thegamecrater.com/sonic-mania-2-dreams-and-desires/) floating around, and all my money is on that one. The big promise is more original zones, as according to The Game Crater, everyone's sick of playing the same old stuff: > That being said, I feel like focusing too much on Genesis-Sonic nostalgia could hamstring the series a bit. One of the recurring jokes in the fandom is that everyone is sick of playing Green Hill Zone and Chemical Plant Zone. But there’s a grain of truth to that. diff --git a/themes/jefklak-creative-portfolio/layouts/partials/reldate.html b/themes/jefklak-creative-portfolio/layouts/partials/reldate.html new file mode 100644 index 0000000..de663fe --- /dev/null +++ b/themes/jefklak-creative-portfolio/layouts/partials/reldate.html @@ -0,0 +1,15 @@ + +{{ $ageDays := div (sub now.Unix .Unix) 86400 }} +{{ $ageMonths := div (sub now.Unix .Unix) 2592000 }} + +{{ if eq $ageDays 0 }} + Today +{{ else if lt $ageDays 31 }} + {{ $ageDays }} + {{ cond (eq $ageDays 1) "day" "days"}} + ago +{{ else }} + {{ $ageMonths }} + {{ cond (eq $ageMonths 1) "month" "months" }} + ago +{{ end }} diff --git a/themes/jefklak-creative-portfolio/layouts/partials/single-mentions.html b/themes/jefklak-creative-portfolio/layouts/partials/single-mentions.html index 747faca..a07a58c 100644 --- a/themes/jefklak-creative-portfolio/layouts/partials/single-mentions.html +++ b/themes/jefklak-creative-portfolio/layouts/partials/single-mentions.html @@ -24,7 +24,8 @@  | by