feat: pages
This commit is contained in:
+7
-2
@@ -17,12 +17,13 @@ export type Page = {
|
||||
status: PageStatus;
|
||||
meta: PageMeta;
|
||||
createdAt: Date;
|
||||
updatedAt: Date;
|
||||
updatedAt: Date | null;
|
||||
publishedAt: Date | null;
|
||||
createdBy: string;
|
||||
updatedBy: string | null;
|
||||
}
|
||||
|
||||
export const BLOCK_TYPES = ["PARAGRAPH", "HEADING", "QUOTE", "DIVIDER", "CALLOUT"] as const;
|
||||
export const BLOCK_TYPES = ["PARAGRAPH", "HEADING", "QUOTE", "DIVIDER", "CALLOUT", "IMAGE", "LIST", "TABLE", "LINK"] as const;
|
||||
export type BlockType = typeof BLOCK_TYPES[number];
|
||||
|
||||
export type BlockContent =
|
||||
@@ -31,6 +32,10 @@ export type BlockContent =
|
||||
| { type: "QUOTE"; text: string; author?: string }
|
||||
| { type: "DIVIDER" }
|
||||
| { type: "CALLOUT"; title: string; text: string }
|
||||
| { type: "IMAGE"; url: string; caption?: string }
|
||||
| { type: "LIST"; style: "BULLET" | "ORDERED"; items: string[] }
|
||||
| { type: "TABLE"; headers: string[]; rows: string[][] }
|
||||
| { type: "LINK"; label: string; href: string }
|
||||
|
||||
export type Block = {
|
||||
id: string;
|
||||
|
||||
Reference in New Issue
Block a user