mirror of
https://github.com/puppeteer/puppeteer
synced 2024-06-14 14:02:48 +00:00
Plumb default prompt value to the dialog (#243)
This patch: - plumbs default prompt value to the dialog - enables one more phantom test
This commit is contained in:
@@ -76,6 +76,7 @@
|
||||
+ [tracing.stop()](#tracingstop)
|
||||
* [class: Dialog](#class-dialog)
|
||||
+ [dialog.accept([promptText])](#dialogacceptprompttext)
|
||||
+ [dialog.defaultValue()](#dialogdefaultvalue)
|
||||
+ [dialog.dismiss()](#dialogdismiss)
|
||||
+ [dialog.message()](#dialogmessage)
|
||||
+ [dialog.type](#dialogtype)
|
||||
@@ -901,6 +902,9 @@ browser.newPage().then(async page => {
|
||||
- `promptText` <[string]> A text to enter in prompt. Does not cause any effects if the dialog's `type` is not prompt.
|
||||
- returns: <[Promise]> Promise which resolves when the dialog has being accepted.
|
||||
|
||||
#### dialog.defaultValue()
|
||||
- returns: <[string]> If dialog is prompt, returns default prompt value. Otherwise, returns empty string.
|
||||
|
||||
#### dialog.dismiss()
|
||||
- returns: <[Promise]> Promise which resolves when the dialog has being dismissed.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user