@percy/core 1.30.9-beta.2 → 1.30.9-beta.4
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/config.js +127 -0
- package/dist/utils.js +3 -0
- package/package.json +8 -8
package/dist/config.js
CHANGED
|
@@ -26,6 +26,33 @@ export const configSchema = {
|
|
|
26
26
|
snapshot: {
|
|
27
27
|
type: 'object',
|
|
28
28
|
additionalProperties: false,
|
|
29
|
+
definitions: {
|
|
30
|
+
configurationProperties: {
|
|
31
|
+
type: 'object',
|
|
32
|
+
additionalProperties: false,
|
|
33
|
+
properties: {
|
|
34
|
+
diffSensitivity: {
|
|
35
|
+
type: 'integer',
|
|
36
|
+
minimum: 0,
|
|
37
|
+
maximum: 4
|
|
38
|
+
},
|
|
39
|
+
imageIgnoreThreshold: {
|
|
40
|
+
type: 'number',
|
|
41
|
+
minimum: 0,
|
|
42
|
+
maximum: 1
|
|
43
|
+
},
|
|
44
|
+
carouselsEnabled: {
|
|
45
|
+
type: 'boolean'
|
|
46
|
+
},
|
|
47
|
+
bannersEnabled: {
|
|
48
|
+
type: 'boolean'
|
|
49
|
+
},
|
|
50
|
+
adsEnabled: {
|
|
51
|
+
type: 'boolean'
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
},
|
|
29
56
|
properties: {
|
|
30
57
|
widths: {
|
|
31
58
|
type: 'array',
|
|
@@ -164,6 +191,88 @@ export const configSchema = {
|
|
|
164
191
|
}
|
|
165
192
|
}
|
|
166
193
|
}
|
|
194
|
+
},
|
|
195
|
+
regions: {
|
|
196
|
+
type: 'array',
|
|
197
|
+
items: {
|
|
198
|
+
type: 'object',
|
|
199
|
+
properties: {
|
|
200
|
+
elementSelector: {
|
|
201
|
+
type: 'object',
|
|
202
|
+
additionalProperties: false,
|
|
203
|
+
properties: {
|
|
204
|
+
boundingBox: {
|
|
205
|
+
type: 'object',
|
|
206
|
+
additionalProperties: false,
|
|
207
|
+
properties: {
|
|
208
|
+
x: {
|
|
209
|
+
type: 'integer'
|
|
210
|
+
},
|
|
211
|
+
y: {
|
|
212
|
+
type: 'integer'
|
|
213
|
+
},
|
|
214
|
+
width: {
|
|
215
|
+
type: 'integer'
|
|
216
|
+
},
|
|
217
|
+
height: {
|
|
218
|
+
type: 'integer'
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
},
|
|
222
|
+
elementXpath: {
|
|
223
|
+
type: 'string'
|
|
224
|
+
},
|
|
225
|
+
elementCSS: {
|
|
226
|
+
type: 'string'
|
|
227
|
+
}
|
|
228
|
+
}
|
|
229
|
+
},
|
|
230
|
+
padding: {
|
|
231
|
+
type: 'object',
|
|
232
|
+
additionalProperties: false,
|
|
233
|
+
properties: {
|
|
234
|
+
top: {
|
|
235
|
+
type: 'integer'
|
|
236
|
+
},
|
|
237
|
+
bottom: {
|
|
238
|
+
type: 'integer'
|
|
239
|
+
},
|
|
240
|
+
left: {
|
|
241
|
+
type: 'integer'
|
|
242
|
+
},
|
|
243
|
+
right: {
|
|
244
|
+
type: 'integer'
|
|
245
|
+
}
|
|
246
|
+
}
|
|
247
|
+
},
|
|
248
|
+
algorithm: {
|
|
249
|
+
type: 'string',
|
|
250
|
+
enum: ['standard', 'layout', 'ignore', 'intelliignore']
|
|
251
|
+
},
|
|
252
|
+
configuration: {
|
|
253
|
+
$ref: '#/definitions/configurationProperties'
|
|
254
|
+
},
|
|
255
|
+
assertion: {
|
|
256
|
+
type: 'object',
|
|
257
|
+
additionalProperties: false,
|
|
258
|
+
properties: {
|
|
259
|
+
diffIgnoreThreshold: {
|
|
260
|
+
type: 'number',
|
|
261
|
+
minimum: 0,
|
|
262
|
+
maximum: 1
|
|
263
|
+
}
|
|
264
|
+
}
|
|
265
|
+
}
|
|
266
|
+
},
|
|
267
|
+
required: ['algorithm']
|
|
268
|
+
}
|
|
269
|
+
},
|
|
270
|
+
algorithm: {
|
|
271
|
+
type: 'string',
|
|
272
|
+
enum: ['standard', 'layout', 'intelliignore']
|
|
273
|
+
},
|
|
274
|
+
algorithmConfiguration: {
|
|
275
|
+
$ref: '#/definitions/configurationProperties'
|
|
167
276
|
}
|
|
168
277
|
}
|
|
169
278
|
},
|
|
@@ -370,6 +479,15 @@ export const snapshotSchema = {
|
|
|
370
479
|
reshuffleInvalidTags: {
|
|
371
480
|
$ref: '/config/snapshot#/properties/reshuffleInvalidTags'
|
|
372
481
|
},
|
|
482
|
+
regions: {
|
|
483
|
+
$ref: '/config/snapshot#/properties/regions'
|
|
484
|
+
},
|
|
485
|
+
algorithm: {
|
|
486
|
+
$ref: '/config/snapshot#/properties/algorithm'
|
|
487
|
+
},
|
|
488
|
+
algorithmConfiguration: {
|
|
489
|
+
$ref: '/config/snapshot#/properties/algorithmConfiguration'
|
|
490
|
+
},
|
|
373
491
|
scopeOptions: {
|
|
374
492
|
$ref: '/config/snapshot#/properties/scopeOptions'
|
|
375
493
|
},
|
|
@@ -913,6 +1031,15 @@ export const comparisonSchema = {
|
|
|
913
1031
|
ignoreElementsData: regionsSchema
|
|
914
1032
|
}
|
|
915
1033
|
},
|
|
1034
|
+
regions: {
|
|
1035
|
+
$ref: '/config/snapshot#/properties/regions'
|
|
1036
|
+
},
|
|
1037
|
+
algorithm: {
|
|
1038
|
+
$ref: '/config/snapshot#/properties/algorithm'
|
|
1039
|
+
},
|
|
1040
|
+
algorithmConfiguration: {
|
|
1041
|
+
$ref: '/config/snapshot#/properties/algorithmConfiguration'
|
|
1042
|
+
},
|
|
916
1043
|
consideredElementsData: {
|
|
917
1044
|
type: 'object',
|
|
918
1045
|
additionalProperties: false,
|
package/dist/utils.js
CHANGED
|
@@ -52,6 +52,9 @@ export function percyAutomateRequestHandler(req, percy) {
|
|
|
52
52
|
ignoreRegionXpaths: (_percy$config$snapsho4 = percy.config.snapshot.ignoreRegions) === null || _percy$config$snapsho4 === void 0 ? void 0 : _percy$config$snapsho4.ignoreRegionXpaths,
|
|
53
53
|
considerRegionSelectors: (_percy$config$snapsho5 = percy.config.snapshot.considerRegions) === null || _percy$config$snapsho5 === void 0 ? void 0 : _percy$config$snapsho5.considerRegionSelectors,
|
|
54
54
|
considerRegionXpaths: (_percy$config$snapsho6 = percy.config.snapshot.considerRegions) === null || _percy$config$snapsho6 === void 0 ? void 0 : _percy$config$snapsho6.considerRegionXpaths,
|
|
55
|
+
regions: percy.config.snapshot.regions,
|
|
56
|
+
algorithm: percy.config.snapshot.algorithm,
|
|
57
|
+
algorithmConfiguration: percy.config.snapshot.algorithmConfiguration,
|
|
55
58
|
sync: percy.config.snapshot.sync,
|
|
56
59
|
version: 'v2'
|
|
57
60
|
}, camelCasedOptions], (path, prev, next) => {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@percy/core",
|
|
3
|
-
"version": "1.30.9-beta.
|
|
3
|
+
"version": "1.30.9-beta.4",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -43,12 +43,12 @@
|
|
|
43
43
|
"test:types": "tsd"
|
|
44
44
|
},
|
|
45
45
|
"dependencies": {
|
|
46
|
-
"@percy/client": "1.30.9-beta.
|
|
47
|
-
"@percy/config": "1.30.9-beta.
|
|
48
|
-
"@percy/dom": "1.30.9-beta.
|
|
49
|
-
"@percy/logger": "1.30.9-beta.
|
|
50
|
-
"@percy/monitoring": "1.30.9-beta.
|
|
51
|
-
"@percy/webdriver-utils": "1.30.9-beta.
|
|
46
|
+
"@percy/client": "1.30.9-beta.4",
|
|
47
|
+
"@percy/config": "1.30.9-beta.4",
|
|
48
|
+
"@percy/dom": "1.30.9-beta.4",
|
|
49
|
+
"@percy/logger": "1.30.9-beta.4",
|
|
50
|
+
"@percy/monitoring": "1.30.9-beta.4",
|
|
51
|
+
"@percy/webdriver-utils": "1.30.9-beta.4",
|
|
52
52
|
"content-disposition": "^0.5.4",
|
|
53
53
|
"cross-spawn": "^7.0.3",
|
|
54
54
|
"extract-zip": "^2.0.1",
|
|
@@ -61,5 +61,5 @@
|
|
|
61
61
|
"ws": "^8.17.1",
|
|
62
62
|
"yaml": "^2.4.1"
|
|
63
63
|
},
|
|
64
|
-
"gitHead": "
|
|
64
|
+
"gitHead": "da775ecb34bc01824f0dee8f208201c373ca78d4"
|
|
65
65
|
}
|