Skip to content

Commit

Permalink
chore: roll to microsoft#6152 (microsoft#172)
Browse files Browse the repository at this point in the history
  • Loading branch information
yury-s authored Apr 9, 2021
1 parent cd34392 commit b8c67dc
Show file tree
Hide file tree
Showing 11 changed files with 157 additions and 157 deletions.
6 changes: 3 additions & 3 deletions java/docs/api/class-browsertype.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public class Example {


- [BrowserType.connect(wsEndpoint[, options])](./api/class-browsertype.mdx#browsertypeconnectwsendpoint-options)
- [BrowserType.connectOverCDP(wsEndpoint[, options])](./api/class-browsertype.mdx#browsertypeconnectovercdpwsendpoint-options)
- [BrowserType.connectOverCDP(endpointURL[, options])](./api/class-browsertype.mdx#browsertypeconnectovercdpendpointurl-options)
- [BrowserType.executablePath()](./api/class-browsertype.mdx#browsertypeexecutablepath)
- [BrowserType.launch([options])](./api/class-browsertype.mdx#browsertypelaunchoptions)
- [BrowserType.launchPersistentContext(userDataDir[, options])](./api/class-browsertype.mdx#browsertypelaunchpersistentcontextuserdatadir-options)
Expand All @@ -41,8 +41,8 @@ public class Example {

This methods attaches Playwright to an existing browser instance.

## BrowserType.connectOverCDP(wsEndpoint[, options])
- `wsEndpoint` <[String]> A CDP websocket endpoint to connect to.
## BrowserType.connectOverCDP(endpointURL[, options])
- `endpointURL` <[String]> A CDP websocket endpoint or http url to connect to. For example `http://localhost:9222/` or `ws://127.0.0.1:9222/devtools/browser/387adf4c-243f-4051-a181-46798f4a46f4`.
- `options` <`BrowserType.ConnectOverCDPOptions`>
- `setSlowMo` <[double]> Slows down Playwright operations by the specified amount of milliseconds. Useful so that you can see what is going on. Defaults to 0.
- `setTimeout` <[double]> Maximum time in milliseconds to wait for the connection to be established. Defaults to `30000` (30 seconds). Pass `0` to disable timeout.
Expand Down
34 changes: 17 additions & 17 deletions java/docs/api/class-elementhandle.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -102,16 +102,16 @@ page.mouse().click(box.x + box.width / 2, box.y + box.height / 2);
- `setTimeout` <[double]> Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by using the [BrowserContext.setDefaultTimeout(timeout)](./api/class-browsercontext.mdx#browsercontextsetdefaulttimeouttimeout) or [Page.setDefaultTimeout(timeout)](./api/class-page.mdx#pagesetdefaulttimeouttimeout) methods.

This method checks the element by performing the following steps:
1. Ensure that element is a checkbox or a radio input. If not, this method rejects. If the element is already checked, this method returns immediately.
1. Ensure that element is a checkbox or a radio input. If not, this method throws. If the element is already checked, this method returns immediately.
1. Wait for [actionability](./actionability.mdx) checks on the element, unless `force` option is set.
1. Scroll the element into view if needed.
1. Use [Page.mouse()](./api/class-page.mdx#pagemouse) to click in the center of the element.
1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set.
1. Ensure that the element is now checked. If not, this method rejects.
1. Ensure that the element is now checked. If not, this method throws.

If the element is detached from the DOM at any moment during the action, this method rejects.
If the element is detached from the DOM at any moment during the action, this method throws.

When all steps combined have not finished during the specified `timeout`, this method rejects with a [TimeoutError]. Passing zero timeout disables this.
When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. Passing zero timeout disables this.

## ElementHandle.click([options])
- `options` <`ElementHandle.ClickOptions`>
Expand All @@ -132,9 +132,9 @@ This method clicks the element by performing the following steps:
1. Use [Page.mouse()](./api/class-page.mdx#pagemouse) to click in the center of the element, or the specified `position`.
1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set.

If the element is detached from the DOM at any moment during the action, this method rejects.
If the element is detached from the DOM at any moment during the action, this method throws.

When all steps combined have not finished during the specified `timeout`, this method rejects with a [TimeoutError]. Passing zero timeout disables this.
When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. Passing zero timeout disables this.

## ElementHandle.contentFrame()
- returns: <[null]|[Frame]>
Expand All @@ -157,11 +157,11 @@ This method double clicks the element by performing the following steps:
1. Wait for [actionability](./actionability.mdx) checks on the element, unless `force` option is set.
1. Scroll the element into view if needed.
1. Use [Page.mouse()](./api/class-page.mdx#pagemouse) to double click in the center of the element, or the specified `position`.
1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set. Note that if the first click of the `dblclick()` triggers a navigation event, this method will reject.
1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set. Note that if the first click of the `dblclick()` triggers a navigation event, this method will throw.

If the element is detached from the DOM at any moment during the action, this method rejects.
If the element is detached from the DOM at any moment during the action, this method throws.

When all steps combined have not finished during the specified `timeout`, this method rejects with a [TimeoutError]. Passing zero timeout disables this.
When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. Passing zero timeout disables this.

:::note
`elementHandle.dblclick()` dispatches two `click` events and a single `dblclick` event.
Expand Down Expand Up @@ -277,9 +277,9 @@ This method hovers over the element by performing the following steps:
1. Use [Page.mouse()](./api/class-page.mdx#pagemouse) to hover over the center of the element, or the specified `position`.
1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set.

If the element is detached from the DOM at any moment during the action, this method rejects.
If the element is detached from the DOM at any moment during the action, this method throws.

When all steps combined have not finished during the specified `timeout`, this method rejects with a [TimeoutError]. Passing zero timeout disables this.
When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. Passing zero timeout disables this.

## ElementHandle.innerHTML()
- returns: <[String]>
Expand Down Expand Up @@ -440,9 +440,9 @@ This method taps the element by performing the following steps:
1. Use [Page.touchscreen()](./api/class-page.mdx#pagetouchscreen) to tap the center of the element, or the specified `position`.
1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set.

If the element is detached from the DOM at any moment during the action, this method rejects.
If the element is detached from the DOM at any moment during the action, this method throws.

When all steps combined have not finished during the specified `timeout`, this method rejects with a [TimeoutError]. Passing zero timeout disables this.
When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. Passing zero timeout disables this.

:::note
`elementHandle.tap()` requires that the `hasTouch` option of the browser context be set to true.
Expand Down Expand Up @@ -484,16 +484,16 @@ elementHandle.press("Enter");
- `setTimeout` <[double]> Maximum time in milliseconds, defaults to 30 seconds, pass `0` to disable timeout. The default value can be changed by using the [BrowserContext.setDefaultTimeout(timeout)](./api/class-browsercontext.mdx#browsercontextsetdefaulttimeouttimeout) or [Page.setDefaultTimeout(timeout)](./api/class-page.mdx#pagesetdefaulttimeouttimeout) methods.

This method checks the element by performing the following steps:
1. Ensure that element is a checkbox or a radio input. If not, this method rejects. If the element is already unchecked, this method returns immediately.
1. Ensure that element is a checkbox or a radio input. If not, this method throws. If the element is already unchecked, this method returns immediately.
1. Wait for [actionability](./actionability.mdx) checks on the element, unless `force` option is set.
1. Scroll the element into view if needed.
1. Use [Page.mouse()](./api/class-page.mdx#pagemouse) to click in the center of the element.
1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set.
1. Ensure that the element is now unchecked. If not, this method rejects.
1. Ensure that the element is now unchecked. If not, this method throws.

If the element is detached from the DOM at any moment during the action, this method rejects.
If the element is detached from the DOM at any moment during the action, this method throws.

When all steps combined have not finished during the specified `timeout`, this method rejects with a [TimeoutError]. Passing zero timeout disables this.
When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. Passing zero timeout disables this.

## ElementHandle.waitForElementState(state[, options])
- `state` <`enum ElementState { VISIBLE, HIDDEN, STABLE, ENABLED, DISABLED, EDITABLE }`> A state to wait for, see below for more details.
Expand Down
Loading

0 comments on commit b8c67dc

Please sign in to comment.