new theme

This commit is contained in:
2005 2024-08-06 17:17:56 +02:00
parent 318610e7d9
commit 85bd81ea3d
36 changed files with 448 additions and 723 deletions

353
assets/css/purple.css Normal file
View file

@ -0,0 +1,353 @@
/* Markdown */
:root{
--maincolor: #fad000;
--bordercl:rebeccapurple;
--callouctcolor:dodgerblue;
--hovercolor:navy;
--darkMaincolor: #50fa7b;
}
html {
color: #232333;
font-family: 'Roboto Mono', monospace;
font-size: 15px;
background-color: #191830;
color: white;
line-height: 1.6em;
}
body{
display: block;
margin: 8px;
}
* {
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}
::selection {
background: var(--maincolor);
color: #fff;
}
p {
font-family: 'Fira Sans', sans-serif;
line-height: 1.5;
}
hr {
border: 0;
border-top: 3px dotted var(--bordercl);
margin: 1em 0;
}
blockquote {
border-left: 3px solid var(--bordercl);
color: #737373;
margin: 0;
padding-left: 1em;
}
a {
border-bottom: 3px solid var(--maincolor);
color: inherit;
text-decoration: none;
}
a:hover {
background-color: var(--hovercolor);
color: #fff;
}
ul {
list-style: none;
padding-left: 2ch;
}
ul li {
text-indent: -2ch;
}
ul > li::before {
content: '* ';
font-weight: bold;
}
/* Images */
img {
border: 3px solid #ececec;
max-width: 100%;
}
figure {
box-sizing: border-box;
display: inline-block;
margin: 0;
max-width: 100%;
}
figure img {
max-height: 500px;
}
@media screen and (min-width: 600px) {
figure {
padding: 0 40px;
}
}
figure h4 {
font-size: 1rem;
margin: 0;
margin-bottom: 1em;
}
figure h4::before {
content: '↳ ';
}
/* Code blocks */
code {
background-color: #131327;
padding: .1em .2em;
color: #fad000;
}
pre {
background-color: #ececec;
line-height: 1.4;
overflow-x: auto;
padding: 1em;
}
.highlight pre ::selection {
background: rgba(255, 255, 255, 0.2);
color: inherit;
}
pre code {
background-color: transparent;
color: inherit;
font-size: 100%;
padding: 0;
}
/* Containers */
.content {
margin-bottom: 4em;
margin-left: auto;
margin-right: auto;
max-width: 800px;
padding: 0 1ch;
word-wrap: break-word;
}
/* Header */
header {
display: flex;
flex-wrap: wrap;
justify-content: space-between;
margin: 1em 0;
line-height: 2.5em;
}
header .main {
font-size: 1.5rem;
}
h1, h2, h3, h4, h5, h6 {
font-size: 1.2rem;
margin-top: 2em;
}
h1::before { color: var(--maincolor); content: '# '; }
h2::before { color: var(--maincolor); content: '## '; }
h3::before { color: var(--maincolor); content: '### '; }
h4::before { color: var(--maincolor); content: '#### '; }
h5::before { color: var(--maincolor); content: '##### '; }
h6::before { color: var(--maincolor); content: '###### '; }
.meta {
color: #999;
letter-spacing: -0.5px;
}
.toc {
background-color: #ececec;
color: #232333;
padding: 10px;
padding-bottom: 0;
border-radius: 5px;
display: inline-block;
}
/* Footer */
footer {
display: flex;
align-items: center;
border-top: 0.4rem dotted var(--bordercl);
padding: 2rem 0rem;
margin-top: 2rem;
}
.soc {
display: flex;
align-items: center;
border-bottom: none;
}
.border {
margin-left: 0.5rem;
margin-right: 0.5rem;
border: 1px solid;
}
.footer-info {
padding: var(--footer-padding);
}
/* Common */
.title h1 {
margin-bottom: 0;
}
time {
color: grey;
}
/* Posts */
article .title {
margin-bottom: 1em;
}
/* Callout */
.callout {
background-color: var(--callouctcolor);
color: #fff;
padding: 1em;
}
.callout p {
font-family: 'IBM Plex Mono', monospace;
margin: 0;
}
.callout a {
border-bottom: 3px solid #fff;
}
.callout a:hover {
background-color: #fff;
color: var(--callouctcolor);
}
.site-description {
display: flex;
justify-content: space-between;
}
.tags li::before{
content: "🏷 ";
}
.tags a{
border-bottom: 3px solid var(--maincolor);
}
.tags a:hover{
color:white;
background-color: var(--hovercolor);
}
svg{
max-height: 15px;
}
.soc:hover{
color: white;
}
.draft-label{
color: var(--bordercl);
text-decoration: none;
padding: 2px 4px;
border-radius: 4px;
margin-left: 6px;
background-color: #f9f2f4;
}
.highlight {
position: relative;
-webkit-overflow-scrolling: touch;
}
.highlight pre code[class*="language-"] {
-webkit-overflow-scrolling: touch;
}
.highlight pre code[class*="language-"]::before {
background: black;
border-radius: 0 0 0.25rem 0.25rem;
color: white;
font-size: 12px;
letter-spacing: 0.025rem;
padding: 0.1rem 0.5rem;
position: absolute;
right: 1rem;
text-align: right;
text-transform: uppercase;
top: 0;
}
.highlight pre code[class=language-javaScript]::before,
.highlight pre code[class="language-js"]::before {
content: "js";
background: #f7df1e;
color: black;
}
.highlight pre code[class*='language-yml']::before,
.highlight pre code[class*='language-yaml']::before {
content: 'yaml';
background: #f71e6a;
color: white;
}
.highlight pre code[class*='language-shell']::before,
.highlight pre code[class*='language-bash']::before,
.highlight pre code[class*='language-sh']::before {
content: 'shell';
background: green;
color:white
}
.highlight pre code[class*='language-json']::before{
content: 'json';
background: dodgerblue;
color: #000000
}
.highlight pre code[class*='language-python']::before,
.highlight pre code[class*='language-py']::before {
content: 'py';
background: blue;
color: yellow ;
}
.highlight pre code[class*='language-css']::before{
content: 'css';
background: cyan;
color: black ;
}
.highlight pre code[class*='language-go']::before{
content: 'Go';
background: cyan;
color: royalblue ;
}
.highlight pre code[class*='language-md']::before,
.highlight pre code[class*='language-md']::before{
content: 'Markdown';
background: royalblue;
color: whitesmoke ;
}
.highlight pre code[class*='language-md']::before,
.highlight pre code[class*='language-md']::before{
content: 'nix';
background: royalblue;
color: whitesmoke ;
}
/* table */
table {
border-spacing: 0;
border-collapse: collapse;
}
table th{
padding: 6px 13px;
border: 1px solid #dfe2e5;
font-size: large;
}
table td{
padding: 6px 13px;
border: 1px solid #dfe2e5;
}

1
assets/icons/forgejo.svg Normal file
View file

@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 24 24"><path fill="currentColor" d="M16.777 0a2.9 2.9 0 1 1-2.529 4.322H12.91a4.266 4.266 0 0 0-4.265 4.195v2.118a7.08 7.08 0 0 1 4.147-1.42l.118-.002h1.338a2.9 2.9 0 0 1 5.43 1.422a2.9 2.9 0 0 1-5.43 1.422H12.91a4.266 4.266 0 0 0-4.265 4.195v2.319A2.9 2.9 0 0 1 7.222 24A2.9 2.9 0 0 1 5.8 18.57V8.589a7.11 7.11 0 0 1 6.991-7.108l.118-.001h1.338A2.9 2.9 0 0 1 16.778 0M7.223 19.905a1.194 1.194 0 1 0 0 2.389a1.194 1.194 0 0 0 0-2.389m9.554-10.464a1.194 1.194 0 1 0 0 2.389a1.194 1.194 0 0 0 0-2.39m0-7.735a1.194 1.194 0 1 0 0 2.389a1.194 1.194 0 0 0 0-2.389"/></svg>

After

Width:  |  Height:  |  Size: 644 B

1
assets/img/forgejo.svg Normal file
View file

@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 24 24"><path fill="currentColor" d="M16.777 0a2.9 2.9 0 1 1-2.529 4.322H12.91a4.266 4.266 0 0 0-4.265 4.195v2.118a7.08 7.08 0 0 1 4.147-1.42l.118-.002h1.338a2.9 2.9 0 0 1 5.43 1.422a2.9 2.9 0 0 1-5.43 1.422H12.91a4.266 4.266 0 0 0-4.265 4.195v2.319A2.9 2.9 0 0 1 7.222 24A2.9 2.9 0 0 1 5.8 18.57V8.589a7.11 7.11 0 0 1 6.991-7.108l.118-.001h1.338A2.9 2.9 0 0 1 16.778 0M7.223 19.905a1.194 1.194 0 1 0 0 2.389a1.194 1.194 0 0 0 0-2.389m9.554-10.464a1.194 1.194 0 1 0 0 2.389a1.194 1.194 0 0 0 0-2.39m0-7.735a1.194 1.194 0 1 0 0 2.389a1.194 1.194 0 0 0 0-2.389"/></svg>

After

Width:  |  Height:  |  Size: 644 B

View file

@ -1,11 +0,0 @@
# Change baseurl before deploy
baseurl = "https://4o1x5.dev"
languageCode = "en-us"
paginate = 5
title = "4o1x5"
#theme = "nostyle"
theme = "stack"
# Available values: en, fr, id, ja, ko, pt-br, zh-cn, zh-tw, es, de, nl, it, th, el, uk, ar
defaultContentLanguage = "en"
hasCJKLanguage = false

View file

@ -1,18 +0,0 @@
# Rename this file to languages.toml to enable multilingual support
[en]
languageName = "English"
languagedirection = "ltr"
title = "4o1x5"
weight = 1
[hu]
languageName = "Magyar"
languagedirection = "ltr"
title = "4o1x5"
weight = 2
[fr]
languageName = "Français"
languagedirection = "ltr"
title = "4o1x5"
weight = 2

View file

@ -1,17 +0,0 @@
# Markdown renderer configuration
[goldmark.renderer]
unsafe = true
[tableOfContents]
endLevel = 4
ordered = true
startLevel = 2
[highlight]
noClasses = false
codeFences = true
guessSyntax = true
lineNoStart = 1
lineNos = true
lineNumbersInTable = true
tabWidth = 4

View file

@ -1,19 +0,0 @@
[[social]]
identifier = "git"
name = "Git"
url = "https://git.4o1x5.dev/4o1x5"
[social.params]
icon = "git-fork"
[[social]]
identifier = "matrix"
name = "Matrix"
url = "https://matrix.to/#/@4o1x5:4o1x5.dev"
[social.params]
icon = "message"

View file

@ -1,83 +0,0 @@
mainSections = ["post"]
rssFullContent = true
favicon = "/favicon.png"
[footer]
since = 2024
customText = "Art by byung jun ko"
customTextUrl= "https://www.behance.net/gallery/111899291/Blue-Spring-2019"
[dateFormat]
published = "Jan 02, 2006"
lastUpdated = "Jan 02, 2006 15:04 MST"
[sidebar]
subtitle = "Software developer of somekind"
musicTitle = "Empathy - Crystal Castles"
musicUrl = "https://youtu.be/NLi2v-Gq-5A"
[sidebar.avatar]
enabled = true
local = true
src = "img/pfp.png"
[article]
math = true
readingTime = true
[article.license]
enabled = true
default = "Licensed under CC-BY-SA 4.0"
[[widgets.homepage]]
type = "search"
[[widgets.homepage]]
type = "archives"
[widgets.homepage.params]
limit = 5
[[widgets.homepage]]
type = "categories"
[widgets.homepage.params]
limit = 10
[[widgets.homepage]]
type = "tag-cloud"
[widgets.homepage.params]
limit = 10
[[widgets.page]]
type = "toc"
[defaultImage.opengraph]
enabled = false
local = false
src = ""
[colorScheme]
toggle = true
default = "auto"
[imageProcessing.cover]
enabled = true
[imageProcessing.content]
enabled = true
## Comments
[comments]
enabled = true
provider = "cactus"
[comments.cactus]
defaultHomeserverUrl = "https://matrix.cactus.chat"
serverName = "cactus.chat"
siteName = "4o1x5dev"

View file

@ -1,3 +0,0 @@
# Permalinks format of each content section
post = "/p/:slug/"
page = "/:slug/"

View file

@ -1,12 +0,0 @@
# Related contents configuration
includeNewer = true
threshold = 60
toLower = false
[[indices]]
name = "tags"
weight = 100
[[indices]]
name = "categories"
weight = 200

View file

@ -1,8 +0,0 @@
---
menu:
main:
name: Kezdőlap
weight: 1
params:
icon: home
---

View file

@ -1,8 +0,0 @@
---
menu:
main:
name: Home
weight: 1
params:
icon: home
---

View file

@ -1,9 +0,0 @@
---
title: "Archive"
date: 2022-03-06
layout: "archives"
menu:
main:
params:
icon: archives
---

View file

@ -1,9 +0,0 @@
---
title: "Könyvtár"
date: 2022-03-06
layout: "archives"
menu:
main:
params:
icon: archives
---

View file

@ -1,10 +0,0 @@
---
title: "Archives"
date: 2022-03-06
layout: "archives"
slug: "archives"
menu:
main:
params:
icon: archives
---

View file

@ -1,32 +0,0 @@
---
title: Frontendek
links:
- title: Piped
description: An alternative privacy-friendly YouTube frontend which is efficient by design.
website: https://piped.4o1x5.dev/
image: piped.svg
- title: Libreddit
description: Private front-end for Reddit
website: https://libreddit.4o1x5.dev/
image: libreddit.png
menu:
main:
params:
icon: cookie-off
comments: true
draft: true
---
# Privacy respecting frontends
You may come across breaches occurring every month or two, which is why I prioritize using privacy-respecting
frontends on a daily basis to protect my data. As I am leveraging someone else's server for free, it's only fair
that I also self-host them as well.
**You are free to use mine anytime free of charge.**
[If you're interested in reviewing my privacy
terms, they are available here.](/privacy-policy) Tho I do not collet any data... ever...

View file

@ -1,79 +1,5 @@
---
title: Frontends
links:
# - title: Piped
# description: An alternative privacy-friendly YouTube frontend which is efficient by design.
# website: https://piped.4o1x5.dev/
# image: piped.svg
# - title: Quetre
# description: An alternaive front-end to Quora. It enables you to see answers without ads, trackers, and other such bloat.
# website: https://libreddit.4o1x5.dev/
# image: quetre.png
# - title: libremdb
# description: An alternaive front-end to Quora. It enables you to see answers without ads, trackers, and other such bloat.
# website: https://libreddit.4o1x5.dev/
# image: libremdb.png
- title: Libreddit
description: Private front-end for Reddit
website: https://libreddit.4o1x5.dev/
image: libreddit.png
- title: Safetwitch
description: A privacy respecting frontend for twitch.tv
website: https://safetwitch.4o1x5.dev/
image: safetwitch.png
- title: Breezewiki
description: An alternative frontend for Fandom
website: https://breezewiki.4o1x5.dev/
image: breezewiki-icon-color.svg
- title: Gothub
description: An alternative frontend for GitHub
website: https://gothub.4o1x5.dev/
image: gothub.svg
- title: AnonymousOverflow
description: View StackOverflow in privacy and without the clutter
website: https://anonymousoverflow.4o1x5.dev/
image: anonymousoverflow.webp
- title: Quetre
description: A libre front-end for Quora
website: https://quetre.4o1x5.dev/
image: quetre.png
- title: Libremdb
description: A free & open source IMDb front-end
website: https://libremdb.4o1x5.dev/
image: libremdb.png
- title: Dumb
description: An alternative frontend for genius.com
website: https://dumb.4o1x5.dev/
image: dumb.png
- title: Rimgo
description: The fast, private image viewer for Imgur.
website: https://rimgo.4o1x5.dev/
image: rimgo.svg
- title: Binternet
description: A custom Pinterest frontend, made in PHP
website: https://binternet.4o1x5.dev/
- title: Librey
description: Framework and JS free privacy respecting meta search engine
website: https://librey.4o1x5.dev/
menu:
main:
params:
icon: cookie-off
comments: false
draft: false
---
@ -91,4 +17,4 @@ A plan on hosting **every** frontend that Libredirect has. I will also make them
terms, they are available here.](/privacy-policy)
Any issues with the services shall be discussed on the [dedicated matrix channel](https://matrix.to/#/#services:4o1x5.dev)
This below is not the full list, if you want all the details go and look at my [infrastructure repo containing them all](https://git.4o1x5.dev/4o1x5/infrastructure/#Privacy-respecting-services)
# [List](https://git.4o1x5.dev/4o1x5/infrastructure/#privacy-respecting-services)

View file

@ -1,13 +0,0 @@
---
title: "Chercher"
slug: "search"
layout: "search"
outputs:
- html
- json
menu:
main:
weight: 3
params:
icon: search
---

View file

@ -1,13 +0,0 @@
---
title: "Keresés"
slug: "search"
layout: "search"
outputs:
- html
- json
menu:
main:
weight: 3
params:
icon: search
---

View file

@ -1,13 +0,0 @@
---
title: "Search"
slug: "search"
layout: "search"
outputs:
- html
- json
menu:
main:
weight: 3
params:
icon: search
---

View file

@ -13,7 +13,7 @@ tags:
- Homelab
- Selfhost
draft: false
draft: true
writingTime: "1h 40m"
---

View file

@ -14,7 +14,7 @@ tags:
- NixOs
- Server Management
draft: false
draft: true
---
With the capabilities of Nix & Nixos, we can tailor-make services on our local computer,

View file

@ -13,7 +13,7 @@ tags:
- Nginx
- Short
- Hugo
draft: false
draft: true
---
## Overview

View file

@ -12,7 +12,7 @@ tags:
- Nginx
- Rövid
- Hugo
draft: false
draft: true
---
## Bevezető

View file

@ -0,0 +1,45 @@
---
title: My two years at Contabo
description: It's been a great run, but we have to say our goodbyes!
date: 2024-08-06 00:00:00+0000
categories:
- Blog
- Guide
- Sysadmin
tags:
- Servers
- VPS
draft: false
---
I wanted to host a few services for myself in 2020 and have decided to rent out a medium VPS at contabo. I stayed at them for exactly two years then I got some servers at home and decided to cancel my subscription. It was a pleasureful experience with them during that time period. Despite many controversies I saw on some reddit posts I had 0 downtime and 0 techinal difficulties.
My use case consisted of hosting a website, matrix server and a bunch of privacy respecting services. Obviously your usage case might vary from mine so its a great idea to take in some information before using their services. I would call them the quantity over quality type of hoster.
I paid about 12 euros a month for 24 months meaning in total I've spent 288 euros. It was a 100% worth since I was still a student with no stable income so I couldn't have bought a big DELL server or something like that.
## Why is contabo so cheap
Contabo is dirt cheap. Compared to many other hosters like Vultr or Digitalocean you can see that they almost have 2x cheaper options. But obviously this comes with some compromises.
### Contabo doesn't use any fancy enterprise level KVM software.
They use [Proxmox](https://www.proxmox.com/en/). It's an awesome suite of linux tools bundled together that makes virtualization really easy. It also offers an API which contabo 100% uses for their business. As an user of their VPS services you are most likely will notice none of this only if you use VNC and log in before the vps starts. (the proxmox bios logo shows up).
But since Proxmox is a free and libre software this means they have to pay $0 to use it. This results in cheaper prices.
### You don't own your CPU cores, and neither are they fast
8 cores, 12 cores or hell even 24 CPU cores might seem exciting at first until you see the _V_ before CPU. In short this means that you are getting _shared_ virtual cpu cores. You are sharing your cpu cores with the hundreds of other virtual servers on that one big physical server. This results in slower/degraded performance. If you intend to run CPU heavy applications on the VPS you are better off buying a dedicated VPS with dedicated virtual cpu cores.
Contabo is known for having older reused/refurbished servers. Meaning even tho you might get 24 cores with their strongest VPS plan you might just end up with a slower cpu. Compared to other hosters out there, most of them give out details on what you're getting. Contabo never dares to mention it.
Also there is no support outside of office hours. Meaning you will only get support if the staff is at the computer during a 9-5. This was not really a deal breaker for me as I never needed support.
### Good things at contabo
#### Zero downtime
During my stay, I really had 0 downtime. ZERO. well.. zero caused by contabo. I have restarted my vps a few times in that period and even ran `rm -fr /` once by accident.
#### Snapshots
Based on your tier, contabo offer a few snapshots that you can manually create. This allows you to switch back to older versions of your server's state in case you do something horrible like I did.... AFAIK there is no option to automatically schedule snapshots and delete older ones, but I might be wrong

39
hugo.toml Normal file
View file

@ -0,0 +1,39 @@
baseURL = "https://4o1x5.dev"
languageCode = "en-us"
title = "4o1x5.dev"
theme="archie"
# Code Highlight
pygmentsstyle = "monokai"
pygmentscodefences = true
pygmentscodefencesguesssyntax = true
paginate=3
[params]
mode="auto" # color-mode → light,dark,toggle or auto
useCDN=false # don't use CDNs for fonts and icons, instead serve them locally.
mathjax = true # enable MathJax support
katex = true # enable KaTeX support
customcss = ["css/purple.css", ]
[[params.social]]
name = "Forgejo"
icon = "forgejo"
url = "https://git.4o1x5.dev/4o1x5"
[[params.social]]
name = "Matrix"
icon = "message"
url = "https://matrix.to/#/@4o1x5:4o1x5.dev"
# Main menu Items
[[menu.main]]
name = "Home"
url = "/"
weight = 1

View file

@ -1,73 +0,0 @@
toggleMenu:
other: Toggle Menu
darkMode:
other: Dark Mode
list:
page:
one: "{{ .Count }} page"
other: "{{ .Count }} pages"
section:
other: Section
subsection:
one: Subsection
other: Subsections
article:
back:
other: Back
tableOfContents:
other: Table of contents
relatedContent:
other: Related content
lastUpdatedOn:
other: Last updated on
readingTime:
one: "{{ .Count }} minute read"
other: "{{ .Count }} minute read"
notFound:
title:
other: Darn... This page does not exist anymore, or hell... maybe never did!
subtitle:
other: Have a look around my site while you are at it :)
widget:
archives:
title:
other: Archives
more:
other: More
tagCloud:
title:
other: Tags
categoriesCloud:
title:
other: Categories
search:
title:
other: Search
placeholder:
other: Type something...
resultTitle:
other: "#PAGES_COUNT pages (#TIME_SECONDS seconds)"
footer:
builtWith:
other: Built with {{ .Generator }}
designedBy:
other: Theme {{ .Theme }} designed by {{ .DesignedBy }}

View file

@ -1,73 +0,0 @@
toggleMenu:
other: Menü Kapcsolása
darkMode:
other: Sötét Mód
list:
page:
one: "{{ .Count }} oldal"
other: "{{ .Count }} oldalak"
section:
other: Szekció
subsection:
one: Alszekció
other: Alszekciók
article:
back:
other: Vissza
tableOfContents:
other: Tartalomjegyzék
relatedContent:
other: Kapcsolódó tartalom
lastUpdatedOn:
other: Utolsó frissítés időpontja
readingTime:
one: "{{ .Count }} percnyi olvasmány"
other: "{{ .Count }} percnyi olvasmány"
notFound:
title:
other: Ez az oldal nem létezik... vagy lehet hogy sose létezett
subtitle:
other: Nézz körül addig :)
widget:
archives:
title:
other: Archívum
more:
other: Több
tagCloud:
title:
other: Cimkék
categoriesCloud:
title:
other: Kategóriák
search:
title:
other: Keresés
placeholder:
other: Írj valamit...
resultTitle:
other: "#PAGES_COUNT oldal (#TIME_SECONDS másodperc alatt)"
footer:
builtWith:
other: "{{ .Generator }} használatával készült"
designedBy:
other: A {{ .Theme }} téma. {{ .DesignedBy }} tervezte

View file

@ -1,80 +0,0 @@
<div class="article-details">
{{ if .Params.categories }}
<header class="article-category">
{{ range (.GetTerms "categories") }}
<a href="{{ .RelPermalink }}" {{ with .Params.style }}style="background-color: {{ .background }}; color: {{ .color }};"{{ end }}>
{{ .LinkTitle }}
</a>
{{ end }}
</header>
{{ end }}
<div class="article-title-wrapper">
<h2 class="article-title">
<a href="{{ .RelPermalink }}">
{{- .Title -}}
</a>
</h2>
{{ with .Params.description }}
<h3 class="article-subtitle">
{{ . }}
</h3>
{{ end }}
</div>
{{ $showReadingTime := .Params.readingTime | default (.Site.Params.article.readingTime) }}
{{ $showDate := not .Date.IsZero }}
{{ $showFooter := or $showDate $showReadingTime }}
{{ if $showFooter }}
<footer class="article-time">
{{ if $showDate }}
<div>
{{ partial "helper/icon" "date" }}
<time class="article-time--published">
{{- .Date.Format (or .Site.Params.dateFormat.published "Jan 02, 2006") -}}
</time>
</div>
{{ end }}
{{ if $showReadingTime }}
<div>
{{ partial "helper/icon" "clock" }}
<time class="article-time--reading">
{{ T "article.readingTime" .ReadingTime }}
</time>
</div>
{{ end }}
<div>
{{ partial "helper/icon" "letter-case-lower" }}
<time class="article-time--reading">
{{ .WordCount }} words
</time>
</div>
{{ if .Params.WritingTime }}
<div>
{{ partial "helper/icon" "hourglass-empty" }}
<time class="article-time--published">
writing time {{ .Params.WritingTime }}
</time>
</div>
{{ end }}
</footer>
{{ end }}
{{ if .IsTranslated }}
<footer class="article-translations">
{{ partial "helper/icon" "language" }}
<div>
{{ range .Translations }}
<a href="{{ .Permalink }}" class="link">{{ .Language.LanguageName }}</a>
{{ end }}
</div>
</footer>
{{ end }}
</div>

View file

@ -1,30 +0,0 @@
<div class="article-list--compact links">
{{ range $i, $link := .Params.links }}
<article>
<a href="{{ $link.website }}" target="_blank" rel="noopener">
<div class="article-details">
<h2 class="article-title">
{{- $link.title -}}
</h2>
<footer class="article-time">
{{ with $link.description }}
{{ . }}
{{ else }}
{{ $link.website }}
{{ end }}
</footer>
</div>
{{ with $link.image }}
{{ $permalink := . }}
{{ with ($.Resources.GetMatch (printf "%s" (. | safeURL))) }}
{{ $permalink = .RelPermalink }}
{{ end }}
<div class="article-image">
<img src="{{ $permalink }}" loading="lazy">
</div>
{{ end }}
</a>
</article>
{{ end }}
</div>

View file

@ -1,110 +0,0 @@
<aside class="sidebar left-sidebar sticky {{ if .Site.Params.sidebar.compact }}compact{{ end }}">
<button class="hamburger hamburger--spin" type="button" id="toggle-menu" aria-label="{{ T `toggleMenu` }}">
<span class="hamburger-box">
<span class="hamburger-inner"></span>
</span>
</button>
<header>
{{ with .Site.Params.sidebar.avatar }}
{{ if (default true .enabled) }}
<figure class="site-avatar">
<a href="{{ .Site.BaseURL | relLangURL }}">
{{ if not .local }}
<img src="{{ .src }}" width="300" height="300" class="site-logo" loading="lazy" alt="Avatar">
{{ else }}
{{ $avatar := resources.Get (.src) }}
{{ if $avatar }}
{{ $avatarResized := $avatar.Resize "300x" }}
<img src="{{ $avatarResized.RelPermalink }}" width="{{ $avatarResized.Width }}"
height="{{ $avatarResized.Height }}" class="site-logo" loading="lazy" alt="Avatar">
{{ else }}
{{ errorf "Failed loading avatar from %q" . }}
{{ end }}
{{ end }}
</a>
{{ with $.Site.Params.sidebar.emoji }}
<span class="emoji">{{ . }}</span>
{{ end }}
</figure>
{{ end }}
{{ end }}
<div class="site-meta">
<h1 class="site-name"><a href="{{ .Site.BaseURL | relLangURL }}">{{ .Site.Title }}</a></h1>
<h2 class="site-description">{{ .Site.Params.sidebar.subtitle }}</h2>
<p class="site-description">Listening to</p>
<p class="site-description">
<a href="{{ .Site.Params.sidebar.musicUrl }}">
{{ .Site.Params.sidebar.musicTitle }}
</a>
</p>
</div>
</header>
{{- with .Site.Menus.social -}}
<ol class="menu-social">
{{ range . }}
<li>
<a
href='{{ .URL }}'
{{ if eq (default true .Params.newTab) true }}target="_blank"{{ end }}
{{ with .Name }}title="{{ . }}"{{ end }}
rel="me"
>
{{ $icon := default "link" .Params.Icon }}
{{ with $icon }}
{{ partial "helper/icon" . }}
{{ end }}
</a>
</li>
{{ end }}
</ol>
{{- end -}}
<ol class="menu" id="main-menu">
{{ $currentPage := . }}
{{ range .Site.Menus.main }}
{{ $active := or (eq $currentPage.Title .Name) (or ($currentPage.HasMenuCurrent "main" .) ($currentPage.IsMenuCurrent "main" .)) }}
<li {{ if $active }} class='current' {{ end }}>
<a href='{{ .URL }}' {{ if eq .Params.newTab true }}target="_blank"{{ end }}>
{{ $icon := default .Pre .Params.Icon }}
{{ if .Pre }}
{{ warnf "Menu item [%s] is using [pre] field to set icon, please use [params.icon] instead.\nMore information: https://stack.jimmycai.com/config/menu" .URL }}
{{ end }}
{{ with $icon }}
{{ partial "helper/icon" . }}
{{ end }}
<span>{{- .Name -}}</span>
</a>
</li>
{{ end }}
<li class="menu-bottom-section">
<ol class="menu">
{{- $currentLanguageCode := .Language.Lang -}}
{{ if ( compare.Gt .Site.Home.AllTranslations.Len 1 ) }}
{{ with .Site.Home.AllTranslations }}
<li id="i18n-switch">
{{ partial "helper/icon" "language" }}
<select name="language" title="language" onchange="window.location.href = this.selectedOptions[0].value">
{{ range . }}
<option value="{{ .Permalink }}" {{ if eq .Language.Lang $currentLanguageCode }}selected{{ end }}>{{ .Language.LanguageName }}</option>
{{ end }}
</select>
</li>
{{ end }}
{{ end }}
{{ if (default false .Site.Params.colorScheme.toggle) }}
<li id="dark-mode-toggle">
{{ partial "helper/icon" "toggle-left" }}
{{ partial "helper/icon" "toggle-right" }}
<span>{{ T "darkMode" }}</span>
</li>
{{ end }}
</ol>
</li>
</ol>
</aside>

1
static/forgejo.svg Normal file
View file

@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 24 24"><path fill="currentColor" d="M16.777 0a2.9 2.9 0 1 1-2.529 4.322H12.91a4.266 4.266 0 0 0-4.265 4.195v2.118a7.08 7.08 0 0 1 4.147-1.42l.118-.002h1.338a2.9 2.9 0 0 1 5.43 1.422a2.9 2.9 0 0 1-5.43 1.422H12.91a4.266 4.266 0 0 0-4.265 4.195v2.319A2.9 2.9 0 0 1 7.222 24A2.9 2.9 0 0 1 5.8 18.57V8.589a7.11 7.11 0 0 1 6.991-7.108l.118-.001h1.338A2.9 2.9 0 0 1 16.778 0M7.223 19.905a1.194 1.194 0 1 0 0 2.389a1.194 1.194 0 0 0 0-2.389m9.554-10.464a1.194 1.194 0 1 0 0 2.389a1.194 1.194 0 0 0 0-2.39m0-7.735a1.194 1.194 0 1 0 0 2.389a1.194 1.194 0 0 0 0-2.389"/></svg>

After

Width:  |  Height:  |  Size: 644 B

1
themes/archie Submodule

@ -0,0 +1 @@
Subproject commit d8819d5eee8b0817f41bda3a9dc2100cd6b2b0bd

1
themes/bear Submodule

@ -0,0 +1 @@
Subproject commit efc24bc5e95f0ccb88051e1a7d95e8a1404e953e

1
themes/typo Submodule

@ -0,0 +1 @@
Subproject commit 9890a0499034f31c7f84a85ed38d05ae14b42b7f