@ada-support/embed2 1.0.81 → 1.1.0
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/npm-entry/index.js +19 -19
- package/package.json +2 -1
package/dist/npm-entry/index.js
CHANGED
|
@@ -8788,7 +8788,7 @@ var client = new error_tracker_BrowserClient({
|
|
|
8788
8788
|
return event;
|
|
8789
8789
|
},
|
|
8790
8790
|
environment: "production",
|
|
8791
|
-
release: "1.0
|
|
8791
|
+
release: "1.1.0-a8e7d44",
|
|
8792
8792
|
sampleRate: 0.25,
|
|
8793
8793
|
autoSessionTracking: false,
|
|
8794
8794
|
// Integrations don't seem to work with Sentry: https://github.com/getsentry/sentry-javascript/issues/2541
|
|
@@ -9490,7 +9490,7 @@ function getEmbedURL(_ref) {
|
|
|
9490
9490
|
polyfillVersionString = "legacy";
|
|
9491
9491
|
}
|
|
9492
9492
|
|
|
9493
|
-
return concat_default()(_context5 = concat_default()(_context6 = concat_default()(_context7 = "".concat(host, "/embed/")).call(_context7, polyfillVersionString, "/")).call(_context6, frameName, "/")).call(_context5, "
|
|
9493
|
+
return concat_default()(_context5 = concat_default()(_context6 = concat_default()(_context7 = "".concat(host, "/embed/")).call(_context7, polyfillVersionString, "/")).call(_context6, frameName, "/")).call(_context5, "a8e7d44", "/index.html");
|
|
9494
9494
|
}
|
|
9495
9495
|
/**
|
|
9496
9496
|
* Generate the Chat / API URL
|
|
@@ -14374,7 +14374,7 @@ window.__AdaEmbedConstructor = Embed;
|
|
|
14374
14374
|
/* harmony export */ });
|
|
14375
14375
|
var isModern = new RegExp("((CPU[ +]OS|iPhone[ +]OS|CPU[ +]iPhone|CPU IPhone OS)[ +]+(15|(1[6-9]|[2-9]\\d|\\d{3,}))[_.]\\d+(?:[_.]\\d+)?)|((Chromium|Chrome)\\/(99|([1-9]\\d\\d|\\d{4,}))\\.\\d+(?:\\.\\d+)?)|(Version\\/(15|(1[6-9]|[2-9]\\d|\\d{3,}))\\.\\d+(?:\\.\\d+)? Safari\\/)|(Firefox\\/(98|(99|\\d{3,}))\\.\\d+\\.\\d+)|(Firefox\\/(98|(99|\\d{3,}))\\.\\d+(pre|[ab]\\d+[a-z]*)?)").test(navigator.userAgent);
|
|
14376
14376
|
var isProduction = "production" === "production";
|
|
14377
|
-
var embed2Version = "
|
|
14377
|
+
var embed2Version = "a8e7d44";
|
|
14378
14378
|
|
|
14379
14379
|
/***/ }),
|
|
14380
14380
|
|
|
@@ -14720,9 +14720,9 @@ function _log() {
|
|
|
14720
14720
|
service: "embed",
|
|
14721
14721
|
env: "production",
|
|
14722
14722
|
embedVersion: 2,
|
|
14723
|
-
version: "1.0
|
|
14723
|
+
version: "1.1.0",
|
|
14724
14724
|
isNpm: true,
|
|
14725
|
-
commitHash: "
|
|
14725
|
+
commitHash: "a8e7d44"
|
|
14726
14726
|
}))
|
|
14727
14727
|
});
|
|
14728
14728
|
|
|
@@ -25636,24 +25636,24 @@ function loadScript(options) {
|
|
|
25636
25636
|
*/
|
|
25637
25637
|
|
|
25638
25638
|
|
|
25639
|
-
function
|
|
25640
|
-
return
|
|
25639
|
+
function loadClientChunk(_x) {
|
|
25640
|
+
return _loadClientChunk.apply(this, arguments);
|
|
25641
25641
|
}
|
|
25642
25642
|
/**
|
|
25643
25643
|
* Returns the public Embed methods to be bound to the window object.
|
|
25644
25644
|
*/
|
|
25645
25645
|
|
|
25646
25646
|
|
|
25647
|
-
function
|
|
25648
|
-
|
|
25649
|
-
var
|
|
25647
|
+
function _loadClientChunk() {
|
|
25648
|
+
_loadClientChunk = (0,asyncToGenerator/* default */.Z)( /*#__PURE__*/regenerator_default().mark(function _callee17(adaSettings) {
|
|
25649
|
+
var clientScriptSource, _context17, _context18, polyfillVersionString, host, clientScriptLoaded;
|
|
25650
25650
|
|
|
25651
25651
|
return regenerator_default().wrap(function _callee17$(_context19) {
|
|
25652
25652
|
while (1) {
|
|
25653
25653
|
switch (_context19.prev = _context19.next) {
|
|
25654
25654
|
case 0:
|
|
25655
25655
|
if (adaSettings.customDomains) {
|
|
25656
|
-
|
|
25656
|
+
clientScriptSource = config_info/* isModern */.pX ? adaSettings.customDomains.embedModern : adaSettings.customDomains.embedLegacy;
|
|
25657
25657
|
} else {
|
|
25658
25658
|
if (config_info/* isProduction */.yv) {
|
|
25659
25659
|
host = "https://static.ada.support";
|
|
@@ -25663,16 +25663,16 @@ function _loadEmbed() {
|
|
|
25663
25663
|
polyfillVersionString = "legacy";
|
|
25664
25664
|
}
|
|
25665
25665
|
|
|
25666
|
-
|
|
25667
|
-
}
|
|
25666
|
+
clientScriptSource = concat_default()(_context17 = concat_default()(_context18 = "".concat(host, "/embed/")).call(_context18, polyfillVersionString, "/client/")).call(_context17, "a8e7d44", "/index.js");
|
|
25667
|
+
} // `window.__AdaEmbedConstructor` gets created in the "client" bundle
|
|
25668
|
+
|
|
25668
25669
|
|
|
25669
|
-
|
|
25670
|
-
0);
|
|
25670
|
+
clientScriptLoaded = Boolean(window.__AdaEmbedConstructor);
|
|
25671
25671
|
/**
|
|
25672
25672
|
* Check to see if the script has already been added. We only ever want to add the script once.
|
|
25673
25673
|
*/
|
|
25674
25674
|
|
|
25675
|
-
if (
|
|
25675
|
+
if (clientScriptLoaded) {
|
|
25676
25676
|
_context19.next = 11;
|
|
25677
25677
|
break;
|
|
25678
25678
|
}
|
|
@@ -25680,7 +25680,7 @@ function _loadEmbed() {
|
|
|
25680
25680
|
_context19.prev = 3;
|
|
25681
25681
|
_context19.next = 6;
|
|
25682
25682
|
return loadScript({
|
|
25683
|
-
src:
|
|
25683
|
+
src: clientScriptSource
|
|
25684
25684
|
});
|
|
25685
25685
|
|
|
25686
25686
|
case 6:
|
|
@@ -25704,7 +25704,7 @@ function _loadEmbed() {
|
|
|
25704
25704
|
}
|
|
25705
25705
|
}, _callee17, null, [[3, 8]]);
|
|
25706
25706
|
}));
|
|
25707
|
-
return
|
|
25707
|
+
return _loadClientChunk.apply(this, arguments);
|
|
25708
25708
|
}
|
|
25709
25709
|
|
|
25710
25710
|
function createEmbedObject() {
|
|
@@ -25765,7 +25765,7 @@ function createEmbedObject() {
|
|
|
25765
25765
|
*/
|
|
25766
25766
|
|
|
25767
25767
|
_context2.next = 5;
|
|
25768
|
-
return
|
|
25768
|
+
return loadClientChunk(adaSettings);
|
|
25769
25769
|
|
|
25770
25770
|
case 5:
|
|
25771
25771
|
if (!(adaSettings.customDomains && window.__AdaEmbedConstructor && window.__AdaEmbedConstructor.embed2Version !== config_info/* embed2Version */.Mk)) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ada-support/embed2",
|
|
3
|
-
"version": "1.0
|
|
3
|
+
"version": "1.1.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "dist/npm-entry",
|
|
6
6
|
"typings": "dist/npm-entry/index.d.ts",
|
|
@@ -54,6 +54,7 @@
|
|
|
54
54
|
"author": "",
|
|
55
55
|
"license": "ISC",
|
|
56
56
|
"devDependencies": {
|
|
57
|
+
"@ada-support/embed-types": "^1.0.0",
|
|
57
58
|
"@ada-support/eslint-config-ada": "^1.2.1",
|
|
58
59
|
"@types/enzyme": "^3.10.11",
|
|
59
60
|
"@types/jest": "^27.0.2",
|