@kameleoon/javascript-sdk-core 2.4.6 → 2.5.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/dist/cacheManager/cacheManager.js +3 -65
- package/dist/cacheManager/cacheManager.js.map +1 -1
- package/dist/cacheManager/index.js +1 -19
- package/dist/cacheManager/index.js.map +1 -1
- package/dist/cacheManager/types.js +1 -5
- package/dist/campaignConfiguration/campaignConfiguration.d.ts +10 -7
- package/dist/campaignConfiguration/campaignConfiguration.js +9 -283
- package/dist/campaignConfiguration/campaignConfiguration.js.map +1 -1
- package/dist/campaignConfiguration/constants.d.ts +2 -10
- package/dist/campaignConfiguration/constants.js +2 -21
- package/dist/campaignConfiguration/constants.js.map +1 -1
- package/dist/campaignConfiguration/index.js +1 -86
- package/dist/campaignConfiguration/index.js.map +1 -1
- package/dist/campaignConfiguration/types.d.ts +8 -7
- package/dist/campaignConfiguration/types.js +1 -54
- package/dist/campaignConfiguration/types.js.map +1 -1
- package/dist/clientSettings/clientSettings.d.ts +1 -1
- package/dist/clientSettings/clientSettings.js +1 -35
- package/dist/clientSettings/clientSettings.js.map +1 -1
- package/dist/clientSettings/index.js +1 -19
- package/dist/clientSettings/index.js.map +1 -1
- package/dist/clientSettings/types.d.ts +1 -1
- package/dist/clientSettings/types.js +1 -5
- package/dist/clientSettings/types.js.map +1 -1
- package/dist/constants.d.ts +13 -4
- package/dist/constants.js +2 -36
- package/dist/constants.js.map +1 -1
- package/dist/eventSource/constants.js +1 -8
- package/dist/eventSource/constants.js.map +1 -1
- package/dist/eventSource/externalEventSource.js +1 -33
- package/dist/eventSource/externalEventSource.js.map +1 -1
- package/dist/eventSource/index.js +1 -50
- package/dist/eventSource/index.js.map +1 -1
- package/dist/eventSource/types.js +1 -5
- package/dist/hasher/hasher.js +6 -44
- package/dist/hasher/hasher.js.map +1 -1
- package/dist/hasher/index.js +1 -12
- package/dist/hasher/index.js.map +1 -1
- package/dist/hasher/types.d.ts +1 -1
- package/dist/hasher/types.js +1 -5
- package/dist/hasher/types.js.map +1 -1
- package/dist/index.d.ts +3 -3
- package/dist/index.js +1 -310
- package/dist/index.js.map +1 -1
- package/dist/kameleoonClient.d.ts +16 -4
- package/dist/kameleoonClient.js +10 -384
- package/dist/kameleoonClient.js.map +1 -1
- package/dist/kameleoonData/browser.d.ts +8 -3
- package/dist/kameleoonData/browser.js +9 -40
- package/dist/kameleoonData/browser.js.map +1 -1
- package/dist/kameleoonData/conversion.d.ts +2 -2
- package/dist/kameleoonData/conversion.js +5 -50
- package/dist/kameleoonData/conversion.js.map +1 -1
- package/dist/kameleoonData/customData.d.ts +2 -2
- package/dist/kameleoonData/customData.js +5 -55
- package/dist/kameleoonData/customData.js.map +1 -1
- package/dist/kameleoonData/device.d.ts +2 -2
- package/dist/kameleoonData/device.js +5 -40
- package/dist/kameleoonData/device.js.map +1 -1
- package/dist/kameleoonData/index.d.ts +1 -1
- package/dist/kameleoonData/index.js +1 -102
- package/dist/kameleoonData/index.js.map +1 -1
- package/dist/kameleoonData/pageView.d.ts +2 -2
- package/dist/kameleoonData/pageView.js +5 -56
- package/dist/kameleoonData/pageView.js.map +1 -1
- package/dist/kameleoonData/types.d.ts +44 -27
- package/dist/kameleoonData/types.js +6 -42
- package/dist/kameleoonData/types.js.map +1 -1
- package/dist/kameleoonData/userAgent.d.ts +2 -2
- package/dist/kameleoonData/userAgent.js +4 -37
- package/dist/kameleoonData/userAgent.js.map +1 -1
- package/dist/kameleoonError/constants.d.ts +4 -2
- package/dist/kameleoonError/constants.js +1 -31
- package/dist/kameleoonError/constants.js.map +1 -1
- package/dist/kameleoonError/helpers.js +1 -9
- package/dist/kameleoonError/helpers.js.map +1 -1
- package/dist/kameleoonError/index.js +1 -26
- package/dist/kameleoonError/index.js.map +1 -1
- package/dist/kameleoonError/kameleoonError.d.ts +3 -3
- package/dist/kameleoonError/kameleoonError.js +2 -75
- package/dist/kameleoonError/kameleoonError.js.map +1 -1
- package/dist/kameleoonError/types.d.ts +2 -0
- package/dist/kameleoonError/types.js +1 -31
- package/dist/kameleoonError/types.js.map +1 -1
- package/dist/kameleoonUtils.js +2 -44
- package/dist/kameleoonUtils.js.map +1 -1
- package/dist/requester/constants.js +1 -73
- package/dist/requester/constants.js.map +1 -1
- package/dist/requester/index.js +1 -80
- package/dist/requester/index.js.map +1 -1
- package/dist/requester/requester.d.ts +4 -5
- package/dist/requester/requester.js +1 -106
- package/dist/requester/requester.js.map +1 -1
- package/dist/requester/types.d.ts +8 -7
- package/dist/requester/types.js +1 -16
- package/dist/requester/types.js.map +1 -1
- package/dist/storage/constants.js +2 -15
- package/dist/storage/constants.js.map +1 -1
- package/dist/storage/externalStorage.d.ts +1 -1
- package/dist/storage/externalStorage.js +1 -40
- package/dist/storage/externalStorage.js.map +1 -1
- package/dist/storage/index.js +1 -56
- package/dist/storage/index.js.map +1 -1
- package/dist/storage/types.d.ts +4 -4
- package/dist/storage/types.js +1 -5
- package/dist/storage/types.js.map +1 -1
- package/dist/targeting/conditions/browserCondition.d.ts +13 -0
- package/dist/targeting/conditions/browserCondition.js +2 -0
- package/dist/targeting/conditions/browserCondition.js.map +1 -0
- package/dist/targeting/conditions/conditionFactory.d.ts +1 -1
- package/dist/targeting/conditions/conditionFactory.js +1 -30
- package/dist/targeting/conditions/conditionFactory.js.map +1 -1
- package/dist/targeting/conditions/conversionCondition.d.ts +10 -0
- package/dist/targeting/conditions/conversionCondition.js +4 -0
- package/dist/targeting/conditions/conversionCondition.js.map +1 -0
- package/dist/targeting/conditions/customDataCondition.d.ts +5 -7
- package/dist/targeting/conditions/customDataCondition.js +7 -114
- package/dist/targeting/conditions/customDataCondition.js.map +1 -1
- package/dist/targeting/conditions/deviceCondition.d.ts +9 -0
- package/dist/targeting/conditions/deviceCondition.js +2 -0
- package/dist/targeting/conditions/deviceCondition.js.map +1 -0
- package/dist/targeting/conditions/exclusiveExperimentCondition.d.ts +3 -5
- package/dist/targeting/conditions/exclusiveExperimentCondition.js +1 -32
- package/dist/targeting/conditions/exclusiveExperimentCondition.js.map +1 -1
- package/dist/targeting/conditions/index.d.ts +7 -0
- package/dist/targeting/conditions/index.js +1 -46
- package/dist/targeting/conditions/index.js.map +1 -1
- package/dist/targeting/conditions/pageTitleCondition.d.ts +11 -0
- package/dist/targeting/conditions/pageTitleCondition.js +2 -0
- package/dist/targeting/conditions/pageTitleCondition.js.map +1 -0
- package/dist/targeting/conditions/pageUrlCondition.d.ts +11 -0
- package/dist/targeting/conditions/pageUrlCondition.js +2 -0
- package/dist/targeting/conditions/pageUrlCondition.js.map +1 -0
- package/dist/targeting/conditions/sdkLanguageCondition.d.ts +15 -0
- package/dist/targeting/conditions/sdkLanguageCondition.js +2 -0
- package/dist/targeting/conditions/sdkLanguageCondition.js.map +1 -0
- package/dist/targeting/conditions/targetExperimentCondition.d.ts +3 -4
- package/dist/targeting/conditions/targetExperimentCondition.js +1 -63
- package/dist/targeting/conditions/targetExperimentCondition.js.map +1 -1
- package/dist/targeting/conditions/types.d.ts +25 -6
- package/dist/targeting/conditions/types.js +1 -5
- package/dist/targeting/conditions/types.js.map +1 -1
- package/dist/targeting/conditions/visitorCodeCondition.d.ts +11 -0
- package/dist/targeting/conditions/visitorCodeCondition.js +2 -0
- package/dist/targeting/conditions/visitorCodeCondition.js.map +1 -0
- package/dist/targeting/index.d.ts +2 -2
- package/dist/targeting/index.js +1 -80
- package/dist/targeting/index.js.map +1 -1
- package/dist/targeting/targetingNode.d.ts +3 -1
- package/dist/targeting/targetingNode.js +1 -47
- package/dist/targeting/targetingNode.js.map +1 -1
- package/dist/targeting/targetingTree.d.ts +3 -1
- package/dist/targeting/targetingTree.js +34 -135
- package/dist/targeting/targetingTree.js.map +1 -1
- package/dist/targeting/types.d.ts +24 -9
- package/dist/targeting/types.js +1 -100
- package/dist/targeting/types.js.map +1 -1
- package/dist/types.d.ts +9 -4
- package/dist/types.js +12 -41
- package/dist/types.js.map +1 -1
- package/dist/utilities/constants.d.ts +1 -0
- package/dist/utilities/constants.js +1 -8
- package/dist/utilities/constants.js.map +1 -1
- package/dist/utilities/index.d.ts +1 -0
- package/dist/utilities/index.js +1 -12
- package/dist/utilities/index.js.map +1 -1
- package/dist/utilities/types.d.ts +14 -7
- package/dist/utilities/types.js +1 -5
- package/dist/utilities/types.js.map +1 -1
- package/dist/utilities/utilities.d.ts +12 -8
- package/dist/utilities/utilities.js +1 -216
- package/dist/utilities/utilities.js.map +1 -1
- package/dist/variationConfiguration/index.js +1 -25
- package/dist/variationConfiguration/index.js.map +1 -1
- package/dist/variationConfiguration/types.d.ts +5 -3
- package/dist/variationConfiguration/types.js +1 -5
- package/dist/variationConfiguration/types.js.map +1 -1
- package/dist/variationConfiguration/variation.d.ts +1 -1
- package/dist/variationConfiguration/variation.js +6 -44
- package/dist/variationConfiguration/variation.js.map +1 -1
- package/dist/variationConfiguration/variationConfiguration.d.ts +4 -4
- package/dist/variationConfiguration/variationConfiguration.js +65 -290
- package/dist/variationConfiguration/variationConfiguration.js.map +1 -1
- package/package.json +1 -1
- package/dist/kameleoonData/constants.d.ts +0 -1
- package/dist/kameleoonData/constants.js +0 -9
- package/dist/kameleoonData/constants.js.map +0 -1
- package/dist/kameleoonData/nonce.d.ts +0 -5
- package/dist/kameleoonData/nonce.js +0 -32
- package/dist/kameleoonData/nonce.js.map +0 -1
package/dist/constants.js
CHANGED
|
@@ -1,39 +1,5 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.VISITOR_CODE_LENGTH = exports.UNALLOCATED_VARIATION_ID = exports.SDKType = exports.OFF_VARIATION_KEY = exports.KAMELEOON_COOKIE_KEY = exports.Cookie = exports.CACHE_ITEM_LIFETIME = exports.CACHE_CLEANUP_TIMEOUT = void 0;
|
|
7
|
-
const UNALLOCATED_VARIATION_ID = 0;
|
|
8
|
-
exports.UNALLOCATED_VARIATION_ID = UNALLOCATED_VARIATION_ID;
|
|
9
|
-
const OFF_VARIATION_KEY = 'off';
|
|
10
|
-
exports.OFF_VARIATION_KEY = OFF_VARIATION_KEY;
|
|
11
|
-
const KAMELEOON_COOKIE_KEY = 'kameleoonVisitorCode';
|
|
12
|
-
exports.KAMELEOON_COOKIE_KEY = KAMELEOON_COOKIE_KEY;
|
|
13
|
-
const VISITOR_CODE_LENGTH = 16;
|
|
14
|
-
exports.VISITOR_CODE_LENGTH = VISITOR_CODE_LENGTH;
|
|
15
|
-
const CACHE_CLEANUP_TIMEOUT = 10;
|
|
16
|
-
exports.CACHE_CLEANUP_TIMEOUT = CACHE_CLEANUP_TIMEOUT;
|
|
17
|
-
const CACHE_ITEM_LIFETIME = 5;
|
|
18
|
-
exports.CACHE_ITEM_LIFETIME = CACHE_ITEM_LIFETIME;
|
|
19
|
-
let Cookie = /*#__PURE__*/function (Cookie) {
|
|
20
|
-
Cookie["PairsDelimiter"] = "; ";
|
|
21
|
-
Cookie["KeyValueDelimiter"] = "=";
|
|
22
|
-
Cookie["MaxAge"] = "Max-Age";
|
|
23
|
-
Cookie["Path"] = "Path";
|
|
24
|
-
Cookie["Domain"] = "Domain";
|
|
25
|
-
return Cookie;
|
|
26
|
-
}({});
|
|
27
|
-
/**
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.VISITOR_CODE_LENGTH=exports.UNALLOCATED_VARIATION_ID=exports.SdkLanguageType=exports.OFF_VARIATION_KEY=exports.KAMELEOON_COOKIE_KEY=exports.Cookie=exports.CACHE_ITEM_LIFETIME=exports.CACHE_CLEANUP_TIMEOUT=void 0;var UNALLOCATED_VARIATION_ID=0;exports.UNALLOCATED_VARIATION_ID=0;var OFF_VARIATION_KEY="off";exports.OFF_VARIATION_KEY="off";var KAMELEOON_COOKIE_KEY="kameleoonVisitorCode";exports.KAMELEOON_COOKIE_KEY="kameleoonVisitorCode";var VISITOR_CODE_LENGTH=16;exports.VISITOR_CODE_LENGTH=16;var CACHE_CLEANUP_TIMEOUT=10;exports.CACHE_CLEANUP_TIMEOUT=10;var CACHE_ITEM_LIFETIME=5;exports.CACHE_ITEM_LIFETIME=5;var Cookie=/*#__PURE__*/function(a){return a.PairsDelimiter="; ",a.KeyValueDelimiter="=",a.MaxAge="Max-Age",a.Path="Path",a.Domain="Domain",a}({});/**
|
|
28
2
|
* @readonly
|
|
29
3
|
* @enum {string} an Enum of all the possible Kameleoon SDK types
|
|
30
|
-
* */
|
|
31
|
-
exports.Cookie = Cookie;
|
|
32
|
-
let SDKType = /*#__PURE__*/function (SDKType) {
|
|
33
|
-
SDKType["NodeJS"] = "nodejs";
|
|
34
|
-
SDKType["JavaScript"] = "javascript";
|
|
35
|
-
SDKType["React"] = "react";
|
|
36
|
-
return SDKType;
|
|
37
|
-
}({});
|
|
38
|
-
exports.SDKType = SDKType;
|
|
4
|
+
* */exports.Cookie=Cookie;var SdkLanguageType=/*#__PURE__*/function(a){return a.ANDROID="ANDROID",a.SWIFT="SWIFT",a.JAVA="JAVA",a.CSHARP="CSHARP",a.NODEJS="NODEJS",a.PHP="PHP",a.RUBY="RUBY",a.GO="GO",a.FLUTTER="FLUTTER",a.REACT="REACT",a.PYTHON="PYTHON",a.JAVASCRIPT="JAVASCRIPT",a}({});exports.SdkLanguageType=SdkLanguageType;
|
|
39
5
|
//# sourceMappingURL=constants.js.map
|
package/dist/constants.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.js","names":["UNALLOCATED_VARIATION_ID","exports","OFF_VARIATION_KEY","KAMELEOON_COOKIE_KEY","VISITOR_CODE_LENGTH","CACHE_CLEANUP_TIMEOUT","CACHE_ITEM_LIFETIME","Cookie","
|
|
1
|
+
{"version":3,"file":"constants.js","names":["UNALLOCATED_VARIATION_ID","exports","OFF_VARIATION_KEY","KAMELEOON_COOKIE_KEY","VISITOR_CODE_LENGTH","CACHE_CLEANUP_TIMEOUT","CACHE_ITEM_LIFETIME","Cookie","PairsDelimiter","KeyValueDelimiter","MaxAge","Path","Domain","SdkLanguageType","ANDROID","SWIFT","JAVA","CSHARP","NODEJS","PHP","RUBY","GO","FLUTTER","REACT","PYTHON","JAVASCRIPT"],"sources":["../src/constants.ts"],"sourcesContent":["export const UNALLOCATED_VARIATION_ID = 0;\nexport const OFF_VARIATION_KEY = 'off';\nexport const KAMELEOON_COOKIE_KEY = 'kameleoonVisitorCode';\nexport const VISITOR_CODE_LENGTH = 16;\nexport const CACHE_CLEANUP_TIMEOUT = 10;\nexport const CACHE_ITEM_LIFETIME = 5;\n\nexport enum Cookie {\n PairsDelimiter = '; ',\n KeyValueDelimiter = '=',\n MaxAge = 'Max-Age',\n Path = 'Path',\n Domain = 'Domain',\n}\n\n/**\n * @readonly\n * @enum {string} an Enum of all the possible Kameleoon SDK types\n * */\nexport enum SdkLanguageType {\n ANDROID = 'ANDROID',\n SWIFT = 'SWIFT',\n JAVA = 'JAVA',\n CSHARP = 'CSHARP',\n NODEJS = 'NODEJS',\n PHP = 'PHP',\n RUBY = 'RUBY',\n GO = 'GO',\n FLUTTER = 'FLUTTER',\n REACT = 'REACT',\n PYTHON = 'PYTHON',\n JAVASCRIPT = 'JAVASCRIPT',\n}\n"],"mappings":"gSAAO,GAAM,CAAAA,wBAAwB,CAAG,CAAC,CAACC,OAAA,CAAAD,wBAAA,GACnC,GAAM,CAAAE,iBAAiB,CAAG,KAAK,CAACD,OAAA,CAAAC,iBAAA,OAChC,GAAM,CAAAC,oBAAoB,CAAG,sBAAsB,CAACF,OAAA,CAAAE,oBAAA,wBACpD,GAAM,CAAAC,mBAAmB,CAAG,EAAE,CAACH,OAAA,CAAAG,mBAAA,IAC/B,GAAM,CAAAC,qBAAqB,CAAG,EAAE,CAACJ,OAAA,CAAAI,qBAAA,IACjC,GAAM,CAAAC,mBAAmB,CAAG,CAAC,CAACL,OAAA,CAAAK,mBAAA,MAEzB,CAAAC,MAAM,uBAANA,CAAM,QAAN,CAAAA,CAAM,CAAAC,cAAA,MAAND,CAAM,CAAAE,iBAAA,KAANF,CAAM,CAAAG,MAAA,WAANH,CAAM,CAAAI,IAAA,QAANJ,CAAM,CAAAK,MAAA,UAANL,CAAM,MAQlB;AACA;AACA;AACA,KAHAN,OAAA,CAAAM,MAAA,CAAAA,MAAA,IAIY,CAAAM,eAAe,uBAAfA,CAAe,QAAf,CAAAA,CAAe,CAAAC,OAAA,WAAfD,CAAe,CAAAE,KAAA,SAAfF,CAAe,CAAAG,IAAA,QAAfH,CAAe,CAAAI,MAAA,UAAfJ,CAAe,CAAAK,MAAA,UAAfL,CAAe,CAAAM,GAAA,OAAfN,CAAe,CAAAO,IAAA,QAAfP,CAAe,CAAAQ,EAAA,MAAfR,CAAe,CAAAS,OAAA,WAAfT,CAAe,CAAAU,KAAA,SAAfV,CAAe,CAAAW,MAAA,UAAfX,CAAe,CAAAY,UAAA,cAAfZ,CAAe,MAAAZ,OAAA,CAAAY,eAAA,CAAAA,eAAA"}
|
|
@@ -1,9 +1,2 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.REAL_TIME_EVENT = void 0;
|
|
7
|
-
const REAL_TIME_EVENT = 'configuration-update-event';
|
|
8
|
-
exports.REAL_TIME_EVENT = REAL_TIME_EVENT;
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.REAL_TIME_EVENT=void 0;var REAL_TIME_EVENT="configuration-update-event";exports.REAL_TIME_EVENT="configuration-update-event";
|
|
9
2
|
//# sourceMappingURL=constants.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.js","names":["REAL_TIME_EVENT","exports"],"sources":["../../src/eventSource/constants.ts"],"sourcesContent":["export const REAL_TIME_EVENT = 'configuration-update-event';\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"constants.js","names":["REAL_TIME_EVENT","exports"],"sources":["../../src/eventSource/constants.ts"],"sourcesContent":["export const REAL_TIME_EVENT = 'configuration-update-event';\n"],"mappings":"mGAAO,GAAM,CAAAA,eAAe,CAAG,4BAA4B,CAACC,OAAA,CAAAD,eAAA"}
|
|
@@ -1,34 +1,2 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.ExternalEventSource = void 0;
|
|
7
|
-
var _requester = require("../requester");
|
|
8
|
-
var _constants = require("../requester/constants");
|
|
9
|
-
var _constants2 = require("./constants");
|
|
10
|
-
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
11
|
-
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return typeof key === "symbol" ? key : String(key); }
|
|
12
|
-
function _toPrimitive(input, hint) { if (typeof input !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (typeof res !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
13
|
-
class ExternalEventSource {
|
|
14
|
-
constructor(siteCode, externalEventSource) {
|
|
15
|
-
_defineProperty(this, "eventSource", void 0);
|
|
16
|
-
_defineProperty(this, "siteCode", void 0);
|
|
17
|
-
const url = _requester.URL.SERVER_SENT_EVENTS + _constants.UrlQuery.Sse + siteCode;
|
|
18
|
-
const eventSource = externalEventSource.initialize(url);
|
|
19
|
-
this.eventSource = eventSource;
|
|
20
|
-
this.siteCode = siteCode;
|
|
21
|
-
}
|
|
22
|
-
open(onEvent) {
|
|
23
|
-
this.eventSource.open({
|
|
24
|
-
onEvent,
|
|
25
|
-
siteCode: this.siteCode,
|
|
26
|
-
eventType: _constants2.REAL_TIME_EVENT
|
|
27
|
-
});
|
|
28
|
-
}
|
|
29
|
-
close() {
|
|
30
|
-
this.eventSource.close();
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
exports.ExternalEventSource = ExternalEventSource;
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.ExternalEventSource=void 0;var _requester=require("../requester"),_constants=require("../requester/constants"),_constants2=require("./constants");function _typeof(a){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},_typeof(a)}function _classCallCheck(a,b){if(!(a instanceof b))throw new TypeError("Cannot call a class as a function")}function _defineProperties(a,b){for(var c,d=0;d<b.length;d++)c=b[d],c.enumerable=c.enumerable||!1,c.configurable=!0,"value"in c&&(c.writable=!0),Object.defineProperty(a,_toPropertyKey(c.key),c)}function _createClass(a,b,c){return b&&_defineProperties(a.prototype,b),c&&_defineProperties(a,c),Object.defineProperty(a,"prototype",{writable:!1}),a}function _defineProperty(a,b,c){return b=_toPropertyKey(b),b in a?Object.defineProperty(a,b,{value:c,enumerable:!0,configurable:!0,writable:!0}):a[b]=c,a}function _toPropertyKey(a){var b=_toPrimitive(a,"string");return"symbol"===_typeof(b)?b:b+""}function _toPrimitive(a,b){if("object"!==_typeof(a)||null===a)return a;var c=a[Symbol.toPrimitive];if(c!==void 0){var d=c.call(a,b||"default");if("object"!==_typeof(d))return d;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===b?String:Number)(a)}var ExternalEventSource=/*#__PURE__*/function(){function a(b,c){_classCallCheck(this,a),_defineProperty(this,"eventSource",void 0),_defineProperty(this,"siteCode",void 0);var d=_requester.URL.SERVER_SENT_EVENTS+_constants.UrlQuery.Sse+b,e=c.initialize(d);this.eventSource=e,this.siteCode=b}return _createClass(a,[{key:"open",value:function open(a){this.eventSource.open({onEvent:a,siteCode:this.siteCode,eventType:_constants2.REAL_TIME_EVENT})}},{key:"close",value:function close(){this.eventSource.close()}}]),a}();exports.ExternalEventSource=ExternalEventSource;
|
|
34
2
|
//# sourceMappingURL=externalEventSource.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"externalEventSource.js","names":["
|
|
1
|
+
{"version":3,"file":"externalEventSource.js","names":["ExternalEventSource","a","siteCode","externalEventSource","_classCallCheck","_defineProperty","url","URL","SERVER_SENT_EVENTS","UrlQuery","Sse","eventSource","initialize","_createClass","key","value","open","onEvent","eventType","REAL_TIME_EVENT","close","exports"],"sources":["../../src/eventSource/externalEventSource.ts"],"sourcesContent":["import { URL } from 'src/requester';\nimport { UrlQuery } from 'src/requester/constants';\nimport { REAL_TIME_EVENT } from './constants';\nimport { IExternalEventSource, IExternalEventSourceConstructor } from './types';\n\nexport interface IEventSource {\n open: (onEvent: (timestamp: number) => void) => void;\n close: () => void;\n}\n\nexport class ExternalEventSource implements IEventSource {\n private eventSource: IExternalEventSource;\n private siteCode: string;\n\n constructor(\n siteCode: string,\n externalEventSource: IExternalEventSourceConstructor,\n ) {\n const url = URL.SERVER_SENT_EVENTS + UrlQuery.Sse + siteCode;\n const eventSource = externalEventSource.initialize(url);\n\n this.eventSource = eventSource;\n this.siteCode = siteCode;\n }\n\n public open(onEvent: (timestamp: number) => void): void {\n this.eventSource.open({\n onEvent,\n siteCode: this.siteCode,\n eventType: REAL_TIME_EVENT,\n });\n }\n\n public close(): void {\n this.eventSource.close();\n }\n}\n"],"mappings":"08CAUa,CAAAA,mBAAmB,yBAI9B,SAAAC,EACEC,CAAgB,CAChBC,CAAoD,CACpD,CAAAC,eAAA,MAAAH,CAAA,EAAAI,eAAA,4BAAAA,eAAA,4BACM,CAAAC,CAAG,CAAGC,cAAG,CAACC,kBAAkB,CAAGC,mBAAQ,CAACC,GAAG,CAAGR,CAAQ,CACtDS,CAAW,CAAGR,CAAmB,CAACS,UAAU,CAACN,CAAG,CAAC,CAEvD,IAAI,CAACK,WAAW,CAAGA,CAAW,CAC9B,IAAI,CAACT,QAAQ,CAAGA,CAClB,CAAC,OAAAW,YAAA,CAAAZ,CAAA,GAAAa,GAAA,QAAAC,KAAA,CAED,SAAAC,KAAYC,CAAoC,CAAQ,CACtD,IAAI,CAACN,WAAW,CAACK,IAAI,CAAC,CACpBC,OAAO,CAAPA,CAAO,CACPf,QAAQ,CAAE,IAAI,CAACA,QAAQ,CACvBgB,SAAS,CAAEC,2BACb,CAAC,CACH,CAAC,GAAAL,GAAA,SAAAC,KAAA,CAED,SAAAK,MAAA,CAAqB,CACnB,IAAI,CAACT,WAAW,CAACS,KAAK,EACxB,CAAC,IAAAnB,CAAA,IAAAoB,OAAA,CAAArB,mBAAA,CAAAA,mBAAA"}
|
|
@@ -1,51 +1,2 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
Object.defineProperty(exports, "EventSourceOpenParametersType", {
|
|
7
|
-
enumerable: true,
|
|
8
|
-
get: function () {
|
|
9
|
-
return _types.EventSourceOpenParametersType;
|
|
10
|
-
}
|
|
11
|
-
});
|
|
12
|
-
Object.defineProperty(exports, "ExternalEventSource", {
|
|
13
|
-
enumerable: true,
|
|
14
|
-
get: function () {
|
|
15
|
-
return _externalEventSource.ExternalEventSource;
|
|
16
|
-
}
|
|
17
|
-
});
|
|
18
|
-
Object.defineProperty(exports, "IEventSource", {
|
|
19
|
-
enumerable: true,
|
|
20
|
-
get: function () {
|
|
21
|
-
return _externalEventSource.IEventSource;
|
|
22
|
-
}
|
|
23
|
-
});
|
|
24
|
-
Object.defineProperty(exports, "IExternalEventSource", {
|
|
25
|
-
enumerable: true,
|
|
26
|
-
get: function () {
|
|
27
|
-
return _types.IExternalEventSource;
|
|
28
|
-
}
|
|
29
|
-
});
|
|
30
|
-
Object.defineProperty(exports, "IExternalEventSourceConstructor", {
|
|
31
|
-
enumerable: true,
|
|
32
|
-
get: function () {
|
|
33
|
-
return _types.IExternalEventSourceConstructor;
|
|
34
|
-
}
|
|
35
|
-
});
|
|
36
|
-
Object.defineProperty(exports, "REAL_TIME_EVENT", {
|
|
37
|
-
enumerable: true,
|
|
38
|
-
get: function () {
|
|
39
|
-
return _constants.REAL_TIME_EVENT;
|
|
40
|
-
}
|
|
41
|
-
});
|
|
42
|
-
Object.defineProperty(exports, "RealTimeEventType", {
|
|
43
|
-
enumerable: true,
|
|
44
|
-
get: function () {
|
|
45
|
-
return _types.RealTimeEventType;
|
|
46
|
-
}
|
|
47
|
-
});
|
|
48
|
-
var _types = require("./types");
|
|
49
|
-
var _externalEventSource = require("./externalEventSource");
|
|
50
|
-
var _constants = require("./constants");
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),Object.defineProperty(exports,"EventSourceOpenParametersType",{enumerable:!0,get:function get(){return _types.EventSourceOpenParametersType}}),Object.defineProperty(exports,"ExternalEventSource",{enumerable:!0,get:function get(){return _externalEventSource.ExternalEventSource}}),Object.defineProperty(exports,"IEventSource",{enumerable:!0,get:function get(){return _externalEventSource.IEventSource}}),Object.defineProperty(exports,"IExternalEventSource",{enumerable:!0,get:function get(){return _types.IExternalEventSource}}),Object.defineProperty(exports,"IExternalEventSourceConstructor",{enumerable:!0,get:function get(){return _types.IExternalEventSourceConstructor}}),Object.defineProperty(exports,"REAL_TIME_EVENT",{enumerable:!0,get:function get(){return _constants.REAL_TIME_EVENT}}),Object.defineProperty(exports,"RealTimeEventType",{enumerable:!0,get:function get(){return _types.RealTimeEventType}});var _types=require("./types"),_externalEventSource=require("./externalEventSource"),_constants=require("./constants");
|
|
51
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../../src/eventSource/index.ts"],"sourcesContent":["export {\n IExternalEventSourceConstructor,\n EventSourceOpenParametersType,\n IExternalEventSource,\n RealTimeEventType,\n} from './types';\nexport { ExternalEventSource, IEventSource } from './externalEventSource';\nexport { REAL_TIME_EVENT } from './constants';\n"],"mappings":""}
|
package/dist/hasher/hasher.js
CHANGED
|
@@ -1,45 +1,7 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
exports.Hasher
|
|
7
|
-
var _cryptoJs = require("crypto-js");
|
|
8
|
-
class Hasher {
|
|
9
|
-
static obtainExperimentHashDouble({
|
|
10
|
-
visitorCode,
|
|
11
|
-
campaignId,
|
|
12
|
-
respoolTime
|
|
13
|
-
}) {
|
|
14
|
-
let respoolTimeString = '';
|
|
15
|
-
if (respoolTime.length) {
|
|
16
|
-
respoolTime.forEach(respoolObject => {
|
|
17
|
-
respoolTimeString += String(respoolObject.value);
|
|
18
|
-
});
|
|
19
|
-
}
|
|
20
|
-
return this.calculateHash(visitorCode + campaignId + respoolTimeString);
|
|
21
|
-
}
|
|
22
|
-
static obtainFeatureFlagHashDouble({
|
|
23
|
-
visitorCode,
|
|
24
|
-
campaignId,
|
|
25
|
-
respoolTime
|
|
26
|
-
}) {
|
|
27
|
-
let suffix = '';
|
|
28
|
-
if (respoolTime) {
|
|
29
|
-
suffix += String(respoolTime);
|
|
30
|
-
}
|
|
31
|
-
return this.calculateHash(visitorCode + campaignId + suffix);
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
// --- Note ---
|
|
35
|
-
// `hashDouble` is a seeded pseudo-random number between 0 and 1
|
|
36
|
-
// used for deciding what variation to assign
|
|
37
|
-
// `calculateHash` algorithm is consistent between every SDK
|
|
38
|
-
// and will always provide same pseudo-random value for the same input parameters
|
|
39
|
-
static calculateHash(seed) {
|
|
40
|
-
const hashDigest = (0, _cryptoJs.SHA256)(seed).toString();
|
|
41
|
-
return parseInt(hashDigest, 16) / Math.pow(2, 256);
|
|
42
|
-
}
|
|
43
|
-
}
|
|
44
|
-
exports.Hasher = Hasher;
|
|
1
|
+
"use strict";var _sha=_interopRequireDefault(require("crypto-js/sha256"));Object.defineProperty(exports,"__esModule",{value:!0}),exports.Hasher=void 0;function _interopRequireDefault(a){return a&&a.__esModule?a:{default:a}}function _typeof(a){"@babel/helpers - typeof";return _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},_typeof(a)}function _classCallCheck(a,b){if(!(a instanceof b))throw new TypeError("Cannot call a class as a function")}function _defineProperties(a,b){for(var c,d=0;d<b.length;d++)c=b[d],c.enumerable=c.enumerable||!1,c.configurable=!0,"value"in c&&(c.writable=!0),Object.defineProperty(a,_toPropertyKey(c.key),c)}function _createClass(a,b,c){return b&&_defineProperties(a.prototype,b),c&&_defineProperties(a,c),Object.defineProperty(a,"prototype",{writable:!1}),a}function _toPropertyKey(a){var b=_toPrimitive(a,"string");return"symbol"===_typeof(b)?b:b+""}function _toPrimitive(a,b){if("object"!==_typeof(a)||null===a)return a;var c=a[Symbol.toPrimitive];if(c!==void 0){var d=c.call(a,b||"default");if("object"!==_typeof(d))return d;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===b?String:Number)(a)}var Hasher=/*#__PURE__*/function(){function a(){_classCallCheck(this,a)}return _createClass(a,null,[{key:"obtainExperimentHashDouble",value:function obtainExperimentHashDouble(a){var b=a.visitorCode,c=a.campaignId,d=a.respoolTime,e="";return d.length&&d.forEach(function(a){e+=a.value+""}),this.calculateHash(b+c+e)}},{key:"obtainFeatureFlagHashDouble",value:function obtainFeatureFlagHashDouble(a){var b=a.visitorCode,c=a.campaignId,d=a.respoolTime,e="";return d&&(e+=d+""),this.calculateHash(b+c+e)}// --- Note ---
|
|
2
|
+
// `hashDouble` is a seeded pseudo-random number between 0 and 1
|
|
3
|
+
// used for deciding what variation to assign
|
|
4
|
+
// `calculateHash` algorithm is consistent between every SDK
|
|
5
|
+
// and will always provide same pseudo-random value for the same input parameters
|
|
6
|
+
},{key:"calculateHash",value:function calculateHash(a){var b=(0,_sha.default)(a).toString();return parseInt(b,16)/Math.pow(2,256)}}]),a}();exports.Hasher=Hasher;
|
|
45
7
|
//# sourceMappingURL=hasher.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hasher.js","names":["
|
|
1
|
+
{"version":3,"file":"hasher.js","names":["_sha","_interopRequireDefault","require","Object","defineProperty","exports","value","Hasher","a","__esModule","default","_typeof","Symbol","iterator","constructor","prototype","_classCallCheck","b","TypeError","_defineProperties","c","d","length","enumerable","configurable","writable","_toPropertyKey","key","_createClass","_toPrimitive","toPrimitive","call","String","Number","obtainExperimentHashDouble","visitorCode","campaignId","respoolTime","respoolTimeString","forEach","respoolObject","calculateHash","obtainFeatureFlagHashDouble","suffix","seed","hashDigest","sha256","toString","parseInt","Math","pow"],"sources":["../../src/hasher/hasher.ts"],"sourcesContent":["import sha256 from 'crypto-js/sha256';\nimport {\n ObtainExperimentHashDoubleParamsType,\n ObtainFeatureFlagHashDoubleParamsType,\n} from './types';\n\nexport class Hasher {\n static obtainExperimentHashDouble({\n visitorCode,\n campaignId,\n respoolTime,\n }: ObtainExperimentHashDoubleParamsType): number {\n let respoolTimeString = '';\n\n if (respoolTime.length) {\n respoolTime.forEach((respoolObject) => {\n respoolTimeString += String(respoolObject.value);\n });\n }\n\n return this.calculateHash(visitorCode + campaignId + respoolTimeString);\n }\n\n static obtainFeatureFlagHashDouble({\n visitorCode,\n campaignId,\n respoolTime,\n }: ObtainFeatureFlagHashDoubleParamsType): number {\n let suffix = '';\n\n if (respoolTime) {\n suffix += String(respoolTime);\n }\n\n return this.calculateHash(visitorCode + campaignId + suffix);\n }\n\n // --- Note ---\n // `hashDouble` is a seeded pseudo-random number between 0 and 1\n // used for deciding what variation to assign\n // `calculateHash` algorithm is consistent between every SDK\n // and will always provide same pseudo-random value for the same input parameters\n static calculateHash(seed: string): number {\n const hashDigest = sha256(seed).toString();\n\n return parseInt(hashDigest, 16) / Math.pow(2, 256);\n }\n}\n"],"mappings":"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"}
|
package/dist/hasher/index.js
CHANGED
|
@@ -1,13 +1,2 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
Object.defineProperty(exports, "Hasher", {
|
|
7
|
-
enumerable: true,
|
|
8
|
-
get: function () {
|
|
9
|
-
return _hasher.Hasher;
|
|
10
|
-
}
|
|
11
|
-
});
|
|
12
|
-
var _hasher = require("./hasher");
|
|
1
|
+
"use strict";var _hasher=require("./hasher");Object.defineProperty(exports,"__esModule",{value:!0}),Object.defineProperty(exports,"Hasher",{enumerable:!0,get:function get(){return _hasher.Hasher}});
|
|
13
2
|
//# sourceMappingURL=index.js.map
|
package/dist/hasher/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["_hasher","require"],"sources":["../../src/hasher/index.ts"],"sourcesContent":["export { Hasher } from './hasher';\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","names":["_hasher","require","Object","defineProperty","exports","value","enumerable","get","Hasher"],"sources":["../../src/hasher/index.ts"],"sourcesContent":["export { Hasher } from './hasher';\n"],"mappings":"aAAA,IAAAA,OAAA,CAAAC,OAAA,aAAkCC,MAAA,CAAAC,cAAA,CAAAC,OAAA,eAAAC,KAAA,MAAAH,MAAA,CAAAC,cAAA,CAAAC,OAAA,WAAAE,UAAA,IAAAC,GAAA,UAAAA,IAAA,SAAAP,OAAA,CAAAQ,MAAA"}
|
package/dist/hasher/types.d.ts
CHANGED
package/dist/hasher/types.js
CHANGED
package/dist/hasher/types.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","names":[],"sources":["../../src/hasher/types.ts"],"sourcesContent":["import { RespoolTimeType } from '
|
|
1
|
+
{"version":3,"file":"types.js","names":[],"sources":["../../src/hasher/types.ts"],"sourcesContent":["import { RespoolTimeType } from 'src/campaignConfiguration/types';\n\ntype ObtainHashDoubleParamsType = {\n visitorCode: string;\n campaignId: string;\n};\n\nexport type ObtainExperimentHashDoubleParamsType =\n ObtainHashDoubleParamsType & {\n respoolTime: RespoolTimeType[];\n };\n\nexport type ObtainFeatureFlagHashDoubleParamsType =\n ObtainHashDoubleParamsType & {\n respoolTime: number | null;\n };\n"],"mappings":""}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
+
export { Ok, Result, Err } from 'ts-res';
|
|
1
2
|
export { KameleoonClient as KameleoonCore, IKameleoonClient as IKameleoonCore, } from './kameleoonClient';
|
|
2
3
|
export { KameleoonUtils as KameleoonCoreUtils } from './kameleoonUtils';
|
|
3
4
|
export { KameleoonException, KameleoonError } from './kameleoonError';
|
|
4
5
|
export { KameleoonStorageKey, IExternalStorage, IExternalStorageConstructor, } from './storage';
|
|
5
|
-
export { Cookie, VISITOR_CODE_LENGTH,
|
|
6
|
+
export { Cookie, VISITOR_CODE_LENGTH, SdkLanguageType } from './constants';
|
|
6
7
|
export { CLEANUP_TARGETING_DATA_INTERVAL } from './campaignConfiguration';
|
|
7
8
|
export { JSONType } from './campaignConfiguration';
|
|
8
|
-
export { Ok, Result, Err } from 'ts-res';
|
|
9
9
|
export { Environment, VariableType, ExperimentType, FeatureFlagType, SDKCoreParameters, SDKConfigurationType, ExternalPackageInfoType, TrackConversionParamsType, FeatureVariableResultType, InternalSDKConfigurationType, GetFeatureFlagVariableParamsType, ServerGetVisitorCodeParametersType, ClientGetVisitorCodeParametersType, MobileGetVisitorCodeParametersType, } from './types';
|
|
10
|
-
export { CustomData, Conversion, Device, Browser, DeviceType, BrowserType, PageView, KameleoonDataType, PageViewParametersType, ConversionParametersType, } from './kameleoonData';
|
|
10
|
+
export { CustomData, Conversion, Device, Browser, DeviceType, BrowserType, PageView, KameleoonData, KameleoonDataType, PageViewParametersType, ConversionParametersType, } from './kameleoonData';
|
|
11
11
|
export { RealTimeEventType, IExternalEventSource, EventSourceOpenParametersType, IExternalEventSourceConstructor, } from './eventSource';
|
|
12
12
|
export { Header, HttpMethod, TrackParametersType, IExternalRequestDispatcher, GetClientConfigurationResultType, } from './requester';
|