feat: refactor chat sharing implementation

This commit is contained in:
shadcn 2023-06-16 16:18:52 +04:00
parent 8cc3fea048
commit 137bdadaf9
12 changed files with 262 additions and 124 deletions

View file

@ -7,15 +7,7 @@ export interface Chat extends Record<string, any> {
userId: string
path: string
messages: Message[]
}
export interface Share {
id: string
title: string
createdAt: number
userId: string
path: string
chat: Chat
sharePath?: string
}
export type ServerActionResult<Result> = Promise<Result | Error>