import { Session } from "../_utils/_session"; export declare namespace Actions { export function register(): void; export interface IAction { namespace: ActionNamespace; session: Session; timeout: number; type: string; message: string; data: T; extra: any; } interface IBaseActionData { } export abstract class BaseAction implements IAction { data: T; message: string; namespace: ActionNamespace; session: Session; type: string; extra: any; timeout: number; } export class ActionData implements BaseAction { data: T; message: string; namespace: Actions.ActionNamespace; session: Session; type: string; extra: any; timeout: number; constructor(props: { data: T; message?: string; namespace?: Actions.ActionNamespace; type?: string; }); build(): string; } interface IRouteActionData extends IBaseActionData { route: string; } interface IDialogBody extends IBaseActionData { content: string; } interface ITextDialogBody extends IDialogBody { content: string; title?: string; } interface IWebDialogBody extends IDialogBody { content: string; } export class PushRoute extends ActionData { namespace: ActionNamespace; type: string; constructor(route: string); } export class PopRoute extends ActionData { namespace: ActionNamespace; type: string; constructor(route: string); } export function pushRoute(route: string): ActionData; export function popRoute(route: string): ActionData; export function showShortDialog(message: string): ActionData; export function showDetailedDialog(title: string, message: string): ActionData; export function showWebDialog(url: string): ActionData; export function showSnack(): ActionData<{ content: string; }>; export enum ActionNamespace { GENERAL = "GENERAL", MATERIAL = "MATERIAL", CUSTOM = "CUSTOM" } export {}; }