Move rendering to playbill

This commit is contained in:
Endeavorance 2025-03-11 20:41:05 -04:00
parent 2e0d4b45ea
commit d550f057c5
5 changed files with 42 additions and 414 deletions

View file

@ -1,8 +1,8 @@
import path from "node:path";
import {
PlaybillSchema,
type Playbill,
type UnknownResource,
getEmptyPlaybill,
} from "@proscenium/playbill";
import { Glob } from "bun";
import z from "zod";
@ -115,7 +115,15 @@ export async function loadFromBinding(
}
// -- COMPILE PLAYBILL FROM RESOURCES --//
const playbill = basePlaybill ?? getEmptyPlaybill();
const playbill =
basePlaybill ??
PlaybillSchema.parse({
$define: "playbill",
id: "blank",
name: "Unnamed playbill",
description: "Unnamed Playbill",
version: "0.0.1",
});
playbill.id = binding.id;
playbill.name = binding.name;