ComponentsControls
FullscreenButton
A control component that toggles fullscreen mode for the video player
Usage
Props
| Prop | Type | Required | Default | Description |
|---|---|---|---|---|
size | number | No | – | Size of the icon. |
color | string | No | – | Color of the icon. |
style | StyleProp<ViewStyle> | No | – | Optional styles applied to the button container. |
renderEnterIcon | () => React.ReactNode | No | Maximize | Custom renderer for the "enter fullscreen" icon. |
renderExitIcon | () => React.ReactNode | No | Minimize | Custom renderer for the "exit fullscreen" icon. |
Examples
Default Fullscreen Button
import { FullscreenButton } from 'react-native-video-toolkit';
<FullscreenButton size={24} color="white" />;- Handles tap gestures internally using
useFullscreenandGestureDetector, so you don't need to wire gestures yourself. - Works seamlessly with both custom layouts and pre-built control sets.