aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/assets/player/videojs-components
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2020-04-17 11:20:12 +0200
committerChocobozzz <me@florianbigard.com>2020-04-17 14:12:43 +0200
commit7e37e111116e41530749b88327bc601cb39ade03 (patch)
treea141a84b6999029084629d45a3d5addbfa34e603 /client/src/assets/player/videojs-components
parentbb3933ef370c46be6090e4e522c6e3f5b7144f4c (diff)
downloadPeerTube-7e37e111116e41530749b88327bc601cb39ade03.tar.gz
PeerTube-7e37e111116e41530749b88327bc601cb39ade03.tar.zst
PeerTube-7e37e111116e41530749b88327bc601cb39ade03.zip
Fix videojs typings
Diffstat (limited to 'client/src/assets/player/videojs-components')
-rw-r--r--client/src/assets/player/videojs-components/next-video-button.ts4
-rw-r--r--client/src/assets/player/videojs-components/p2p-info-button.ts2
-rw-r--r--client/src/assets/player/videojs-components/peertube-link-button.ts4
-rw-r--r--client/src/assets/player/videojs-components/peertube-load-progress-bar.ts4
-rw-r--r--client/src/assets/player/videojs-components/resolution-menu-button.ts4
-rw-r--r--client/src/assets/player/videojs-components/resolution-menu-item.ts4
-rw-r--r--client/src/assets/player/videojs-components/settings-dialog.ts4
-rw-r--r--client/src/assets/player/videojs-components/settings-menu-button.ts4
-rw-r--r--client/src/assets/player/videojs-components/settings-menu-item.ts4
-rw-r--r--client/src/assets/player/videojs-components/settings-panel-child.ts4
-rw-r--r--client/src/assets/player/videojs-components/settings-panel.ts4
-rw-r--r--client/src/assets/player/videojs-components/theater-button.ts4
12 files changed, 23 insertions, 23 deletions
diff --git a/client/src/assets/player/videojs-components/next-video-button.ts b/client/src/assets/player/videojs-components/next-video-button.ts
index bdb245dcc..c97ecdda6 100644
--- a/client/src/assets/player/videojs-components/next-video-button.ts
+++ b/client/src/assets/player/videojs-components/next-video-button.ts
@@ -1,4 +1,4 @@
1import videojs, { VideoJsPlayer } from 'video.js' 1import videojs from 'video.js/dist/alt/video.core.js'
2 2
3const Button = videojs.getComponent('Button') 3const Button = videojs.getComponent('Button')
4 4
@@ -9,7 +9,7 @@ export interface NextVideoButtonOptions extends videojs.ComponentOptions {
9class NextVideoButton extends Button { 9class NextVideoButton extends Button {
10 private readonly nextVideoButtonOptions: NextVideoButtonOptions 10 private readonly nextVideoButtonOptions: NextVideoButtonOptions
11 11
12 constructor (player: VideoJsPlayer, options?: NextVideoButtonOptions) { 12 constructor (player: videojs.Player, options?: NextVideoButtonOptions) {
13 super(player, options) 13 super(player, options)
14 14
15 this.nextVideoButtonOptions = options 15 this.nextVideoButtonOptions = options
diff --git a/client/src/assets/player/videojs-components/p2p-info-button.ts b/client/src/assets/player/videojs-components/p2p-info-button.ts
index db6806fed..e340337ed 100644
--- a/client/src/assets/player/videojs-components/p2p-info-button.ts
+++ b/client/src/assets/player/videojs-components/p2p-info-button.ts
@@ -1,5 +1,5 @@
1import { PlayerNetworkInfo } from '../peertube-videojs-typings' 1import { PlayerNetworkInfo } from '../peertube-videojs-typings'
2import videojs from 'video.js' 2import videojs from 'video.js/dist/alt/video.core.js'
3import { bytes } from '../utils' 3import { bytes } from '../utils'
4 4
5const Button = videojs.getComponent('Button') 5const Button = videojs.getComponent('Button')
diff --git a/client/src/assets/player/videojs-components/peertube-link-button.ts b/client/src/assets/player/videojs-components/peertube-link-button.ts
index 0db9762a5..4151758d4 100644
--- a/client/src/assets/player/videojs-components/peertube-link-button.ts
+++ b/client/src/assets/player/videojs-components/peertube-link-button.ts
@@ -1,10 +1,10 @@
1import { buildVideoLink } from '../utils' 1import { buildVideoLink } from '../utils'
2import videojs, { VideoJsPlayer } from 'video.js' 2import videojs from 'video.js/dist/alt/video.core.js'
3 3
4const Button = videojs.getComponent('Button') 4const Button = videojs.getComponent('Button')
5class PeerTubeLinkButton extends Button { 5class PeerTubeLinkButton extends Button {
6 6
7 constructor (player: VideoJsPlayer, options?: videojs.ComponentOptions) { 7 constructor (player: videojs.Player, options?: videojs.ComponentOptions) {
8 super(player, options) 8 super(player, options)
9 } 9 }
10 10
diff --git a/client/src/assets/player/videojs-components/peertube-load-progress-bar.ts b/client/src/assets/player/videojs-components/peertube-load-progress-bar.ts
index 8168e8f2d..395720c53 100644
--- a/client/src/assets/player/videojs-components/peertube-load-progress-bar.ts
+++ b/client/src/assets/player/videojs-components/peertube-load-progress-bar.ts
@@ -1,10 +1,10 @@
1import videojs, { VideoJsPlayer } from 'video.js' 1import videojs from 'video.js/dist/alt/video.core.js'
2 2
3const Component = videojs.getComponent('Component') 3const Component = videojs.getComponent('Component')
4 4
5class PeerTubeLoadProgressBar extends Component { 5class PeerTubeLoadProgressBar extends Component {
6 6
7 constructor (player: VideoJsPlayer, options?: videojs.ComponentOptions) { 7 constructor (player: videojs.Player, options?: videojs.ComponentOptions) {
8 super(player, options) 8 super(player, options)
9 9
10 this.on(player, 'progress', this.update) 10 this.on(player, 'progress', this.update)
diff --git a/client/src/assets/player/videojs-components/resolution-menu-button.ts b/client/src/assets/player/videojs-components/resolution-menu-button.ts
index 0fa6272e7..d49ca0230 100644
--- a/client/src/assets/player/videojs-components/resolution-menu-button.ts
+++ b/client/src/assets/player/videojs-components/resolution-menu-button.ts
@@ -1,4 +1,4 @@
1import videojs, { VideoJsPlayer } from 'video.js' 1import videojs from 'video.js/dist/alt/video.core.js'
2 2
3import { LoadedQualityData } from '../peertube-videojs-typings' 3import { LoadedQualityData } from '../peertube-videojs-typings'
4import { ResolutionMenuItem } from './resolution-menu-item' 4import { ResolutionMenuItem } from './resolution-menu-item'
@@ -8,7 +8,7 @@ const MenuButton = videojs.getComponent('MenuButton')
8class ResolutionMenuButton extends MenuButton { 8class ResolutionMenuButton extends MenuButton {
9 labelEl_: HTMLElement 9 labelEl_: HTMLElement
10 10
11 constructor (player: VideoJsPlayer, options?: videojs.MenuButtonOptions) { 11 constructor (player: videojs.Player, options?: videojs.MenuButtonOptions) {
12 super(player, options) 12 super(player, options)
13 13
14 this.controlText('Quality') 14 this.controlText('Quality')
diff --git a/client/src/assets/player/videojs-components/resolution-menu-item.ts b/client/src/assets/player/videojs-components/resolution-menu-item.ts
index b039c4572..cb0d219ad 100644
--- a/client/src/assets/player/videojs-components/resolution-menu-item.ts
+++ b/client/src/assets/player/videojs-components/resolution-menu-item.ts
@@ -1,4 +1,4 @@
1import videojs, { VideoJsPlayer } from 'video.js' 1import videojs from 'video.js/dist/alt/video.core.js'
2import { AutoResolutionUpdateData, ResolutionUpdateData } from '../peertube-videojs-typings' 2import { AutoResolutionUpdateData, ResolutionUpdateData } from '../peertube-videojs-typings'
3 3
4const MenuItem = videojs.getComponent('MenuItem') 4const MenuItem = videojs.getComponent('MenuItem')
@@ -19,7 +19,7 @@ class ResolutionMenuItem extends MenuItem {
19 private autoResolutionPossible: boolean 19 private autoResolutionPossible: boolean
20 private currentResolutionLabel: string 20 private currentResolutionLabel: string
21 21
22 constructor (player: VideoJsPlayer, options?: ResolutionMenuItemOptions) { 22 constructor (player: videojs.Player, options?: ResolutionMenuItemOptions) {
23 options.selectable = true 23 options.selectable = true
24 24
25 super(player, options) 25 super(player, options)
diff --git a/client/src/assets/player/videojs-components/settings-dialog.ts b/client/src/assets/player/videojs-components/settings-dialog.ts
index dd0b1e472..8fd5ad96c 100644
--- a/client/src/assets/player/videojs-components/settings-dialog.ts
+++ b/client/src/assets/player/videojs-components/settings-dialog.ts
@@ -1,9 +1,9 @@
1import videojs, { VideoJsPlayer } from 'video.js' 1import videojs from 'video.js/dist/alt/video.core.js'
2 2
3const Component = videojs.getComponent('Component') 3const Component = videojs.getComponent('Component')
4 4
5class SettingsDialog extends Component { 5class SettingsDialog extends Component {
6 constructor (player: VideoJsPlayer) { 6 constructor (player: videojs.Player) {
7 super(player) 7 super(player)
8 8
9 this.hide() 9 this.hide()
diff --git a/client/src/assets/player/videojs-components/settings-menu-button.ts b/client/src/assets/player/videojs-components/settings-menu-button.ts
index eae628e7d..749128bdc 100644
--- a/client/src/assets/player/videojs-components/settings-menu-button.ts
+++ b/client/src/assets/player/videojs-components/settings-menu-button.ts
@@ -1,7 +1,7 @@
1// Thanks to Yanko Shterev: https://github.com/yshterev/videojs-settings-menu 1// Thanks to Yanko Shterev: https://github.com/yshterev/videojs-settings-menu
2import { SettingsMenuItem } from './settings-menu-item' 2import { SettingsMenuItem } from './settings-menu-item'
3import { toTitleCase } from '../utils' 3import { toTitleCase } from '../utils'
4import videojs, { VideoJsPlayer } from 'video.js' 4import videojs from 'video.js/dist/alt/video.core.js'
5 5
6import { SettingsDialog } from './settings-dialog' 6import { SettingsDialog } from './settings-dialog'
7import { SettingsPanel } from './settings-panel' 7import { SettingsPanel } from './settings-panel'
@@ -32,7 +32,7 @@ class SettingsButton extends Button {
32 32
33 private settingsButtonOptions: SettingsButtonOptions 33 private settingsButtonOptions: SettingsButtonOptions
34 34
35 constructor (player: VideoJsPlayer, options?: SettingsButtonOptions) { 35 constructor (player: videojs.Player, options?: SettingsButtonOptions) {
36 super(player, options) 36 super(player, options)
37 37
38 this.settingsButtonOptions = options 38 this.settingsButtonOptions = options
diff --git a/client/src/assets/player/videojs-components/settings-menu-item.ts b/client/src/assets/player/videojs-components/settings-menu-item.ts
index f5671f49d..8d364591b 100644
--- a/client/src/assets/player/videojs-components/settings-menu-item.ts
+++ b/client/src/assets/player/videojs-components/settings-menu-item.ts
@@ -1,6 +1,6 @@
1// Thanks to Yanko Shterev: https://github.com/yshterev/videojs-settings-menu 1// Thanks to Yanko Shterev: https://github.com/yshterev/videojs-settings-menu
2import { toTitleCase } from '../utils' 2import { toTitleCase } from '../utils'
3import videojs, { VideoJsPlayer } from 'video.js' 3import videojs from 'video.js/dist/alt/video.core.js'
4import { SettingsButton } from './settings-menu-button' 4import { SettingsButton } from './settings-menu-button'
5import { SettingsDialog } from './settings-dialog' 5import { SettingsDialog } from './settings-dialog'
6import { SettingsPanel } from './settings-panel' 6import { SettingsPanel } from './settings-panel'
@@ -32,7 +32,7 @@ class SettingsMenuItem extends MenuItem {
32 settingsSubMenuValueEl_: HTMLElement 32 settingsSubMenuValueEl_: HTMLElement
33 settingsSubMenuEl_: HTMLElement 33 settingsSubMenuEl_: HTMLElement
34 34
35 constructor (player: VideoJsPlayer, options?: SettingsMenuItemOptions) { 35 constructor (player: videojs.Player, options?: SettingsMenuItemOptions) {
36 super(player, options) 36 super(player, options)
37 37
38 this.settingsButton = options.menuButton 38 this.settingsButton = options.menuButton
diff --git a/client/src/assets/player/videojs-components/settings-panel-child.ts b/client/src/assets/player/videojs-components/settings-panel-child.ts
index d12e8218a..6dee6d7df 100644
--- a/client/src/assets/player/videojs-components/settings-panel-child.ts
+++ b/client/src/assets/player/videojs-components/settings-panel-child.ts
@@ -1,10 +1,10 @@
1import videojs, { VideoJsPlayer } from 'video.js' 1import videojs from 'video.js/dist/alt/video.core.js'
2 2
3const Component = videojs.getComponent('Component') 3const Component = videojs.getComponent('Component')
4 4
5class SettingsPanelChild extends Component { 5class SettingsPanelChild extends Component {
6 6
7 constructor (player: VideoJsPlayer, options?: videojs.ComponentOptions) { 7 constructor (player: videojs.Player, options?: videojs.ComponentOptions) {
8 super(player, options) 8 super(player, options)
9 } 9 }
10 10
diff --git a/client/src/assets/player/videojs-components/settings-panel.ts b/client/src/assets/player/videojs-components/settings-panel.ts
index 2090abf45..833ee2f21 100644
--- a/client/src/assets/player/videojs-components/settings-panel.ts
+++ b/client/src/assets/player/videojs-components/settings-panel.ts
@@ -1,10 +1,10 @@
1import videojs, { VideoJsPlayer } from 'video.js' 1import videojs from 'video.js/dist/alt/video.core.js'
2 2
3const Component = videojs.getComponent('Component') 3const Component = videojs.getComponent('Component')
4 4
5class SettingsPanel extends Component { 5class SettingsPanel extends Component {
6 6
7 constructor (player: VideoJsPlayer, options?: videojs.ComponentOptions) { 7 constructor (player: videojs.Player, options?: videojs.ComponentOptions) {
8 super(player, options) 8 super(player, options)
9 } 9 }
10 10
diff --git a/client/src/assets/player/videojs-components/theater-button.ts b/client/src/assets/player/videojs-components/theater-button.ts
index 1c8c9f154..41875af71 100644
--- a/client/src/assets/player/videojs-components/theater-button.ts
+++ b/client/src/assets/player/videojs-components/theater-button.ts
@@ -1,4 +1,4 @@
1import videojs, { VideoJsPlayer } from 'video.js' 1import videojs from 'video.js/dist/alt/video.core.js'
2import { saveTheaterInStore, getStoredTheater } from '../peertube-player-local-storage' 2import { saveTheaterInStore, getStoredTheater } from '../peertube-player-local-storage'
3 3
4const Button = videojs.getComponent('Button') 4const Button = videojs.getComponent('Button')
@@ -6,7 +6,7 @@ class TheaterButton extends Button {
6 6
7 private static readonly THEATER_MODE_CLASS = 'vjs-theater-enabled' 7 private static readonly THEATER_MODE_CLASS = 'vjs-theater-enabled'
8 8
9 constructor (player: VideoJsPlayer, options: videojs.ComponentOptions) { 9 constructor (player: videojs.Player, options: videojs.ComponentOptions) {
10 super(player, options) 10 super(player, options)
11 11
12 const enabled = getStoredTheater() 12 const enabled = getStoredTheater()