Skip to content

Dialog

type Dialog = 
  | {
  mainFrame?: boolean;
  message: string;
  type: "alert" | "confirm";
  url: string;
}
  | {
  defaultValue: string | null;
  mainFrame?: boolean;
  message: string;
  type: "prompt";
  url: string;
};

A page's alert, confirm or prompt, for dialogs.

Union Members

Type Literal

{
  mainFrame?: boolean;
  message: string;
  type: "alert" | "confirm";
  url: string;
}

mainFrame?

mainFrame?: boolean;

iOS

Whether the main frame opened it.

message

message: string;

type

type: "alert" | "confirm";

url

url: string;

The URL of the frame that opened it.


Type Literal

{
  defaultValue: string | null;
  mainFrame?: boolean;
  message: string;
  type: "prompt";
  url: string;
}

defaultValue

defaultValue: string | null;

The prompt's default text.

mainFrame?

mainFrame?: boolean;

iOS

Whether the main frame opened it.

message

message: string;

type

type: "prompt";

url

url: string;

The URL of the frame that opened it.