@openreplay/tracker 3.4.17-beta.0 → 3.4.17-beta.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.
package/cjs/app/index.js CHANGED
@@ -18,7 +18,7 @@ class App {
18
18
  this.commitCallbacks = [];
19
19
  this._sessionID = null;
20
20
  this.isActive = false;
21
- this.version = '3.4.17-beta.0';
21
+ this.version = '3.4.17-beta.1';
22
22
  this.projectKey = projectKey;
23
23
  this.options = Object.assign({
24
24
  revID: '',
@@ -5,7 +5,8 @@ const context_js_1 = require("../context.js");
5
5
  const iframe_observer_js_1 = require("./iframe_observer.js");
6
6
  const shadow_root_observer_js_1 = require("./shadow_root_observer.js");
7
7
  const index_js_1 = require("../../messages/index.js");
8
- const attachShadowNativeFn = Element.prototype.attachShadow;
8
+ const utils_js_1 = require("../../utils.js");
9
+ const attachShadowNativeFn = utils_js_1.IN_BROWSER ? Element.prototype.attachShadow : () => new ShadowRoot();
9
10
  class TopObserver extends observer_js_1.default {
10
11
  constructor(app, options) {
11
12
  super(app);
package/cjs/index.js CHANGED
@@ -115,7 +115,7 @@ class API {
115
115
  // no-cors issue only with text/plain or not-set Content-Type
116
116
  // req.setRequestHeader("Content-Type", "application/json;charset=UTF-8");
117
117
  req.send(JSON.stringify({
118
- trackerVersion: '3.4.17-beta.0',
118
+ trackerVersion: '3.4.17-beta.1',
119
119
  projectKey: options.projectKey,
120
120
  doNotTrack,
121
121
  // TODO: add precise reason (an exact API missing)
package/lib/app/index.js CHANGED
@@ -15,7 +15,7 @@ export default class App {
15
15
  this.commitCallbacks = [];
16
16
  this._sessionID = null;
17
17
  this.isActive = false;
18
- this.version = '3.4.17-beta.0';
18
+ this.version = '3.4.17-beta.1';
19
19
  this.projectKey = projectKey;
20
20
  this.options = Object.assign({
21
21
  revID: '',
@@ -3,7 +3,8 @@ import { isInstance } from "../context.js";
3
3
  import IFrameObserver from "./iframe_observer.js";
4
4
  import ShadowRootObserver from "./shadow_root_observer.js";
5
5
  import { CreateDocument } from "../../messages/index.js";
6
- const attachShadowNativeFn = Element.prototype.attachShadow;
6
+ import { IN_BROWSER } from '../../utils.js';
7
+ const attachShadowNativeFn = IN_BROWSER ? Element.prototype.attachShadow : () => new ShadowRoot();
7
8
  export default class TopObserver extends Observer {
8
9
  constructor(app, options) {
9
10
  super(app);
package/lib/index.js CHANGED
@@ -111,7 +111,7 @@ export default class API {
111
111
  // no-cors issue only with text/plain or not-set Content-Type
112
112
  // req.setRequestHeader("Content-Type", "application/json;charset=UTF-8");
113
113
  req.send(JSON.stringify({
114
- trackerVersion: '3.4.17-beta.0',
114
+ trackerVersion: '3.4.17-beta.1',
115
115
  projectKey: options.projectKey,
116
116
  doNotTrack,
117
117
  // TODO: add precise reason (an exact API missing)
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@openreplay/tracker",
3
3
  "description": "The OpenReplay tracker main package",
4
- "version": "3.4.17-beta.0",
4
+ "version": "3.4.17-beta.1",
5
5
  "keywords": [
6
6
  "logging",
7
7
  "replay"