Frontend uudelleenrakennettu: Astro-komponentit, Wasm pääsäikeessä, ei Workeria

Vanha frontend siirretty temp/. Uusi rakenne:
- StatusBar.astro, Terminal.astro, Editor.astro, Guide.astro
- global.css erillinen
- Wasm pääsäikeessä (ei Worker — yksinkertainen, debugattava)
- Tab-completion, dropdown, projektikortti, Monaco, GUIDE.md
- Ei tokenisointia eikä koodilaboratoriota

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Jaakko Vanhala
2026-04-09 20:17:39 +03:00
parent e3fdb91ac5
commit a8c4af0975
9617 changed files with 996171 additions and 5349 deletions

View File

@@ -0,0 +1,33 @@
import * as z from "zod/v4";
import { defineLiveCollection } from "../content/config.js";
function createErrorFunction(message) {
return () => {
const error = new Error(`The ${message}() function is not available in live config files.`);
const stackLines = error.stack?.split("\n");
if (stackLines && stackLines.length > 1) {
stackLines.splice(1, 1);
error.stack = stackLines.join("\n");
}
throw error;
};
}
const getCollection = createErrorFunction("getCollection");
const render = createErrorFunction("render");
const getEntry = createErrorFunction("getEntry");
const getEntries = createErrorFunction("getEntries");
const reference = createErrorFunction("reference");
const getLiveCollection = createErrorFunction("getLiveCollection");
const getLiveEntry = createErrorFunction("getLiveEntry");
const defineCollection = createErrorFunction("defineCollection");
export {
defineCollection,
defineLiveCollection,
getCollection,
getEntries,
getEntry,
getLiveCollection,
getLiveEntry,
reference,
render,
z
};