chore: handles live preview data (#3440)

This commit is contained in:
Jacob Fletcher
2023-10-05 10:14:57 -04:00
committed by GitHub
parent f989e02a85
commit 0ac36069bd
12 changed files with 588 additions and 20 deletions

View File

@@ -10,6 +10,7 @@ export interface Config {
collections: {
users: User
pages: Page
posts: Post
'payload-preferences': PayloadPreference
'payload-migrations': PayloadMigration
}
@@ -33,6 +34,20 @@ export interface Page {
title: string
description: string
slug: string
layout?: {
title: string
description: string
id?: string
blockName?: string
blockType: 'hero'
}[]
featuredPosts?: string[] | Post[]
updatedAt: string
createdAt: string
}
export interface Post {
id: string
title: string
updatedAt: string
createdAt: string
}
@@ -77,6 +92,7 @@ declare module 'payload' {
collections: {
users: User
pages: Page
posts: Post
'payload-preferences': PayloadPreference
'payload-migrations': PayloadMigration
}