@amplitude/plugin-session-replay-browser
Advanced tools
Comparing version 0.4.0 to 0.4.1
@@ -74,5 +74,2 @@ Object.defineProperty(exports, "__esModule", { value: true }); | ||
} | ||
return [4 /*yield*/, this.initialize(true)]; | ||
case 1: | ||
_a.sent(); | ||
GlobalScope = (0, analytics_client_common_1.getGlobalScope)(); | ||
@@ -88,3 +85,8 @@ if (GlobalScope && GlobalScope.window) { | ||
} | ||
return [2 /*return*/]; | ||
if (!(GlobalScope && GlobalScope.document && GlobalScope.document.hasFocus())) return [3 /*break*/, 2]; | ||
return [4 /*yield*/, this.initialize(true)]; | ||
case 1: | ||
_a.sent(); | ||
_a.label = 2; | ||
case 2: return [2 /*return*/]; | ||
} | ||
@@ -96,4 +98,9 @@ }); | ||
return tslib_1.__awaiter(this, void 0, void 0, function () { | ||
var GlobalScope; | ||
var _a; | ||
return tslib_1.__generator(this, function (_b) { | ||
GlobalScope = (0, analytics_client_common_1.getGlobalScope)(); | ||
if (GlobalScope && GlobalScope.document && !GlobalScope.document.hasFocus()) { | ||
return [2 /*return*/, Promise.resolve(event)]; | ||
} | ||
if (this.shouldRecord) { | ||
@@ -100,0 +107,0 @@ event.event_properties = tslib_1.__assign(tslib_1.__assign({}, event.event_properties), (_a = {}, _a[constants_1.DEFAULT_SESSION_REPLAY_PROPERTY] = true, _a)); |
@@ -72,5 +72,2 @@ import { __assign, __awaiter, __generator, __read } from "tslib"; | ||
} | ||
return [4 /*yield*/, this.initialize(true)]; | ||
case 1: | ||
_a.sent(); | ||
GlobalScope = getGlobalScope(); | ||
@@ -86,3 +83,8 @@ if (GlobalScope && GlobalScope.window) { | ||
} | ||
return [2 /*return*/]; | ||
if (!(GlobalScope && GlobalScope.document && GlobalScope.document.hasFocus())) return [3 /*break*/, 2]; | ||
return [4 /*yield*/, this.initialize(true)]; | ||
case 1: | ||
_a.sent(); | ||
_a.label = 2; | ||
case 2: return [2 /*return*/]; | ||
} | ||
@@ -94,4 +96,9 @@ }); | ||
return __awaiter(this, void 0, void 0, function () { | ||
var GlobalScope; | ||
var _a; | ||
return __generator(this, function (_b) { | ||
GlobalScope = getGlobalScope(); | ||
if (GlobalScope && GlobalScope.document && !GlobalScope.document.hasFocus()) { | ||
return [2 /*return*/, Promise.resolve(event)]; | ||
} | ||
if (this.shouldRecord) { | ||
@@ -98,0 +105,0 @@ event.event_properties = __assign(__assign({}, event.event_properties), (_a = {}, _a[DEFAULT_SESSION_REPLAY_PROPERTY] = true, _a)); |
{ | ||
"name": "@amplitude/plugin-session-replay-browser", | ||
"version": "0.4.0", | ||
"version": "0.4.1", | ||
"description": "", | ||
@@ -58,3 +58,3 @@ "author": "Amplitude Inc", | ||
], | ||
"gitHead": "66d8395c7bac0a60252a80ddf03e037301150b86" | ||
"gitHead": "856f91dc11c7f0336a800e299838ef2e2b8556df" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
409872
2124