@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.cjs
CHANGED
|
@@ -14536,7 +14536,7 @@ class VisibilityManager {
|
|
|
14536
14536
|
}
|
|
14537
14537
|
}
|
|
14538
14538
|
}
|
|
14539
|
-
const version$1 = "2.1.3-alpha.
|
|
14539
|
+
const version$1 = "2.1.3-alpha.4";
|
|
14540
14540
|
let wrappedEmit;
|
|
14541
14541
|
let takeFullSnapshot$1;
|
|
14542
14542
|
let canvasManager;
|
|
@@ -14698,13 +14698,27 @@ function record(options = {}) {
|
|
|
14698
14698
|
}
|
|
14699
14699
|
return e2;
|
|
14700
14700
|
};
|
|
14701
|
+
let lastMetaHref = null;
|
|
14702
|
+
let navSnapshotInProgress = false;
|
|
14701
14703
|
wrappedEmit = (r2, isCheckout) => {
|
|
14702
|
-
var _a2;
|
|
14704
|
+
var _a2, _b;
|
|
14703
14705
|
const e2 = r2;
|
|
14704
14706
|
e2.timestamp = nowTimestamp();
|
|
14707
|
+
let navTriggeredFS = false;
|
|
14705
14708
|
if (((_a2 = mutationBuffers[0]) == null ? void 0 : _a2.isFrozen()) && e2.type !== EventType.FullSnapshot && !(e2.type === EventType.IncrementalSnapshot && e2.data.source === IncrementalSource.Mutation)) {
|
|
14706
14709
|
mutationBuffers.forEach((buf) => buf.unfreeze());
|
|
14707
14710
|
}
|
|
14711
|
+
if (!navSnapshotInProgress && e2.type !== EventType.Meta && e2.type !== EventType.FullSnapshot && lastMetaHref && window.location.href !== lastMetaHref) {
|
|
14712
|
+
navSnapshotInProgress = true;
|
|
14713
|
+
try {
|
|
14714
|
+
recentVisibilityChanges = 0;
|
|
14715
|
+
incrementalSnapshotCount = 0;
|
|
14716
|
+
navTriggeredFS = true;
|
|
14717
|
+
takeFullSnapshot$1(true);
|
|
14718
|
+
} finally {
|
|
14719
|
+
navSnapshotInProgress = false;
|
|
14720
|
+
}
|
|
14721
|
+
}
|
|
14708
14722
|
if (inEmittingFrame) {
|
|
14709
14723
|
emit == null ? void 0 : emit(eventProcessor(e2), isCheckout);
|
|
14710
14724
|
} else if (passEmitsToParent) {
|
|
@@ -14716,6 +14730,9 @@ function record(options = {}) {
|
|
|
14716
14730
|
};
|
|
14717
14731
|
window.parent.postMessage(message, "*");
|
|
14718
14732
|
}
|
|
14733
|
+
if (e2.type === EventType.Meta) {
|
|
14734
|
+
lastMetaHref = ((_b = e2.data) == null ? void 0 : _b.href) || window.location.href;
|
|
14735
|
+
}
|
|
14719
14736
|
if (e2.type === EventType.FullSnapshot) {
|
|
14720
14737
|
lastFullSnapshotEvent = e2;
|
|
14721
14738
|
incrementalSnapshotCount = 0;
|
|
@@ -14724,14 +14741,16 @@ function record(options = {}) {
|
|
|
14724
14741
|
return;
|
|
14725
14742
|
}
|
|
14726
14743
|
incrementalSnapshotCount++;
|
|
14727
|
-
|
|
14728
|
-
|
|
14729
|
-
|
|
14730
|
-
|
|
14731
|
-
if (exceedVisibility) {
|
|
14732
|
-
|
|
14744
|
+
if (!navTriggeredFS) {
|
|
14745
|
+
const exceedCount = checkoutEveryNth && incrementalSnapshotCount >= checkoutEveryNth;
|
|
14746
|
+
const exceedTime = checkoutEveryNms && e2.timestamp - lastFullSnapshotEvent.timestamp > checkoutEveryNms;
|
|
14747
|
+
const exceedVisibility = checkoutEveryNvm && recentVisibilityChanges >= checkoutEveryNvm;
|
|
14748
|
+
if (exceedCount || exceedTime || exceedVisibility) {
|
|
14749
|
+
if (exceedVisibility) {
|
|
14750
|
+
recentVisibilityChanges = 0;
|
|
14751
|
+
}
|
|
14752
|
+
takeFullSnapshot$1(true);
|
|
14733
14753
|
}
|
|
14734
|
-
takeFullSnapshot$1(true);
|
|
14735
14754
|
}
|
|
14736
14755
|
}
|
|
14737
14756
|
};
|
|
@@ -18035,7 +18054,7 @@ class Replayer {
|
|
|
18035
18054
|
this.config.logger.log(REPLAY_CONSOLE_PREFIX, ...args);
|
|
18036
18055
|
}
|
|
18037
18056
|
}
|
|
18038
|
-
const version = "2.1.3-alpha.
|
|
18057
|
+
const version = "2.1.3-alpha.4";
|
|
18039
18058
|
const { getVersion } = record;
|
|
18040
18059
|
const { isRecording } = record;
|
|
18041
18060
|
const { flushCustomEventQueue } = record;
|