@appsurify-testmap/rrweb-snapshot 2.1.3-alpha.3 → 3.1.1-alpha.1
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.cts +26 -6
- package/dist/index.d.ts +26 -6
- package/dist/rrweb-snapshot.cjs +1367 -130
- package/dist/rrweb-snapshot.cjs.map +1 -1
- package/dist/rrweb-snapshot.js +1367 -130
- package/dist/rrweb-snapshot.js.map +1 -1
- package/dist/rrweb-snapshot.umd.cjs +1405 -136
- package/dist/rrweb-snapshot.umd.cjs.map +4 -4
- package/dist/rrweb-snapshot.umd.min.cjs +17 -17
- package/dist/rrweb-snapshot.umd.min.cjs.map +4 -4
- package/package.json +5 -3
package/dist/index.d.cts
CHANGED
|
@@ -21,10 +21,6 @@ export declare function buildNodeWithSN(n: serializedNodeWithId, options: {
|
|
|
21
21
|
cache: BuildCache;
|
|
22
22
|
}): Node | null;
|
|
23
23
|
|
|
24
|
-
export declare function buildSelector(node: Node): string | null;
|
|
25
|
-
|
|
26
|
-
export declare function buildXPath(node: Node): string;
|
|
27
|
-
|
|
28
24
|
export declare function classMatchesRegex(node: Node | null, regex: RegExp, checkAncestors: boolean): boolean;
|
|
29
25
|
|
|
30
26
|
export declare function cleanupSnapshot(): void;
|
|
@@ -82,7 +78,7 @@ export declare function isElementInteractive(n: Node): boolean;
|
|
|
82
78
|
|
|
83
79
|
export declare function isElementVisible(el: Element): boolean;
|
|
84
80
|
|
|
85
|
-
export declare function isExcludeAttribute(name: string, exclude: string | RegExp): boolean;
|
|
81
|
+
export declare function isExcludeAttribute(name: string, exclude: string | RegExp | undefined): boolean;
|
|
86
82
|
|
|
87
83
|
export declare function isNativeShadowDom(shadowRoot: ShadowRoot): boolean;
|
|
88
84
|
|
|
@@ -158,6 +154,13 @@ export declare function rebuild(n: serializedNodeWithId, options: {
|
|
|
158
154
|
mirror: Mirror;
|
|
159
155
|
}): Node | null;
|
|
160
156
|
|
|
157
|
+
export declare type SelectorOptions = {
|
|
158
|
+
preferShortPath?: boolean;
|
|
159
|
+
useLevel4?: boolean;
|
|
160
|
+
includeDataAttributes?: boolean;
|
|
161
|
+
includeAriaAttributes?: boolean;
|
|
162
|
+
};
|
|
163
|
+
|
|
161
164
|
export declare function serializeNodeWithId(n: Node, options: {
|
|
162
165
|
doc: Document;
|
|
163
166
|
mirror: Mirror;
|
|
@@ -165,7 +168,7 @@ export declare function serializeNodeWithId(n: Node, options: {
|
|
|
165
168
|
blockSelector: string | null;
|
|
166
169
|
maskTextClass: string | RegExp;
|
|
167
170
|
maskTextSelector: string | null;
|
|
168
|
-
excludeAttribute
|
|
171
|
+
excludeAttribute?: string | RegExp;
|
|
169
172
|
skipChild: boolean;
|
|
170
173
|
inlineStylesheet: boolean;
|
|
171
174
|
newlyAddedElement?: boolean;
|
|
@@ -185,6 +188,12 @@ export declare function serializeNodeWithId(n: Node, options: {
|
|
|
185
188
|
onStylesheetLoad?: (linkNode: HTMLLinkElement, node: serializedElementNodeWithId) => unknown;
|
|
186
189
|
stylesheetLoadTimeout?: number;
|
|
187
190
|
cssCaptured?: boolean;
|
|
191
|
+
selectorOptions?: {
|
|
192
|
+
maxPathDepth: number;
|
|
193
|
+
enableSvgFingerprint?: boolean;
|
|
194
|
+
confidenceThreshold?: number;
|
|
195
|
+
fallbackToBody?: boolean;
|
|
196
|
+
} | null;
|
|
188
197
|
}): serializedNodeWithId | null;
|
|
189
198
|
|
|
190
199
|
export declare type SlimDOMOptions = Partial<{
|
|
@@ -223,6 +232,12 @@ export declare function snapshot(n: Document, options?: {
|
|
|
223
232
|
onStylesheetLoad?: (linkNode: HTMLLinkElement, node: serializedElementNodeWithId) => unknown;
|
|
224
233
|
stylesheetLoadTimeout?: number;
|
|
225
234
|
keepIframeSrcFn?: KeepIframeSrcFn;
|
|
235
|
+
selector?: boolean | {
|
|
236
|
+
maxPathDepth?: number;
|
|
237
|
+
enableSvgFingerprint?: boolean;
|
|
238
|
+
confidenceThreshold?: number;
|
|
239
|
+
fallbackToBody?: boolean;
|
|
240
|
+
};
|
|
226
241
|
}): serializedNodeWithId | null;
|
|
227
242
|
|
|
228
243
|
export declare function splitCssText(cssText: string, style: HTMLStyleElement, _testNoPxNorm?: boolean): string[];
|
|
@@ -241,4 +256,9 @@ export declare function transformAttribute(doc: Document, tagName: Lowercase<str
|
|
|
241
256
|
|
|
242
257
|
export declare function visitSnapshot(node: serializedNodeWithId, onVisit: (node: serializedNodeWithId) => unknown): void;
|
|
243
258
|
|
|
259
|
+
export declare type XPathOptions = {
|
|
260
|
+
preferShortPath?: boolean;
|
|
261
|
+
includeNamespaces?: boolean;
|
|
262
|
+
};
|
|
263
|
+
|
|
244
264
|
export { }
|
package/dist/index.d.ts
CHANGED
|
@@ -21,10 +21,6 @@ export declare function buildNodeWithSN(n: serializedNodeWithId, options: {
|
|
|
21
21
|
cache: BuildCache;
|
|
22
22
|
}): Node | null;
|
|
23
23
|
|
|
24
|
-
export declare function buildSelector(node: Node): string | null;
|
|
25
|
-
|
|
26
|
-
export declare function buildXPath(node: Node): string;
|
|
27
|
-
|
|
28
24
|
export declare function classMatchesRegex(node: Node | null, regex: RegExp, checkAncestors: boolean): boolean;
|
|
29
25
|
|
|
30
26
|
export declare function cleanupSnapshot(): void;
|
|
@@ -82,7 +78,7 @@ export declare function isElementInteractive(n: Node): boolean;
|
|
|
82
78
|
|
|
83
79
|
export declare function isElementVisible(el: Element): boolean;
|
|
84
80
|
|
|
85
|
-
export declare function isExcludeAttribute(name: string, exclude: string | RegExp): boolean;
|
|
81
|
+
export declare function isExcludeAttribute(name: string, exclude: string | RegExp | undefined): boolean;
|
|
86
82
|
|
|
87
83
|
export declare function isNativeShadowDom(shadowRoot: ShadowRoot): boolean;
|
|
88
84
|
|
|
@@ -158,6 +154,13 @@ export declare function rebuild(n: serializedNodeWithId, options: {
|
|
|
158
154
|
mirror: Mirror;
|
|
159
155
|
}): Node | null;
|
|
160
156
|
|
|
157
|
+
export declare type SelectorOptions = {
|
|
158
|
+
preferShortPath?: boolean;
|
|
159
|
+
useLevel4?: boolean;
|
|
160
|
+
includeDataAttributes?: boolean;
|
|
161
|
+
includeAriaAttributes?: boolean;
|
|
162
|
+
};
|
|
163
|
+
|
|
161
164
|
export declare function serializeNodeWithId(n: Node, options: {
|
|
162
165
|
doc: Document;
|
|
163
166
|
mirror: Mirror;
|
|
@@ -165,7 +168,7 @@ export declare function serializeNodeWithId(n: Node, options: {
|
|
|
165
168
|
blockSelector: string | null;
|
|
166
169
|
maskTextClass: string | RegExp;
|
|
167
170
|
maskTextSelector: string | null;
|
|
168
|
-
excludeAttribute
|
|
171
|
+
excludeAttribute?: string | RegExp;
|
|
169
172
|
skipChild: boolean;
|
|
170
173
|
inlineStylesheet: boolean;
|
|
171
174
|
newlyAddedElement?: boolean;
|
|
@@ -185,6 +188,12 @@ export declare function serializeNodeWithId(n: Node, options: {
|
|
|
185
188
|
onStylesheetLoad?: (linkNode: HTMLLinkElement, node: serializedElementNodeWithId) => unknown;
|
|
186
189
|
stylesheetLoadTimeout?: number;
|
|
187
190
|
cssCaptured?: boolean;
|
|
191
|
+
selectorOptions?: {
|
|
192
|
+
maxPathDepth: number;
|
|
193
|
+
enableSvgFingerprint?: boolean;
|
|
194
|
+
confidenceThreshold?: number;
|
|
195
|
+
fallbackToBody?: boolean;
|
|
196
|
+
} | null;
|
|
188
197
|
}): serializedNodeWithId | null;
|
|
189
198
|
|
|
190
199
|
export declare type SlimDOMOptions = Partial<{
|
|
@@ -223,6 +232,12 @@ export declare function snapshot(n: Document, options?: {
|
|
|
223
232
|
onStylesheetLoad?: (linkNode: HTMLLinkElement, node: serializedElementNodeWithId) => unknown;
|
|
224
233
|
stylesheetLoadTimeout?: number;
|
|
225
234
|
keepIframeSrcFn?: KeepIframeSrcFn;
|
|
235
|
+
selector?: boolean | {
|
|
236
|
+
maxPathDepth?: number;
|
|
237
|
+
enableSvgFingerprint?: boolean;
|
|
238
|
+
confidenceThreshold?: number;
|
|
239
|
+
fallbackToBody?: boolean;
|
|
240
|
+
};
|
|
226
241
|
}): serializedNodeWithId | null;
|
|
227
242
|
|
|
228
243
|
export declare function splitCssText(cssText: string, style: HTMLStyleElement, _testNoPxNorm?: boolean): string[];
|
|
@@ -241,4 +256,9 @@ export declare function transformAttribute(doc: Document, tagName: Lowercase<str
|
|
|
241
256
|
|
|
242
257
|
export declare function visitSnapshot(node: serializedNodeWithId, onVisit: (node: serializedNodeWithId) => unknown): void;
|
|
243
258
|
|
|
259
|
+
export declare type XPathOptions = {
|
|
260
|
+
preferShortPath?: boolean;
|
|
261
|
+
includeNamespaces?: boolean;
|
|
262
|
+
};
|
|
263
|
+
|
|
244
264
|
export { }
|