-import { Config, Level } from 'hls.js'
+import { HlsConfig, Level } from 'hls.js'
import videojs from 'video.js'
import { VideoFile, VideoPlaylist, VideoPlaylistElement } from '@shared/models'
import { P2pMediaLoaderPlugin } from './p2p-media-loader/p2p-media-loader-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' {
bezels (): void
- stats (options?: Partial<StatsCardOptions>): any
+ stats (options?: StatsCardOptions): StatsForNerdsPlugin
qualityLevels (): QualityLevels
}
export interface HlsjsConfigHandlerOptions {
- hlsjsConfig?: Config & { cueHandler: any }// FIXME: typings
+ hlsjsConfig?: HlsConfig & { cueHandler: any }// FIXME: typings
captionConfig?: any // FIXME: typings
levelLabelHandler?: (level: Level) => string
isDisabled: () => boolean
}
+type PeerTubeLinkButtonOptions = {
+ shortUUID: string
+}
+
type WebtorrentPluginOptions = {
playerElement: HTMLVideoElement
uploaded: number
numPeers: number
}
+
+ // In bytes
+ bandwidthEstimate: number
}
type PlaylistItemOptions = {
VideoJSPluginOptions,
LoadedQualityData,
QualityLevelRepresentation,
+ PeerTubeLinkButtonOptions,
QualityLevels
}