Skip to main content

ManuallyRequestSheet.Container

Content container component that provides padding, spacing, and safe-area handling for bottom-sheet content.

Quick Example​

import { DataSync } from "@ovok/native/data-sync";
import { BottomSheetModal } from "@gorhom/bottom-sheet";
import React from "react";
import { Button, Text } from "react-native-paper";

const ContainerExample = () => {
const sheetRef = React.useRef<BottomSheetModal | null>(null);

return (
<>
<Button
onPress={() => {
sheetRef.current?.present();
}}
>
Open Sheet
</Button>
{/* It's important to wrap container with DataSync.ManuallyRequestSheet */}
<DataSync.ManuallyRequestSheet ref={(ref) => (sheetRef.current = ref)}>
<DataSync.ManuallyRequestSheet.Container>
<Text>Hello</Text>
</DataSync.ManuallyRequestSheet.Container>
</DataSync.ManuallyRequestSheet>
</>
);
};

export default ContainerExample;

Props​

PropTypeRequiredDefaultDescription
childrenReact.ReactNode--Child components to render
styleViewStyle--Additional styling (merged with default)

Inherits all BottomSheetViewProps from @gorhom/bottom-sheet

Component Behavior​

The Container component provides:

  1. Consistent Padding: Standard padding around all content
  2. Safe Area Handling: Proper bottom safe area insets
  3. Flex Layout: Vertical flex layout with proper spacing
  4. Gap Management: Consistent spacing between child elements

Container is a BottomSheetView, not a scroll view. Use a supported bottom-sheet scrollable child when the request content can exceed the available height.

Styling​

Theme Values Used​

  • theme.spacing(3) - Container padding (horizontal and top)
  • theme.spacing(5) - Gap between child components
  • bottom + theme.spacing(3) - Safe area bottom padding