Focus player on video loading
This commit is contained in:
parent
3062112200
commit
d275e75453
|
@ -477,6 +477,7 @@ export class VideoWatchComponent implements OnInit, OnDestroy {
|
|||
|
||||
this.zone.runOutsideAngular(async () => {
|
||||
this.player = await PeertubePlayerManager.initialize(mode, options, player => this.player = player)
|
||||
this.player.focus()
|
||||
|
||||
this.player.on('customError', ({ err }: { err: any }) => this.handleError(err))
|
||||
|
||||
|
|
|
@ -329,6 +329,8 @@ class SettingsMenuItem extends MenuItem {
|
|||
}
|
||||
|
||||
setMargin () {
|
||||
if (!this.size) return
|
||||
|
||||
const [ width ] = this.size
|
||||
|
||||
this.settingsSubMenuEl_.style.marginRight = `-${width}px`
|
||||
|
|
Loading…
Reference in New Issue