react-native-animated-modal
    Preparing search index...

    Type Alias ModalProps

    Props for the Modal component. This is the type intended for end-user usage. All properties are optional.

    type ModalProps = {
        animation?: AnimationNs.Config;
        backdrop?: BackdropNs.Config;
        children?: ReactNode;
        hardwareAccelerated?: boolean;
        navigationBarTranslucent?: boolean;
        onBackdropPress?: () => void;
        onBackPress?: () => void;
        onHide?: () => void;
        onOrientationChange?: (event: NativeSyntheticEvent<any>) => void;
        onShow?: () => void;
        onSwipeCancel?: () => void;
        onSwipeComplete?: () => void;
        statusBarTranslucent?: boolean;
        style?: StyleProp<ViewStyle>;
        supportedOrientations?: (
            | "portrait"
            | "portrait-upside-down"
            | "landscape"
            | "landscape-left"
            | "landscape-right"
        )[];
        swipe?: SwipeNs.Config;
        visible?: boolean;
    }
    Index

    Properties

    animation?: AnimationNs.Config

    Animation configuration.

    {type: 'fade', duration: 350}
    
    backdrop?: BackdropNs.Config

    Backdrop configuration.

    {enabled: true, opacity: 0.6, backgroundColor: 'black'}
    
    children?: ReactNode

    Modal children.

    hardwareAccelerated?: boolean

    Controls whether to force hardware acceleration for the underlying window.

    navigationBarTranslucent?: boolean

    Should the navigation bar be translucent.

    true
    
    onBackdropPress?: () => void

    Callback fired when the backdrop is pressed.

    onBackPress?: () => void

    Callback fired when the back button is pressed.

    onHide?: () => void

    Callback fired when the modal is hidden.

    onOrientationChange?: (event: NativeSyntheticEvent<any>) => void

    The onOrientationChange callback is called when the orientation changes while the modal is being displayed. The orientation provided is only 'portrait' or 'landscape'. This callback is also called on initial render, regardless of the current orientation.

    onShow?: () => void

    Callback fired when the modal is shown.

    onSwipeCancel?: () => void

    Callback fired when a swipe gesture is canceled.

    onSwipeComplete?: () => void

    Callback fired when a swipe gesture completes successfully.

    statusBarTranslucent?: boolean

    Should the status bar be translucent.

    true
    
    style?: StyleProp<ViewStyle>

    Children container style.

    supportedOrientations?: (
        | "portrait"
        | "portrait-upside-down"
        | "landscape"
        | "landscape-left"
        | "landscape-right"
    )[]

    The supportedOrientations prop allows the modal to be rotated to any of the specified orientations. On iOS, the modal is still restricted by what's specified in your app's Info.plist's UISupportedInterfaceOrientations field.

    swipe?: SwipeNs.Config

    Swipe configuration.

    {enabled: false, directions: [], distance: 120, velocity: 800, closable: false}
    
    visible?: boolean

    The visible prop determines whether your modal is visible.

    false