mirror of https://git.lenooby09.tech/LeNooby09/social-app.git
1import React from 'react'
2import {ColorValue, NativeSyntheticEvent} from 'react-native'
3
4export type BottomSheetState = 'closed' | 'closing' | 'open' | 'opening'
5
6export enum BottomSheetSnapPoint {
7 Hidden,
8 Partial,
9 Full,
10}
11
12export type BottomSheetAttemptDismissEvent = NativeSyntheticEvent<object>
13export type BottomSheetSnapPointChangeEvent = NativeSyntheticEvent<{
14 snapPoint: BottomSheetSnapPoint
15}>
16export type BottomSheetStateChangeEvent = NativeSyntheticEvent<{
17 state: BottomSheetState
18}>
19
20export interface BottomSheetViewProps {
21 children: React.ReactNode
22 cornerRadius?: number
23 preventDismiss?: boolean
24 preventExpansion?: boolean
25 backgroundColor?: ColorValue
26 containerBackgroundColor?: ColorValue
27 disableDrag?: boolean
28
29 minHeight?: number
30 maxHeight?: number
31
32 onAttemptDismiss?: (event: BottomSheetAttemptDismissEvent) => void
33 onSnapPointChange?: (event: BottomSheetSnapPointChangeEvent) => void
34 onStateChange?: (event: BottomSheetStateChangeEvent) => void
35}