yarn typings (#635)

This commit is contained in:
Justin Halsall
2021-07-15 17:26:43 +02:00
committed by GitHub
parent eb6b336106
commit 7210eaa7b2
3 changed files with 29 additions and 0 deletions

View File

@@ -18,6 +18,7 @@ export declare class Replayer {
private treeIndex; private treeIndex;
private fragmentParentMap; private fragmentParentMap;
private elementStateMap; private elementStateMap;
private virtualStyleRulesMap;
private imageMap; private imageMap;
private mirror; private mirror;
private firstFullSnapshot; private firstFullSnapshot;
@@ -59,6 +60,7 @@ export declare class Replayer {
private restoreRealParent; private restoreRealParent;
private storeState; private storeState;
private restoreState; private restoreState;
private restoreNodeSheet;
private warnNodeNotFound; private warnNodeNotFound;
private warnCanvasMutationFailed; private warnCanvasMutationFailed;
private debugNodeNotFound; private debugNodeNotFound;

24
typings/replay/virtual-styles.d.ts vendored Normal file
View File

@@ -0,0 +1,24 @@
import { INode } from 'rrweb-snapshot';
export declare enum StyleRuleType {
Insert = 0,
Remove = 1,
Snapshot = 2
}
declare type InsertRule = {
cssText: string;
type: StyleRuleType.Insert;
index?: number;
};
declare type RemoveRule = {
type: StyleRuleType.Remove;
index: number;
};
declare type SnapshotRule = {
type: StyleRuleType.Snapshot;
cssTexts: string[];
};
export declare type VirtualStyleRules = Array<InsertRule | RemoveRule | SnapshotRule>;
export declare type VirtualStyleRulesMap = Map<INode, VirtualStyleRules>;
export declare function applyVirtualStyleRulesToNode(storedRules: VirtualStyleRules, styleNode: HTMLStyleElement): void;
export declare function storeCSSRules(parentElement: HTMLStyleElement, virtualStyleRulesMap: VirtualStyleRulesMap): void;
export {};

3
typings/types.d.ts vendored
View File

@@ -144,6 +144,7 @@ export declare type recordOptions<T> = {
packFn?: PackFn; packFn?: PackFn;
sampling?: SamplingStrategy; sampling?: SamplingStrategy;
recordCanvas?: boolean; recordCanvas?: boolean;
userTriggeredOnInput?: boolean;
collectFonts?: boolean; collectFonts?: boolean;
plugins?: RecordPlugin[]; plugins?: RecordPlugin[];
mousemoveWait?: number; mousemoveWait?: number;
@@ -171,6 +172,7 @@ export declare type observerParam = {
fontCb: fontCallback; fontCb: fontCallback;
sampling: SamplingStrategy; sampling: SamplingStrategy;
recordCanvas: boolean; recordCanvas: boolean;
userTriggeredOnInput: boolean;
collectFonts: boolean; collectFonts: boolean;
slimDOMOptions: SlimDOMOptions; slimDOMOptions: SlimDOMOptions;
doc: Document; doc: Document;
@@ -313,6 +315,7 @@ export declare type viewportResizeCallback = (d: viewportResizeDimension) => voi
export declare type inputValue = { export declare type inputValue = {
text: string; text: string;
isChecked: boolean; isChecked: boolean;
userTriggered?: boolean;
}; };
export declare type inputCallback = (v: inputValue & { export declare type inputCallback = (v: inputValue & {
id: number; id: number;