Compare commits
4 Commits
e117d4cbcc
..
main
| Author | SHA1 | Date | |
|---|---|---|---|
| f26b11cd28 | |||
| c3b14da220 | |||
| 96011d6454 | |||
| cee55012a5 |
@@ -2,14 +2,15 @@
|
|||||||
<html lang="en">
|
<html lang="en">
|
||||||
|
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<meta property="description" content="Tech, Chunibyo & Other Delusions" />
|
||||||
<meta name="theme-color" content="#4D58FF">
|
<meta name="theme-color" content="#4D58FF">
|
||||||
<link rel="icon" href="{{ include-b64 'type='image/png' '/include/favicon.png' }}" />
|
<link rel="icon" href="{{ include 'image/png' '/include/favicon.png' }}" />
|
||||||
<title>About • pancakz.net</title>
|
<title>About • pancakz.net</title>
|
||||||
|
|
||||||
{{ include-tag 'style' '/include/fonts/poppins.css' }}
|
{{ include 'style' '/include/fonts/poppins.css' }}
|
||||||
{{ include-tag 'style' '/include/about/main.css' }}
|
{{ include 'style' '/include/about/main.css' }}
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
|
|||||||
@@ -0,0 +1,46 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="en">
|
||||||
|
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8" />
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<meta property="description" content="Tech, Chunibyo & Other Delusions" />
|
||||||
|
<meta name="theme-color" content="#4D58FF">
|
||||||
|
<link rel="icon" href="{{ include 'image/png' '/include/favicon.png' }}" />
|
||||||
|
<title>Blog • pancakz.net</title>
|
||||||
|
|
||||||
|
{{ include 'style' '/include/fonts/poppins.css' }}
|
||||||
|
{{ include 'style' '/include/blog/main.css' }}
|
||||||
|
{{ include 'script' '/include/blog/main.ts' }}
|
||||||
|
{{ include 'directory' '/include/blog/directory.json' }}
|
||||||
|
</head>
|
||||||
|
|
||||||
|
<body>
|
||||||
|
{{ include 'noscript' '/include/noscript.html' }}
|
||||||
|
<noscript>
|
||||||
|
<style>
|
||||||
|
div.layout-wrapper {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
</noscript>
|
||||||
|
|
||||||
|
<div class="layout-wrapper">
|
||||||
|
<div class="layout-navigation">
|
||||||
|
<div class="container-actions">
|
||||||
|
<a class="link" href="/">Homepage</a>
|
||||||
|
<a class="link" href="/blog.html">Articles</a>
|
||||||
|
</div>
|
||||||
|
<div class="container-tags"></div>
|
||||||
|
<div class="container-chapters"></div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="layout-content">
|
||||||
|
<div class="container-articles"></div>
|
||||||
|
<div class="container-content"></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
|
||||||
|
</html>
|
||||||
@@ -313,8 +313,8 @@ function renderFrame(t: number) {
|
|||||||
gl.uniform1f(U.bloom, /*--*/ 0.5)
|
gl.uniform1f(U.bloom, /*--*/ 0.5)
|
||||||
gl.uniform1f(U.vig, /*----*/ 1)
|
gl.uniform1f(U.vig, /*----*/ 1)
|
||||||
gl.uniform1f(U.noise, /*--*/ noise)
|
gl.uniform1f(U.noise, /*--*/ noise)
|
||||||
gl.uniform1f(U.flicker, /**/ 0.045)
|
gl.uniform1f(U.flicker, /**/ 0.0375)
|
||||||
gl.uniform1f(U.jitter, /*-*/ 0.00075)
|
gl.uniform1f(U.jitter, /*-*/ 0.0005)
|
||||||
gl.uniform1f(U.bright, /*-*/ 0.8)
|
gl.uniform1f(U.bright, /*-*/ 0.8)
|
||||||
gl.uniform1f(U.sat, /*----*/ 1.0)
|
gl.uniform1f(U.sat, /*----*/ 1.0)
|
||||||
gl.uniform1f(U.corner, /*-*/ 0.1)
|
gl.uniform1f(U.corner, /*-*/ 0.1)
|
||||||
@@ -325,7 +325,7 @@ function renderFrame(t: number) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async function nextSlide(init = false) {
|
async function nextSlide(init = false) {
|
||||||
const duration = 1000
|
const transitionTime = 1000
|
||||||
const nextIndex = slideCounter++ % slides.length
|
const nextIndex = slideCounter++ % slides.length
|
||||||
if (nextIndex === slideIndex) return
|
if (nextIndex === slideIndex) return
|
||||||
slideIndex = nextIndex
|
slideIndex = nextIndex
|
||||||
@@ -365,10 +365,10 @@ async function nextSlide(init = false) {
|
|||||||
gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, textureCanvasB)
|
gl.texImage2D(gl.TEXTURE_2D, 0, gl.RGBA, gl.RGBA, gl.UNSIGNED_BYTE, textureCanvasB)
|
||||||
|
|
||||||
if (init) {
|
if (init) {
|
||||||
tween(0, 0.02, duration, (t) => (noise = t))
|
tween(0, 0.025, transitionTime, (t) => (noise = t))
|
||||||
setInterval(nextSlide, duration + 8000)
|
setInterval(nextSlide, transitionTime + 8000)
|
||||||
}
|
}
|
||||||
await tween(0, 1, duration, (t) => (degauss = t))
|
await tween(0, 1, transitionTime, (t) => (degauss = t))
|
||||||
|
|
||||||
textureContextA.drawImage(next.image!, 0, 0, W, H)
|
textureContextA.drawImage(next.image!, 0, 0, W, H)
|
||||||
gl.activeTexture(gl.TEXTURE0)
|
gl.activeTexture(gl.TEXTURE0)
|
||||||
|
|||||||
@@ -6,17 +6,17 @@
|
|||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||||
<meta property="description" content="Tech, Chunibyo & Other Delusions" />
|
<meta property="description" content="Tech, Chunibyo & Other Delusions" />
|
||||||
<meta property="theme-color" content="#4D58FF" />
|
<meta property="theme-color" content="#4D58FF" />
|
||||||
<link rel="icon" href="{{ include-b64 'type='image/png' '/include/favicon.png' }}" />
|
<link rel="icon" href="{{ include 'image/png' '/include/favicon.png' }}" />
|
||||||
<title>pancakz.net</title>
|
<title>pancakz.net</title>
|
||||||
|
|
||||||
{{ include-tag 'style' '/include/fonts/poppins.css' }}
|
{{ include 'style' '/include/fonts/poppins.css' }}
|
||||||
{{ include-tag 'style' '/include/index/main.css' }}
|
{{ include 'style' '/include/index/main.css' }}
|
||||||
{{ include-tag 'script' '/include/index/main.ts' }}
|
{{ include 'script' '/include/index/main.ts' }}
|
||||||
{{ include-tag 'script' '/include/index/motd.ts' }}
|
{{ include 'script' '/include/index/motd.ts' }}
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
{{ include-tag 'noscript' '/include/noscript.html' }}
|
{{ include 'noscript' '/include/noscript.html' }}
|
||||||
<noscript>
|
<noscript>
|
||||||
<style>
|
<style>
|
||||||
div.layout-wrapper {
|
div.layout-wrapper {
|
||||||
@@ -30,7 +30,9 @@
|
|||||||
<div class="section">
|
<div class="section">
|
||||||
<span>LOCAL</span>
|
<span>LOCAL</span>
|
||||||
<a href="/about.html">About</a>
|
<a href="/about.html">About</a>
|
||||||
|
<a href="/blog.html">Blog</a>
|
||||||
<a href="https://code.pancakz.net/">Code</a>
|
<a href="https://code.pancakz.net/">Code</a>
|
||||||
|
<a href="https://files.pancakz.net/">Files</a>
|
||||||
</div>
|
</div>
|
||||||
<div class="section">
|
<div class="section">
|
||||||
<span>PROJECTS</span>
|
<span>PROJECTS</span>
|
||||||
@@ -42,21 +44,21 @@
|
|||||||
<canvas class="layout-section layout-display"></canvas>
|
<canvas class="layout-section layout-display"></canvas>
|
||||||
|
|
||||||
<div class="layout-section layout-footer">
|
<div class="layout-section layout-footer">
|
||||||
<img class="barcode" alt="QR Code" src="{{ include-b64 'type='image/png' '/include/index/qrcode.png' }}">
|
<img class="barcode" alt="QR Code" src="{{ include 'image/png' '/include/index/qrcode.png' }}">
|
||||||
<div role="main" class="tooltip">
|
<div role="main" class="tooltip">
|
||||||
<p class="header"></p>
|
<p class="header"></p>
|
||||||
<p class="description"> </p>
|
<p class="description"> </p>
|
||||||
<a class="redirect">See More >>></a>
|
<a class="redirect">See More >>></a>
|
||||||
</div>
|
</div>
|
||||||
<a href="/secret-sprites.html">
|
<a href="/secret-sprites.html">
|
||||||
<img height="80" width="210" alt="Site Logo" src="{{ include-b64 'type='image/png' '/include/index/logo.png' }}">
|
<img height="80" width="210" alt="Site Logo" src="{{ include 'image/png' '/include/index/logo.png' }}">
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div style="height: 32px;"></div>
|
<div style="height: 32px;"></div>
|
||||||
|
|
||||||
<p class="layout-message">© 2026 bakonpancakz. All Rights Reserved.</p>
|
|
||||||
<p class="layout-message" id="motd"></p>
|
<p class="layout-message" id="motd"></p>
|
||||||
|
<p class="layout-message">© 2026 bakonpancakz. All Rights Reserved.</p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
|
|||||||
@@ -3,15 +3,16 @@
|
|||||||
|
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
|
<meta name="robots" content="noindex">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<meta property="description" content="Tech, Chunibyo & Other Delusions" />
|
<meta property="description" content="Tech, Chunibyo & Other Delusions" />
|
||||||
<meta property="theme-color" content="#4D58FF" />
|
<meta property="theme-color" content="#4D58FF" />
|
||||||
<link rel="icon" href="{{ include-b64 'type='image/png' '/include/favicon.png' }}" />
|
<link rel="icon" href="{{ include 'image/png' '/include/favicon.png' }}" />
|
||||||
<title>Lost & Found • pancakz.net</title>
|
<title>Lost & Found • pancakz.net</title>
|
||||||
|
|
||||||
{{ include-tag 'style' '/include/fonts/terminus.css' }}
|
{{ include 'style' '/include/fonts/terminus.css' }}
|
||||||
{{ include-tag 'style' '/include/not-found/main.css' }}
|
{{ include 'style' '/include/not-found/main.css' }}
|
||||||
{{ include-tag 'script' '/include/not-found/main.ts' }}
|
{{ include 'script' '/include/not-found/main.ts' }}
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 15 KiB |
@@ -1,7 +1,13 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html>
|
<html>
|
||||||
|
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8" />
|
||||||
|
<meta name="robots" content="noindex">
|
||||||
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<noscript>
|
<noscript>
|
||||||
JavaScript is required to use this page.
|
JavaScript is required to use this page.
|
||||||
</noscript>
|
</noscript>
|
||||||
|
|||||||
@@ -2,15 +2,15 @@
|
|||||||
<html lang="en">
|
<html lang="en">
|
||||||
|
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<meta name="robots" content="noindex">
|
<meta name="robots" content="noindex">
|
||||||
<link rel="icon" href="{{ include-b64 'type='image/png' '/include/favicon.png' }}" />
|
<link rel="icon" href="{{ include 'image/png' '/include/favicon.png' }}" />
|
||||||
<title>Picross • pancakz.net</title>
|
<title>Picross • pancakz.net</title>
|
||||||
|
|
||||||
{{ include-tag 'style' '/include/fonts/poppins.css' }}
|
{{ include 'style' '/include/fonts/poppins.css' }}
|
||||||
{{ include-tag 'style' '/include/secret-picross/main.css' }}
|
{{ include 'style' '/include/secret-picross/main.css' }}
|
||||||
{{ include-tag 'script' '/include/secret-picross/main.ts' }}
|
{{ include 'script' '/include/secret-picross/main.ts' }}
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
|
|||||||
@@ -5,12 +5,12 @@
|
|||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<meta name="robots" content="noindex">
|
<meta name="robots" content="noindex">
|
||||||
<link rel="texture" href="{{ include-b64 'type='image/png' '/include/secret-sprites/sprite.gif' }}" />
|
<link rel="texture" href="{{ include 'image/png' '/include/secret-sprites/sprite.gif' }}" />
|
||||||
<link rel="icon" href="{{ include-b64 'type='image/png' '/include/favicon.png' }}" />
|
<link rel="icon" href="{{ include 'image/png' '/include/favicon.png' }}" />
|
||||||
<title>Sprites • pancakz.net</title>
|
<title>Sprites • pancakz.net</title>
|
||||||
|
|
||||||
{{ include-tag 'style' '/include/fonts/poppins.css' }}
|
{{ include 'style' '/include/fonts/poppins.css' }}
|
||||||
{{ include-tag 'style' '/include/secret-sprites/main.css' }}
|
{{ include 'style' '/include/secret-sprites/main.css' }}
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
@@ -42,7 +42,7 @@
|
|||||||
<canvas id="sprites"></canvas>
|
<canvas id="sprites"></canvas>
|
||||||
<audio id="active" hidden src="/secret-sprites/pop.webm"></audio>
|
<audio id="active" hidden src="/secret-sprites/pop.webm"></audio>
|
||||||
<audio id="bounce" hidden src="/secret-sprites/pop.webm"></audio>
|
<audio id="bounce" hidden src="/secret-sprites/pop.webm"></audio>
|
||||||
{{ include-tag 'script' '/include/secret-sprites/banner.ts' }}
|
{{ include 'script' '/include/secret-sprites/banner.ts' }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</body>
|
</body>
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
import { defineConfig } from 'vite'
|
import { defineConfig } from 'vite'
|
||||||
import { readFileSync } from 'fs'
|
import { readFileSync } from 'fs'
|
||||||
import { basename, extname, join } from 'path'
|
import { join } from 'path'
|
||||||
import { minify } from 'html-minifier-next'
|
import { minify } from 'html-minifier-next'
|
||||||
import { buildSync } from 'esbuild'
|
import { buildSync } from 'esbuild'
|
||||||
|
|
||||||
@@ -51,13 +51,9 @@ export default defineConfig({
|
|||||||
{
|
{
|
||||||
name: 'html-generator',
|
name: 'html-generator',
|
||||||
transformIndexHtml(html, _) {
|
transformIndexHtml(html, _) {
|
||||||
html = html.replaceAll(/{{ include-b64 '(.*?)' '(.*?)' }}/g, (_, mime: string, filepath: string) => {
|
html = html.replaceAll(/{{ include '(.*?)' '(.*?)' }}/g, (_, metadata: string, filepath: string) => {
|
||||||
const content = readFileSync(join(ROOT, filepath), 'base64')
|
// Transpile typescript and bundle dependencies
|
||||||
return `data:${mime};base64,${content}`
|
if (filepath.endsWith('.ts')) {
|
||||||
})
|
|
||||||
|
|
||||||
html = html.replaceAll(/{{ include-tag '(.*?)' '(.*?)' }}/g, (_, tag: string, filepath: string) => {
|
|
||||||
if (tag === 'script' && filepath.endsWith('.ts')) {
|
|
||||||
const result = buildSync({
|
const result = buildSync({
|
||||||
entryPoints: [join(ROOT, filepath)],
|
entryPoints: [join(ROOT, filepath)],
|
||||||
bundle: true,
|
bundle: true,
|
||||||
@@ -65,28 +61,24 @@ export default defineConfig({
|
|||||||
format: 'esm',
|
format: 'esm',
|
||||||
target: 'es2023',
|
target: 'es2023',
|
||||||
})
|
})
|
||||||
return `<script>window.addEventListener('load',()=>{${result.outputFiles[0].text}})</script>`
|
return `<script>window.addEventListener('load',()=>{${result.outputFiles[0].text};})</script>`
|
||||||
} else {
|
|
||||||
const content = readFileSync(join(ROOT, filepath), 'utf8')
|
|
||||||
return `<${tag}>\n${content}</${tag}>`
|
|
||||||
}
|
}
|
||||||
})
|
|
||||||
|
|
||||||
html = html.replaceAll(/{{ include-article '(.*?)' }}/g, (_, filepath: string) => {
|
// Embed as JSON string
|
||||||
const id = basename(filepath).slice(0, -extname(filepath).length)
|
if (filepath.endsWith('.json')) {
|
||||||
const content = readFileSync(join(ROOT, filepath), 'utf8').replaceAll(
|
const content = readFileSync(join(ROOT, filepath), 'utf8')
|
||||||
/<pre([^>]*)>\s*\n([\s\S]*?)<\/pre>/g,
|
return `<script type="application/json" id="${metadata}">\n${content}</script>`
|
||||||
(_, attributes, inner) => {
|
}
|
||||||
const lines = inner.split('\n')
|
|
||||||
const indent = lines[0].match(/^(\s*)/)?.[1].length ?? 0
|
// Embed as data URI
|
||||||
const trimmed = lines
|
if (['.png', '.jpg', '.jpeg', '.gif', '.webp', '.avif'].find((ext) => filepath.endsWith(ext))) {
|
||||||
.map((l: string) => l.slice(indent))
|
const content = readFileSync(join(ROOT, filepath), 'base64')
|
||||||
.join('\n')
|
return `data:${metadata};base64,${content}`
|
||||||
.trim()
|
}
|
||||||
return `<pre${attributes}>${trimmed}</pre>`
|
|
||||||
},
|
// Generic tag generator
|
||||||
)
|
const content = readFileSync(join(ROOT, filepath), 'utf8')
|
||||||
return `<template class="article" id="${id}">\n${content}</template>`
|
return `<${metadata}>\n${content}</${metadata}>`
|
||||||
})
|
})
|
||||||
|
|
||||||
return minify(html, {
|
return minify(html, {
|
||||||
|
|||||||
Reference in New Issue
Block a user