update dependencies
In this commit, we updated rrweb-snapshot to 0.6.0 which including a breaking change in data structure.
This commit is contained in:
@@ -44,10 +44,10 @@
|
||||
"ts-node": "^7.0.1",
|
||||
"tslib": "^1.9.3",
|
||||
"tslint": "^4.5.1",
|
||||
"typescript": "^3.1.1"
|
||||
"typescript": "^3.1.6"
|
||||
},
|
||||
"dependencies": {
|
||||
"mitt": "^1.1.3",
|
||||
"rrweb-snapshot": "^0.5.6"
|
||||
"rrweb-snapshot": "^0.6.0"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -132,14 +132,14 @@ function initMutationObserver(cb: mutationCallBack): MutationObserver {
|
||||
});
|
||||
|
||||
Array.from(addsSet).forEach(n => {
|
||||
const parentId = mirror.getId(n.parentNode as INode);
|
||||
const parentId = mirror.getId((n.parentNode as Node) as INode);
|
||||
if (
|
||||
parentId &&
|
||||
!dropped.some(d => d === n.parentNode) &&
|
||||
!removes.some(r => r.id === parentId)
|
||||
) {
|
||||
adds.push({
|
||||
parentId: mirror.getId(n.parentNode as INode),
|
||||
parentId: mirror.getId((n.parentNode as Node) as INode),
|
||||
previousId: !n.previousSibling
|
||||
? n.previousSibling
|
||||
: mirror.getId(n.previousSibling as INode),
|
||||
@@ -256,8 +256,8 @@ function initScrollObserver(cb: scrollCallback): listenerHandler {
|
||||
if (evt.target === document) {
|
||||
cb({
|
||||
id,
|
||||
x: document.documentElement.scrollLeft,
|
||||
y: document.documentElement.scrollTop,
|
||||
x: document.documentElement!.scrollLeft,
|
||||
y: document.documentElement!.scrollTop,
|
||||
});
|
||||
} else {
|
||||
cb({
|
||||
|
||||
Reference in New Issue
Block a user