]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - shared/models/users/user-notification.model.ts
Add delete/manual approval instance followers in client
[github/Chocobozzz/PeerTube.git] / shared / models / users / user-notification.model.ts
CommitLineData
cef534ed
C
1export enum UserNotificationType {
2 NEW_VIDEO_FROM_SUBSCRIPTION = 1,
3 NEW_COMMENT_ON_MY_VIDEO = 2,
4 NEW_VIDEO_ABUSE_FOR_MODERATORS = 3,
2f1548fd 5
cef534ed 6 BLACKLIST_ON_MY_VIDEO = 4,
dc133480 7 UNBLACKLIST_ON_MY_VIDEO = 5,
2f1548fd 8
dc133480 9 MY_VIDEO_PUBLISHED = 6,
2f1548fd 10
dc133480 11 MY_VIDEO_IMPORT_SUCCESS = 7,
f7cc67b4 12 MY_VIDEO_IMPORT_ERROR = 8,
2f1548fd 13
f7cc67b4
C
14 NEW_USER_REGISTRATION = 9,
15 NEW_FOLLOW = 10,
7ccddd7b
JM
16 COMMENT_MENTION = 11,
17
18 VIDEO_AUTO_BLACKLIST_FOR_MODERATORS = 12
cef534ed
C
19}
20
dc133480 21export interface VideoInfo {
cef534ed
C
22 id: number
23 uuid: string
24 name: string
25}
26
457bb213
C
27export interface ActorInfo {
28 id: number
29 displayName: string
30 name: string
38967f7b 31 host: string
457bb213
C
32 avatar?: {
33 path: string
34 }
35}
36
cef534ed
C
37export interface UserNotification {
38 id: number
39 type: UserNotificationType
40 read: boolean
41
42 video?: VideoInfo & {
457bb213 43 channel: ActorInfo
cef534ed
C
44 }
45
dc133480
C
46 videoImport?: {
47 id: number
48 video?: VideoInfo
49 torrentName?: string
50 magnetUri?: string
51 targetUrl?: string
52 }
53
cef534ed
C
54 comment?: {
55 id: number
dc133480 56 threadId: number
457bb213 57 account: ActorInfo
dc133480 58 video: VideoInfo
cef534ed
C
59 }
60
61 videoAbuse?: {
62 id: number
63 video: VideoInfo
64 }
65
66 videoBlacklist?: {
67 id: number
68 video: VideoInfo
69 }
70
457bb213 71 account?: ActorInfo
f7cc67b4
C
72
73 actorFollow?: {
74 id: number
457bb213 75 follower: ActorInfo
f7cc67b4
C
76 following: {
77 type: 'account' | 'channel'
78 name: string
79 displayName: string
80 }
81 }
82
cef534ed
C
83 createdAt: string
84 updatedAt: string
85}