@betterbugs/replay 2.0.0-alpha.19 → 2.0.0-alpha.20

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/replay.cjs CHANGED
@@ -10785,7 +10785,7 @@ class Replayer {
10785
10785
  speed: 1,
10786
10786
  maxSpeed: 360,
10787
10787
  root: document.body,
10788
- loadTimeout: 0,
10788
+ loadTimeout: 5e3,
10789
10789
  skipInactive: false,
10790
10790
  inactivePeriodThreshold: 10 * 1e3,
10791
10791
  showWarning: true,
@@ -11349,7 +11349,7 @@ class Replayer {
11349
11349
  head.querySelectorAll('link[rel="stylesheet"]').forEach((css) => {
11350
11350
  if (!css.sheet) {
11351
11351
  unloadSheets.add(css);
11352
- css.addEventListener("load", () => {
11352
+ const onLoadOrError = () => {
11353
11353
  unloadSheets.delete(css);
11354
11354
  if (unloadSheets.size === 0 && timer !== -1) {
11355
11355
  if (beforeLoadState.matches("playing")) {
@@ -11361,7 +11361,9 @@ class Replayer {
11361
11361
  }
11362
11362
  unsubscribe();
11363
11363
  }
11364
- });
11364
+ };
11365
+ css.addEventListener("load", onLoadOrError);
11366
+ css.addEventListener("error", onLoadOrError);
11365
11367
  }
11366
11368
  });
11367
11369
  if (unloadSheets.size > 0) {