Release 0.7.28
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "rrweb-snapshot",
|
"name": "rrweb-snapshot",
|
||||||
"version": "0.7.27",
|
"version": "0.7.28",
|
||||||
"description": "rrweb's component to take a snapshot of DOM, aka DOM serializer",
|
"description": "rrweb's component to take a snapshot of DOM, aka DOM serializer",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"test": "cross-env TS_NODE_CACHE=false TS_NODE_FILES=true mocha -r ts-node/register test/**/*.ts",
|
"test": "cross-env TS_NODE_CACHE=false TS_NODE_FILES=true mocha -r ts-node/register test/**/*.ts",
|
||||||
|
|||||||
6
typings/snapshot.d.ts
vendored
6
typings/snapshot.d.ts
vendored
@@ -1,7 +1,7 @@
|
|||||||
import { serializedNodeWithId, INode, idNodeMap } from './types';
|
import { serializedNodeWithId, INode, idNodeMap, MaskInputOptions } from './types';
|
||||||
export declare function absoluteToStylesheet(cssText: string | null, href: string): string;
|
export declare function absoluteToStylesheet(cssText: string | null, href: string): string;
|
||||||
export declare function absoluteToDoc(doc: Document, attributeValue: string): string;
|
export declare function absoluteToDoc(doc: Document, attributeValue: string): string;
|
||||||
export declare function transformAttribute(doc: Document, name: string, value: string): string;
|
export declare function transformAttribute(doc: Document, name: string, value: string): string;
|
||||||
export declare function serializeNodeWithId(n: Node | INode, doc: Document, map: idNodeMap, blockClass: string | RegExp, skipChild?: boolean, inlineStylesheet?: boolean, maskAllInputs?: boolean): serializedNodeWithId | null;
|
export declare function serializeNodeWithId(n: Node | INode, doc: Document, map: idNodeMap, blockClass: string | RegExp, skipChild?: boolean, inlineStylesheet?: boolean, maskInputOptions?: MaskInputOptions): serializedNodeWithId | null;
|
||||||
declare function snapshot(n: Document, blockClass?: string | RegExp, inlineStylesheet?: boolean, maskAllInputs?: boolean): [serializedNodeWithId | null, idNodeMap];
|
declare function snapshot(n: Document, blockClass: string | RegExp | undefined, inlineStylesheet: boolean | undefined, maskAllInputsOrOptions: boolean | MaskInputOptions): [serializedNodeWithId | null, idNodeMap];
|
||||||
export default snapshot;
|
export default snapshot;
|
||||||
|
|||||||
15
typings/types.d.ts
vendored
15
typings/types.d.ts
vendored
@@ -53,3 +53,18 @@ export interface INode extends Node {
|
|||||||
export declare type idNodeMap = {
|
export declare type idNodeMap = {
|
||||||
[key: number]: INode;
|
[key: number]: INode;
|
||||||
};
|
};
|
||||||
|
export declare type MaskInputOptions = Partial<{
|
||||||
|
color: boolean;
|
||||||
|
date: boolean;
|
||||||
|
'datetime-local': boolean;
|
||||||
|
email: boolean;
|
||||||
|
month: boolean;
|
||||||
|
number: boolean;
|
||||||
|
range: boolean;
|
||||||
|
search: boolean;
|
||||||
|
tel: boolean;
|
||||||
|
text: boolean;
|
||||||
|
time: boolean;
|
||||||
|
url: boolean;
|
||||||
|
week: boolean;
|
||||||
|
}>;
|
||||||
|
|||||||
Reference in New Issue
Block a user