]>
Commit | Line | Data |
---|---|---|
f5fcd9f7 C |
1 | import videojs, { VideoJsPlayer } from 'video.js' |
2 | import './pause-bezel' | |
62ab565d | 3 | |
f5fcd9f7 | 4 | const Plugin = videojs.getPlugin('plugin') |
62ab565d | 5 | |
62ab565d | 6 | class BezelsPlugin extends Plugin { |
f5fcd9f7 C |
7 | |
8 | constructor (player: VideoJsPlayer, options?: videojs.ComponentOptions) { | |
9 | super(player) | |
62ab565d RK |
10 | |
11 | this.player.ready(() => { | |
12 | player.addClass('vjs-bezels') | |
13 | }) | |
14 | ||
15 | player.addChild('PauseBezel', options) | |
16 | } | |
17 | } | |
18 | ||
19 | videojs.registerPlugin('bezels', BezelsPlugin) | |
f5fcd9f7 | 20 | |
62ab565d | 21 | export { BezelsPlugin } |