module Playwright::Dialog
Overview
Dialog objects are dispatched by page via the page.on('dialog') event.
An example of using Dialog
class:
Defined in:
playwright/dialog.crInstance Method Summary
-
#accept(prompt_text : String | Nil) : Nil
Returns when the dialog has been accepted.
- #accept : Nil
-
#default_value : String
If dialog is prompt, returns default prompt value.
-
#dismiss : Nil
Returns when the dialog has been dismissed.
-
#message : String
A message displayed in the dialog.
-
#type : Type
Returns dialog's type, can be one of
alert
,beforeunload
,confirm
orprompt
.
Instance Method Detail
abstract
def default_value : String
#
If dialog is prompt, returns default prompt value. Otherwise, returns empty string.
Returns dialog's type, can be one of alert
, beforeunload
, confirm
or prompt
.