New Code Editor and fun

This commit is contained in:
2023-12-03 19:31:29 +01:00
parent 2abe554059
commit fbd52f3edb
53 changed files with 1330 additions and 489 deletions

View File

@@ -20,18 +20,6 @@ export const help = defineCollection({
})
})
export const event = defineCollection({
type: "content",
schema: z.object({
name: z.string(),
start: z.date(),
end: z.date(),
mode: z.string().optional(),
leader: z.string().array().optional(),
eventId: z.number().gte(0)
})
})
export const modes = defineCollection({
type: "data",
schema: z.object({
@@ -59,11 +47,22 @@ export const rules = defineCollection({
})
})
export const announcements = defineCollection({
type: "content",
schema: ({image}) => z.object({
title: z.string(),
description: z.string(),
image: image().optional(),
tags: z.array(z.string()),
created: z.date()
})
})
export const collections = {
'pages': pages,
'help': help,
'event': event,
'modes': modes,
'rules': rules,
'downloads': downloads
'downloads': downloads,
'announcements': announcements
}