@appsurify-testmap/rrweb 2.1.3-alpha.3 → 2.1.3-alpha.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/rrweb.cjs +29 -10
- package/dist/rrweb.cjs.map +1 -1
- package/dist/rrweb.js +29 -10
- package/dist/rrweb.js.map +1 -1
- package/dist/rrweb.umd.cjs +29 -10
- package/dist/rrweb.umd.cjs.map +2 -2
- package/dist/rrweb.umd.min.cjs +26 -26
- package/dist/rrweb.umd.min.cjs.map +3 -3
- package/package.json +5 -5
package/dist/rrweb.umd.cjs
CHANGED
|
@@ -14981,7 +14981,7 @@ class VisibilityManager {
|
|
|
14981
14981
|
}
|
|
14982
14982
|
}
|
|
14983
14983
|
}
|
|
14984
|
-
const version$1 = "2.1.3-alpha.
|
|
14984
|
+
const version$1 = "2.1.3-alpha.4";
|
|
14985
14985
|
let wrappedEmit;
|
|
14986
14986
|
let takeFullSnapshot$1;
|
|
14987
14987
|
let canvasManager;
|
|
@@ -15143,13 +15143,27 @@ function record(options = {}) {
|
|
|
15143
15143
|
}
|
|
15144
15144
|
return e2;
|
|
15145
15145
|
};
|
|
15146
|
+
let lastMetaHref = null;
|
|
15147
|
+
let navSnapshotInProgress = false;
|
|
15146
15148
|
wrappedEmit = (r2, isCheckout) => {
|
|
15147
|
-
var _a2;
|
|
15149
|
+
var _a2, _b;
|
|
15148
15150
|
const e2 = r2;
|
|
15149
15151
|
e2.timestamp = nowTimestamp();
|
|
15152
|
+
let navTriggeredFS = false;
|
|
15150
15153
|
if (((_a2 = mutationBuffers[0]) == null ? void 0 : _a2.isFrozen()) && e2.type !== EventType.FullSnapshot && !(e2.type === EventType.IncrementalSnapshot && e2.data.source === IncrementalSource.Mutation)) {
|
|
15151
15154
|
mutationBuffers.forEach((buf) => buf.unfreeze());
|
|
15152
15155
|
}
|
|
15156
|
+
if (!navSnapshotInProgress && e2.type !== EventType.Meta && e2.type !== EventType.FullSnapshot && lastMetaHref && window.location.href !== lastMetaHref) {
|
|
15157
|
+
navSnapshotInProgress = true;
|
|
15158
|
+
try {
|
|
15159
|
+
recentVisibilityChanges = 0;
|
|
15160
|
+
incrementalSnapshotCount = 0;
|
|
15161
|
+
navTriggeredFS = true;
|
|
15162
|
+
takeFullSnapshot$1(true);
|
|
15163
|
+
} finally {
|
|
15164
|
+
navSnapshotInProgress = false;
|
|
15165
|
+
}
|
|
15166
|
+
}
|
|
15153
15167
|
if (inEmittingFrame) {
|
|
15154
15168
|
emit == null ? void 0 : emit(eventProcessor(e2), isCheckout);
|
|
15155
15169
|
} else if (passEmitsToParent) {
|
|
@@ -15161,6 +15175,9 @@ function record(options = {}) {
|
|
|
15161
15175
|
};
|
|
15162
15176
|
window.parent.postMessage(message, "*");
|
|
15163
15177
|
}
|
|
15178
|
+
if (e2.type === EventType.Meta) {
|
|
15179
|
+
lastMetaHref = ((_b = e2.data) == null ? void 0 : _b.href) || window.location.href;
|
|
15180
|
+
}
|
|
15164
15181
|
if (e2.type === EventType.FullSnapshot) {
|
|
15165
15182
|
lastFullSnapshotEvent = e2;
|
|
15166
15183
|
incrementalSnapshotCount = 0;
|
|
@@ -15169,14 +15186,16 @@ function record(options = {}) {
|
|
|
15169
15186
|
return;
|
|
15170
15187
|
}
|
|
15171
15188
|
incrementalSnapshotCount++;
|
|
15172
|
-
|
|
15173
|
-
|
|
15174
|
-
|
|
15175
|
-
|
|
15176
|
-
if (exceedVisibility) {
|
|
15177
|
-
|
|
15189
|
+
if (!navTriggeredFS) {
|
|
15190
|
+
const exceedCount = checkoutEveryNth && incrementalSnapshotCount >= checkoutEveryNth;
|
|
15191
|
+
const exceedTime = checkoutEveryNms && e2.timestamp - lastFullSnapshotEvent.timestamp > checkoutEveryNms;
|
|
15192
|
+
const exceedVisibility = checkoutEveryNvm && recentVisibilityChanges >= checkoutEveryNvm;
|
|
15193
|
+
if (exceedCount || exceedTime || exceedVisibility) {
|
|
15194
|
+
if (exceedVisibility) {
|
|
15195
|
+
recentVisibilityChanges = 0;
|
|
15196
|
+
}
|
|
15197
|
+
takeFullSnapshot$1(true);
|
|
15178
15198
|
}
|
|
15179
|
-
takeFullSnapshot$1(true);
|
|
15180
15199
|
}
|
|
15181
15200
|
}
|
|
15182
15201
|
};
|
|
@@ -18499,7 +18518,7 @@ class Replayer {
|
|
|
18499
18518
|
this.config.logger.log(REPLAY_CONSOLE_PREFIX, ...args);
|
|
18500
18519
|
}
|
|
18501
18520
|
}
|
|
18502
|
-
const version = "2.1.3-alpha.
|
|
18521
|
+
const version = "2.1.3-alpha.4";
|
|
18503
18522
|
const { getVersion } = record;
|
|
18504
18523
|
const { isRecording } = record;
|
|
18505
18524
|
const { flushCustomEventQueue } = record;
|