This commit is contained in:
728
2023-02-16 20:04:55 +08:00
parent 2a30d298c9
commit 744e47e30d
5 changed files with 151 additions and 7 deletions

View File

@@ -24,6 +24,7 @@ export const main = document.getElementById("main")! as HTMLDivElement
export const pas_a = document.getElementById("pas")! as HTMLAnchorElement
const t: typeof document.createElement = (s: string) => document.createElement(s)
const svg = <S extends keyof SVGElementTagNameMap>(s: S) => document.createElementNS("http://www.w3.org/2000/svg", s)
const template = {
pasact: {
@@ -60,6 +61,20 @@ const template = {
pro: t("section"), prorej: t("button"), proref: t("button"),
},
agd: {
tid: "agd" as const,
idnam: t("a"), id: t("code"), nam: t("span"),
adm: t("span"), utc: t("span"),
rej: t("span"), ref: t("span"),
rejc: t("span"), refc: t("span"), proc: t("span"),
fundbar: svg("rect"), expensebar: svg("rect"),
fund: svg("text"), fundpct: svg("text"), budget: svg("text"),
expense: svg("text"), expensepct: svg("text"),
detail: t("a"),
intro: t("p"), rec: t("p"),
pro: t("section"), prorej: t("button"), proref: t("button"),
},
pre: {
tid: "pre" as const,
idnam: t("a"), id: t("code"), nam: t("span"),