added a lot of boilerplate things while trying to get things to work

This commit is contained in:
Lio 2024-01-06 02:53:00 +01:00
parent d12269cd5f
commit e9389f3bcf
35 changed files with 3407 additions and 0 deletions

5
.vscode/settings.json vendored Normal file
View file

@ -0,0 +1,5 @@
{
"deno.enable": true,
"deno.lint": true,
"deno.unstable": true
}

59
_config.ts Normal file
View file

@ -0,0 +1,59 @@
import lume from "lume/mod.ts";
import jsx from "lume/plugins/jsx.ts";
import attributes from "lume/plugins/attributes.ts";
import code_highlight from "lume/plugins/code_highlight.ts";
// import favicon from "lume/plugins/favicon.ts";
// import liquid from "lume/plugins/liquid.ts";
import pug from "lume/plugins/pug.ts";
import feed from "lume/plugins/feed.ts";
import filter_pages from "lume/plugins/filter_pages.ts";
import mdx from "lume/plugins/mdx.ts";
import metas from "lume/plugins/metas.ts";
import nav from "lume/plugins/nav.ts";
import pagefind from "lume/plugins/pagefind.ts";
import reading_info from "lume/plugins/reading_info.ts";
import source_maps from "lume/plugins/source_maps.ts";
import tailwindcss from "lume/plugins/tailwindcss.ts";
import postcss from "lume/plugins/postcss.ts";
import terser from "lume/plugins/terser.ts";
const site = lume({
src: "_src",
});
site.ignore(
"readme.md",
)
site.data("greeting", () => {
const hellos = ["Ahoy!", "Ahoy there!", "Hey there!", "Howdy howdy!", "Howdy, friend!", "Howdy!", "Hey!", "Hey there!", "Hi!", "Hello!", "Hello there!", "Hi there!"];
return hellos[Math.floor(Math.random() * hellos.length)];
})
site.data("getYear", () => {
return new Date().getFullYear();
});
site.use(pug());
site.use(jsx());
site.use(attributes());
site.use(code_highlight());
// site.use(favicon());
site.use(feed());
site.use(filter_pages({ fn: (page) => page.data.ignored !== true }));
site.use(mdx());
site.use(metas({
extensions: [".md", ".mdx"],
}));
site.use(nav());
site.use(pagefind());
site.use(reading_info());
site.use(source_maps());
site.use(tailwindcss());
site.use(postcss());
site.use(terser());
site.copy("files");
export default site;

4
_data.yml Normal file
View file

@ -0,0 +1,4 @@
metas:
site: Lio's Website
twitter: "@fangmrks"
generator: true

3
_data/metas.yml Normal file
View file

@ -0,0 +1,3 @@
site: Lio's Website
twitter: "@fangmrks"
generator: true

10
_data/socials.yml Normal file
View file

@ -0,0 +1,10 @@
- name: Twitter
url: https://twitter.com/fangmrks
- name: Bluesky
url: https://pogcha.mp
- name: Mastodon
url: https://lio.to/mastodon
- name: Forge
url: https://git.lio.cat/l
- name: Github
url: https://github.com/fangmarks

21
_site/feed.rss Normal file
View file

@ -0,0 +1,21 @@
<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" version="2.0">
<channel>
<title>My RSS Feed</title>
<link>http://localhost:3000/</link>
<atom:link href="http://localhost:3000/feed.rss" rel="self" type="application/rss+xml"/>
<description></description>
<lastBuildDate>Sat, 06 Jan 2024 01:47:06 GMT</lastBuildDate>
<language>en</language>
<generator>Lume v2.0.2</generator>
<item>
<link>http://localhost:3000/</link>
<guid isPermaLink="false">http://localhost:3000/</guid>
<content:encoded>
<![CDATA[<h1>Howdy!</h1>
]]>
</content:encoded>
<pubDate>Fri, 05 Jan 2024 21:19:45 GMT</pubDate>
</item>
</channel>
</rss>

BIN
_site/files/TwitterAvi.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

67
_site/index.html Normal file
View file

@ -0,0 +1,67 @@
<!DOCTYPE html>
<html lang="en"><head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Lio</title>
<meta name="description" content="Lio's personal site">
<link rel="stylesheet" href="/styles.css">
<link rel="alternate" href="/feed.xml" type="application/atom+xml" title="Lio">
<link rel="alternate" href="/feed.json" type="application/json" title="Lio">
<style>
body {
font-family: 'Inter', sans-serif;
font-size: 1.2rem;
line-height: 1.5;
color: #fff;
background-color: #222;
margin: 0;
padding: 0;
}
</style>
<meta property="og:type" content="website">
<meta property="og:url" content="http://localhost:3000/">
<meta name="twitter:card" content="summary">
</head>
<body>
<a href="https://twitter.com/fangmrks" target="_blank" class="social-icon">
Twitter
</a>
<a href="https://pogcha.mp" target="_blank" class="social-icon">
Bluesky
</a>
<a href="https://lio.to/mastodon" target="_blank" class="social-icon">
Mastodon
</a>
<a href="https://git.lio.cat/l" target="_blank" class="social-icon">
Forge
</a>
<a href="https://github.com/fangmarks" target="_blank" class="social-icon">
Github
</a>
<main class="">
<h1>Howdy!</h1>
</main>
<footer>
© 2024
Lio
</footer>
<!-- Current page: / -->
</body></html>

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View file

@ -0,0 +1 @@
{"version":"1.0.4","languages":{"en":{"hash":"en_1eb54973a8","wasm":"en","page_count":1}}}

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1,223 @@
:root {
--pagefind-ui-scale: 0.8;
--pagefind-ui-primary: #034AD8;
--pagefind-ui-fade: #707070;
--pagefind-ui-text: #393939;
--pagefind-ui-background: #ffffff;
--pagefind-ui-border: #eeeeee;
--pagefind-ui-tag: #eeeeee;
--pagefind-ui-border-width: 2px;
--pagefind-ui-border-radius: 8px;
--pagefind-ui-image-border-radius: 8px;
--pagefind-ui-image-box-ratio: 3 / 2;
--pagefind-ui-font: system, -apple-system, ".SFNSText-Regular",
"San Francisco", "Roboto", "Segoe UI", "Helvetica Neue",
"Lucida Grande", sans-serif;
}
[data-pfmod-hidden] {
display: none !important;
}
[data-pfmod-suppressed] {
opacity: 0 !important;
pointer-events: none !important;
}
[data-pfmod-sr-hidden] {
-webkit-clip: rect(0 0 0 0) !important;
clip: rect(0 0 0 0) !important;
-webkit-clip-path: inset(100%) !important;
clip-path: inset(100%) !important;
height: 1px !important;
overflow: hidden !important;
overflow: clip !important;
position: absolute !important;
white-space: nowrap !important;
width: 1px !important;
}
[data-pfmod-loading] {
color: var(--pagefind-ui-text);
background-color: var(--pagefind-ui-text);
border-radius: var(--pagefind-ui-border-radius);
opacity: 0.1;
pointer-events: none;
}
/* Input */
.pagefind-modular-input-wrapper {
position: relative;
}
.pagefind-modular-input-wrapper::before {
background-color: var(--pagefind-ui-text);
width: calc(18px * var(--pagefind-ui-scale));
height: calc(18px * var(--pagefind-ui-scale));
top: calc(23px * var(--pagefind-ui-scale));
left: calc(20px * var(--pagefind-ui-scale));
content: "";
position: absolute;
display: block;
opacity: 0.7;
-webkit-mask-image: url("data:image/svg+xml,%3Csvg width='18' height='18' viewBox='0 0 18 18' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12.7549 11.255H11.9649L11.6849 10.985C12.6649 9.845 13.2549 8.365 13.2549 6.755C13.2549 3.165 10.3449 0.255005 6.75488 0.255005C3.16488 0.255005 0.254883 3.165 0.254883 6.755C0.254883 10.345 3.16488 13.255 6.75488 13.255C8.36488 13.255 9.84488 12.665 10.9849 11.685L11.2549 11.965V12.755L16.2549 17.745L17.7449 16.255L12.7549 11.255ZM6.75488 11.255C4.26488 11.255 2.25488 9.245 2.25488 6.755C2.25488 4.26501 4.26488 2.255 6.75488 2.255C9.24488 2.255 11.2549 4.26501 11.2549 6.755C11.2549 9.245 9.24488 11.255 6.75488 11.255Z' fill='%23000000'/%3E%3C/svg%3E%0A");
mask-image: url("data:image/svg+xml,%3Csvg width='18' height='18' viewBox='0 0 18 18' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M12.7549 11.255H11.9649L11.6849 10.985C12.6649 9.845 13.2549 8.365 13.2549 6.755C13.2549 3.165 10.3449 0.255005 6.75488 0.255005C3.16488 0.255005 0.254883 3.165 0.254883 6.755C0.254883 10.345 3.16488 13.255 6.75488 13.255C8.36488 13.255 9.84488 12.665 10.9849 11.685L11.2549 11.965V12.755L16.2549 17.745L17.7449 16.255L12.7549 11.255ZM6.75488 11.255C4.26488 11.255 2.25488 9.245 2.25488 6.755C2.25488 4.26501 4.26488 2.255 6.75488 2.255C9.24488 2.255 11.2549 4.26501 11.2549 6.755C11.2549 9.245 9.24488 11.255 6.75488 11.255Z' fill='%23000000'/%3E%3C/svg%3E%0A");
-webkit-mask-size: 100%;
mask-size: 100%;
z-index: 9;
pointer-events: none;
}
.pagefind-modular-input {
height: calc(64px * var(--pagefind-ui-scale));
padding: 0 calc(70px * var(--pagefind-ui-scale)) 0 calc(54px * var(--pagefind-ui-scale));
background-color: var(--pagefind-ui-background);
border: var(--pagefind-ui-border-width) solid var(--pagefind-ui-border);
border-radius: var(--pagefind-ui-border-radius);
font-size: calc(21px * var(--pagefind-ui-scale));
position: relative;
-moz-appearance: none;
appearance: none;
-webkit-appearance: none;
display: flex;
width: 100%;
box-sizing: border-box;
font-weight: 700;
}
.pagefind-modular-input::-moz-placeholder {
opacity: 0.2;
}
.pagefind-modular-input::placeholder {
opacity: 0.2;
}
.pagefind-modular-input-clear {
position: absolute;
top: calc(2px * var(--pagefind-ui-scale));
right: calc(2px * var(--pagefind-ui-scale));
height: calc(60px * var(--pagefind-ui-scale));
border-radius: var(--pagefind-ui-border-radius);
padding: 0 calc(15px * var(--pagefind-ui-scale)) 0 calc(2px * var(--pagefind-ui-scale));
color: var(--pagefind-ui-text);
font-size: calc(14px * var(--pagefind-ui-scale));
cursor: pointer;
background-color: var(--pagefind-ui-background);
border: none;
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
}
/* ResultList */
.pagefind-modular-list-result {
list-style-type: none;
display: flex;
align-items: flex-start;
gap: min(calc(40px * var(--pagefind-ui-scale)), 3%);
padding: calc(30px * var(--pagefind-ui-scale)) 0 calc(40px * var(--pagefind-ui-scale));
border-top: solid var(--pagefind-ui-border-width) var(--pagefind-ui-border);
}
.pagefind-modular-list-result:last-of-type {
border-bottom: solid var(--pagefind-ui-border-width) var(--pagefind-ui-border);
}
.pagefind-modular-list-thumb {
width: min(30%,
calc((30% - (100px * var(--pagefind-ui-scale))) * 100000));
max-width: calc(120px * var(--pagefind-ui-scale));
margin-top: calc(10px * var(--pagefind-ui-scale));
aspect-ratio: var(--pagefind-ui-image-box-ratio);
position: relative;
}
.pagefind-modular-list-image {
display: block;
position: absolute;
left: 50%;
transform: translateX(-50%);
font-size: 0;
width: auto;
height: auto;
max-width: 100%;
max-height: 100%;
border-radius: var(--pagefind-ui-image-border-radius);
}
.pagefind-modular-list-inner {
flex: 1;
display: flex;
flex-direction: column;
align-items: flex-start;
margin-top: calc(10px * var(--pagefind-ui-scale));
}
.pagefind-modular-list-title {
display: inline-block;
font-weight: 700;
font-size: calc(21px * var(--pagefind-ui-scale));
margin-top: 0;
margin-bottom: 0;
}
.pagefind-modular-list-link {
color: var(--pagefind-ui-text);
text-decoration: none;
}
.pagefind-modular-list-link:hover {
text-decoration: underline;
}
.pagefind-modular-list-excerpt {
display: inline-block;
font-weight: 400;
font-size: calc(16px * var(--pagefind-ui-scale));
margin-top: calc(4px * var(--pagefind-ui-scale));
margin-bottom: 0;
min-width: calc(250px * var(--pagefind-ui-scale));
}
/* FilterPills */
.pagefind-modular-filter-pills-wrapper {
overflow-x: scroll;
padding: 15px 0;
}
.pagefind-modular-filter-pills {
display: flex;
gap: 6px;
}
.pagefind-modular-filter-pill {
display: flex;
justify-content: center;
align-items: center;
border: none;
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
padding: 0 calc(24px * var(--pagefind-ui-scale));
background-color: var(--pagefind-ui-background);
color: var(--pagefind-ui-fade);
border: var(--pagefind-ui-border-width) solid var(--pagefind-ui-border);
border-radius: calc(25px * var(--pagefind-ui-scale));
font-size: calc(18px * var(--pagefind-ui-scale));
height: calc(50px * var(--pagefind-ui-scale));
cursor: pointer;
white-space: nowrap;
}
.pagefind-modular-filter-pill:hover {
border-color: var(--pagefind-ui-primary);
}
.pagefind-modular-filter-pill[aria-pressed="true"] {
border-color: var(--pagefind-ui-primary);
color: var(--pagefind-ui-primary);
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

File diff suppressed because one or more lines are too long

Binary file not shown.

Binary file not shown.

View file

@ -0,0 +1,49 @@
---
title: Lio
description: "Lio's personal site"
---
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>{{ title }}</title>
<meta name="description" content="{{ description }}">
<link rel="stylesheet" href="/styles.css">
<link rel="alternate" href="/feed.xml" type="application/atom+xml" title="{{ title }}">
<link rel="alternate" href="/feed.json" type="application/json" title="{{ title }}">
<style>
body {
font-family: 'Inter', sans-serif;
font-size: 1.2rem;
line-height: 1.5;
color: #fff;
background-color: #222;
margin: 0;
padding: 0;
}
</style>
</head>
<body>
{{ if includeSocials }}
{{ include "partials/socials.vento" }}
{{ /if}}
<main class="">
{{ content }}
</main>
<footer>
{{if getYear() === 2024}}
&copy; {{ getYear() }}
Lio
{{else}}
&copy; {{ getYear() }} - 2024
Lio
{{/if}}
</footer>
<!-- Current page: {{ url }} -->
</body>
</html>

View file

@ -0,0 +1,24 @@
---
socials:
- name: Twitter
url: https://twitter.com/fangmrks
- name: Bluesky
url: https://pogcha.mp
- name: Mastodon
url: https://lio.to/mastodon
- name: Forge
url: https://git.lio.cat/l
- name: Github
url: https://github.com/fangmarks
---
{{for social of socials}}
<a href="{{social.url}}" target="_blank" class="social-icon">
{{social.name}}
</a>
{{/for}}
{{# {{> console.log(socials) }} #}}

BIN
_src/files/TwitterAvi.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

7
_src/index.md Normal file
View file

@ -0,0 +1,7 @@
---
layout: layouts/landing.vento
includeSocials: true
templateEngine: [vento, md]
---
# {{greeting()}}

18
deno.json Normal file
View file

@ -0,0 +1,18 @@
{
"compilerOptions": {
"jsx": "react-jsx",
"jsxImportSource": "npm:react",
"types": [
"https://unpkg.com/@types/react@18.2.37/index.d.ts",
"lume/types.ts"
]
},
"tasks": {
"lume": "echo \"import 'lume/cli.ts'\" | deno run --unstable -A --allow-read -",
"build": "deno task lume",
"serve": "deno task lume -s"
},
"imports": {
"lume/": "https://deno.land/x/lume@v2.0.2/"
}
}

2901
deno.lock generated Normal file

File diff suppressed because it is too large Load diff