@appsurify-testmap/rrweb-replay 2.1.3-alpha.3 → 3.1.1-alpha.1

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.
@@ -219,6 +219,33 @@ const pseudoClassPlugin = {
219
219
  };
220
220
  }
221
221
  };
222
+ const animationFillModePlugin = {
223
+ postcssPlugin: "postcss-animation-fill-mode",
224
+ prepare: function() {
225
+ return {
226
+ Rule: function(rule2) {
227
+ let hasAnimation = false;
228
+ let hasAnimationFillMode = false;
229
+ let animationDeclaration = null;
230
+ rule2.walkDecls((decl) => {
231
+ if (decl.prop === "animation") {
232
+ hasAnimation = true;
233
+ animationDeclaration = decl;
234
+ }
235
+ if (decl.prop === "animation-fill-mode") {
236
+ hasAnimationFillMode = true;
237
+ }
238
+ });
239
+ if (hasAnimation && !hasAnimationFillMode && animationDeclaration) {
240
+ rule2.insertAfter(animationDeclaration, {
241
+ prop: "animation-fill-mode",
242
+ value: "forwards"
243
+ });
244
+ }
245
+ }
246
+ };
247
+ }
248
+ };
222
249
  function getDefaultExportFromCjs$1(x2) {
223
250
  return x2 && x2.__esModule && Object.prototype.hasOwnProperty.call(x2, "default") ? x2["default"] : x2;
224
251
  }
@@ -235,12 +262,12 @@ function getAugmentedNamespace$1(n2) {
235
262
  a2.prototype = f2.prototype;
236
263
  } else a2 = {};
237
264
  Object.defineProperty(a2, "__esModule", { value: true });
238
- Object.keys(n2).forEach(function(k) {
239
- var d = Object.getOwnPropertyDescriptor(n2, k);
240
- Object.defineProperty(a2, k, d.get ? d : {
265
+ Object.keys(n2).forEach(function(k2) {
266
+ var d = Object.getOwnPropertyDescriptor(n2, k2);
267
+ Object.defineProperty(a2, k2, d.get ? d : {
241
268
  enumerable: true,
242
269
  get: function() {
243
- return n2[k];
270
+ return n2[k2];
244
271
  }
245
272
  });
246
273
  });
@@ -664,7 +691,7 @@ function cloneNode$1(obj, parent) {
664
691
  } else if (i2 === "source") {
665
692
  cloned[i2] = value;
666
693
  } else if (Array.isArray(value)) {
667
- cloned[i2] = value.map((j) => cloneNode$1(j, cloned));
694
+ cloned[i2] = value.map((j2) => cloneNode$1(j2, cloned));
668
695
  } else {
669
696
  if (type === "object" && value !== null) value = cloneNode$1(value);
670
697
  cloned[i2] = value;
@@ -899,7 +926,7 @@ let Node$5$1 = class Node2 {
899
926
  }
900
927
  return result2;
901
928
  }
902
- toJSON(_, inputs) {
929
+ toJSON(_2, inputs) {
903
930
  let fixed = {};
904
931
  let emitInputs = inputs == null;
905
932
  inputs = inputs || /* @__PURE__ */ new Map();
@@ -2544,8 +2571,8 @@ let Parser$1$1 = class Parser {
2544
2571
  if (colon === false) return;
2545
2572
  let founded = 0;
2546
2573
  let token;
2547
- for (let j = colon - 1; j >= 0; j--) {
2548
- token = tokens[j];
2574
+ for (let j2 = colon - 1; j2 >= 0; j2--) {
2575
+ token = tokens[j2];
2549
2576
  if (token[0] !== "space") {
2550
2577
  founded += 1;
2551
2578
  if (founded === 2) break;
@@ -2663,8 +2690,8 @@ let Parser$1$1 = class Parser {
2663
2690
  } else if (token[1].toLowerCase() === "important") {
2664
2691
  let cache = tokens.slice(0);
2665
2692
  let str = "";
2666
- for (let j = i2; j > 0; j--) {
2667
- let type = cache[j][0];
2693
+ for (let j2 = i2; j2 > 0; j2--) {
2694
+ let type = cache[j2][0];
2668
2695
  if (str.trim().indexOf("!") === 0 && type !== "space") {
2669
2696
  break;
2670
2697
  }
@@ -3822,7 +3849,8 @@ function adaptCssForReplay(cssText, cache) {
3822
3849
  try {
3823
3850
  const ast = postcss$1$1([
3824
3851
  mediaSelectorPlugin,
3825
- pseudoClassPlugin
3852
+ pseudoClassPlugin,
3853
+ animationFillModePlugin
3826
3854
  ]).process(cssText);
3827
3855
  result2 = ast.css;
3828
3856
  } catch (error) {
@@ -4347,12 +4375,12 @@ function getAugmentedNamespace(n2) {
4347
4375
  a2.prototype = f2.prototype;
4348
4376
  } else a2 = {};
4349
4377
  Object.defineProperty(a2, "__esModule", { value: true });
4350
- Object.keys(n2).forEach(function(k) {
4351
- var d = Object.getOwnPropertyDescriptor(n2, k);
4352
- Object.defineProperty(a2, k, d.get ? d : {
4378
+ Object.keys(n2).forEach(function(k2) {
4379
+ var d = Object.getOwnPropertyDescriptor(n2, k2);
4380
+ Object.defineProperty(a2, k2, d.get ? d : {
4353
4381
  enumerable: true,
4354
4382
  get: function() {
4355
- return n2[k];
4383
+ return n2[k2];
4356
4384
  }
4357
4385
  });
4358
4386
  });
@@ -4776,7 +4804,7 @@ function cloneNode(obj, parent) {
4776
4804
  } else if (i2 === "source") {
4777
4805
  cloned[i2] = value;
4778
4806
  } else if (Array.isArray(value)) {
4779
- cloned[i2] = value.map((j) => cloneNode(j, cloned));
4807
+ cloned[i2] = value.map((j2) => cloneNode(j2, cloned));
4780
4808
  } else {
4781
4809
  if (type === "object" && value !== null) value = cloneNode(value);
4782
4810
  cloned[i2] = value;
@@ -5011,7 +5039,7 @@ let Node$5 = class Node22 {
5011
5039
  }
5012
5040
  return result2;
5013
5041
  }
5014
- toJSON(_, inputs) {
5042
+ toJSON(_2, inputs) {
5015
5043
  let fixed = {};
5016
5044
  let emitInputs = inputs == null;
5017
5045
  inputs = inputs || /* @__PURE__ */ new Map();
@@ -6656,8 +6684,8 @@ let Parser$1 = class Parser2 {
6656
6684
  if (colon === false) return;
6657
6685
  let founded = 0;
6658
6686
  let token;
6659
- for (let j = colon - 1; j >= 0; j--) {
6660
- token = tokens[j];
6687
+ for (let j2 = colon - 1; j2 >= 0; j2--) {
6688
+ token = tokens[j2];
6661
6689
  if (token[0] !== "space") {
6662
6690
  founded += 1;
6663
6691
  if (founded === 2) break;
@@ -6775,8 +6803,8 @@ let Parser$1 = class Parser2 {
6775
6803
  } else if (token[1].toLowerCase() === "important") {
6776
6804
  let cache = tokens.slice(0);
6777
6805
  let str = "";
6778
- for (let j = i2; j > 0; j--) {
6779
- let type = cache[j][0];
6806
+ for (let j2 = i2; j2 > 0; j2--) {
6807
+ let type = cache[j2][0];
6780
6808
  if (str.trim().indexOf("!") === 0 && type !== "space") {
6781
6809
  break;
6782
6810
  }
@@ -7916,7 +7944,7 @@ const camelizeRE = /-([a-z])/g;
7916
7944
  const CUSTOM_PROPERTY_REGEX = /^--[a-zA-Z0-9-]+$/;
7917
7945
  const camelize = (str) => {
7918
7946
  if (CUSTOM_PROPERTY_REGEX.test(str)) return str;
7919
- return str.replace(camelizeRE, (_, c2) => c2 ? c2.toUpperCase() : "");
7947
+ return str.replace(camelizeRE, (_2, c2) => c2 ? c2.toUpperCase() : "");
7920
7948
  };
7921
7949
  const hyphenateRE = /\B([A-Z])/g;
7922
7950
  const hyphenate = (str) => {
@@ -9686,30 +9714,30 @@ const mittProxy = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.definePro
9686
9714
  __proto__: null,
9687
9715
  default: mitt$1
9688
9716
  }, Symbol.toStringTag, { value: "Module" }));
9689
- function polyfill(w = window, d = document) {
9690
- if ("scrollBehavior" in d.documentElement.style && w.__forceSmoothScrollPolyfill__ !== true) {
9717
+ function polyfill(w2 = window, d = document) {
9718
+ if ("scrollBehavior" in d.documentElement.style && w2.__forceSmoothScrollPolyfill__ !== true) {
9691
9719
  return;
9692
9720
  }
9693
- const Element2 = w.HTMLElement || w.Element;
9721
+ const Element2 = w2.HTMLElement || w2.Element;
9694
9722
  const SCROLL_TIME = 468;
9695
9723
  const original = {
9696
- scroll: w.scroll || w.scrollTo,
9697
- scrollBy: w.scrollBy,
9724
+ scroll: w2.scroll || w2.scrollTo,
9725
+ scrollBy: w2.scrollBy,
9698
9726
  elementScroll: Element2.prototype.scroll || scrollElement,
9699
9727
  scrollIntoView: Element2.prototype.scrollIntoView
9700
9728
  };
9701
- const now = w.performance && w.performance.now ? w.performance.now.bind(w.performance) : Date.now;
9729
+ const now = w2.performance && w2.performance.now ? w2.performance.now.bind(w2.performance) : Date.now;
9702
9730
  function isMicrosoftBrowser(userAgent) {
9703
9731
  const userAgentPatterns = ["MSIE ", "Trident/", "Edge/"];
9704
9732
  return new RegExp(userAgentPatterns.join("|")).test(userAgent);
9705
9733
  }
9706
- const ROUNDING_TOLERANCE = isMicrosoftBrowser(w.navigator.userAgent) ? 1 : 0;
9734
+ const ROUNDING_TOLERANCE = isMicrosoftBrowser(w2.navigator.userAgent) ? 1 : 0;
9707
9735
  function scrollElement(x2, y) {
9708
9736
  this.scrollLeft = x2;
9709
9737
  this.scrollTop = y;
9710
9738
  }
9711
- function ease(k) {
9712
- return 0.5 * (1 - Math.cos(Math.PI * k));
9739
+ function ease(k2) {
9740
+ return 0.5 * (1 - Math.cos(Math.PI * k2));
9713
9741
  }
9714
9742
  function shouldBailOut(firstArg) {
9715
9743
  if (firstArg === null || typeof firstArg !== "object" || firstArg.behavior === void 0 || firstArg.behavior === "auto" || firstArg.behavior === "instant") {
@@ -9731,7 +9759,7 @@ function polyfill(w = window, d = document) {
9731
9759
  }
9732
9760
  }
9733
9761
  function canOverflow(el, axis) {
9734
- const overflowValue = w.getComputedStyle(el, null)["overflow" + axis];
9762
+ const overflowValue = w2.getComputedStyle(el, null)["overflow" + axis];
9735
9763
  return overflowValue === "auto" || overflowValue === "scroll";
9736
9764
  }
9737
9765
  function isScrollable(el) {
@@ -9757,7 +9785,7 @@ function polyfill(w = window, d = document) {
9757
9785
  currentY = context.startY + (context.y - context.startY) * value;
9758
9786
  context.method.call(context.scrollable, currentX, currentY);
9759
9787
  if (currentX !== context.x || currentY !== context.y) {
9760
- w.requestAnimationFrame(step.bind(w, context));
9788
+ w2.requestAnimationFrame(step.bind(w2, context));
9761
9789
  }
9762
9790
  }
9763
9791
  function smoothScroll(el, x2, y) {
@@ -9767,9 +9795,9 @@ function polyfill(w = window, d = document) {
9767
9795
  let method;
9768
9796
  const startTime = now();
9769
9797
  if (el === d.body) {
9770
- scrollable = w;
9771
- startX = w.scrollX || w.pageXOffset;
9772
- startY = w.scrollY || w.pageYOffset;
9798
+ scrollable = w2;
9799
+ startX = w2.scrollX || w2.pageXOffset;
9800
+ startY = w2.scrollY || w2.pageYOffset;
9773
9801
  method = original.scroll;
9774
9802
  } else {
9775
9803
  scrollable = el;
@@ -9787,43 +9815,43 @@ function polyfill(w = window, d = document) {
9787
9815
  y
9788
9816
  });
9789
9817
  }
9790
- w.scroll = w.scrollTo = function() {
9818
+ w2.scroll = w2.scrollTo = function() {
9791
9819
  if (arguments[0] === void 0) {
9792
9820
  return;
9793
9821
  }
9794
9822
  if (shouldBailOut(arguments[0]) === true) {
9795
9823
  original.scroll.call(
9796
- w,
9797
- arguments[0].left !== void 0 ? arguments[0].left : typeof arguments[0] !== "object" ? arguments[0] : w.scrollX || w.pageXOffset,
9824
+ w2,
9825
+ arguments[0].left !== void 0 ? arguments[0].left : typeof arguments[0] !== "object" ? arguments[0] : w2.scrollX || w2.pageXOffset,
9798
9826
  // use top prop, second argument if present or fallback to scrollY
9799
- arguments[0].top !== void 0 ? arguments[0].top : arguments[1] !== void 0 ? arguments[1] : w.scrollY || w.pageYOffset
9827
+ arguments[0].top !== void 0 ? arguments[0].top : arguments[1] !== void 0 ? arguments[1] : w2.scrollY || w2.pageYOffset
9800
9828
  );
9801
9829
  return;
9802
9830
  }
9803
9831
  smoothScroll.call(
9804
- w,
9832
+ w2,
9805
9833
  d.body,
9806
- arguments[0].left !== void 0 ? ~~arguments[0].left : w.scrollX || w.pageXOffset,
9807
- arguments[0].top !== void 0 ? ~~arguments[0].top : w.scrollY || w.pageYOffset
9834
+ arguments[0].left !== void 0 ? ~~arguments[0].left : w2.scrollX || w2.pageXOffset,
9835
+ arguments[0].top !== void 0 ? ~~arguments[0].top : w2.scrollY || w2.pageYOffset
9808
9836
  );
9809
9837
  };
9810
- w.scrollBy = function() {
9838
+ w2.scrollBy = function() {
9811
9839
  if (arguments[0] === void 0) {
9812
9840
  return;
9813
9841
  }
9814
9842
  if (shouldBailOut(arguments[0])) {
9815
9843
  original.scrollBy.call(
9816
- w,
9844
+ w2,
9817
9845
  arguments[0].left !== void 0 ? arguments[0].left : typeof arguments[0] !== "object" ? arguments[0] : 0,
9818
9846
  arguments[0].top !== void 0 ? arguments[0].top : arguments[1] !== void 0 ? arguments[1] : 0
9819
9847
  );
9820
9848
  return;
9821
9849
  }
9822
9850
  smoothScroll.call(
9823
- w,
9851
+ w2,
9824
9852
  d.body,
9825
- ~~arguments[0].left + (w.scrollX || w.pageXOffset),
9826
- ~~arguments[0].top + (w.scrollY || w.pageYOffset)
9853
+ ~~arguments[0].left + (w2.scrollX || w2.pageXOffset),
9854
+ ~~arguments[0].top + (w2.scrollY || w2.pageYOffset)
9827
9855
  );
9828
9856
  };
9829
9857
  Element2.prototype.scroll = Element2.prototype.scrollTo = function() {
@@ -9888,15 +9916,15 @@ function polyfill(w = window, d = document) {
9888
9916
  scrollableParent.scrollLeft + clientRects.left - parentRects.left,
9889
9917
  scrollableParent.scrollTop + clientRects.top - parentRects.top
9890
9918
  );
9891
- if (w.getComputedStyle(scrollableParent).position !== "fixed") {
9892
- w.scrollBy({
9919
+ if (w2.getComputedStyle(scrollableParent).position !== "fixed") {
9920
+ w2.scrollBy({
9893
9921
  left: parentRects.left,
9894
9922
  top: parentRects.top,
9895
9923
  behavior: "smooth"
9896
9924
  });
9897
9925
  }
9898
9926
  } else {
9899
- w.scrollBy({
9927
+ w2.scrollBy({
9900
9928
  left: clientRects.left,
9901
9929
  top: clientRects.top,
9902
9930
  behavior: "smooth"
@@ -10082,16 +10110,16 @@ function s(n2, o2) {
10082
10110
  }(m), b = h.next(); !b.done; b = h.next()) {
10083
10111
  var S = b.value;
10084
10112
  if (void 0 === S) return c(p, g);
10085
- var w = "string" == typeof S ? { target: S } : S, j = w.target, E = w.actions, R = void 0 === E ? [] : E, N = w.cond, O = void 0 === N ? function() {
10113
+ var w2 = "string" == typeof S ? { target: S } : S, j2 = w2.target, E = w2.actions, R = void 0 === E ? [] : E, N2 = w2.cond, O2 = void 0 === N2 ? function() {
10086
10114
  return true;
10087
- } : N, _ = void 0 === j, k = null != j ? j : p, T = n2.states[k];
10088
- if (O(g, d)) {
10089
- var q = t(f((_ ? r(R) : [].concat(x2.exit, R, T.entry).filter(function(t2) {
10115
+ } : N2, _2 = void 0 === j2, k2 = null != j2 ? j2 : p, T = n2.states[k2];
10116
+ if (O2(g, d)) {
10117
+ var q2 = t(f((_2 ? r(R) : [].concat(x2.exit, R, T.entry).filter(function(t2) {
10090
10118
  return t2;
10091
10119
  })).map(function(t2) {
10092
10120
  return i(t2, y._options.actions);
10093
- }), g, d), 3), z = q[0], A = q[1], B = q[2], C = null != j ? j : p;
10094
- return { value: C, context: A, actions: z, changed: j !== p || z.length > 0 || B, matches: a(C) };
10121
+ }), g, d), 3), z = q2[0], A = q2[1], B2 = q2[2], C = null != j2 ? j2 : p;
10122
+ return { value: C, context: A, actions: z, changed: j2 !== p || z.length > 0 || B2, matches: a(C) };
10095
10123
  }
10096
10124
  }
10097
10125
  } catch (t2) {