react-all-player
Version:
react-all-player is a simple, lightweight, accessible and customizable React media player that supports modern browsers.
25 lines (24 loc) • 706 B
TypeScript
export declare type Source = {
file: string;
label?: string;
type?: string | 'hls' | 'dash';
};
export declare type Subtitle = {
file: string;
lang: string;
language: string;
};
export declare type Audio = {
lang: string;
language: string;
};
declare const shortcuts: readonly ["play", "pause", "forward", "backward", "subtitle", "fullscreen", "volume"];
export declare type Shortcut = string | string[];
export declare type Shortcuts = Record<typeof shortcuts[number], Shortcut>;
export declare type HotKey = {
fn: (videoEl: HTMLVideoElement) => void;
name: string;
hotKey: string | string[];
preventDefault?: boolean;
};
export {};