@theoplayer/react-native-ui
Version:
A React Native UI for @theoplayer/react-native
59 lines • 1.75 kB
TypeScript
import React, { ReactNode } from 'react';
import { PlayerConfiguration, THEOplayer } from 'react-native-theoplayer';
import { THEOplayerTheme } from './THEOplayerTheme';
import { StyleProp, ViewStyle } from 'react-native';
import type { Locale } from './components/util/Locale';
export declare enum UIFeature {
Chromecast = 0,
AirPlay = 1,
Fullscreen = 2,
Language = 3,
Mute = 4,
PiP = 5,
PlaybackRate = 6,
SeekBar = 7,
TrickPlay = 8,
VideoQuality = 9
}
export interface THEOplayerDefaultUiProps {
/**
* The style for the container.
*/
style?: StyleProp<ViewStyle>;
/**
* The theme for all components.
*/
theme?: Partial<THEOplayerTheme>;
/**
* The localized strings used in the UI components.
*/
locale?: Partial<Locale>;
/**
* The player configuration with THEOplayer license.
*/
config?: PlayerConfiguration;
/**
* The callback that is called when the internal THEOplayer is created.
* @param player the internal THEOplayer
*/
onPlayerReady?: (player: THEOplayer) => void;
/**
* A slot in the top right to add additional UI components.
*/
topSlot?: ReactNode;
/**
* A slot in the bottom right to add additional UI components.
*/
bottomSlot?: ReactNode;
/**
* A set of features to exclude from the UI.
*
* @default [Cast]
*/
excludedFeatures?: UIFeature[];
}
/**
* A default UI layout which uses UI components from `react-native-theoplayer` to create a basic playback UI around a THEOplayerView.
*/
export declare function THEOplayerDefaultUi(props: THEOplayerDefaultUiProps): React.JSX.Element;
//# sourceMappingURL=THEOplayerDefaultUi.d.ts.map