Add social page with archived mastodon posts, move source to /site
This commit is contained in:
parent
a301a5cc5e
commit
648869bf76
40 changed files with 58 additions and 2 deletions
63
site/_includes/base.njk
Normal file
63
site/_includes/base.njk
Normal file
|
|
@ -0,0 +1,63 @@
|
|||
<!--
|
||||
_ _ _
|
||||
| |_ ___ _ __ | | ___ _ _ __ ___ __ _ __ ____ _ ___ | |__ ___ _ __ ___
|
||||
| __/ _ \ '_ \| |/ / | | | '_ ` _ \ / _` | \ \ /\ / / _` / __| | '_ \ / _ \ '__/ _ \
|
||||
| || __/ | | | <| |_| | | | | | | (_| | \ V V / (_| \__ \ | | | | __/ | | __/
|
||||
\__\___|_| |_|_|\_\\__,_|_| |_| |_|\__,_| \_/\_/ \__,_|___/ |_| |_|\___|_| \___|
|
||||
|
||||
-->
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html lang="{{ langKey }}">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Adrian Victor{% if pageTitle or postTitle %} - {{ pageTitle or postTitle }}{% endif %}</title>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<link rel="stylesheet" href="{{ '/static/main.css?fixcache=1' | url }}">
|
||||
<link href="{{ '/static/prism.css' | url }}" rel="stylesheet"/>
|
||||
<script type="module" src="{{ '/static/scripts/ccd.js' | url }}"></script>
|
||||
<script type="module" src="{{ '/static/scripts/music.js' | url }}" defer></script>
|
||||
<script type="module" src="{{ '/static/scripts/88x31.js' | url }}" defer></script>
|
||||
<script type="module" src="{{ '/static/scripts/tips.js' | url }}" defer></script>
|
||||
<script type="module" src="{{ '/static/scripts/click.js' | url }}" defer></script>
|
||||
<link rel="apple-touch-icon" sizes="180x180" href="{{ '/static/apple-touch-icon.png' | url }}">
|
||||
<link rel="icon" type="image/png" sizes="32x32" href="{{ '/static/favicon-32x32.png' | url }}">
|
||||
<link rel="icon" type="image/png" sizes="16x16" href="{{ '/static/favicon-16x16.png' | url }}">
|
||||
<link rel="manifest" href="{{ '/static/site.webmanifest' | url }}">
|
||||
<meta property="og:title" content="Adrian Victor{% if pageTitle or postTitle %} - {{ pageTitle or postTitle }}{% endif %}">
|
||||
<meta property="og:description" content="{{ description or i18n[langKey].websiteDescription }}">
|
||||
<meta property="og:type" content="article">
|
||||
<meta property="og:url" content="{{ page.url | url | absoluteUrl }}">
|
||||
<meta property="og:image" content="{{ ('/static/images/' ~ (background or 'bear.jpg')) | url | absoluteUrl }}">
|
||||
</head>
|
||||
<body>
|
||||
{% poison %}
|
||||
<script>
|
||||
const rootPrefix = "{{ '/' | url }}";
|
||||
</script>
|
||||
|
||||
<style>
|
||||
.bg {
|
||||
opacity: {{ backgroundOpacity or ".4" }}!important;
|
||||
}
|
||||
</style>
|
||||
|
||||
<noscript>
|
||||
<style>
|
||||
.i88x31:hover {
|
||||
transform: scale(2);
|
||||
}
|
||||
</style>
|
||||
</noscript>
|
||||
|
||||
<div id="everythingHelper">
|
||||
<img src="{{ ('/static/images/' ~ (background or 'bear.jpg')) | url }}" class="bg">
|
||||
|
||||
{% include "header.njk" %}
|
||||
|
||||
<div id="mainHelper">
|
||||
{{ content | safe }}
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
36
site/_includes/header.njk
Normal file
36
site/_includes/header.njk
Normal file
|
|
@ -0,0 +1,36 @@
|
|||
<header>
|
||||
<div>
|
||||
<h1>{{ title or "Adrian Victor" }}</h1>
|
||||
<p id="headerSubtitle"><i>{{ subtitle or "Fanasy is not a crime, find your castle in the sky." }}</i></p>
|
||||
<script>
|
||||
const headeri18n =
|
||||
{
|
||||
by: "{{ i18n[langKey].by | safe }}",
|
||||
options: "{{ i18n[langKey].options | safe }}",
|
||||
hideBackground: "{{ i18n[langKey].hideBackground | safe }}",
|
||||
back: "{{ i18n[langKey].back | safe }}",
|
||||
permissionIssue: "{{ i18n[langKey].permissionIssue | safe }}",
|
||||
permissionIssueNotificationContent: "{{ i18n[langKey].permissionIssueNotificationContent | safe }}",
|
||||
notificationDefaultHint: "{{ i18n[langKey].notificationDefaultHint | safe }}",
|
||||
disableSoundEffects: "{{ i18n[langKey].disableSoundEffects | safe }}"
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
<div id="linksHelper">
|
||||
<div id="music"></div>
|
||||
|
||||
<ul id="headerLinks">
|
||||
{% if langKey %}
|
||||
<a href="{{ ('/' ~ langKey ~ '/') | url }}">{{ i18n[langKey].home }}</a>
|
||||
<a href="{{ ('/' ~ langKey ~ '/blog/') | url }}">blog</a>
|
||||
<a href="{{ ('/' ~ langKey ~ '/misc/') | url }}">misc</a>
|
||||
<a href="{{ ('/' ~ langKey ~ '/social/') | url }}">social</a>
|
||||
{% endif %}
|
||||
{% if langKey == undefined %}
|
||||
<a href="{{ ('/') | url }}">home</a>
|
||||
{% endif %}
|
||||
<a rel="me" href="https://mstdn.social/@tenkuma" style="display: none;">Mastodon</a>
|
||||
<a href="https://github.com/adrianvic" rel="me" style="display: none;">github.com/aaronpk</a>
|
||||
</ul>
|
||||
</div>
|
||||
</header>
|
||||
62
site/_includes/macros.njk
Normal file
62
site/_includes/macros.njk
Normal file
|
|
@ -0,0 +1,62 @@
|
|||
{% macro i88x31(link, alt=link, interactive=true) %}
|
||||
<img
|
||||
class="i88x31{% if interactive == true %} i88x31i{% endif %}"
|
||||
src="{{ ('/static/images/88x31/' ~ link) | url }}"
|
||||
{% if alt == link %}
|
||||
data-tip="<b>{{ i18n[langKey].i88x31hover }}</b> ({{ link }})"
|
||||
{% endif %}
|
||||
{% if alt != link %}
|
||||
data-tip="{{ alt }}"
|
||||
{% endif %}
|
||||
alt="{{ alt }}"
|
||||
>
|
||||
{% endmacro %}
|
||||
|
||||
{% macro videoCard(videoLink, videoTitle, videoImage, videoWebsite, videoDuration, videoAccent) %}
|
||||
<div class="youtubeCardHolderHelper">
|
||||
<div class="youtubeCardHolder">
|
||||
<a href="{{ videoLink }}">
|
||||
<div class="blogpostYoutubeVideo" {% if videoAccent %}style="border-color: {{ videoAccent }};"{% endif %}>
|
||||
<img src="{{ ('/static/images' ~ videoImage) | url }}">
|
||||
<div class="videoHeader">
|
||||
{# <p class="alsoAvailable">{{ i18n[langKey].alsoAvailableAsVideo }}:</p> #}
|
||||
<h2 class="videoTitle" {% if videoAccent %}style="color: {{ videoAccent }};"{% endif %}>
|
||||
{{ videoTitle }}
|
||||
</h2>
|
||||
<p>{{ videoWebsite }}{% if videoDuration %} ({{ videoDuration }}){% endif %}</p>
|
||||
</div>
|
||||
{# <p class="goLabel">ir</p> #}
|
||||
</div>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
{% endmacro %}
|
||||
|
||||
{% macro projectCard(projectName, projectDescription, projectLink, projectImage, projectImageAlt) %}
|
||||
<div class="hsProject">
|
||||
<div class="hsProjectHeader">
|
||||
<div class="hsProjectImage">
|
||||
<img src="{{ projectImage | url }}" alt="{{ projectImageAlt or projectName }}">
|
||||
</div>
|
||||
<a href="{{ projectLink }}" class="hsProjectHeaderIcon">
|
||||
<img src="{{ '/static/visual/github.svg' | url }}" class="invertedc">
|
||||
</a>
|
||||
</div>
|
||||
<div class="hsProjectContent">
|
||||
<p>{{ projectDescription | safe }}</p>
|
||||
</div>
|
||||
</div>
|
||||
{% endmacro %}
|
||||
|
||||
{% macro webring(opts) %}
|
||||
<div class="webringGeneric"
|
||||
style="{% if opts.image %}background-image:url('{{ opts.image | url }}');{% endif %}
|
||||
{% if opts.color %}background-color:{{ opts.color }};{% endif %}">
|
||||
<p>{{ opts.text }}</p>
|
||||
<div class="webringButtons">
|
||||
{% for link in opts.links %}
|
||||
{{ link | safe }}
|
||||
{% endfor %}
|
||||
</div>
|
||||
</div>
|
||||
{% endmacro %}
|
||||
31
site/_includes/post.njk
Normal file
31
site/_includes/post.njk
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
---
|
||||
layout: base.njk
|
||||
title: Adrian Victor:Blog
|
||||
---
|
||||
{% set altLanguages = collections.post | alternateLanguages(postId, langKey) %}
|
||||
{% from "macros.njk" import videoCard with context %}
|
||||
|
||||
<main>
|
||||
<article>
|
||||
<div id="postHeader">
|
||||
<h1>{{ postTitle }}</h1>
|
||||
<p>{{ i18n[langKey].readingTime }}: {{ content | readingTime }}</p>
|
||||
<p>{{ authors or "Adrian Victor" }} - <b>{{ date | postDate }}</b>{% if lastModified | postDate !== date | postDate %} ({{ i18n[langKey].lastEditedIn }} {{ lastModified | postDate }}){% endif %}</p>
|
||||
{% if altLanguages.length > 0 %}
|
||||
{{ i18n[langKey].availableInOtherLanguages }}:
|
||||
{% for alt in altLanguages %}
|
||||
<li class="inlineList">
|
||||
<a href="{{ alt.url | url }}" hreflang="{{ alt.lang }}">
|
||||
{{ i18n[alt.lang].language }}
|
||||
</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
</div>
|
||||
{% if postVideoLink and postVideoImage and postVideoTitle and postVideoWebsite %}
|
||||
{{ videoCard(postVideoLink, postVideoTitle, postVideoImage, postVideoWebsite, postVideoDuration) }}
|
||||
{% endif %}
|
||||
|
||||
{{ content | safe }}
|
||||
</article>
|
||||
</main>
|
||||
6
site/_includes/text.njk
Normal file
6
site/_includes/text.njk
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
---
|
||||
layout: base.njk
|
||||
---
|
||||
<main class="fullWidth">
|
||||
{{ content | safe }}
|
||||
</main>
|
||||
44
site/_includes/widgets/droidring.html
Normal file
44
site/_includes/widgets/droidring.html
Normal file
|
|
@ -0,0 +1,44 @@
|
|||
<center>
|
||||
<div class="droidringwidget">
|
||||
<a href="https://kanandraw.neocities.org/stuffs/droidring/home"><img src="https://kanandraw.neocities.org/stuffs/droidring/assets/logo.png" style="width: 200px; padding: .4em;"></a><br/>
|
||||
<!-- <img src="https://kanandraw.neocities.org/stuffs/droidring/assets/droidwidget.png" style="width: 115px;"><br> -->
|
||||
<div class="buttonsdroidring">
|
||||
<a href="https://kanandraw.neocities.org/stuffs/droidring/home?action=previous"><button class="navdroidring" data-tip="{{ i18n[langKey].previousSite | smartTitle }}">←</button></a>
|
||||
<a href="https://kanandraw.neocities.org/stuffs/droidring/home?action=random"><button class="navdroidring" data-tip="{{ i18n[langKey].random | smartTitle }}">⇄</button></a>
|
||||
<a href="https://kanandraw.neocities.org/stuffs/droidring/home?action=next"><button class="navdroidring" data-tip="{{ i18n[langKey].nextSite | smartTitle }}">→</button></a>
|
||||
</div>
|
||||
<style>
|
||||
.droidringwidget {
|
||||
font-family: 'Droid Sans',sans-serif;
|
||||
align-content: center;
|
||||
text-align: center;
|
||||
/* width: 215px; */
|
||||
border: 1px solid #666666;
|
||||
background: linear-gradient(0deg, black, #000000db);
|
||||
padding: 5px;
|
||||
}
|
||||
.buttonsdroidring {
|
||||
background: #989898;
|
||||
padding: 4px;
|
||||
margin: -5px;
|
||||
}
|
||||
|
||||
.navdroidring {
|
||||
background: linear-gradient(to bottom, #F1F1F1, #B8B8B8);
|
||||
padding: 5px;
|
||||
color: black;
|
||||
box-shadow: 0 3px 6px #00000029, 0 3px 6px #0000003B;
|
||||
border: none;
|
||||
width: 50px;
|
||||
height: 27px;
|
||||
min-width: 50px;
|
||||
}
|
||||
.navdroidring:active {
|
||||
background: linear-gradient(to bottom,#FFD554,#E99D00);
|
||||
}
|
||||
.navdroidring:hover {
|
||||
background: linear-gradient(to bottom, #ffebc4, #f2f2f2);
|
||||
}
|
||||
</style>
|
||||
</div>
|
||||
</center>
|
||||
7
site/_includes/widgets/internetometer-aside.html
Normal file
7
site/_includes/widgets/internetometer-aside.html
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
<div class="internetometerAside">
|
||||
<div>
|
||||
<h1 class="negativeMargin">{{ i18n[langKey].liked | smartTitle }}?</h1>
|
||||
<hr style="margin-bottom: .4em;">
|
||||
</div>
|
||||
<a href='http://internetometer.com/give/52060'><img src='http://internetometer.com/image/52060.png'/></a>
|
||||
</div>
|
||||
Loading…
Reference in a new issue