peertube-theme-nctv-dark/peertube-plugin-hello-world/client/embed-client-plugin.js

21 lines
447 B
JavaScript
Raw Normal View History

2020-08-21 12:45:18 +00:00
function register ({ registerHook, peertubeHelpers }) {
registerHook({
target: 'action:embed.player.loaded',
handler: () => alert('video loaded')
})
2021-06-30 14:44:42 +00:00
registerHook({
target: 'filter:internal.player.videojs.options.result',
handler: (options) => {
options.poster = 'https://joinpeertube.org/img/brand-with-v3.png'
return options
}
})
2020-08-21 12:45:18 +00:00
console.log(peertubeHelpers.translate('toto'))
}
export {
register
}