()
| 8 | const sheets = createSheets(); |
| 9 | |
| 10 | export function BottomSheetExample() { |
| 11 | return ( |
| 12 | <sheets.Provider> |
| 13 | <View className="flex-1 pt-24"> |
| 14 | <View className="flex-1"> |
| 15 | <Button title="Show sheet" onPress={() => sheets.open("my-sheet")} /> |
| 16 | |
| 17 | <Sheet |
| 18 | id="my-sheet" |
| 19 | // initialIndex={1} |
| 20 | canDismiss |
| 21 | // onStateChange={(event) => console.log({ event })} |
| 22 | snapPoints={[400, 600, 1200]} |
| 23 | appearanceAndroid={{ |
| 24 | dimAmount: 0, |
| 25 | cornerRadius: 32.0, |
| 26 | backgroundColor: "#ffffff", |
| 27 | }} |
| 28 | appearanceIOS={{ |
| 29 | cornerRadius: 16.0, |
| 30 | grabberVisible: true, |
| 31 | backgroundColor: "#ffffff", |
| 32 | }} |
| 33 | > |
| 34 | <SheetContent /> |
| 35 | </Sheet> |
| 36 | </View> |
| 37 | </View> |
| 38 | </sheets.Provider> |
| 39 | ); |
| 40 | } |
| 41 | |
| 42 | function SheetContent() { |
| 43 | const handleClose = React.useCallback(() => { |
nothing calls this directly
no outgoing calls
no test coverage detected