]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blame - server/typings/models/video/video-streaming-playlist.ts
Add auto follow back support for instances
[github/Chocobozzz/PeerTube.git] / server / typings / models / video / video-streaming-playlist.ts
CommitLineData
453e83ea 1import { VideoStreamingPlaylistModel } from '../../../models/video/video-streaming-playlist'
b5fecbf4 2import { PickWith, PickWithOpt } from '../../utils'
453e83ea 3import { MVideoRedundancyFileUrl } from './video-redundancy'
b5fecbf4 4import { MVideo, MVideoUrl } from '@server/typings/models'
453e83ea 5
0283eaac
C
6type Use<K extends keyof VideoStreamingPlaylistModel, M> = PickWith<VideoStreamingPlaylistModel, K, M>
7
8// ############################################################################
9
453e83ea
C
10export type MStreamingPlaylist = Omit<VideoStreamingPlaylistModel, 'Video' | 'RedundancyVideos'>
11
12export type MStreamingPlaylistVideo = MStreamingPlaylist &
0283eaac 13 Use<'Video', MVideo>
453e83ea
C
14
15export type MStreamingPlaylistRedundancies = MStreamingPlaylist &
0283eaac 16 Use<'RedundancyVideos', MVideoRedundancyFileUrl[]>
b5fecbf4
C
17
18export type MStreamingPlaylistRedundanciesOpt = MStreamingPlaylist &
19 PickWithOpt<VideoStreamingPlaylistModel, 'RedundancyVideos', MVideoRedundancyFileUrl[]>