aboutsummaryrefslogtreecommitdiffhomepage
path: root/server/types/models/video/video-share.ts
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2020-06-18 10:45:25 +0200
committerChocobozzz <me@florianbigard.com>2020-06-18 10:46:27 +0200
commit26d6bf6533023326fa017812cf31bbe20c752d36 (patch)
tree9c4e3ecdc344420190f17d429bdf05d78fae7a8c /server/types/models/video/video-share.ts
parentd6d951ddc0c492f3261065b5dcb4df0534d252fc (diff)
downloadPeerTube-26d6bf6533023326fa017812cf31bbe20c752d36.tar.gz
PeerTube-26d6bf6533023326fa017812cf31bbe20c752d36.tar.zst
PeerTube-26d6bf6533023326fa017812cf31bbe20c752d36.zip
Split types and typings
Diffstat (limited to 'server/types/models/video/video-share.ts')
-rw-r--r--server/types/models/video/video-share.ts19
1 files changed, 19 insertions, 0 deletions
diff --git a/server/types/models/video/video-share.ts b/server/types/models/video/video-share.ts
new file mode 100644
index 000000000..50ca75d26
--- /dev/null
+++ b/server/types/models/video/video-share.ts
@@ -0,0 +1,19 @@
1import { VideoShareModel } from '../../../models/video/video-share'
2import { PickWith } from '../../utils'
3import { MActorDefault } from '../account'
4import { MVideo } from './video'
5
6type Use<K extends keyof VideoShareModel, M> = PickWith<VideoShareModel, K, M>
7
8// ############################################################################
9
10export type MVideoShare = Omit<VideoShareModel, 'Actor' | 'Video'>
11
12export type MVideoShareActor =
13 MVideoShare &
14 Use<'Actor', MActorDefault>
15
16export type MVideoShareFull =
17 MVideoShare &
18 Use<'Actor', MActorDefault> &
19 Use<'Video', MVideo>