Const
// Basic grid with video tiles
<FlexibleGrid
customWidth={200}
customHeight={150}
rows={2}
columns={3}
componentsToRender={[
<VideoTile key="1" participantId="user1" />,
<VideoTile key="2" participantId="user2" />,
<VideoTile key="3" participantId="user3" />,
<VideoTile key="4" participantId="user4" />,
<VideoTile key="5" participantId="user5" />,
<VideoTile key="6" participantId="user6" />,
]}
backgroundColor="#1a1a1a"
/>
// Square aspect grid with custom container
<FlexibleGrid
customWidth={100}
customHeight={100}
rows={3}
columns={3}
componentsToRender={audienceCards}
showAspect
renderContainer={({ defaultContainer, dimensions }) => (
<Animated.View style={{ opacity: fadeAnim }}>
{defaultContainer}
</Animated.View>
)}
/>
FlexibleGrid arranges arbitrary children into a fixed row/column matrix. It is primarily used for media tiles that need explicit sizing while still allowing consumers to override either the content or the wrapper container.
Key Features
Accessibility