-
Notifications
You must be signed in to change notification settings - Fork 37
Open
Description
When passing a data object to the VideoPlayer, muxPlaybackId (or playbackId) is required, but not indicated as such in the type:
export type Video = {
/** Title attribute (`title`) for the video */
title?: Possibly<string>;
/** The height of the video */
height?: Possibly<number>;
/** The width of the video */
width?: Possibly<number>;
/** The MUX playbaack ID */
muxPlaybackId?: Possibly<string>;
/** The MUX playbaack ID */
playbackId?: Possibly<string>;
/** A data: URI containing a blurhash for the video */
blurUpThumb?: Possibly<string>;
/** Other data can be passed, but they have no effect on rendering the player */
// biome-ignore lint/suspicious/noExplicitAny: we intentionally want to allow to add any other value to this video object
[k: string]: any;
};As such, it causes situations where a missing ID can cause the player to appear as though it has a loading issue (the bottom player in this case), showing a loading spinner forever:
Should we do any of the following:
- Mark at least one of the playback ID parameters as required in the TypeScript
- Optionally also accept, and check for,
streamingUrlas a fallback and extract the ID from there - If no ID is present in either the param or a fallback, how a visual error (like a
divoverlay) instead of trying to actually load the video
Metadata
Metadata
Assignees
Labels
No labels