@axe-core/playwright 4.11.2-6dd39af.0 → 4.11.2-71c4179.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +0 -67
- package/dist/index.d.ts +0 -67
- package/dist/index.js +1 -0
- package/dist/index.mjs +1 -0
- package/package.json +4 -7
package/dist/index.d.mts
CHANGED
|
@@ -15,84 +15,17 @@ declare class AxeBuilder {
|
|
|
15
15
|
private legacyMode;
|
|
16
16
|
private errorUrl;
|
|
17
17
|
constructor({ page, axeSource }: AxePlaywrightParams);
|
|
18
|
-
/**
|
|
19
|
-
* Selector to include in analysis.
|
|
20
|
-
* This may be called any number of times.
|
|
21
|
-
* @param String selector
|
|
22
|
-
* @returns this
|
|
23
|
-
*/
|
|
24
18
|
include(selector: SerialFrameSelector): this;
|
|
25
|
-
/**
|
|
26
|
-
* Selector to exclude in analysis.
|
|
27
|
-
* This may be called any number of times.
|
|
28
|
-
* @param String selector
|
|
29
|
-
* @returns this
|
|
30
|
-
*/
|
|
31
19
|
exclude(selector: SerialFrameSelector): this;
|
|
32
|
-
/**
|
|
33
|
-
* Set options to be passed into axe-core
|
|
34
|
-
* @param RunOptions options
|
|
35
|
-
* @returns AxeBuilder
|
|
36
|
-
*/
|
|
37
20
|
options(options: RunOptions): this;
|
|
38
|
-
/**
|
|
39
|
-
* Limit analysis to only the specified rules.
|
|
40
|
-
* Cannot be used with `AxeBuilder#withTags`
|
|
41
|
-
* @param String|Array rules
|
|
42
|
-
* @returns this
|
|
43
|
-
*/
|
|
44
21
|
withRules(rules: string | string[]): this;
|
|
45
|
-
/**
|
|
46
|
-
* Limit analysis to only specified tags.
|
|
47
|
-
* Cannot be used with `AxeBuilder#withRules`
|
|
48
|
-
* @param String|Array tags
|
|
49
|
-
* @returns this
|
|
50
|
-
*/
|
|
51
22
|
withTags(tags: string | string[]): this;
|
|
52
|
-
/**
|
|
53
|
-
* Set the list of rules to skip when running an analysis.
|
|
54
|
-
* @param String|Array rules
|
|
55
|
-
* @returns this
|
|
56
|
-
*/
|
|
57
23
|
disableRules(rules: string | string[]): this;
|
|
58
|
-
/**
|
|
59
|
-
* Use frameMessenger with <same_origin_only>
|
|
60
|
-
*
|
|
61
|
-
* This disables use of axe.runPartial() which is called in each frame, and
|
|
62
|
-
* axe.finishRun() which is called in a blank page. This uses axe.run() instead,
|
|
63
|
-
* but with the restriction that cross-origin frames will not be tested.
|
|
64
|
-
*/
|
|
65
24
|
setLegacyMode(legacyMode?: boolean): this;
|
|
66
|
-
/**
|
|
67
|
-
* Perform analysis and retrieve results. *Does not chain.*
|
|
68
|
-
* @return Promise<Result | Error>
|
|
69
|
-
*/
|
|
70
25
|
analyze(): Promise<AxeResults>;
|
|
71
|
-
/**
|
|
72
|
-
* Injects `axe-core` into all frames.
|
|
73
|
-
* @param Page - playwright page object
|
|
74
|
-
* @returns Promise<void>
|
|
75
|
-
*/
|
|
76
26
|
private inject;
|
|
77
|
-
/**
|
|
78
|
-
* Get axe-core source and configurations
|
|
79
|
-
* @returns String
|
|
80
|
-
*/
|
|
81
27
|
private script;
|
|
82
28
|
private runLegacy;
|
|
83
|
-
/**
|
|
84
|
-
* Inject `axe-core` into each frame and run `axe.runPartial`.
|
|
85
|
-
* Because we need to inject axe into all frames all at once
|
|
86
|
-
* (to avoid any potential problems with the DOM becoming out-of-sync)
|
|
87
|
-
* but also need to not process results for any child frames if the parent
|
|
88
|
-
* frame throws an error (requirements of the data structure for `axe.finishRun`),
|
|
89
|
-
* we have to return a deeply nested array of Promises and then flatten
|
|
90
|
-
* the array once all Promises have finished, throwing out any nested Promises
|
|
91
|
-
* if the parent Promise is not fulfilled.
|
|
92
|
-
* @param frame - playwright frame object
|
|
93
|
-
* @param context - axe-core context object
|
|
94
|
-
* @returns Promise<AxePartialRunner>
|
|
95
|
-
*/
|
|
96
29
|
private runPartialRecursive;
|
|
97
30
|
private finishRun;
|
|
98
31
|
private axeConfigure;
|
package/dist/index.d.ts
CHANGED
|
@@ -15,84 +15,17 @@ declare class AxeBuilder {
|
|
|
15
15
|
private legacyMode;
|
|
16
16
|
private errorUrl;
|
|
17
17
|
constructor({ page, axeSource }: AxePlaywrightParams);
|
|
18
|
-
/**
|
|
19
|
-
* Selector to include in analysis.
|
|
20
|
-
* This may be called any number of times.
|
|
21
|
-
* @param String selector
|
|
22
|
-
* @returns this
|
|
23
|
-
*/
|
|
24
18
|
include(selector: SerialFrameSelector): this;
|
|
25
|
-
/**
|
|
26
|
-
* Selector to exclude in analysis.
|
|
27
|
-
* This may be called any number of times.
|
|
28
|
-
* @param String selector
|
|
29
|
-
* @returns this
|
|
30
|
-
*/
|
|
31
19
|
exclude(selector: SerialFrameSelector): this;
|
|
32
|
-
/**
|
|
33
|
-
* Set options to be passed into axe-core
|
|
34
|
-
* @param RunOptions options
|
|
35
|
-
* @returns AxeBuilder
|
|
36
|
-
*/
|
|
37
20
|
options(options: RunOptions): this;
|
|
38
|
-
/**
|
|
39
|
-
* Limit analysis to only the specified rules.
|
|
40
|
-
* Cannot be used with `AxeBuilder#withTags`
|
|
41
|
-
* @param String|Array rules
|
|
42
|
-
* @returns this
|
|
43
|
-
*/
|
|
44
21
|
withRules(rules: string | string[]): this;
|
|
45
|
-
/**
|
|
46
|
-
* Limit analysis to only specified tags.
|
|
47
|
-
* Cannot be used with `AxeBuilder#withRules`
|
|
48
|
-
* @param String|Array tags
|
|
49
|
-
* @returns this
|
|
50
|
-
*/
|
|
51
22
|
withTags(tags: string | string[]): this;
|
|
52
|
-
/**
|
|
53
|
-
* Set the list of rules to skip when running an analysis.
|
|
54
|
-
* @param String|Array rules
|
|
55
|
-
* @returns this
|
|
56
|
-
*/
|
|
57
23
|
disableRules(rules: string | string[]): this;
|
|
58
|
-
/**
|
|
59
|
-
* Use frameMessenger with <same_origin_only>
|
|
60
|
-
*
|
|
61
|
-
* This disables use of axe.runPartial() which is called in each frame, and
|
|
62
|
-
* axe.finishRun() which is called in a blank page. This uses axe.run() instead,
|
|
63
|
-
* but with the restriction that cross-origin frames will not be tested.
|
|
64
|
-
*/
|
|
65
24
|
setLegacyMode(legacyMode?: boolean): this;
|
|
66
|
-
/**
|
|
67
|
-
* Perform analysis and retrieve results. *Does not chain.*
|
|
68
|
-
* @return Promise<Result | Error>
|
|
69
|
-
*/
|
|
70
25
|
analyze(): Promise<AxeResults>;
|
|
71
|
-
/**
|
|
72
|
-
* Injects `axe-core` into all frames.
|
|
73
|
-
* @param Page - playwright page object
|
|
74
|
-
* @returns Promise<void>
|
|
75
|
-
*/
|
|
76
26
|
private inject;
|
|
77
|
-
/**
|
|
78
|
-
* Get axe-core source and configurations
|
|
79
|
-
* @returns String
|
|
80
|
-
*/
|
|
81
27
|
private script;
|
|
82
28
|
private runLegacy;
|
|
83
|
-
/**
|
|
84
|
-
* Inject `axe-core` into each frame and run `axe.runPartial`.
|
|
85
|
-
* Because we need to inject axe into all frames all at once
|
|
86
|
-
* (to avoid any potential problems with the DOM becoming out-of-sync)
|
|
87
|
-
* but also need to not process results for any child frames if the parent
|
|
88
|
-
* frame throws an error (requirements of the data structure for `axe.finishRun`),
|
|
89
|
-
* we have to return a deeply nested array of Promises and then flatten
|
|
90
|
-
* the array once all Promises have finished, throwing out any nested Promises
|
|
91
|
-
* if the parent Promise is not fulfilled.
|
|
92
|
-
* @param frame - playwright frame object
|
|
93
|
-
* @param context - axe-core context object
|
|
94
|
-
* @returns Promise<AxePartialRunner>
|
|
95
|
-
*/
|
|
96
29
|
private runPartialRecursive;
|
|
97
30
|
private finishRun;
|
|
98
31
|
private axeConfigure;
|
package/dist/index.js
CHANGED
package/dist/index.mjs
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@axe-core/playwright",
|
|
3
|
-
"version": "4.11.2-
|
|
3
|
+
"version": "4.11.2-71c4179.0+71c4179",
|
|
4
4
|
"description": "Provides a method to inject and analyze web pages using axe",
|
|
5
5
|
"contributors": [
|
|
6
6
|
{
|
|
@@ -51,14 +51,13 @@
|
|
|
51
51
|
"prepare": "npx playwright install && npm run build"
|
|
52
52
|
},
|
|
53
53
|
"dependencies": {
|
|
54
|
-
"axe-core": "~4.11.
|
|
54
|
+
"axe-core": "~4.11.3"
|
|
55
55
|
},
|
|
56
56
|
"devDependencies": {
|
|
57
57
|
"@playwright/test": "^1.44.0",
|
|
58
58
|
"@types/chai": "^4.3.3",
|
|
59
59
|
"@types/express": "^5.0.3",
|
|
60
60
|
"@types/mocha": "^10.0.0",
|
|
61
|
-
"@types/node": "^22.0.2",
|
|
62
61
|
"async-listen": "^3.0.1",
|
|
63
62
|
"axe-test-fixtures": "github:dequelabs/axe-test-fixtures#v1",
|
|
64
63
|
"chai": "^4.3.6",
|
|
@@ -66,9 +65,7 @@
|
|
|
66
65
|
"mocha": "^11.7.1",
|
|
67
66
|
"nyc": "^17.1.0",
|
|
68
67
|
"rimraf": "^6.0.1",
|
|
69
|
-
"
|
|
70
|
-
"tsup": "^8.0.1",
|
|
71
|
-
"typescript": "^5.2.2"
|
|
68
|
+
"tsup": "^8.0.1"
|
|
72
69
|
},
|
|
73
70
|
"peerDependencies": {
|
|
74
71
|
"playwright-core": ">= 1.0.0"
|
|
@@ -92,5 +89,5 @@
|
|
|
92
89
|
"functions": 100,
|
|
93
90
|
"lines": 95
|
|
94
91
|
},
|
|
95
|
-
"gitHead": "
|
|
92
|
+
"gitHead": "71c41796f4cdf2aebcb5e49d1bf6896f4ad72a2a"
|
|
96
93
|
}
|