]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - client/src/assets/player/peertube-videojs-typings.ts
Filter videos by live in custom markup
[github/Chocobozzz/PeerTube.git] / client / src / assets / player / peertube-videojs-typings.ts
index a48ff2cd0c9108c0e7665027338c829386165991..d3c75990b94235f44b307a818c08106a1487cf7e 100644 (file)
@@ -7,7 +7,9 @@ import { PlayerMode } from './peertube-player-manager'
 import { PeerTubePlugin } from './peertube-plugin'
 import { PlaylistPlugin } from './playlist/playlist-plugin'
 import { EndCardOptions } from './upnext/end-card'
+import { StatsCardOptions } from './stats/stats-card'
 import { WebTorrentPlugin } from './webtorrent/webtorrent-plugin'
+import { StatsForNerdsPlugin } from './stats/stats-plugin'
 
 declare module 'video.js' {
 
@@ -36,6 +38,8 @@ declare module 'video.js' {
 
     bezels (): void
 
+    stats (options?: StatsCardOptions): StatsForNerdsPlugin
+
     qualityLevels (): QualityLevels
 
     textTracks (): TextTrackList & {
@@ -113,18 +117,13 @@ type PeerTubePluginOptions = {
 }
 
 type PlaylistPluginOptions = {
-  createComponent: boolean
-
-  elements?: VideoPlaylistElement[]
+  elements: VideoPlaylistElement[]
 
   playlist: VideoPlaylist
 
   getCurrentPosition: () => number
 
-  embedUrl: string
-  embedTitle: string
-
-  onItemClicked?: (element: VideoPlaylistElement) => void
+  onItemClicked: (element: VideoPlaylistElement) => void
 }
 
 type NextPreviousVideoButtonOptions = {
@@ -133,6 +132,10 @@ type NextPreviousVideoButtonOptions = {
   isDisabled: () => boolean
 }
 
+type PeerTubeLinkButtonOptions = {
+  shortUUID: string
+}
+
 type WebtorrentPluginOptions = {
   playerElement: HTMLVideoElement
 
@@ -200,6 +203,9 @@ type PlayerNetworkInfo = {
     uploaded: number
     numPeers: number
   }
+
+  // In bytes
+  bandwidthEstimate: number
 }
 
 type PlaylistItemOptions = {
@@ -223,5 +229,6 @@ export {
   VideoJSPluginOptions,
   LoadedQualityData,
   QualityLevelRepresentation,
+  PeerTubeLinkButtonOptions,
   QualityLevels
 }