player icon indicating copy to clipboard operation
player copied to clipboard

feat(player): more settings for default layout

Open bezumkin opened this issue 1 year ago • 6 comments

Description:

I'm using the programmatic initialization of Vidstack with the default layout.

const player = await VidstackPlayer.create({
  target,
  src: {src: url, type: 'application/x-mpegurl'},
  viewType: 'video',
  layout: new VidstackPlayerLayout(layoutSettings),
  // etc...
})

I tried to make Vidstack to look more like regular video player with simple settings. And that is why I'm introducing some new settings for default layout.

The main setting is flatSettingsMenu allows you to get rid of nested menus.

Screenshot 2024-09-16 at 10 15 54

Then you can disable any features you don't want to see:

const layoutSettings: Partial<DefaultLayoutProps> = {
  flatSettingsMenu: true,
  noAudioGain: true,
  noAudioTracks: true,
  noCaptions: true,
  noAnnouncements: true,
  noKeyboardAnimations: true,
  noCaptionStyles: true,
  noMediaLoop: true,
  // other settings...
}

And here is the final result! I hope you like it.

Screenshot 2024-09-16 at 10 30 07

Ready?

Yes, it has already been working for thousands of users in a production for a couple of months.

P.S.

Thank you for the great player!

bezumkin avatar Sep 16 '24 03:09 bezumkin

Would be awesome if this gets merged.

Benny739 avatar Oct 05 '24 01:10 Benny739

May i know when quality feature is available ?

JayanthGummitha avatar Jan 06 '25 05:01 JayanthGummitha

May i know when quality feature is available ?

I think when you play an HLS stream.

bezumkin avatar Jan 06 '25 06:01 bezumkin

but is it possible for local videos when i pass the the video like 480p, 720p,1080p to Vidstack it can detect automatically

JayanthGummitha avatar Jan 06 '25 18:01 JayanthGummitha

but is it possible for local videos when i pass the the video like 480p, 720p,1080p to Vidstack it can detect automatically

I don't know, never tried to use it with local files.

bezumkin avatar Jan 07 '25 09:01 bezumkin

I like this suggestion. I also would love to see the option to "disable the users choice for video quality" so the "Quality" section basically. Is this something that would be considered?

chrisspiegl avatar Jun 14 '25 15:06 chrisspiegl