diff --git a/.release-please-manifest.json b/.release-please-manifest.json index d6b6c610..7a48e52a 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "2.11.2" + ".": "2.12.0" } diff --git a/CHANGELOG.md b/CHANGELOG.md index b1c7eb8a..d1706bd6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,13 @@ All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. +## [2.12.0](https://github.com/puppeteer/replay/compare/v2.11.2...v2.12.0) (2023-07-04) + + +### Features + +* use locators in Puppeteer extensions ([#569](https://github.com/puppeteer/replay/issues/569)) ([92d7666](https://github.com/puppeteer/replay/commit/92d76666abf73de3cb3d1bc0ffc3b7276f4ed376)) + ## [2.11.2](https://github.com/puppeteer/replay/compare/v2.11.1...v2.11.2) (2023-06-12) diff --git a/docs/api/README.md b/docs/api/README.md index d855c94a..21d7b172 100644 --- a/docs/api/README.md +++ b/docs/api/README.md @@ -89,6 +89,7 @@ - [parse](README.md#parse) - [parseSourceMap](README.md#parsesourcemap) - [parseStep](README.md#parsestep) +- [selectorToPElementSelector](README.md#selectortopelementselector) - [stringify](README.md#stringify) - [stringifyStep](README.md#stringifystep) - [stripSourceMap](README.md#stripsourcemap) @@ -254,7 +255,7 @@ The format is [version, [lineNo, length], [lineNo, length] ... [lineNo, length]] #### Defined in -[SchemaUtils.ts:563](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L563) +[SchemaUtils.ts:564](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L564) --- @@ -264,7 +265,7 @@ The format is [version, [lineNo, length], [lineNo, length] ... [lineNo, length]] #### Defined in -[SchemaUtils.ts:562](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L562) +[SchemaUtils.ts:563](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L563) --- @@ -274,7 +275,7 @@ The format is [version, [lineNo, length], [lineNo, length] ... [lineNo, length]] #### Defined in -[SchemaUtils.ts:70](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L70) +[SchemaUtils.ts:71](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L71) --- @@ -284,7 +285,7 @@ The format is [version, [lineNo, length], [lineNo, length] ... [lineNo, length]] #### Defined in -[SchemaUtils.ts:64](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L64) +[SchemaUtils.ts:65](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L65) --- @@ -294,7 +295,7 @@ The format is [version, [lineNo, length], [lineNo, length] ... [lineNo, length]] #### Defined in -[SchemaUtils.ts:53](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L53) +[SchemaUtils.ts:54](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L54) ## Functions @@ -314,7 +315,7 @@ The format is [version, [lineNo, length], [lineNo, length] ... [lineNo, length]] #### Defined in -[SchemaUtils.ts:48](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L48) +[SchemaUtils.ts:49](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L49) --- @@ -448,7 +449,7 @@ therefore, SelectorType.CSS is the default type if other types didn't match. #### Defined in -[SchemaUtils.ts:615](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L615) +[SchemaUtils.ts:616](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L616) --- @@ -468,7 +469,7 @@ therefore, SelectorType.CSS is the default type if other types didn't match. #### Defined in -[SchemaUtils.ts:571](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L571) +[SchemaUtils.ts:572](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L572) --- @@ -511,7 +512,33 @@ Extracts a source map from a text. #### Defined in -[SchemaUtils.ts:495](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L495) +[SchemaUtils.ts:496](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L496) + +--- + +### selectorToPElementSelector + +▸ **selectorToPElementSelector**(`selector`): `string` + +Converts a selector or an array of selector parts into a Puppeteer selector. + +**`See`** + +https://pptr.dev/guides/query-selectors#p-elements + +#### Parameters + +| Name | Type | +| :--------- | :--------------------- | +| `selector` | `string` \| `string`[] | + +#### Returns + +`string` + +#### Defined in + +[SchemaUtils.ts:630](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L630) --- @@ -607,4 +634,4 @@ Stringifes a single step. Only the following hooks are invoked with the `flow` p #### Defined in -[SchemaUtils.ts:567](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L567) +[SchemaUtils.ts:568](https://github.com/puppeteer/replay/blob/main/src/SchemaUtils.ts#L568) diff --git a/docs/api/classes/LighthouseRunnerExtension.md b/docs/api/classes/LighthouseRunnerExtension.md index c0a0accf..f1fc72d6 100644 --- a/docs/api/classes/LighthouseRunnerExtension.md +++ b/docs/api/classes/LighthouseRunnerExtension.md @@ -44,7 +44,7 @@ #### Defined in -[PuppeteerRunnerExtension.ts:47](https://github.com/puppeteer/replay/blob/main/src/PuppeteerRunnerExtension.ts#L47) +[PuppeteerRunnerExtension.ts:52](https://github.com/puppeteer/replay/blob/main/src/PuppeteerRunnerExtension.ts#L52) ## Methods @@ -181,4 +181,4 @@ #### Defined in -[PuppeteerRunnerExtension.ts:68](https://github.com/puppeteer/replay/blob/main/src/PuppeteerRunnerExtension.ts#L68) +[PuppeteerRunnerExtension.ts:73](https://github.com/puppeteer/replay/blob/main/src/PuppeteerRunnerExtension.ts#L73) diff --git a/docs/api/classes/PuppeteerRunnerExtension.md b/docs/api/classes/PuppeteerRunnerExtension.md index e99ddd4e..7041eac1 100644 --- a/docs/api/classes/PuppeteerRunnerExtension.md +++ b/docs/api/classes/PuppeteerRunnerExtension.md @@ -47,7 +47,7 @@ #### Defined in -[PuppeteerRunnerExtension.ts:47](https://github.com/puppeteer/replay/blob/main/src/PuppeteerRunnerExtension.ts#L47) +[PuppeteerRunnerExtension.ts:52](https://github.com/puppeteer/replay/blob/main/src/PuppeteerRunnerExtension.ts#L52) ## Methods @@ -170,4 +170,4 @@ #### Defined in -[PuppeteerRunnerExtension.ts:68](https://github.com/puppeteer/replay/blob/main/src/PuppeteerRunnerExtension.ts#L68) +[PuppeteerRunnerExtension.ts:73](https://github.com/puppeteer/replay/blob/main/src/PuppeteerRunnerExtension.ts#L73) diff --git a/docs/api/classes/PuppeteerRunnerOwningBrowserExtension.md b/docs/api/classes/PuppeteerRunnerOwningBrowserExtension.md index 5288ce4d..d12f6b46 100644 --- a/docs/api/classes/PuppeteerRunnerOwningBrowserExtension.md +++ b/docs/api/classes/PuppeteerRunnerOwningBrowserExtension.md @@ -43,7 +43,7 @@ #### Defined in -[PuppeteerRunnerExtension.ts:47](https://github.com/puppeteer/replay/blob/main/src/PuppeteerRunnerExtension.ts#L47) +[PuppeteerRunnerExtension.ts:52](https://github.com/puppeteer/replay/blob/main/src/PuppeteerRunnerExtension.ts#L52) ## Methods @@ -61,7 +61,7 @@ #### Defined in -[PuppeteerRunnerExtension.ts:373](https://github.com/puppeteer/replay/blob/main/src/PuppeteerRunnerExtension.ts#L373) +[PuppeteerRunnerExtension.ts:291](https://github.com/puppeteer/replay/blob/main/src/PuppeteerRunnerExtension.ts#L291) --- @@ -160,4 +160,4 @@ #### Defined in -[PuppeteerRunnerExtension.ts:68](https://github.com/puppeteer/replay/blob/main/src/PuppeteerRunnerExtension.ts#L68) +[PuppeteerRunnerExtension.ts:73](https://github.com/puppeteer/replay/blob/main/src/PuppeteerRunnerExtension.ts#L73) diff --git a/package-lock.json b/package-lock.json index 039c5178..236a8e18 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "@puppeteer/replay", - "version": "2.11.2", + "version": "2.12.0", "lockfileVersion": 3, "requires": true, "packages": { diff --git a/package.json b/package.json index c2384ae9..142aa76b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@puppeteer/replay", - "version": "2.11.2", + "version": "2.12.0", "description": "Replay is a library which provides an API to replay and stringify recordings created using Chrome DevTools Recorder](https://developer.chrome.com/docs/devtools/recorder/)", "main": "lib/cjs/main.cjs", "types": "lib/main.d.ts",