diff --git a/packages/playwright-core/types/types.d.ts b/packages/playwright-core/types/types.d.ts index b8d4dba399..e577a3ad20 100644 --- a/packages/playwright-core/types/types.d.ts +++ b/packages/playwright-core/types/types.d.ts @@ -31,9 +31,9 @@ type ElementHandleWaitForSelectorOptionsNotHidden = ElementHandleWaitForSelector /** * - extends: [EventEmitter] * - * Page provides methods to interact with a single tab in a [Browser], or an - * [extension background page](https://developer.chrome.com/extensions/background_pages) in Chromium. One [Browser] - * instance might have multiple [Page] instances. + * Page provides methods to interact with a single tab in a {@link Browser}, or an + * [extension background page](https://developer.chrome.com/extensions/background_pages) in Chromium. One {@link + * Browser} instance might have multiple {@link Page} instances. * * This example creates a page, navigates it to a URL, and then saves a screenshot: * @@ -107,7 +107,7 @@ export interface Page { * console.log(await page.evaluate(`1 + ${x}`)); // prints "11" * ``` * - * [ElementHandle] instances can be passed as an argument to the + * {@link ElementHandle} instances can be passed as an argument to the * [page.evaluate(pageFunction[, arg])](https://playwright.dev/docs/api/class-page#page-evaluate): * * ```js @@ -154,7 +154,7 @@ export interface Page { * console.log(await page.evaluate(`1 + ${x}`)); // prints "11" * ``` * - * [ElementHandle] instances can be passed as an argument to the + * {@link ElementHandle} instances can be passed as an argument to the * [page.evaluate(pageFunction[, arg])](https://playwright.dev/docs/api/class-page#page-evaluate): * * ```js @@ -169,13 +169,13 @@ export interface Page { evaluate(pageFunction: PageFunction, arg?: any): Promise; /** - * Returns the value of the `pageFunction` invocation as a [JSHandle]. + * Returns the value of the `pageFunction` invocation as a {@link JSHandle}. * * The only difference between * [page.evaluate(pageFunction[, arg])](https://playwright.dev/docs/api/class-page#page-evaluate) and * [page.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-page#page-evaluate-handle) is that * [page.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-page#page-evaluate-handle) returns - * [JSHandle]. + * {@link JSHandle}. * * If the function passed to the * [page.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-page#page-evaluate-handle) returns @@ -196,7 +196,7 @@ export interface Page { * const aHandle = await page.evaluateHandle('document'); // Handle for the 'document' * ``` * - * [JSHandle] instances can be passed as an argument to the + * {@link JSHandle} instances can be passed as an argument to the * [page.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-page#page-evaluate-handle): * * ```js @@ -211,13 +211,13 @@ export interface Page { */ evaluateHandle(pageFunction: PageFunction, arg: Arg): Promise>; /** - * Returns the value of the `pageFunction` invocation as a [JSHandle]. + * Returns the value of the `pageFunction` invocation as a {@link JSHandle}. * * The only difference between * [page.evaluate(pageFunction[, arg])](https://playwright.dev/docs/api/class-page#page-evaluate) and * [page.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-page#page-evaluate-handle) is that * [page.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-page#page-evaluate-handle) returns - * [JSHandle]. + * {@link JSHandle}. * * If the function passed to the * [page.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-page#page-evaluate-handle) returns @@ -238,7 +238,7 @@ export interface Page { * const aHandle = await page.evaluateHandle('document'); // Handle for the 'document' * ``` * - * [JSHandle] instances can be passed as an argument to the + * {@link JSHandle} instances can be passed as an argument to the * [page.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-page#page-evaluate-handle): * * ```js @@ -337,7 +337,7 @@ export interface Page { * **NOTE** This method does not wait for the element to pass actionability checks and therefore can lead to the flaky tests. * Use * [locator.evaluate(pageFunction[, arg, options])](https://playwright.dev/docs/api/class-locator#locator-evaluate), - * other [Locator] helper methods or web-first assertions instead. + * other {@link Locator} helper methods or web-first assertions instead. * * The method finds an element matching the specified selector within the page and passes it as a first argument to * `pageFunction`. If no elements match the selector, the method throws an error. Returns the value of `pageFunction`. @@ -366,7 +366,7 @@ export interface Page { * **NOTE** This method does not wait for the element to pass actionability checks and therefore can lead to the flaky tests. * Use * [locator.evaluate(pageFunction[, arg, options])](https://playwright.dev/docs/api/class-locator#locator-evaluate), - * other [Locator] helper methods or web-first assertions instead. + * other {@link Locator} helper methods or web-first assertions instead. * * The method finds an element matching the specified selector within the page and passes it as a first argument to * `pageFunction`. If no elements match the selector, the method throws an error. Returns the value of `pageFunction`. @@ -395,7 +395,7 @@ export interface Page { * **NOTE** This method does not wait for the element to pass actionability checks and therefore can lead to the flaky tests. * Use * [locator.evaluate(pageFunction[, arg, options])](https://playwright.dev/docs/api/class-locator#locator-evaluate), - * other [Locator] helper methods or web-first assertions instead. + * other {@link Locator} helper methods or web-first assertions instead. * * The method finds an element matching the specified selector within the page and passes it as a first argument to * `pageFunction`. If no elements match the selector, the method throws an error. Returns the value of `pageFunction`. @@ -424,7 +424,7 @@ export interface Page { * **NOTE** This method does not wait for the element to pass actionability checks and therefore can lead to the flaky tests. * Use * [locator.evaluate(pageFunction[, arg, options])](https://playwright.dev/docs/api/class-locator#locator-evaluate), - * other [Locator] helper methods or web-first assertions instead. + * other {@link Locator} helper methods or web-first assertions instead. * * The method finds an element matching the specified selector within the page and passes it as a first argument to * `pageFunction`. If no elements match the selector, the method throws an error. Returns the value of `pageFunction`. @@ -453,7 +453,7 @@ export interface Page { /** * **NOTE** In most cases, * [locator.evaluateAll(pageFunction[, arg])](https://playwright.dev/docs/api/class-locator#locator-evaluate-all), - * other [Locator] helper methods and web-first assertions do a better job. + * other {@link Locator} helper methods and web-first assertions do a better job. * * The method finds all elements matching the specified selector within the page and passes an array of matched * elements as a first argument to `pageFunction`. Returns the result of `pageFunction` invocation. @@ -476,7 +476,7 @@ export interface Page { /** * **NOTE** In most cases, * [locator.evaluateAll(pageFunction[, arg])](https://playwright.dev/docs/api/class-locator#locator-evaluate-all), - * other [Locator] helper methods and web-first assertions do a better job. + * other {@link Locator} helper methods and web-first assertions do a better job. * * The method finds all elements matching the specified selector within the page and passes an array of matched * elements as a first argument to `pageFunction`. Returns the result of `pageFunction` invocation. @@ -499,7 +499,7 @@ export interface Page { /** * **NOTE** In most cases, * [locator.evaluateAll(pageFunction[, arg])](https://playwright.dev/docs/api/class-locator#locator-evaluate-all), - * other [Locator] helper methods and web-first assertions do a better job. + * other {@link Locator} helper methods and web-first assertions do a better job. * * The method finds all elements matching the specified selector within the page and passes an array of matched * elements as a first argument to `pageFunction`. Returns the result of `pageFunction` invocation. @@ -522,7 +522,7 @@ export interface Page { /** * **NOTE** In most cases, * [locator.evaluateAll(pageFunction[, arg])](https://playwright.dev/docs/api/class-locator#locator-evaluate-all), - * other [Locator] helper methods and web-first assertions do a better job. + * other {@link Locator} helper methods and web-first assertions do a better job. * * The method finds all elements matching the specified selector within the page and passes an array of matched * elements as a first argument to `pageFunction`. Returns the result of `pageFunction` invocation. @@ -624,7 +624,7 @@ export interface Page { * Returns when element specified by selector satisfies `state` option. Returns `null` if waiting for `hidden` or * `detached`. * - * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using [Locator] + * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using {@link Locator} * objects and web-first assertions makes the code wait-for-selector-free. * * Wait for the `selector` to satisfy `state` option (either appear/disappear from dom, or become visible/hidden). If @@ -662,7 +662,7 @@ export interface Page { * Returns when element specified by selector satisfies `state` option. Returns `null` if waiting for `hidden` or * `detached`. * - * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using [Locator] + * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using {@link Locator} * objects and web-first assertions makes the code wait-for-selector-free. * * Wait for the `selector` to satisfy `state` option (either appear/disappear from dom, or become visible/hidden). If @@ -700,7 +700,7 @@ export interface Page { * Returns when element specified by selector satisfies `state` option. Returns `null` if waiting for `hidden` or * `detached`. * - * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using [Locator] + * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using {@link Locator} * objects and web-first assertions makes the code wait-for-selector-free. * * Wait for the `selector` to satisfy `state` option (either appear/disappear from dom, or become visible/hidden). If @@ -738,7 +738,7 @@ export interface Page { * Returns when element specified by selector satisfies `state` option. Returns `null` if waiting for `hidden` or * `detached`. * - * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using [Locator] + * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using {@link Locator} * objects and web-first assertions makes the code wait-for-selector-free. * * Wait for the `selector` to satisfy `state` option (either appear/disappear from dom, or become visible/hidden). If @@ -900,7 +900,7 @@ export interface Page { * Emitted when JavaScript within the page calls one of console API methods, e.g. `console.log` or `console.dir`. Also * emitted if the page throws an error or a warning. * - * The arguments passed into `console.log` are available on the [ConsoleMessage] event handler argument. + * The arguments passed into `console.log` are available on the {@link ConsoleMessage} event handler argument. * * **Usage** * @@ -966,7 +966,7 @@ export interface Page { /** * Emitted when attachment download started. User can access basic file operations on downloaded content via the - * passed [Download] instance. + * passed {@link Download} instance. */ on(event: 'download', listener: (download: Download) => void): this; @@ -1082,7 +1082,7 @@ export interface Page { on(event: 'response', listener: (response: Response) => void): this; /** - * Emitted when [WebSocket] request is sent. + * Emitted when {@link WebSocket} request is sent. */ on(event: 'websocket', listener: (webSocket: WebSocket) => void): this; @@ -1196,7 +1196,7 @@ export interface Page { * Emitted when JavaScript within the page calls one of console API methods, e.g. `console.log` or `console.dir`. Also * emitted if the page throws an error or a warning. * - * The arguments passed into `console.log` are available on the [ConsoleMessage] event handler argument. + * The arguments passed into `console.log` are available on the {@link ConsoleMessage} event handler argument. * * **Usage** * @@ -1262,7 +1262,7 @@ export interface Page { /** * Emitted when attachment download started. User can access basic file operations on downloaded content via the - * passed [Download] instance. + * passed {@link Download} instance. */ addListener(event: 'download', listener: (download: Download) => void): this; @@ -1378,7 +1378,7 @@ export interface Page { addListener(event: 'response', listener: (response: Response) => void): this; /** - * Emitted when [WebSocket] request is sent. + * Emitted when {@link WebSocket} request is sent. */ addListener(event: 'websocket', listener: (webSocket: WebSocket) => void): this; @@ -1587,7 +1587,7 @@ export interface Page { * Emitted when JavaScript within the page calls one of console API methods, e.g. `console.log` or `console.dir`. Also * emitted if the page throws an error or a warning. * - * The arguments passed into `console.log` are available on the [ConsoleMessage] event handler argument. + * The arguments passed into `console.log` are available on the {@link ConsoleMessage} event handler argument. * * **Usage** * @@ -1653,7 +1653,7 @@ export interface Page { /** * Emitted when attachment download started. User can access basic file operations on downloaded content via the - * passed [Download] instance. + * passed {@link Download} instance. */ prependListener(event: 'download', listener: (download: Download) => void): this; @@ -1769,7 +1769,7 @@ export interface Page { prependListener(event: 'response', listener: (response: Response) => void): this; /** - * Emitted when [WebSocket] request is sent. + * Emitted when {@link WebSocket} request is sent. */ prependListener(event: 'websocket', listener: (webSocket: WebSocket) => void): this; @@ -1852,8 +1852,8 @@ export interface Page { * 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 throws. * - * When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * @param selector A selector to search for an element. If there are multiple elements satisfying the selector, the first will be * used. * @param options @@ -1915,8 +1915,8 @@ export interface Page { * element, or the specified `position`. * 1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set. * - * When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * @param selector A selector to search for an element. If there are multiple elements satisfying the selector, the first will be * used. * @param options @@ -2028,8 +2028,8 @@ export interface Page { * 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. * - * When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * * **NOTE** `page.dblclick()` dispatches two `click` events and a single `dblclick` event. * @param selector A selector to search for an element. If there are multiple elements satisfying the selector, the first will be @@ -2921,8 +2921,8 @@ export interface Page { * element, or the specified `position`. * 1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set. * - * When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * @param selector A selector to search for an element. If there are multiple elements satisfying the selector, the first will be * used. * @param options @@ -3228,7 +3228,8 @@ export interface Page { * Matches elements containing an element that matches an inner locator. Inner locator is queried against the outer * one. For example, `article` that has `text=Playwright` matches `
Playwright
`. * - * Note that outer and inner locators must belong to the same frame. Inner locator must not contain [FrameLocator]s. + * Note that outer and inner locators must belong to the same frame. Inner locator must not contain {@link + * FrameLocator}s. */ has?: Locator; @@ -3236,7 +3237,8 @@ export interface Page { * Matches elements that do not contain an element that matches an inner locator. Inner locator is queried against the * outer one. For example, `article` that does not have `div` matches `
Playwright
`. * - * Note that outer and inner locators must belong to the same frame. Inner locator must not contain [FrameLocator]s. + * Note that outer and inner locators must belong to the same frame. Inner locator must not contain {@link + * FrameLocator}s. */ hasNot?: Locator; @@ -3757,8 +3759,8 @@ export interface Page { * 1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set. * 1. Ensure that the element is now checked or unchecked. If not, this method throws. * - * When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * @param selector A selector to search for an element. If there are multiple elements satisfying the selector, the first will be * used. * @param checked Whether to check or uncheck the checkbox. @@ -3998,8 +4000,8 @@ export interface Page { * element, or the specified `position`. * 1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set. * - * When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * * **NOTE** [page.tap(selector[, options])](https://playwright.dev/docs/api/class-page#page-tap) the method will throw * if `hasTouch` option of the browser context is false. @@ -4155,8 +4157,8 @@ export interface Page { * 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 throws. * - * When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * @param selector A selector to search for an element. If there are multiple elements satisfying the selector, the first will be * used. * @param options @@ -4242,7 +4244,7 @@ export interface Page { * Emitted when JavaScript within the page calls one of console API methods, e.g. `console.log` or `console.dir`. Also * emitted if the page throws an error or a warning. * - * The arguments passed into `console.log` are available on the [ConsoleMessage] event handler argument. + * The arguments passed into `console.log` are available on the {@link ConsoleMessage} event handler argument. * * **Usage** * @@ -4308,7 +4310,7 @@ export interface Page { /** * Emitted when attachment download started. User can access basic file operations on downloaded content via the - * passed [Download] instance. + * passed {@link Download} instance. */ waitForEvent(event: 'download', optionsOrPredicate?: { predicate?: (download: Download) => boolean | Promise, timeout?: number } | ((download: Download) => boolean | Promise)): Promise; @@ -4424,7 +4426,7 @@ export interface Page { waitForEvent(event: 'response', optionsOrPredicate?: { predicate?: (response: Response) => boolean | Promise, timeout?: number } | ((response: Response) => boolean | Promise)): Promise; /** - * Emitted when [WebSocket] request is sent. + * Emitted when {@link WebSocket} request is sent. */ waitForEvent(event: 'websocket', optionsOrPredicate?: { predicate?: (webSocket: WebSocket) => boolean | Promise, timeout?: number } | ((webSocket: WebSocket) => boolean | Promise)): Promise; @@ -4549,7 +4551,7 @@ export interface Page { * const request = await requestPromise; * ``` * - * @param urlOrPredicate Request URL string, regex or predicate receiving [Request] object. + * @param urlOrPredicate Request URL string, regex or predicate receiving {@link Request} object. * @param options */ waitForRequest(urlOrPredicate: string|RegExp|((request: Request) => boolean|Promise), options?: { @@ -4579,8 +4581,8 @@ export interface Page { * const response = await responsePromise; * ``` * - * @param urlOrPredicate Request URL string, regex or predicate receiving [Response] object. When a `baseURL` via the context options was - * provided and the passed URL is a path, it gets merged via the + * @param urlOrPredicate Request URL string, regex or predicate receiving {@link Response} object. When a `baseURL` via the context options + * was provided and the passed URL is a path, it gets merged via the * [`new URL()`](https://developer.mozilla.org/en-US/docs/Web/API/URL/URL) constructor. * @param options */ @@ -4595,8 +4597,8 @@ export interface Page { }): Promise; /** - * **NOTE** Never wait for timeout in production. Tests that wait for time are inherently flaky. Use [Locator] actions and web - * assertions that wait automatically. + * **NOTE** Never wait for timeout in production. Tests that wait for time are inherently flaky. Use {@link Locator} actions + * and web assertions that wait automatically. * * Waits for the given `timeout` in milliseconds. * @@ -4670,7 +4672,7 @@ export interface Page { /** * **NOTE** Only available for Chromium atm. * - * Browser-specific Coverage implementation. See [Coverage] for more details. + * Browser-specific Coverage implementation. See {@link Coverage} for more details. */ coverage: Coverage; @@ -4695,7 +4697,7 @@ export interface Page { * [page.mainFrame()](https://playwright.dev/docs/api/class-page#page-main-frame) and * [frame.childFrames()](https://playwright.dev/docs/api/class-frame#frame-child-frames) methods. * - * [Frame] object's lifecycle is controlled by three events, dispatched on the page object: + * {@link Frame} object's lifecycle is controlled by three events, dispatched on the page object: * - [page.on('frameattached')](https://playwright.dev/docs/api/class-page#page-event-frame-attached) - fired when * the frame gets attached to the page. A Frame can be attached to the page only once. * - [page.on('framenavigated')](https://playwright.dev/docs/api/class-page#page-event-frame-navigated) - fired when @@ -4756,7 +4758,7 @@ export interface Frame { * console.log(await frame.evaluate('1 + 2')); // prints "3" * ``` * - * [ElementHandle] instances can be passed as an argument to the + * {@link ElementHandle} instances can be passed as an argument to the * [frame.evaluate(pageFunction[, arg])](https://playwright.dev/docs/api/class-frame#frame-evaluate): * * ```js @@ -4799,7 +4801,7 @@ export interface Frame { * console.log(await frame.evaluate('1 + 2')); // prints "3" * ``` * - * [ElementHandle] instances can be passed as an argument to the + * {@link ElementHandle} instances can be passed as an argument to the * [frame.evaluate(pageFunction[, arg])](https://playwright.dev/docs/api/class-frame#frame-evaluate): * * ```js @@ -4814,13 +4816,13 @@ export interface Frame { evaluate(pageFunction: PageFunction, arg?: any): Promise; /** - * Returns the return value of `pageFunction` as a [JSHandle]. + * Returns the return value of `pageFunction` as a {@link JSHandle}. * * The only difference between * [frame.evaluate(pageFunction[, arg])](https://playwright.dev/docs/api/class-frame#frame-evaluate) and * [frame.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-frame#frame-evaluate-handle) is * that [frame.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-frame#frame-evaluate-handle) - * returns [JSHandle]. + * returns {@link JSHandle}. * * If the function, passed to the * [frame.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-frame#frame-evaluate-handle), @@ -4841,7 +4843,7 @@ export interface Frame { * const aHandle = await frame.evaluateHandle('document'); // Handle for the 'document'. * ``` * - * [JSHandle] instances can be passed as an argument to the + * {@link JSHandle} instances can be passed as an argument to the * [frame.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-frame#frame-evaluate-handle): * * ```js @@ -4856,13 +4858,13 @@ export interface Frame { */ evaluateHandle(pageFunction: PageFunction, arg: Arg): Promise>; /** - * Returns the return value of `pageFunction` as a [JSHandle]. + * Returns the return value of `pageFunction` as a {@link JSHandle}. * * The only difference between * [frame.evaluate(pageFunction[, arg])](https://playwright.dev/docs/api/class-frame#frame-evaluate) and * [frame.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-frame#frame-evaluate-handle) is * that [frame.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-frame#frame-evaluate-handle) - * returns [JSHandle]. + * returns {@link JSHandle}. * * If the function, passed to the * [frame.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-frame#frame-evaluate-handle), @@ -4883,7 +4885,7 @@ export interface Frame { * const aHandle = await frame.evaluateHandle('document'); // Handle for the 'document'. * ``` * - * [JSHandle] instances can be passed as an argument to the + * {@link JSHandle} instances can be passed as an argument to the * [frame.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-frame#frame-evaluate-handle): * * ```js @@ -4904,7 +4906,8 @@ export interface Frame { * * Returns the ElementHandle pointing to the frame element. * - * **NOTE** The use of [ElementHandle] is discouraged, use [Locator] objects and web-first assertions instead. + * **NOTE** The use of {@link ElementHandle} is discouraged, use {@link Locator} objects and web-first assertions + * instead. * * The method finds an element matching the specified selector within the frame. If no elements match the selector, * returns `null`. @@ -4918,7 +4921,8 @@ export interface Frame { * * Returns the ElementHandle pointing to the frame element. * - * **NOTE** The use of [ElementHandle] is discouraged, use [Locator] objects and web-first assertions instead. + * **NOTE** The use of {@link ElementHandle} is discouraged, use {@link Locator} objects and web-first assertions + * instead. * * The method finds an element matching the specified selector within the frame. If no elements match the selector, * returns `null`. @@ -4933,7 +4937,7 @@ export interface Frame { * * Returns the ElementHandles pointing to the frame elements. * - * **NOTE** The use of [ElementHandle] is discouraged, use [Locator] objects instead. + * **NOTE** The use of {@link ElementHandle} is discouraged, use {@link Locator} objects instead. * * The method finds all elements matching the specified selector within the frame. If no elements match the selector, * returns empty array. @@ -4946,7 +4950,7 @@ export interface Frame { * * Returns the ElementHandles pointing to the frame elements. * - * **NOTE** The use of [ElementHandle] is discouraged, use [Locator] objects instead. + * **NOTE** The use of {@link ElementHandle} is discouraged, use {@link Locator} objects instead. * * The method finds all elements matching the specified selector within the frame. If no elements match the selector, * returns empty array. @@ -4958,7 +4962,7 @@ export interface Frame { * **NOTE** This method does not wait for the element to pass the actionability checks and therefore can lead to the flaky * tests. Use * [locator.evaluate(pageFunction[, arg, options])](https://playwright.dev/docs/api/class-locator#locator-evaluate), - * other [Locator] helper methods or web-first assertions instead. + * other {@link Locator} helper methods or web-first assertions instead. * * Returns the return value of `pageFunction`. * @@ -4987,7 +4991,7 @@ export interface Frame { * **NOTE** This method does not wait for the element to pass the actionability checks and therefore can lead to the flaky * tests. Use * [locator.evaluate(pageFunction[, arg, options])](https://playwright.dev/docs/api/class-locator#locator-evaluate), - * other [Locator] helper methods or web-first assertions instead. + * other {@link Locator} helper methods or web-first assertions instead. * * Returns the return value of `pageFunction`. * @@ -5016,7 +5020,7 @@ export interface Frame { * **NOTE** This method does not wait for the element to pass the actionability checks and therefore can lead to the flaky * tests. Use * [locator.evaluate(pageFunction[, arg, options])](https://playwright.dev/docs/api/class-locator#locator-evaluate), - * other [Locator] helper methods or web-first assertions instead. + * other {@link Locator} helper methods or web-first assertions instead. * * Returns the return value of `pageFunction`. * @@ -5045,7 +5049,7 @@ export interface Frame { * **NOTE** This method does not wait for the element to pass the actionability checks and therefore can lead to the flaky * tests. Use * [locator.evaluate(pageFunction[, arg, options])](https://playwright.dev/docs/api/class-locator#locator-evaluate), - * other [Locator] helper methods or web-first assertions instead. + * other {@link Locator} helper methods or web-first assertions instead. * * Returns the return value of `pageFunction`. * @@ -5074,7 +5078,7 @@ export interface Frame { /** * **NOTE** In most cases, * [locator.evaluateAll(pageFunction[, arg])](https://playwright.dev/docs/api/class-locator#locator-evaluate-all), - * other [Locator] helper methods and web-first assertions do a better job. + * other {@link Locator} helper methods and web-first assertions do a better job. * * Returns the return value of `pageFunction`. * @@ -5099,7 +5103,7 @@ export interface Frame { /** * **NOTE** In most cases, * [locator.evaluateAll(pageFunction[, arg])](https://playwright.dev/docs/api/class-locator#locator-evaluate-all), - * other [Locator] helper methods and web-first assertions do a better job. + * other {@link Locator} helper methods and web-first assertions do a better job. * * Returns the return value of `pageFunction`. * @@ -5124,7 +5128,7 @@ export interface Frame { /** * **NOTE** In most cases, * [locator.evaluateAll(pageFunction[, arg])](https://playwright.dev/docs/api/class-locator#locator-evaluate-all), - * other [Locator] helper methods and web-first assertions do a better job. + * other {@link Locator} helper methods and web-first assertions do a better job. * * Returns the return value of `pageFunction`. * @@ -5149,7 +5153,7 @@ export interface Frame { /** * **NOTE** In most cases, * [locator.evaluateAll(pageFunction[, arg])](https://playwright.dev/docs/api/class-locator#locator-evaluate-all), - * other [Locator] helper methods and web-first assertions do a better job. + * other {@link Locator} helper methods and web-first assertions do a better job. * * Returns the return value of `pageFunction`. * @@ -5249,7 +5253,7 @@ export interface Frame { * Returns when element specified by selector satisfies `state` option. Returns `null` if waiting for `hidden` or * `detached`. * - * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using [Locator] + * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using {@link Locator} * objects and web-first assertions make the code wait-for-selector-free. * * Wait for the `selector` to satisfy `state` option (either appear/disappear from dom, or become visible/hidden). If @@ -5287,7 +5291,7 @@ export interface Frame { * Returns when element specified by selector satisfies `state` option. Returns `null` if waiting for `hidden` or * `detached`. * - * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using [Locator] + * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using {@link Locator} * objects and web-first assertions make the code wait-for-selector-free. * * Wait for the `selector` to satisfy `state` option (either appear/disappear from dom, or become visible/hidden). If @@ -5325,7 +5329,7 @@ export interface Frame { * Returns when element specified by selector satisfies `state` option. Returns `null` if waiting for `hidden` or * `detached`. * - * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using [Locator] + * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using {@link Locator} * objects and web-first assertions make the code wait-for-selector-free. * * Wait for the `selector` to satisfy `state` option (either appear/disappear from dom, or become visible/hidden). If @@ -5363,7 +5367,7 @@ export interface Frame { * Returns when element specified by selector satisfies `state` option. Returns `null` if waiting for `hidden` or * `detached`. * - * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using [Locator] + * **NOTE** Playwright automatically waits for element to be ready before performing an action. Using {@link Locator} * objects and web-first assertions make the code wait-for-selector-free. * * Wait for the `selector` to satisfy `state` option (either appear/disappear from dom, or become visible/hidden). If @@ -5464,8 +5468,8 @@ export interface Frame { * 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 throws. * - * When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * @param selector A selector to search for an element. If there are multiple elements satisfying the selector, the first will be * used. * @param options @@ -5529,8 +5533,8 @@ export interface Frame { * element, or the specified `position`. * 1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set. * - * When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * @param selector A selector to search for an element. If there are multiple elements satisfying the selector, the first will be * used. * @param options @@ -5619,8 +5623,8 @@ export interface Frame { * 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. * - * When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * * **NOTE** `frame.dblclick()` dispatches two `click` events and a single `dblclick` event. * @param selector A selector to search for an element. If there are multiple elements satisfying the selector, the first will be @@ -6317,8 +6321,8 @@ export interface Frame { * element, or the specified `position`. * 1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set. * - * When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * @param selector A selector to search for an element. If there are multiple elements satisfying the selector, the first will be * used. * @param options @@ -6623,7 +6627,8 @@ export interface Frame { * Matches elements containing an element that matches an inner locator. Inner locator is queried against the outer * one. For example, `article` that has `text=Playwright` matches `
Playwright
`. * - * Note that outer and inner locators must belong to the same frame. Inner locator must not contain [FrameLocator]s. + * Note that outer and inner locators must belong to the same frame. Inner locator must not contain {@link + * FrameLocator}s. */ has?: Locator; @@ -6631,7 +6636,8 @@ export interface Frame { * Matches elements that do not contain an element that matches an inner locator. Inner locator is queried against the * outer one. For example, `article` that does not have `div` matches `
Playwright
`. * - * Note that outer and inner locators must belong to the same frame. Inner locator must not contain [FrameLocator]s. + * Note that outer and inner locators must belong to the same frame. Inner locator must not contain {@link + * FrameLocator}s. */ hasNot?: Locator; @@ -6835,8 +6841,8 @@ export interface Frame { * 1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set. * 1. Ensure that the element is now checked or unchecked. If not, this method throws. * - * When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * @param selector A selector to search for an element. If there are multiple elements satisfying the selector, the first will be * used. * @param checked Whether to check or uncheck the checkbox. @@ -6996,8 +7002,8 @@ export interface Frame { * element, or the specified `position`. * 1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set. * - * When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * * **NOTE** `frame.tap()` requires that the `hasTouch` option of the browser context be set to true. * @param selector A selector to search for an element. If there are multiple elements satisfying the selector, the first will be @@ -7152,8 +7158,8 @@ export interface Frame { * 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 throws. * - * When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * @param selector A selector to search for an element. If there are multiple elements satisfying the selector, the first will be * used. * @param options @@ -7295,8 +7301,8 @@ export interface Frame { }): Promise; /** - * **NOTE** Never wait for timeout in production. Tests that wait for time are inherently flaky. Use [Locator] actions and web - * assertions that wait automatically. + * **NOTE** Never wait for timeout in production. Tests that wait for time are inherently flaky. Use {@link Locator} actions + * and web assertions that wait automatically. * * Waits for the given `timeout` in milliseconds. * @@ -7539,7 +7545,8 @@ export interface BrowserContext { * Emitted when JavaScript within the page calls one of console API methods, e.g. `console.log` or `console.dir`. Also * emitted if the page throws an error or a warning. * - * The arguments passed into `console.log` and the page are available on the [ConsoleMessage] event handler argument. + * The arguments passed into `console.log` and the page are available on the {@link ConsoleMessage} event handler + * argument. * * **Usage** * @@ -7719,7 +7726,8 @@ export interface BrowserContext { * Emitted when JavaScript within the page calls one of console API methods, e.g. `console.log` or `console.dir`. Also * emitted if the page throws an error or a warning. * - * The arguments passed into `console.log` and the page are available on the [ConsoleMessage] event handler argument. + * The arguments passed into `console.log` and the page are available on the {@link ConsoleMessage} event handler + * argument. * * **Usage** * @@ -7949,7 +7957,8 @@ export interface BrowserContext { * Emitted when JavaScript within the page calls one of console API methods, e.g. `console.log` or `console.dir`. Also * emitted if the page throws an error or a warning. * - * The arguments passed into `console.log` and the page are available on the [ConsoleMessage] event handler argument. + * The arguments passed into `console.log` and the page are available on the {@link ConsoleMessage} event handler + * argument. * * **Usage** * @@ -8532,7 +8541,8 @@ export interface BrowserContext { * Emitted when JavaScript within the page calls one of console API methods, e.g. `console.log` or `console.dir`. Also * emitted if the page throws an error or a warning. * - * The arguments passed into `console.log` and the page are available on the [ConsoleMessage] event handler argument. + * The arguments passed into `console.log` and the page are available on the {@link ConsoleMessage} event handler + * argument. * * **Usage** * @@ -8705,14 +8715,14 @@ export interface Worker { evaluate(pageFunction: PageFunction, arg?: any): Promise; /** - * Returns the return value of `pageFunction` as a [JSHandle]. + * Returns the return value of `pageFunction` as a {@link JSHandle}. * * The only difference between * [worker.evaluate(pageFunction[, arg])](https://playwright.dev/docs/api/class-worker#worker-evaluate) and * [worker.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-worker#worker-evaluate-handle) * is that * [worker.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-worker#worker-evaluate-handle) - * returns [JSHandle]. + * returns {@link JSHandle}. * * If the function passed to the * [worker.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-worker#worker-evaluate-handle) @@ -8724,14 +8734,14 @@ export interface Worker { */ evaluateHandle(pageFunction: PageFunction, arg: Arg): Promise>; /** - * Returns the return value of `pageFunction` as a [JSHandle]. + * Returns the return value of `pageFunction` as a {@link JSHandle}. * * The only difference between * [worker.evaluate(pageFunction[, arg])](https://playwright.dev/docs/api/class-worker#worker-evaluate) and * [worker.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-worker#worker-evaluate-handle) * is that * [worker.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-worker#worker-evaluate-handle) - * returns [JSHandle]. + * returns {@link JSHandle}. * * If the function passed to the * [worker.evaluateHandle(pageFunction[, arg])](https://playwright.dev/docs/api/class-worker#worker-evaluate-handle) @@ -8838,12 +8848,12 @@ export interface JSHandle { evaluate(pageFunction: PageFunctionOn, arg?: any): Promise; /** - * Returns the return value of `pageFunction` as a [JSHandle]. + * Returns the return value of `pageFunction` as a {@link JSHandle}. * * This method passes this handle as the first argument to `pageFunction`. * * The only difference between `jsHandle.evaluate` and `jsHandle.evaluateHandle` is that `jsHandle.evaluateHandle` - * returns [JSHandle]. + * returns {@link JSHandle}. * * If the function passed to the `jsHandle.evaluateHandle` returns a [Promise], then `jsHandle.evaluateHandle` would * wait for the promise to resolve and return its value. @@ -8855,12 +8865,12 @@ export interface JSHandle { */ evaluateHandle(pageFunction: PageFunctionOn, arg: Arg): Promise>; /** - * Returns the return value of `pageFunction` as a [JSHandle]. + * Returns the return value of `pageFunction` as a {@link JSHandle}. * * This method passes this handle as the first argument to `pageFunction`. * * The only difference between `jsHandle.evaluate` and `jsHandle.evaluateHandle` is that `jsHandle.evaluateHandle` - * returns [JSHandle]. + * returns {@link JSHandle}. * * If the function passed to the `jsHandle.evaluateHandle` returns a [Promise], then `jsHandle.evaluateHandle` would * wait for the promise to resolve and return its value. @@ -8880,7 +8890,7 @@ export interface JSHandle { */ jsonValue(): Promise; /** - * Returns either `null` or the object handle itself, if the object handle is an instance of [ElementHandle]. + * Returns either `null` or the object handle itself, if the object handle is an instance of {@link ElementHandle}. */ asElement(): T extends Node ? ElementHandle : null; /** @@ -8912,12 +8922,12 @@ export interface JSHandle { } /** - * - extends: [JSHandle] + * - extends: {@link JSHandle} * * ElementHandle represents an in-page DOM element. ElementHandles can be created with the * [page.$(selector[, options])](https://playwright.dev/docs/api/class-page#page-query-selector) method. * - * **NOTE** The use of ElementHandle is discouraged, use [Locator] objects and web-first assertions instead. + * **NOTE** The use of ElementHandle is discouraged, use {@link Locator} objects and web-first assertions instead. * * ```js * const hrefElement = await page.$('a'); @@ -8932,8 +8942,8 @@ export interface JSHandle { * [page.$eval(selector, pageFunction[, arg, options])](https://playwright.dev/docs/api/class-page#page-eval-on-selector) * and [page.evaluate(pageFunction[, arg])](https://playwright.dev/docs/api/class-page#page-evaluate) methods. * - * The difference between the [Locator] and ElementHandle is that the ElementHandle points to a particular element, - * while [Locator] captures the logic of how to retrieve an element. + * The difference between the {@link Locator} and ElementHandle is that the ElementHandle points to a particular + * element, while {@link Locator} captures the logic of how to retrieve an element. * * In the example below, handle points to a particular DOM element on page. If that element changes text or is used by * React to render an entirely different component, handle is still pointing to that very DOM element. This can lead @@ -9351,8 +9361,8 @@ export interface ElementHandle extends JSHandle { * * 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 throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * @param options */ check(options?: { @@ -9403,8 +9413,8 @@ export interface ElementHandle extends JSHandle { * * 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 throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * @param options */ click(options?: { @@ -9482,8 +9492,8 @@ export interface ElementHandle extends JSHandle { * * 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 throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * * **NOTE** `elementHandle.dblclick()` dispatches two `click` events and a single `dblclick` event. * @param options @@ -9635,8 +9645,8 @@ export interface ElementHandle extends JSHandle { * * 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 throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * @param options */ hover(options?: { @@ -10013,8 +10023,8 @@ export interface ElementHandle extends JSHandle { * 1. Wait for initiated navigations to either succeed or fail, unless `noWaitAfter` option is set. * 1. Ensure that the element is now checked or unchecked. If not, this method throws. * - * When all steps combined have not finished during the specified `timeout`, this method throws a [TimeoutError]. - * Passing zero timeout disables this. + * When all steps combined have not finished during the specified `timeout`, this method throws a {@link + * TimeoutError}. Passing zero timeout disables this. * @param checked Whether to check or uncheck the checkbox. * @param options */ @@ -10060,7 +10070,7 @@ export interface ElementHandle extends JSHandle { * Sets the value of the file input to these file paths or files. If some of the `filePaths` are relative paths, then * they are resolved relative to the current working directory. For empty array, clears the selected files. * - * This method expects [ElementHandle] to point to an + * This method expects {@link ElementHandle} to point to an * [input element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input). However, if the element is inside * the `