Player deck configurations (React Native)
PlayerDeck component provides playerDeckConfiguration prop for configuring player deck appearance, layout, autoplay, item controls, ad badge, fullscreen behavior, and subtitles.
Configuration reference
Customize player deck appearance and layout
const playerDeckConfiguration = {
// Configure background color
backgroundColor: '#FFFFFF',
// Configure the corner radius for each deck item
cornerRadius: 8,
// Configure the spacing between each deck item
itemSpacing: 16,
// Configure content padding
contentPadding: {
top: 10,
right: 10,
bottom: 10,
left: 10,
},
};
<PlayerDeck
style={{ height: 580 }}
source="discover"
playerDeckConfiguration={playerDeckConfiguration}
/>Customize player deck item controls
Customize player deck subtitles
Update player deck configuration
You can update playerDeckConfiguration by rendering PlayerDeck with a new configuration value.
Custom thumbnail play icon
Set playerDeckConfiguration.playIcon.imageName to use artwork bundled in your app:
Use an asset catalog image name on iOS or an Android res/drawable resource name without its extension. systemImageName is an iOS-only alternative. The icon stays square and retains its own colors, with no tint applied. iconWidth also applies when using the default artwork. See custom thumbnail play icon for asset setup.
The default icon width is 50 on iOS and 50dp on Android. Android previously used 36dp; set playIcon: { iconWidth: 36 } to preserve that size.
Autoplay and first-display mute behavior on iOS
When autoplay is enabled, the thumbnail autoplay trigger requires 100% visibility. Player Deck uses a viewport that is not inset by the safe area.
If onFirstDisplayMuteState is omitted, Player Deck follows the SDK initialization option videoLaunchBehavior: .muteOnFirstLaunch starts the inline deck muted; otherwise it starts unmuted. Explicitly setting onFirstDisplayMuteState to 'default' or 'unmuted' overrides that initialization behavior for the inline player. Omit it when you want the initialization setting to apply.
The full-screen player also honors videoLaunchBehavior when no videoPlayerConfiguration is supplied. See iOS playback behavior.
Last updated
Was this helpful?