mirror of
https://github.com/RGBCube/Site
synced 2025-07-30 20:47:46 +00:00
blog: ???
This commit is contained in:
parent
ab09647f76
commit
6564bd61c7
2 changed files with 78 additions and 5 deletions
21
deno.lock
generated
21
deno.lock
generated
|
@ -19,6 +19,7 @@
|
|||
"jsr:@std/html@1.0.3": "1.0.3",
|
||||
"jsr:@std/html@^1.0.4": "1.0.4",
|
||||
"jsr:@std/http@1.0.16": "1.0.16",
|
||||
"jsr:@std/json@^1.0.2": "1.0.2",
|
||||
"jsr:@std/jsonc@1.0.2": "1.0.2",
|
||||
"jsr:@std/media-types@1.1.0": "1.1.0",
|
||||
"jsr:@std/media-types@^1.1.0": "1.1.0",
|
||||
|
@ -34,6 +35,7 @@
|
|||
"jsr:@std/yaml@^1.0.5": "1.0.6",
|
||||
"npm:@tailwindcss/node@4.1.7": "4.1.7",
|
||||
"npm:@tailwindcss/oxide@4.1.7": "4.1.7",
|
||||
"npm:@types/estree@1.0.6": "1.0.6",
|
||||
"npm:estree-walker@3.0.3": "3.0.3",
|
||||
"npm:highlight.js@11.11.1": "11.11.1",
|
||||
"npm:lightningcss-wasm@1.30.1": "1.30.1",
|
||||
|
@ -109,8 +111,14 @@
|
|||
"jsr:@std/streams"
|
||||
]
|
||||
},
|
||||
"@std/json@1.0.2": {
|
||||
"integrity": "d9e5497801c15fb679f55a2c01c7794ad7a5dfda4dd1bebab5e409cb5e0d34d4"
|
||||
},
|
||||
"@std/jsonc@1.0.2": {
|
||||
"integrity": "909605dae3af22bd75b1cbda8d64a32cf1fd2cf6efa3f9e224aba6d22c0f44c7"
|
||||
"integrity": "909605dae3af22bd75b1cbda8d64a32cf1fd2cf6efa3f9e224aba6d22c0f44c7",
|
||||
"dependencies": [
|
||||
"jsr:@std/json"
|
||||
]
|
||||
},
|
||||
"@std/media-types@1.1.0": {
|
||||
"integrity": "c9d093f0c05c3512932b330e3cc1fe1d627b301db33a4c2c2185c02471d6eaa4"
|
||||
|
@ -283,6 +291,9 @@
|
|||
"tslib"
|
||||
]
|
||||
},
|
||||
"@types/estree@1.0.6": {
|
||||
"integrity": "sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw=="
|
||||
},
|
||||
"@types/estree@1.0.7": {
|
||||
"integrity": "sha512-w28IoSUCJpidD/TGviZwwMJckNESJZXFu7NBZ5YJ4mEUnNraUn9Pm8HSZm/jDF1pDWYKspWE7oVphigUPRakIQ=="
|
||||
},
|
||||
|
@ -308,7 +319,7 @@
|
|||
"estree-walker@3.0.3": {
|
||||
"integrity": "sha512-7RUKfXgSMMkzt6ZuXmqapOurLGPPfgj6l9uRZ7lRGolvk0y2yocc35LdcxKC5PQZdn2DMqioAQ2NoWcrTKmm6g==",
|
||||
"dependencies": [
|
||||
"@types/estree"
|
||||
"@types/estree@1.0.7"
|
||||
]
|
||||
},
|
||||
"graceful-fs@4.2.11": {
|
||||
|
@ -462,6 +473,7 @@
|
|||
}
|
||||
},
|
||||
"remote": {
|
||||
"https://cdn.jsdelivr.net/gh/lumeland/bar@0.1.4/types.ts": "89d131290feb5c6781bf752525bc35d21a49612f9b3cd6b5e3a44dca15a996d6",
|
||||
"https://deno.land/std@0.170.0/_util/asserts.ts": "d0844e9b62510f89ce1f9878b046f6a57bf88f208a10304aab50efcb48365272",
|
||||
"https://deno.land/std@0.170.0/_util/os.ts": "8a33345f74990e627b9dfe2de9b040004b08ea5146c7c9e8fe9a29070d193934",
|
||||
"https://deno.land/std@0.170.0/encoding/base64.ts": "8605e018e49211efc767686f6f687827d7f5fd5217163e981d8d693105640d7a",
|
||||
|
@ -667,6 +679,7 @@
|
|||
"https://deno.land/x/lume@v3.0.2/deps/vento.ts": "56cfaa39bc2bc8d67f4460a46e29f9174df223dffcb815bda0d8a8cd1cd19f75",
|
||||
"https://deno.land/x/lume@v3.0.2/deps/xml.ts": "a2171f6ed75576354faa685ebd62b63cf1d4ee518477f295604526416dd27e2f",
|
||||
"https://deno.land/x/lume@v3.0.2/deps/yaml.ts": "d0f41ff80ce1eee045a87bf055c199b5c6f316571dcad0fff99fba17e34990a2",
|
||||
"https://deno.land/x/lume@v3.0.2/lint.ts": "4b369361e0cff20a8dfd9e3ff8cb642aa805e7532825ea3a5378eb1f80901fc6",
|
||||
"https://deno.land/x/lume@v3.0.2/middlewares/logger.ts": "c96f1a9f9d5757555b6f141865ce8551ac176f90c8ee3e9ad797b2b400a9a567",
|
||||
"https://deno.land/x/lume@v3.0.2/middlewares/no_cache.ts": "0119e3ae3a596ab12c42df693b93e5b03dd9608e289d862242751a9739438f35",
|
||||
"https://deno.land/x/lume@v3.0.2/middlewares/no_cors.ts": "4d24619b5373c98bcc3baf404db47ba088c87ac8538ea1784e58d197b81d4d02",
|
||||
|
@ -697,6 +710,10 @@
|
|||
"https://deno.land/x/lume@v3.0.2/plugins/url.ts": "15f2e80b6fcbf86f8795a3676b8d533bab003ac016ff127e58165a6ac3bffc1a",
|
||||
"https://deno.land/x/lume@v3.0.2/plugins/vento.ts": "908ffbf31864507afa72c506584f2d28c2449b57a339ddfe8a7220eecf082766",
|
||||
"https://deno.land/x/lume@v3.0.2/plugins/yaml.ts": "d0ebf37c38648172c6b95c502753a3edf60278ab4f6a063f3ca00f31e0dd90cc",
|
||||
"https://deno.land/x/lume@v3.0.2/types.ts": "5f580502f366b9b25106eb72d49b30d9af7715c8a304fe6e21f382d3c2a4cc38",
|
||||
"https://deno.land/x/ssx@v0.1.10/css.ts": "39972fa9e375465b82e4fbf735dcc727acc89fdd836f93a395cfb3ccab54e7f0",
|
||||
"https://deno.land/x/ssx@v0.1.10/html.ts": "5ad7bfd7a6a5b676b2686d406c105bbb02bea537183d95e0c04e76853a9ee155",
|
||||
"https://deno.land/x/ssx@v0.1.10/jsx-runtime.ts": "f3d37c172698f0b0d7510c2023119264057cbc64a5602d4ca9091e80199a2abe",
|
||||
"https://deno.land/x/vento@v1.13.0/bare.ts": "b6cdcc245d4626832ab3a7fb4f2885541e997d2806334d8048d39401fa63d50e",
|
||||
"https://deno.land/x/vento@v1.13.0/deps.ts": "155958dfada8d8cb3c8a001413c759928647b23e0e9db25195614549b58d085f",
|
||||
"https://deno.land/x/vento@v1.13.0/mod.ts": "53262793b5e0176acdec84aa9c34ed3ecb0c45cc9d396bf34a06ed4ad3d9930a",
|
||||
|
|
|
@ -9,8 +9,8 @@ title: about:blog
|
|||
Blog Articles
|
||||
|
||||
<span class="whitespace-nowrap overflow-hidden text-sm font-[ecrou]">
|
||||
<a href="/blog.rss">rss</a>
|
||||
<a href="/blog.json">json</a>
|
||||
<a id="matrix" href="/blog.rss">rss</a>
|
||||
<a id="matrix" href="/blog.json">json</a>
|
||||
</span>
|
||||
</h1>
|
||||
|
||||
|
@ -20,7 +20,7 @@ Blog Articles
|
|||
<ul>
|
||||
{{ for article of search.pages("type=article", "order=asc date=desc")}}
|
||||
<li class="flex">
|
||||
<a class="text-right font-mono" style="margin-right:calc(var(--spacing)*2)" href="{{ article.url }}">
|
||||
<a id="matrix" class="text-right font-mono" style="margin-right:calc(var(--spacing)*2)" href="{{ article.url }}">
|
||||
{{ article.date.toISOString().slice(2, 10).replaceAll("-", " ") }}
|
||||
</a>
|
||||
|
||||
|
@ -28,3 +28,59 @@ Blog Articles
|
|||
</li>
|
||||
{{ /for }}
|
||||
</ul>
|
||||
|
||||
<script>
|
||||
let typed = "";
|
||||
const target = "m";
|
||||
|
||||
document.addEventListener("keydown", (event) => {
|
||||
typed += event.key.toLowerCase();
|
||||
|
||||
if (typed.length > target.length) typed = typed.slice(-target.length);
|
||||
|
||||
if (typed === target) {
|
||||
toggleMatrix();
|
||||
typed = "";
|
||||
}
|
||||
});
|
||||
|
||||
let matrix = {};
|
||||
|
||||
const toggleMatrix = () => {
|
||||
if (Object.keys(matrix).length > 0) {
|
||||
Object.values(matrix).forEach(({ interval, element, original }) => {
|
||||
clearInterval(interval);
|
||||
|
||||
element.innerHTML = original;
|
||||
|
||||
element.style.color = "";
|
||||
element.style.textShadow = "";
|
||||
element.style.filter = "";
|
||||
});
|
||||
|
||||
matrix = {};
|
||||
return;
|
||||
}
|
||||
|
||||
document.querySelectorAll("#matrix").forEach((element, index) => {
|
||||
const original = element.textContent;
|
||||
|
||||
const randomize = () => {
|
||||
const dark = window.matchMedia("(prefers-color-scheme: dark)").matches;
|
||||
|
||||
const color = dark ? "#00ff00" : "#00cc00";
|
||||
const glowColor = dark ? "#00ff00" : "#00ff00";
|
||||
|
||||
element.style.color = color;
|
||||
element.style.filter = `drop-shadow(0 0 5px ${glowColor})`;
|
||||
|
||||
element.innerHTML = original.replace(/\d/g, () => `<span${Math.random() > 0.5 ? "" : ` style="text-shadow: 0 0 2px ${glowColor}"`}>${Math.floor(Math.random() * 10)}</span>`);
|
||||
};
|
||||
|
||||
randomize();
|
||||
const interval = setInterval(randomize, 100);
|
||||
|
||||
matrix[index] = { interval, element, original };
|
||||
});
|
||||
};
|
||||
</script>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue