]>
Commit | Line | Data |
---|---|---|
1 | import { LocalVideoViewerModel } from '@server/models/view/local-video-viewer' | |
2 | import { PickWith } from '@shared/typescript-utils' | |
3 | import { MLocalVideoViewerWatchSection } from './local-video-viewer-watch-section' | |
4 | import { MVideo } from './video' | |
5 | ||
6 | type Use<K extends keyof LocalVideoViewerModel, M> = PickWith<LocalVideoViewerModel, K, M> | |
7 | ||
8 | // ############################################################################ | |
9 | ||
10 | export type MLocalVideoViewer = Omit<LocalVideoViewerModel, 'Video'> | |
11 | ||
12 | export type MLocalVideoViewerVideo = | |
13 | MLocalVideoViewer & | |
14 | Use<'Video', MVideo> | |
15 | ||
16 | export type MLocalVideoViewerWithWatchSections = | |
17 | MLocalVideoViewer & | |
18 | Use<'Video', MVideo> & | |
19 | Use<'WatchSections', MLocalVideoViewerWatchSection[]> |