import { default as App } from './App'; export interface IToastOption { popType: 'toast'; type?: 'none' | 'success' | 'fail' | 'exception'; duration?: number; content?: string; complete?: () => void; isBlock?: boolean; } export declare type InputToastOption = Omit; export interface IAlertOption { popType: 'alert'; title?: string; content?: string; buttonText?: string; complete?: () => void; isBlock?: boolean; } export declare type InputAlertOption = Omit; export interface IPromptOption { popType: 'prompt'; title?: string; content?: string; placeholder?: string; align?: 'left' | 'center' | 'right'; okButtonText?: string; cancelButtonText?: string; complete?: (result: { ok?: boolean; cancel?: boolean; inputValue?: string; }) => void; isBlock?: boolean; } export declare type InputPromptOption = Omit; export interface IConfirmOption { popType: 'confirm'; content?: string; title?: string; okButtonText?: string; cancelButtonText?: string; complete?: (result: { ok?: boolean; cancel?: boolean; }) => void; isBlock?: boolean; } export declare type InputConfirmOption = Omit; export declare type FeedbackOption = IToastOption | IAlertOption | IConfirmOption | IPromptOption; export declare type View = { showToast: typeof my.showToast; hideToast: typeof my.hideToast; alert: typeof my.alert; prompt: typeof my.prompt; confirm: typeof my.confirm; }; export declare class Feedback { private stopWatchFeedbackQueue; feedbackQueue: FeedbackOption[]; private view?; private isFeedbackConsuming; private shouldStopIteration; private consumeFeedback; private startWatchFeedbackQueue; init(): void; setView(view: Partial): void; destroy(): void; } export default function useFeedback(passInApp?: App): { setView(options: Parameters[0]): void; addToast(option: InputToastOption): void; addAlert(option: InputAlertOption): void; addConfirm(option: InputConfirmOption): void; addPrompt(option: InputPromptOption): void; };