import React from 'react'; import { StyleProp, TextStyle, ViewStyle } from 'react-native'; import { ModalStyle } from './style/index'; export interface ModalPropsType { animateAppear?: boolean; animationDuration?: number; animated?: boolean; animationType?: 'none' | 'fade' | 'slide-up' | 'slide-down' | 'slide'; bodyStyle?: StyleProp; children?: React.ReactNode; closable?: boolean; footer?: Action[]; locale?: object; maskClosable?: boolean; modalType?: 'portal' | 'modal' | 'view'; onAnimationEnd?: (visible: boolean) => void; onClose?: () => void; operation?: boolean; onRequestClose?: CallbackOnBackHandler; popup?: boolean; style?: StyleProp; styles?: Partial; title?: React.ReactNode; transparent?: boolean; visible: boolean; } export interface Action { text: string; onPress?: () => void | Promise; style?: T | string; } export type Callback = (valueOrLogin: string, password?: string) => void; export type CallbackOrActions = Callback | Action[]; export type CallbackOnBackHandler = () => boolean;