]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - shared/models/activitypub/objects/common-objects.ts
Rename downloadingEnabled property to downloadEnabled
[github/Chocobozzz/PeerTube.git] / shared / models / activitypub / objects / common-objects.ts
index 5b2b3adaedb19f455635742c6aab529e50400e1f..1de60da94f5cf4445fafbf8e79d6c6566f3c8721 100644 (file)
@@ -17,16 +17,31 @@ export interface ActivityIconObject {
   height: number
 }
 
-export interface ActivityUrlObject {
+export type ActivityVideoUrlObject = {
   type: 'Link'
-  mimeType: 'video/mp4' | 'video/webm' | 'application/x-bittorrent' | 'application/x-bittorrent;x-scheme-handler/magnet'
+  mimeType: 'video/mp4' | 'video/webm' | 'video/ogg'
   href: string
-  width: number
-
-  size?: number
-  fps?: number
+  height: number
+  size: number
+  fps: number
 }
 
+export type ActivityUrlObject =
+  ActivityVideoUrlObject
+  |
+  {
+    type: 'Link'
+    mimeType: 'application/x-bittorrent' | 'application/x-bittorrent;x-scheme-handler/magnet'
+    href: string
+    height: number
+  }
+  |
+  {
+    type: 'Link'
+    mimeType: 'text/html'
+    href: string
+  }
+
 export interface ActivityPubAttributedTo {
   type: 'Group' | 'Person'
   id: string