diff options
Diffstat (limited to 'server/types')
-rw-r--r-- | server/types/models/video/video-channels.ts | 5 | ||||
-rw-r--r-- | server/types/models/video/video.ts | 23 |
2 files changed, 19 insertions, 9 deletions
diff --git a/server/types/models/video/video-channels.ts b/server/types/models/video/video-channels.ts index 2e05d8753..77790daa4 100644 --- a/server/types/models/video/video-channels.ts +++ b/server/types/models/video/video-channels.ts | |||
@@ -17,6 +17,7 @@ import { | |||
17 | MActorDefault, | 17 | MActorDefault, |
18 | MActorDefaultLight, | 18 | MActorDefaultLight, |
19 | MActorFormattable, | 19 | MActorFormattable, |
20 | MActorHost, | ||
20 | MActorLight, | 21 | MActorLight, |
21 | MActorSummary, | 22 | MActorSummary, |
22 | MActorSummaryFormattable, MActorUrl | 23 | MActorSummaryFormattable, MActorUrl |
@@ -71,6 +72,10 @@ export type MChannelAccountLight = | |||
71 | Use<'Actor', MActorDefaultLight> & | 72 | Use<'Actor', MActorDefaultLight> & |
72 | Use<'Account', MAccountLight> | 73 | Use<'Account', MAccountLight> |
73 | 74 | ||
75 | export type MChannelHost = | ||
76 | MChannelId & | ||
77 | Use<'Actor', MActorHost> | ||
78 | |||
74 | // ############################################################################ | 79 | // ############################################################################ |
75 | 80 | ||
76 | // Account associations | 81 | // Account associations |
diff --git a/server/types/models/video/video.ts b/server/types/models/video/video.ts index ae23cc30f..92dcbaf59 100644 --- a/server/types/models/video/video.ts +++ b/server/types/models/video/video.ts | |||
@@ -1,27 +1,28 @@ | |||
1 | import { VideoModel } from '../../../models/video/video' | ||
2 | import { PickWith, PickWithOpt } from '@shared/core-utils' | 1 | import { PickWith, PickWithOpt } from '@shared/core-utils' |
2 | import { VideoModel } from '../../../models/video/video' | ||
3 | import { MUserVideoHistoryTime } from '../user/user-video-history' | ||
4 | import { MScheduleVideoUpdate } from './schedule-video-update' | ||
5 | import { MTag } from './tag' | ||
6 | import { MThumbnail } from './thumbnail' | ||
7 | import { MVideoBlacklist, MVideoBlacklistLight, MVideoBlacklistUnfederated } from './video-blacklist' | ||
8 | import { MVideoCaptionLanguage, MVideoCaptionLanguageUrl } from './video-caption' | ||
3 | import { | 9 | import { |
4 | MChannelAccountDefault, | 10 | MChannelAccountDefault, |
5 | MChannelAccountLight, | 11 | MChannelAccountLight, |
6 | MChannelAccountSummaryFormattable, | 12 | MChannelAccountSummaryFormattable, |
7 | MChannelActor, | 13 | MChannelActor, |
8 | MChannelFormattable, | 14 | MChannelFormattable, |
15 | MChannelHost, | ||
9 | MChannelUserId | 16 | MChannelUserId |
10 | } from './video-channels' | 17 | } from './video-channels' |
11 | import { MTag } from './tag' | 18 | import { MVideoFile, MVideoFileRedundanciesAll, MVideoFileRedundanciesOpt } from './video-file' |
12 | import { MVideoCaptionLanguage, MVideoCaptionLanguageUrl } from './video-caption' | 19 | import { MVideoLive } from './video-live' |
13 | import { | 20 | import { |
14 | MStreamingPlaylistFiles, | 21 | MStreamingPlaylistFiles, |
15 | MStreamingPlaylistRedundancies, | 22 | MStreamingPlaylistRedundancies, |
16 | MStreamingPlaylistRedundanciesAll, | 23 | MStreamingPlaylistRedundanciesAll, |
17 | MStreamingPlaylistRedundanciesOpt | 24 | MStreamingPlaylistRedundanciesOpt |
18 | } from './video-streaming-playlist' | 25 | } from './video-streaming-playlist' |
19 | import { MVideoFile, MVideoFileRedundanciesAll, MVideoFileRedundanciesOpt } from './video-file' | ||
20 | import { MThumbnail } from './thumbnail' | ||
21 | import { MVideoBlacklist, MVideoBlacklistLight, MVideoBlacklistUnfederated } from './video-blacklist' | ||
22 | import { MScheduleVideoUpdate } from './schedule-video-update' | ||
23 | import { MUserVideoHistoryTime } from '../user/user-video-history' | ||
24 | import { MVideoLive } from './video-live' | ||
25 | 26 | ||
26 | type Use<K extends keyof VideoModel, M> = PickWith<VideoModel, K, M> | 27 | type Use<K extends keyof VideoModel, M> = PickWith<VideoModel, K, M> |
27 | 28 | ||
@@ -143,6 +144,10 @@ export type MVideoWithChannelActor = | |||
143 | MVideo & | 144 | MVideo & |
144 | Use<'VideoChannel', MChannelActor> | 145 | Use<'VideoChannel', MChannelActor> |
145 | 146 | ||
147 | export type MVideoWithHost = | ||
148 | MVideo & | ||
149 | Use<'VideoChannel', MChannelHost> | ||
150 | |||
146 | export type MVideoFullLight = | 151 | export type MVideoFullLight = |
147 | MVideo & | 152 | MVideo & |
148 | Use<'Thumbnails', MThumbnail[]> & | 153 | Use<'Thumbnails', MThumbnail[]> & |