new post type
This commit is contained in:
20
enjoy/src/types/post.d.ts
vendored
20
enjoy/src/types/post.d.ts
vendored
@@ -1,9 +1,17 @@
|
||||
type PostType = {
|
||||
id: string;
|
||||
content?: string;
|
||||
metadata: {
|
||||
type: 'text' | 'prompt' | 'llm_configuration';
|
||||
content:
|
||||
| string
|
||||
| {
|
||||
[key: string]: any;
|
||||
};
|
||||
};
|
||||
user: UserType;
|
||||
targetType: string;
|
||||
target?: MediumType;
|
||||
createdAt: string;
|
||||
updatedAt: string;
|
||||
}
|
||||
targetType?: string;
|
||||
targetId?: string;
|
||||
target?: MediumType | StoryType;
|
||||
createdAt: Date;
|
||||
updatedAt: Date;
|
||||
};
|
||||
|
||||
24
enjoy/src/types/story.d.ts
vendored
Normal file
24
enjoy/src/types/story.d.ts
vendored
Normal file
@@ -0,0 +1,24 @@
|
||||
type StoryType = {
|
||||
id: string;
|
||||
url: string;
|
||||
title: string;
|
||||
content: string;
|
||||
metadata: {
|
||||
[key: string]: string;
|
||||
};
|
||||
vocabulary?: string[];
|
||||
extracted?: boolean;
|
||||
starred?: boolean;
|
||||
createdAt: Date;
|
||||
updatedAt: Date;
|
||||
};
|
||||
|
||||
type CreateStoryParamsType = {
|
||||
title: string;
|
||||
content: string;
|
||||
url: string;
|
||||
html: string;
|
||||
metadata: {
|
||||
[key: string]: string;
|
||||
};
|
||||
};
|
||||
Reference in New Issue
Block a user