@liquidcommercedev/rmn-sdk 1.5.0-beta.43 → 1.5.0-beta.45

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/index.cjs CHANGED
@@ -114,9 +114,6 @@ const SDK_CONFIG = {
114
114
  apiHeader: REQUEST_CLOUD_API_KEY,
115
115
  accessHeader: 'Authorization',
116
116
  credentials: {
117
- authenticated: false,
118
- apiKey: '',
119
- token: '',
120
117
  env: exports.RMN_ENV.DEVELOPMENT,
121
118
  },
122
119
  };
@@ -261,94 +258,18 @@ function Item(fun, array) {
261
258
  Item.prototype.run = function () {
262
259
  this.fun.apply(null, this.array);
263
260
  };
264
- var title = 'browser';
265
- var platform$2 = 'browser';
266
- var browser = true;
267
- var env = {};
268
- var argv = [];
269
- var version = ''; // empty string to avoid regexp issues
270
- var versions = {};
271
- var release = {};
272
- var config = {};
273
-
274
- function noop$1() {}
275
-
276
- var on = noop$1;
277
- var addListener = noop$1;
278
- var once = noop$1;
279
- var off = noop$1;
280
- var removeListener = noop$1;
281
- var removeAllListeners = noop$1;
282
- var emit = noop$1;
283
-
284
- function binding(name) {
285
- throw new Error('process.binding is not supported');
286
- }
287
-
288
- function cwd () { return '/' }
289
- function chdir (dir) {
290
- throw new Error('process.chdir is not supported');
291
- }function umask() { return 0; }
292
261
 
293
262
  // from https://github.com/kumavis/browser-process-hrtime/blob/master/index.js
294
263
  var performance = global$1.performance || {};
295
- var performanceNow =
296
- performance.now ||
264
+ performance.now ||
297
265
  performance.mozNow ||
298
266
  performance.msNow ||
299
267
  performance.oNow ||
300
268
  performance.webkitNow ||
301
269
  function(){ return (new Date()).getTime() };
302
270
 
303
- // generate timestamp or delta
304
- // see http://nodejs.org/api/process.html#process_process_hrtime
305
- function hrtime(previousTimestamp){
306
- var clocktime = performanceNow.call(performance)*1e-3;
307
- var seconds = Math.floor(clocktime);
308
- var nanoseconds = Math.floor((clocktime%1)*1e9);
309
- if (previousTimestamp) {
310
- seconds = seconds - previousTimestamp[0];
311
- nanoseconds = nanoseconds - previousTimestamp[1];
312
- if (nanoseconds<0) {
313
- seconds--;
314
- nanoseconds += 1e9;
315
- }
316
- }
317
- return [seconds,nanoseconds]
318
- }
319
-
320
- var startTime = new Date();
321
- function uptime() {
322
- var currentTime = new Date();
323
- var dif = currentTime - startTime;
324
- return dif / 1000;
325
- }
326
-
327
271
  var browser$1 = {
328
- nextTick: nextTick,
329
- title: title,
330
- browser: browser,
331
- env: env,
332
- argv: argv,
333
- version: version,
334
- versions: versions,
335
- on: on,
336
- addListener: addListener,
337
- once: once,
338
- off: off,
339
- removeListener: removeListener,
340
- removeAllListeners: removeAllListeners,
341
- emit: emit,
342
- binding: binding,
343
- cwd: cwd,
344
- chdir: chdir,
345
- umask: umask,
346
- hrtime: hrtime,
347
- platform: platform$2,
348
- release: release,
349
- config: config,
350
- uptime: uptime
351
- };
272
+ nextTick: nextTick};
352
273
 
353
274
  function bind(fn, thisArg) {
354
275
  return function wrap() {
@@ -956,26 +877,6 @@ const toFiniteNumber = (value, defaultValue) => {
956
877
  return value != null && Number.isFinite(value = +value) ? value : defaultValue;
957
878
  };
958
879
 
959
- const ALPHA = 'abcdefghijklmnopqrstuvwxyz';
960
-
961
- const DIGIT = '0123456789';
962
-
963
- const ALPHABET = {
964
- DIGIT,
965
- ALPHA,
966
- ALPHA_DIGIT: ALPHA + ALPHA.toUpperCase() + DIGIT
967
- };
968
-
969
- const generateString = (size = 16, alphabet = ALPHABET.ALPHA_DIGIT) => {
970
- let str = '';
971
- const {length} = alphabet;
972
- while (size--) {
973
- str += alphabet[Math.random() * length|0];
974
- }
975
-
976
- return str;
977
- };
978
-
979
880
  /**
980
881
  * If the thing is a FormData object, return true, otherwise return false.
981
882
  *
@@ -1103,8 +1004,6 @@ var utils$1 = {
1103
1004
  findKey,
1104
1005
  global: _global,
1105
1006
  isContextDefined,
1106
- ALPHABET,
1107
- generateString,
1108
1007
  isSpecCompliantForm,
1109
1008
  toJSONObject,
1110
1009
  isAsyncFn,
@@ -3101,7 +3000,7 @@ function isSlowBuffer (obj) {
3101
3000
  *
3102
3001
  * @returns {Error} The created error.
3103
3002
  */
3104
- function AxiosError(message, code, config, request, response) {
3003
+ function AxiosError$1(message, code, config, request, response) {
3105
3004
  Error.call(this);
3106
3005
 
3107
3006
  if (Error.captureStackTrace) {
@@ -3121,7 +3020,7 @@ function AxiosError(message, code, config, request, response) {
3121
3020
  }
3122
3021
  }
3123
3022
 
3124
- utils$1.inherits(AxiosError, Error, {
3023
+ utils$1.inherits(AxiosError$1, Error, {
3125
3024
  toJSON: function toJSON() {
3126
3025
  return {
3127
3026
  // Standard
@@ -3143,7 +3042,7 @@ utils$1.inherits(AxiosError, Error, {
3143
3042
  }
3144
3043
  });
3145
3044
 
3146
- const prototype$1 = AxiosError.prototype;
3045
+ const prototype$1 = AxiosError$1.prototype;
3147
3046
  const descriptors = {};
3148
3047
 
3149
3048
  [
@@ -3164,11 +3063,11 @@ const descriptors = {};
3164
3063
  descriptors[code] = {value: code};
3165
3064
  });
3166
3065
 
3167
- Object.defineProperties(AxiosError, descriptors);
3066
+ Object.defineProperties(AxiosError$1, descriptors);
3168
3067
  Object.defineProperty(prototype$1, 'isAxiosError', {value: true});
3169
3068
 
3170
3069
  // eslint-disable-next-line func-names
3171
- AxiosError.from = (error, code, config, request, response, customProps) => {
3070
+ AxiosError$1.from = (error, code, config, request, response, customProps) => {
3172
3071
  const axiosError = Object.create(prototype$1);
3173
3072
 
3174
3073
  utils$1.toFlatObject(error, axiosError, function filter(obj) {
@@ -3177,7 +3076,7 @@ AxiosError.from = (error, code, config, request, response, customProps) => {
3177
3076
  return prop !== 'isAxiosError';
3178
3077
  });
3179
3078
 
3180
- AxiosError.call(axiosError, error.message, code, config, request, response);
3079
+ AxiosError$1.call(axiosError, error.message, code, config, request, response);
3181
3080
 
3182
3081
  axiosError.cause = error;
3183
3082
 
@@ -3269,7 +3168,7 @@ const predicates = utils$1.toFlatObject(utils$1, {}, null, function filter(prop)
3269
3168
  *
3270
3169
  * @returns
3271
3170
  */
3272
- function toFormData(obj, formData, options) {
3171
+ function toFormData$1(obj, formData, options) {
3273
3172
  if (!utils$1.isObject(obj)) {
3274
3173
  throw new TypeError('target must be an object');
3275
3174
  }
@@ -3307,7 +3206,7 @@ function toFormData(obj, formData, options) {
3307
3206
  }
3308
3207
 
3309
3208
  if (!useBlob && utils$1.isBlob(value)) {
3310
- throw new AxiosError('Blob is not supported. Use a Buffer instead.');
3209
+ throw new AxiosError$1('Blob is not supported. Use a Buffer instead.');
3311
3210
  }
3312
3211
 
3313
3212
  if (utils$1.isArrayBuffer(value) || utils$1.isTypedArray(value)) {
@@ -3436,7 +3335,7 @@ function encode$2(str) {
3436
3335
  function AxiosURLSearchParams(params, options) {
3437
3336
  this._pairs = [];
3438
3337
 
3439
- params && toFormData(params, this, options);
3338
+ params && toFormData$1(params, this, options);
3440
3339
  }
3441
3340
 
3442
3341
  const prototype = AxiosURLSearchParams.prototype;
@@ -3667,7 +3566,7 @@ var platform = {
3667
3566
  };
3668
3567
 
3669
3568
  function toURLEncodedForm(data, options) {
3670
- return toFormData(data, new platform.classes.URLSearchParams(), Object.assign({
3569
+ return toFormData$1(data, new platform.classes.URLSearchParams(), Object.assign({
3671
3570
  visitor: function(value, key, path, helpers) {
3672
3571
  if (platform.isNode && utils$1.isBuffer(value)) {
3673
3572
  this.append(key, value.toString('base64'));
@@ -3791,7 +3690,7 @@ function stringifySafely(rawValue, parser, encoder) {
3791
3690
  }
3792
3691
  }
3793
3692
 
3794
- return (0, JSON.stringify)(rawValue);
3693
+ return (encoder || JSON.stringify)(rawValue);
3795
3694
  }
3796
3695
 
3797
3696
  const defaults = {
@@ -3842,7 +3741,7 @@ const defaults = {
3842
3741
  if ((isFileList = utils$1.isFileList(data)) || contentType.indexOf('multipart/form-data') > -1) {
3843
3742
  const _FormData = this.env && this.env.FormData;
3844
3743
 
3845
- return toFormData(
3744
+ return toFormData$1(
3846
3745
  isFileList ? {'files[]': data} : data,
3847
3746
  _FormData && new _FormData(),
3848
3747
  this.formSerializer
@@ -3876,7 +3775,7 @@ const defaults = {
3876
3775
  } catch (e) {
3877
3776
  if (strictJSONParsing) {
3878
3777
  if (e.name === 'SyntaxError') {
3879
- throw AxiosError.from(e, AxiosError.ERR_BAD_RESPONSE, this, null, this.response);
3778
+ throw AxiosError$1.from(e, AxiosError$1.ERR_BAD_RESPONSE, this, null, this.response);
3880
3779
  }
3881
3780
  throw e;
3882
3781
  }
@@ -4039,7 +3938,7 @@ function buildAccessors(obj, header) {
4039
3938
  });
4040
3939
  }
4041
3940
 
4042
- class AxiosHeaders {
3941
+ let AxiosHeaders$1 = class AxiosHeaders {
4043
3942
  constructor(headers) {
4044
3943
  headers && this.set(headers);
4045
3944
  }
@@ -4250,12 +4149,12 @@ class AxiosHeaders {
4250
4149
 
4251
4150
  return this;
4252
4151
  }
4253
- }
4152
+ };
4254
4153
 
4255
- AxiosHeaders.accessor(['Content-Type', 'Content-Length', 'Accept', 'Accept-Encoding', 'User-Agent', 'Authorization']);
4154
+ AxiosHeaders$1.accessor(['Content-Type', 'Content-Length', 'Accept', 'Accept-Encoding', 'User-Agent', 'Authorization']);
4256
4155
 
4257
4156
  // reserved names hotfix
4258
- utils$1.reduceDescriptors(AxiosHeaders.prototype, ({value}, key) => {
4157
+ utils$1.reduceDescriptors(AxiosHeaders$1.prototype, ({value}, key) => {
4259
4158
  let mapped = key[0].toUpperCase() + key.slice(1); // map `set` => `Set`
4260
4159
  return {
4261
4160
  get: () => value,
@@ -4265,7 +4164,7 @@ utils$1.reduceDescriptors(AxiosHeaders.prototype, ({value}, key) => {
4265
4164
  }
4266
4165
  });
4267
4166
 
4268
- utils$1.freezeMethods(AxiosHeaders);
4167
+ utils$1.freezeMethods(AxiosHeaders$1);
4269
4168
 
4270
4169
  /**
4271
4170
  * Transform the data for a request or a response
@@ -4278,7 +4177,7 @@ utils$1.freezeMethods(AxiosHeaders);
4278
4177
  function transformData(fns, response) {
4279
4178
  const config = this || defaults;
4280
4179
  const context = response || config;
4281
- const headers = AxiosHeaders.from(context.headers);
4180
+ const headers = AxiosHeaders$1.from(context.headers);
4282
4181
  let data = context.data;
4283
4182
 
4284
4183
  utils$1.forEach(fns, function transform(fn) {
@@ -4290,7 +4189,7 @@ function transformData(fns, response) {
4290
4189
  return data;
4291
4190
  }
4292
4191
 
4293
- function isCancel(value) {
4192
+ function isCancel$1(value) {
4294
4193
  return !!(value && value.__CANCEL__);
4295
4194
  }
4296
4195
 
@@ -4303,13 +4202,13 @@ function isCancel(value) {
4303
4202
  *
4304
4203
  * @returns {CanceledError} The created error.
4305
4204
  */
4306
- function CanceledError(message, config, request) {
4205
+ function CanceledError$1(message, config, request) {
4307
4206
  // eslint-disable-next-line no-eq-null,eqeqeq
4308
- AxiosError.call(this, message == null ? 'canceled' : message, AxiosError.ERR_CANCELED, config, request);
4207
+ AxiosError$1.call(this, message == null ? 'canceled' : message, AxiosError$1.ERR_CANCELED, config, request);
4309
4208
  this.name = 'CanceledError';
4310
4209
  }
4311
4210
 
4312
- utils$1.inherits(CanceledError, AxiosError, {
4211
+ utils$1.inherits(CanceledError$1, AxiosError$1, {
4313
4212
  __CANCEL__: true
4314
4213
  });
4315
4214
 
@@ -4327,9 +4226,9 @@ function settle(resolve, reject, response) {
4327
4226
  if (!response.status || !validateStatus || validateStatus(response.status)) {
4328
4227
  resolve(response);
4329
4228
  } else {
4330
- reject(new AxiosError(
4229
+ reject(new AxiosError$1(
4331
4230
  'Request failed with status code ' + response.status,
4332
- [AxiosError.ERR_BAD_REQUEST, AxiosError.ERR_BAD_RESPONSE][Math.floor(response.status / 100) - 4],
4231
+ [AxiosError$1.ERR_BAD_REQUEST, AxiosError$1.ERR_BAD_RESPONSE][Math.floor(response.status / 100) - 4],
4333
4232
  response.config,
4334
4233
  response.request,
4335
4234
  response
@@ -4568,14 +4467,15 @@ function combineURLs(baseURL, relativeURL) {
4568
4467
  *
4569
4468
  * @returns {string} The combined full path
4570
4469
  */
4571
- function buildFullPath(baseURL, requestedURL) {
4572
- if (baseURL && !isAbsoluteURL(requestedURL)) {
4470
+ function buildFullPath(baseURL, requestedURL, allowAbsoluteUrls) {
4471
+ let isRelativeUrl = !isAbsoluteURL(requestedURL);
4472
+ if (baseURL && isRelativeUrl || allowAbsoluteUrls == false) {
4573
4473
  return combineURLs(baseURL, requestedURL);
4574
4474
  }
4575
4475
  return requestedURL;
4576
4476
  }
4577
4477
 
4578
- const headersToObject = (thing) => thing instanceof AxiosHeaders ? { ...thing } : thing;
4478
+ const headersToObject = (thing) => thing instanceof AxiosHeaders$1 ? { ...thing } : thing;
4579
4479
 
4580
4480
  /**
4581
4481
  * Config-specific merge-function which creates a new config-object
@@ -4586,7 +4486,7 @@ const headersToObject = (thing) => thing instanceof AxiosHeaders ? { ...thing }
4586
4486
  *
4587
4487
  * @returns {Object} New object resulting from merging config2 to config1
4588
4488
  */
4589
- function mergeConfig(config1, config2) {
4489
+ function mergeConfig$1(config1, config2) {
4590
4490
  // eslint-disable-next-line no-param-reassign
4591
4491
  config2 = config2 || {};
4592
4492
  const config = {};
@@ -4678,11 +4578,11 @@ function mergeConfig(config1, config2) {
4678
4578
  }
4679
4579
 
4680
4580
  var resolveConfig = (config) => {
4681
- const newConfig = mergeConfig({}, config);
4581
+ const newConfig = mergeConfig$1({}, config);
4682
4582
 
4683
4583
  let {data, withXSRFToken, xsrfHeaderName, xsrfCookieName, headers, auth} = newConfig;
4684
4584
 
4685
- newConfig.headers = headers = AxiosHeaders.from(headers);
4585
+ newConfig.headers = headers = AxiosHeaders$1.from(headers);
4686
4586
 
4687
4587
  newConfig.url = buildURL(buildFullPath(newConfig.baseURL, newConfig.url), config.params, config.paramsSerializer);
4688
4588
 
@@ -4731,7 +4631,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
4731
4631
  return new Promise(function dispatchXhrRequest(resolve, reject) {
4732
4632
  const _config = resolveConfig(config);
4733
4633
  let requestData = _config.data;
4734
- const requestHeaders = AxiosHeaders.from(_config.headers).normalize();
4634
+ const requestHeaders = AxiosHeaders$1.from(_config.headers).normalize();
4735
4635
  let {responseType, onUploadProgress, onDownloadProgress} = _config;
4736
4636
  let onCanceled;
4737
4637
  let uploadThrottled, downloadThrottled;
@@ -4758,7 +4658,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
4758
4658
  return;
4759
4659
  }
4760
4660
  // Prepare the response
4761
- const responseHeaders = AxiosHeaders.from(
4661
+ const responseHeaders = AxiosHeaders$1.from(
4762
4662
  'getAllResponseHeaders' in request && request.getAllResponseHeaders()
4763
4663
  );
4764
4664
  const responseData = !responseType || responseType === 'text' || responseType === 'json' ?
@@ -4813,7 +4713,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
4813
4713
  return;
4814
4714
  }
4815
4715
 
4816
- reject(new AxiosError('Request aborted', AxiosError.ECONNABORTED, config, request));
4716
+ reject(new AxiosError$1('Request aborted', AxiosError$1.ECONNABORTED, config, request));
4817
4717
 
4818
4718
  // Clean up request
4819
4719
  request = null;
@@ -4823,7 +4723,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
4823
4723
  request.onerror = function handleError() {
4824
4724
  // Real errors are hidden from us by the browser
4825
4725
  // onerror should only fire if it's a network error
4826
- reject(new AxiosError('Network Error', AxiosError.ERR_NETWORK, config, request));
4726
+ reject(new AxiosError$1('Network Error', AxiosError$1.ERR_NETWORK, config, request));
4827
4727
 
4828
4728
  // Clean up request
4829
4729
  request = null;
@@ -4836,9 +4736,9 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
4836
4736
  if (_config.timeoutErrorMessage) {
4837
4737
  timeoutErrorMessage = _config.timeoutErrorMessage;
4838
4738
  }
4839
- reject(new AxiosError(
4739
+ reject(new AxiosError$1(
4840
4740
  timeoutErrorMessage,
4841
- transitional.clarifyTimeoutError ? AxiosError.ETIMEDOUT : AxiosError.ECONNABORTED,
4741
+ transitional.clarifyTimeoutError ? AxiosError$1.ETIMEDOUT : AxiosError$1.ECONNABORTED,
4842
4742
  config,
4843
4743
  request));
4844
4744
 
@@ -4888,7 +4788,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
4888
4788
  if (!request) {
4889
4789
  return;
4890
4790
  }
4891
- reject(!cancel || cancel.type ? new CanceledError(null, config, request) : cancel);
4791
+ reject(!cancel || cancel.type ? new CanceledError$1(null, config, request) : cancel);
4892
4792
  request.abort();
4893
4793
  request = null;
4894
4794
  };
@@ -4902,7 +4802,7 @@ var xhrAdapter = isXHRAdapterSupported && function (config) {
4902
4802
  const protocol = parseProtocol(_config.url);
4903
4803
 
4904
4804
  if (protocol && platform.protocols.indexOf(protocol) === -1) {
4905
- reject(new AxiosError('Unsupported protocol ' + protocol + ':', AxiosError.ERR_BAD_REQUEST, config));
4805
+ reject(new AxiosError$1('Unsupported protocol ' + protocol + ':', AxiosError$1.ERR_BAD_REQUEST, config));
4906
4806
  return;
4907
4807
  }
4908
4808
 
@@ -4925,13 +4825,13 @@ const composeSignals = (signals, timeout) => {
4925
4825
  aborted = true;
4926
4826
  unsubscribe();
4927
4827
  const err = reason instanceof Error ? reason : this.reason;
4928
- controller.abort(err instanceof AxiosError ? err : new CanceledError(err instanceof Error ? err.message : err));
4828
+ controller.abort(err instanceof AxiosError$1 ? err : new CanceledError$1(err instanceof Error ? err.message : err));
4929
4829
  }
4930
4830
  };
4931
4831
 
4932
4832
  let timer = timeout && setTimeout(() => {
4933
4833
  timer = null;
4934
- onabort(new AxiosError(`timeout ${timeout} of ms exceeded`, AxiosError.ETIMEDOUT));
4834
+ onabort(new AxiosError$1(`timeout ${timeout} of ms exceeded`, AxiosError$1.ETIMEDOUT));
4935
4835
  }, timeout);
4936
4836
 
4937
4837
  const unsubscribe = () => {
@@ -5088,7 +4988,7 @@ isFetchSupported && (((res) => {
5088
4988
  ['text', 'arrayBuffer', 'blob', 'formData', 'stream'].forEach(type => {
5089
4989
  !resolvers[type] && (resolvers[type] = utils$1.isFunction(res[type]) ? (res) => res[type]() :
5090
4990
  (_, config) => {
5091
- throw new AxiosError(`Response type '${type}' is not supported`, AxiosError.ERR_NOT_SUPPORT, config);
4991
+ throw new AxiosError$1(`Response type '${type}' is not supported`, AxiosError$1.ERR_NOT_SUPPORT, config);
5092
4992
  });
5093
4993
  });
5094
4994
  })(new Response));
@@ -5237,7 +5137,7 @@ var fetchAdapter = isFetchSupported && (async (config) => {
5237
5137
  return await new Promise((resolve, reject) => {
5238
5138
  settle(resolve, reject, {
5239
5139
  data: responseData,
5240
- headers: AxiosHeaders.from(response.headers),
5140
+ headers: AxiosHeaders$1.from(response.headers),
5241
5141
  status: response.status,
5242
5142
  statusText: response.statusText,
5243
5143
  config,
@@ -5249,14 +5149,14 @@ var fetchAdapter = isFetchSupported && (async (config) => {
5249
5149
 
5250
5150
  if (err && err.name === 'TypeError' && /fetch/i.test(err.message)) {
5251
5151
  throw Object.assign(
5252
- new AxiosError('Network Error', AxiosError.ERR_NETWORK, config, request),
5152
+ new AxiosError$1('Network Error', AxiosError$1.ERR_NETWORK, config, request),
5253
5153
  {
5254
5154
  cause: err.cause || err
5255
5155
  }
5256
5156
  )
5257
5157
  }
5258
5158
 
5259
- throw AxiosError.from(err, err && err.code, config, request);
5159
+ throw AxiosError$1.from(err, err && err.code, config, request);
5260
5160
  }
5261
5161
  });
5262
5162
 
@@ -5301,7 +5201,7 @@ var adapters = {
5301
5201
  adapter = knownAdapters[(id = String(nameOrAdapter)).toLowerCase()];
5302
5202
 
5303
5203
  if (adapter === undefined) {
5304
- throw new AxiosError(`Unknown adapter '${id}'`);
5204
+ throw new AxiosError$1(`Unknown adapter '${id}'`);
5305
5205
  }
5306
5206
  }
5307
5207
 
@@ -5323,7 +5223,7 @@ var adapters = {
5323
5223
  (reasons.length > 1 ? 'since :\n' + reasons.map(renderReason).join('\n') : ' ' + renderReason(reasons[0])) :
5324
5224
  'as no adapter specified';
5325
5225
 
5326
- throw new AxiosError(
5226
+ throw new AxiosError$1(
5327
5227
  `There is no suitable adapter to dispatch the request ` + s,
5328
5228
  'ERR_NOT_SUPPORT'
5329
5229
  );
@@ -5347,7 +5247,7 @@ function throwIfCancellationRequested(config) {
5347
5247
  }
5348
5248
 
5349
5249
  if (config.signal && config.signal.aborted) {
5350
- throw new CanceledError(null, config);
5250
+ throw new CanceledError$1(null, config);
5351
5251
  }
5352
5252
  }
5353
5253
 
@@ -5361,7 +5261,7 @@ function throwIfCancellationRequested(config) {
5361
5261
  function dispatchRequest(config) {
5362
5262
  throwIfCancellationRequested(config);
5363
5263
 
5364
- config.headers = AxiosHeaders.from(config.headers);
5264
+ config.headers = AxiosHeaders$1.from(config.headers);
5365
5265
 
5366
5266
  // Transform request data
5367
5267
  config.data = transformData.call(
@@ -5385,11 +5285,11 @@ function dispatchRequest(config) {
5385
5285
  response
5386
5286
  );
5387
5287
 
5388
- response.headers = AxiosHeaders.from(response.headers);
5288
+ response.headers = AxiosHeaders$1.from(response.headers);
5389
5289
 
5390
5290
  return response;
5391
5291
  }, function onAdapterRejection(reason) {
5392
- if (!isCancel(reason)) {
5292
+ if (!isCancel$1(reason)) {
5393
5293
  throwIfCancellationRequested(config);
5394
5294
 
5395
5295
  // Transform response data
@@ -5399,7 +5299,7 @@ function dispatchRequest(config) {
5399
5299
  config.transformResponse,
5400
5300
  reason.response
5401
5301
  );
5402
- reason.response.headers = AxiosHeaders.from(reason.response.headers);
5302
+ reason.response.headers = AxiosHeaders$1.from(reason.response.headers);
5403
5303
  }
5404
5304
  }
5405
5305
 
@@ -5407,7 +5307,7 @@ function dispatchRequest(config) {
5407
5307
  });
5408
5308
  }
5409
5309
 
5410
- const VERSION = "1.7.9";
5310
+ const VERSION$1 = "1.8.2";
5411
5311
 
5412
5312
  const validators$1 = {};
5413
5313
 
@@ -5431,15 +5331,15 @@ const deprecatedWarnings = {};
5431
5331
  */
5432
5332
  validators$1.transitional = function transitional(validator, version, message) {
5433
5333
  function formatMessage(opt, desc) {
5434
- return '[Axios v' + VERSION + '] Transitional option \'' + opt + '\'' + desc + (message ? '. ' + message : '');
5334
+ return '[Axios v' + VERSION$1 + '] Transitional option \'' + opt + '\'' + desc + (message ? '. ' + message : '');
5435
5335
  }
5436
5336
 
5437
5337
  // eslint-disable-next-line func-names
5438
5338
  return (value, opt, opts) => {
5439
5339
  if (validator === false) {
5440
- throw new AxiosError(
5340
+ throw new AxiosError$1(
5441
5341
  formatMessage(opt, ' has been removed' + (version ? ' in ' + version : '')),
5442
- AxiosError.ERR_DEPRECATED
5342
+ AxiosError$1.ERR_DEPRECATED
5443
5343
  );
5444
5344
  }
5445
5345
 
@@ -5478,7 +5378,7 @@ validators$1.spelling = function spelling(correctSpelling) {
5478
5378
 
5479
5379
  function assertOptions(options, schema, allowUnknown) {
5480
5380
  if (typeof options !== 'object') {
5481
- throw new AxiosError('options must be an object', AxiosError.ERR_BAD_OPTION_VALUE);
5381
+ throw new AxiosError$1('options must be an object', AxiosError$1.ERR_BAD_OPTION_VALUE);
5482
5382
  }
5483
5383
  const keys = Object.keys(options);
5484
5384
  let i = keys.length;
@@ -5489,12 +5389,12 @@ function assertOptions(options, schema, allowUnknown) {
5489
5389
  const value = options[opt];
5490
5390
  const result = value === undefined || validator(value, opt, options);
5491
5391
  if (result !== true) {
5492
- throw new AxiosError('option ' + opt + ' must be ' + result, AxiosError.ERR_BAD_OPTION_VALUE);
5392
+ throw new AxiosError$1('option ' + opt + ' must be ' + result, AxiosError$1.ERR_BAD_OPTION_VALUE);
5493
5393
  }
5494
5394
  continue;
5495
5395
  }
5496
5396
  if (allowUnknown !== true) {
5497
- throw new AxiosError('Unknown option ' + opt, AxiosError.ERR_BAD_OPTION);
5397
+ throw new AxiosError$1('Unknown option ' + opt, AxiosError$1.ERR_BAD_OPTION);
5498
5398
  }
5499
5399
  }
5500
5400
  }
@@ -5513,7 +5413,7 @@ const validators = validator.validators;
5513
5413
  *
5514
5414
  * @return {Axios} A new instance of Axios
5515
5415
  */
5516
- class Axios {
5416
+ let Axios$1 = class Axios {
5517
5417
  constructor(instanceConfig) {
5518
5418
  this.defaults = instanceConfig;
5519
5419
  this.interceptors = {
@@ -5567,7 +5467,7 @@ class Axios {
5567
5467
  config = configOrUrl || {};
5568
5468
  }
5569
5469
 
5570
- config = mergeConfig(this.defaults, config);
5470
+ config = mergeConfig$1(this.defaults, config);
5571
5471
 
5572
5472
  const {transitional, paramsSerializer, headers} = config;
5573
5473
 
@@ -5592,6 +5492,13 @@ class Axios {
5592
5492
  }
5593
5493
  }
5594
5494
 
5495
+ // Set config.allowAbsoluteUrls
5496
+ if (config.allowAbsoluteUrls !== undefined) ; else if (this.defaults.allowAbsoluteUrls !== undefined) {
5497
+ config.allowAbsoluteUrls = this.defaults.allowAbsoluteUrls;
5498
+ } else {
5499
+ config.allowAbsoluteUrls = true;
5500
+ }
5501
+
5595
5502
  validator.assertOptions(config, {
5596
5503
  baseUrl: validators.spelling('baseURL'),
5597
5504
  withXsrfToken: validators.spelling('withXSRFToken')
@@ -5613,7 +5520,7 @@ class Axios {
5613
5520
  }
5614
5521
  );
5615
5522
 
5616
- config.headers = AxiosHeaders.concat(contextHeaders, headers);
5523
+ config.headers = AxiosHeaders$1.concat(contextHeaders, headers);
5617
5524
 
5618
5525
  // filter out skipped interceptors
5619
5526
  const requestInterceptorChain = [];
@@ -5686,17 +5593,17 @@ class Axios {
5686
5593
  }
5687
5594
 
5688
5595
  getUri(config) {
5689
- config = mergeConfig(this.defaults, config);
5690
- const fullPath = buildFullPath(config.baseURL, config.url);
5596
+ config = mergeConfig$1(this.defaults, config);
5597
+ const fullPath = buildFullPath(config.baseURL, config.url, config.allowAbsoluteUrls);
5691
5598
  return buildURL(fullPath, config.params, config.paramsSerializer);
5692
5599
  }
5693
- }
5600
+ };
5694
5601
 
5695
5602
  // Provide aliases for supported request methods
5696
5603
  utils$1.forEach(['delete', 'get', 'head', 'options'], function forEachMethodNoData(method) {
5697
5604
  /*eslint func-names:0*/
5698
- Axios.prototype[method] = function(url, config) {
5699
- return this.request(mergeConfig(config || {}, {
5605
+ Axios$1.prototype[method] = function(url, config) {
5606
+ return this.request(mergeConfig$1(config || {}, {
5700
5607
  method,
5701
5608
  url,
5702
5609
  data: (config || {}).data
@@ -5709,7 +5616,7 @@ utils$1.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method)
5709
5616
 
5710
5617
  function generateHTTPMethod(isForm) {
5711
5618
  return function httpMethod(url, data, config) {
5712
- return this.request(mergeConfig(config || {}, {
5619
+ return this.request(mergeConfig$1(config || {}, {
5713
5620
  method,
5714
5621
  headers: isForm ? {
5715
5622
  'Content-Type': 'multipart/form-data'
@@ -5720,9 +5627,9 @@ utils$1.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method)
5720
5627
  };
5721
5628
  }
5722
5629
 
5723
- Axios.prototype[method] = generateHTTPMethod();
5630
+ Axios$1.prototype[method] = generateHTTPMethod();
5724
5631
 
5725
- Axios.prototype[method + 'Form'] = generateHTTPMethod(true);
5632
+ Axios$1.prototype[method + 'Form'] = generateHTTPMethod(true);
5726
5633
  });
5727
5634
 
5728
5635
  /**
@@ -5732,7 +5639,7 @@ utils$1.forEach(['post', 'put', 'patch'], function forEachMethodWithData(method)
5732
5639
  *
5733
5640
  * @returns {CancelToken}
5734
5641
  */
5735
- class CancelToken {
5642
+ let CancelToken$1 = class CancelToken {
5736
5643
  constructor(executor) {
5737
5644
  if (typeof executor !== 'function') {
5738
5645
  throw new TypeError('executor must be a function.');
@@ -5780,7 +5687,7 @@ class CancelToken {
5780
5687
  return;
5781
5688
  }
5782
5689
 
5783
- token.reason = new CanceledError(message, config, request);
5690
+ token.reason = new CanceledError$1(message, config, request);
5784
5691
  resolvePromise(token.reason);
5785
5692
  });
5786
5693
  }
@@ -5853,7 +5760,7 @@ class CancelToken {
5853
5760
  cancel
5854
5761
  };
5855
5762
  }
5856
- }
5763
+ };
5857
5764
 
5858
5765
  /**
5859
5766
  * Syntactic sugar for invoking a function and expanding an array for arguments.
@@ -5876,7 +5783,7 @@ class CancelToken {
5876
5783
  *
5877
5784
  * @returns {Function}
5878
5785
  */
5879
- function spread(callback) {
5786
+ function spread$1(callback) {
5880
5787
  return function wrap(arr) {
5881
5788
  return callback.apply(null, arr);
5882
5789
  };
@@ -5889,11 +5796,11 @@ function spread(callback) {
5889
5796
  *
5890
5797
  * @returns {boolean} True if the payload is an error thrown by Axios, otherwise false
5891
5798
  */
5892
- function isAxiosError(payload) {
5799
+ function isAxiosError$1(payload) {
5893
5800
  return utils$1.isObject(payload) && (payload.isAxiosError === true);
5894
5801
  }
5895
5802
 
5896
- const HttpStatusCode = {
5803
+ const HttpStatusCode$1 = {
5897
5804
  Continue: 100,
5898
5805
  SwitchingProtocols: 101,
5899
5806
  Processing: 102,
@@ -5959,8 +5866,8 @@ const HttpStatusCode = {
5959
5866
  NetworkAuthenticationRequired: 511,
5960
5867
  };
5961
5868
 
5962
- Object.entries(HttpStatusCode).forEach(([key, value]) => {
5963
- HttpStatusCode[value] = key;
5869
+ Object.entries(HttpStatusCode$1).forEach(([key, value]) => {
5870
+ HttpStatusCode$1[value] = key;
5964
5871
  });
5965
5872
 
5966
5873
  /**
@@ -5971,18 +5878,18 @@ Object.entries(HttpStatusCode).forEach(([key, value]) => {
5971
5878
  * @returns {Axios} A new instance of Axios
5972
5879
  */
5973
5880
  function createInstance(defaultConfig) {
5974
- const context = new Axios(defaultConfig);
5975
- const instance = bind(Axios.prototype.request, context);
5881
+ const context = new Axios$1(defaultConfig);
5882
+ const instance = bind(Axios$1.prototype.request, context);
5976
5883
 
5977
5884
  // Copy axios.prototype to instance
5978
- utils$1.extend(instance, Axios.prototype, context, {allOwnKeys: true});
5885
+ utils$1.extend(instance, Axios$1.prototype, context, {allOwnKeys: true});
5979
5886
 
5980
5887
  // Copy context to instance
5981
5888
  utils$1.extend(instance, context, null, {allOwnKeys: true});
5982
5889
 
5983
5890
  // Factory for creating new instances
5984
5891
  instance.create = function create(instanceConfig) {
5985
- return createInstance(mergeConfig(defaultConfig, instanceConfig));
5892
+ return createInstance(mergeConfig$1(defaultConfig, instanceConfig));
5986
5893
  };
5987
5894
 
5988
5895
  return instance;
@@ -5992,17 +5899,17 @@ function createInstance(defaultConfig) {
5992
5899
  const axios = createInstance(defaults);
5993
5900
 
5994
5901
  // Expose Axios class to allow class inheritance
5995
- axios.Axios = Axios;
5902
+ axios.Axios = Axios$1;
5996
5903
 
5997
5904
  // Expose Cancel & CancelToken
5998
- axios.CanceledError = CanceledError;
5999
- axios.CancelToken = CancelToken;
6000
- axios.isCancel = isCancel;
6001
- axios.VERSION = VERSION;
6002
- axios.toFormData = toFormData;
5905
+ axios.CanceledError = CanceledError$1;
5906
+ axios.CancelToken = CancelToken$1;
5907
+ axios.isCancel = isCancel$1;
5908
+ axios.VERSION = VERSION$1;
5909
+ axios.toFormData = toFormData$1;
6003
5910
 
6004
5911
  // Expose AxiosError class
6005
- axios.AxiosError = AxiosError;
5912
+ axios.AxiosError = AxiosError$1;
6006
5913
 
6007
5914
  // alias for CanceledError for backward compatibility
6008
5915
  axios.Cancel = axios.CanceledError;
@@ -6012,24 +5919,46 @@ axios.all = function all(promises) {
6012
5919
  return Promise.all(promises);
6013
5920
  };
6014
5921
 
6015
- axios.spread = spread;
5922
+ axios.spread = spread$1;
6016
5923
 
6017
5924
  // Expose isAxiosError
6018
- axios.isAxiosError = isAxiosError;
5925
+ axios.isAxiosError = isAxiosError$1;
6019
5926
 
6020
5927
  // Expose mergeConfig
6021
- axios.mergeConfig = mergeConfig;
5928
+ axios.mergeConfig = mergeConfig$1;
6022
5929
 
6023
- axios.AxiosHeaders = AxiosHeaders;
5930
+ axios.AxiosHeaders = AxiosHeaders$1;
6024
5931
 
6025
5932
  axios.formToJSON = thing => formDataToJSON(utils$1.isHTMLForm(thing) ? new FormData(thing) : thing);
6026
5933
 
6027
5934
  axios.getAdapter = adapters.getAdapter;
6028
5935
 
6029
- axios.HttpStatusCode = HttpStatusCode;
5936
+ axios.HttpStatusCode = HttpStatusCode$1;
6030
5937
 
6031
5938
  axios.default = axios;
6032
5939
 
5940
+ // This module is intended to unwrap Axios default export as named.
5941
+ // Keep top-level export same with static properties
5942
+ // so that it can keep same with es module or cjs
5943
+ const {
5944
+ Axios,
5945
+ AxiosError,
5946
+ CanceledError,
5947
+ isCancel,
5948
+ CancelToken,
5949
+ VERSION,
5950
+ all,
5951
+ Cancel,
5952
+ isAxiosError,
5953
+ spread,
5954
+ toFormData,
5955
+ AxiosHeaders,
5956
+ HttpStatusCode,
5957
+ formToJSON,
5958
+ getAdapter,
5959
+ mergeConfig
5960
+ } = axios;
5961
+
6033
5962
  /**
6034
5963
  * Keyword patterns for each RMN_SPOT_EVENT.
6035
5964
  * Each event type has required keywords that must be present and optional ones.
@@ -6092,7 +6021,7 @@ function matchesKeywordPattern(words, required, optional) {
6092
6021
  return false;
6093
6022
  }
6094
6023
  // If no optional keywords are specified, return true
6095
- if (!(optional === null || optional === undefined ? undefined : optional.length)) {
6024
+ if (!(optional === null || optional === void 0 ? void 0 : optional.length)) {
6096
6025
  return true;
6097
6026
  }
6098
6027
  // If optional keywords exist, check if at least one matches as a whole word
@@ -6105,7 +6034,7 @@ function matchesKeywordPattern(words, required, optional) {
6105
6034
  * @returns {RMN_SPOT_EVENT | null} - The corresponding RMN_SPOT_EVENT or null if no match
6106
6035
  */
6107
6036
  function getEventTypeFromRawEvent(event) {
6108
- if (!(event === null || event === undefined ? undefined : event.trim())) {
6037
+ if (!(event === null || event === void 0 ? void 0 : event.trim())) {
6109
6038
  return null;
6110
6039
  }
6111
6040
  const words = normalizeEventName(event);
@@ -7592,7 +7521,7 @@ class ObjectHelper {
7592
7521
  else if (typeof value === 'object') {
7593
7522
  return this.mergeObjectValues(targetValue, value);
7594
7523
  }
7595
- return (_a = value !== null && value !== undefined ? value : targetValue) !== null && _a !== undefined ? _a : undefined;
7524
+ return (_a = value !== null && value !== void 0 ? value : targetValue) !== null && _a !== void 0 ? _a : undefined;
7596
7525
  }
7597
7526
  /**
7598
7527
  * Merges the values of an array or object with a given array of objects and returns the merged result as an object.
@@ -7673,7 +7602,7 @@ function xhrFallbackEventFire(url) {
7673
7602
  }
7674
7603
  function beaconEventFire(url) {
7675
7604
  var _a;
7676
- return (_a = navigator === null || navigator === undefined ? undefined : navigator.sendBeacon) === null || _a === undefined ? undefined : _a.call(navigator, url);
7605
+ return (_a = navigator === null || navigator === void 0 ? void 0 : navigator.sendBeacon) === null || _a === void 0 ? void 0 : _a.call(navigator, url);
7677
7606
  }
7678
7607
  /**
7679
7608
  * Helper function to decode base64 string and parse JSON
@@ -7794,7 +7723,7 @@ function calculateScaleFactor(elementScale) {
7794
7723
  * @returns {string} - The query string.
7795
7724
  */
7796
7725
  function objectToQueryParams(obj) {
7797
- return Object.entries(obj !== null && obj !== undefined ? obj : {})
7726
+ return Object.entries(obj !== null && obj !== void 0 ? obj : {})
7798
7727
  .map(([key, value]) => {
7799
7728
  if (value == null) {
7800
7729
  return '';
@@ -7943,7 +7872,7 @@ UniqueIdGenerator.base32Chars = '0123456789ABCDEFGHJKMNPQRSTVWXYZ';
7943
7872
  var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
7944
7873
 
7945
7874
  function getAugmentedNamespace(n) {
7946
- if (n.__esModule) return n;
7875
+ if (Object.prototype.hasOwnProperty.call(n, '__esModule')) return n;
7947
7876
  var f = n.default;
7948
7877
  if (typeof f == "function") {
7949
7878
  var a = function a () {
@@ -15726,6 +15655,11 @@ function checkSigCryptoKey(key, alg, ...usages) {
15726
15655
  }
15727
15656
  break;
15728
15657
  }
15658
+ case 'Ed25519': {
15659
+ if (!isAlgorithm(key.algorithm, 'Ed25519'))
15660
+ throw unusable('Ed25519');
15661
+ break;
15662
+ }
15729
15663
  case 'ES256':
15730
15664
  case 'ES384':
15731
15665
  case 'ES512': {
@@ -15905,6 +15839,10 @@ function subtleMapping(jwk) {
15905
15839
  }
15906
15840
  case 'OKP': {
15907
15841
  switch (jwk.alg) {
15842
+ case 'Ed25519':
15843
+ algorithm = { name: 'Ed25519' };
15844
+ keyUsages = jwk.d ? ['sign'] : ['verify'];
15845
+ break;
15908
15846
  case 'EdDSA':
15909
15847
  algorithm = { name: jwk.crv };
15910
15848
  keyUsages = jwk.d ? ['sign'] : ['verify'];
@@ -16020,7 +15958,7 @@ async function importJWK(jwk, alg) {
16020
15958
  }
16021
15959
  return decode(jwk.k);
16022
15960
  case 'RSA':
16023
- if (jwk.oth !== undefined) {
15961
+ if ('oth' in jwk && jwk.oth !== undefined) {
16024
15962
  throw new JOSENotSupported('RSA JWK "oth" (Other Primes Info) Parameter value is not supported');
16025
15963
  }
16026
15964
  case 'EC':
@@ -16158,6 +16096,8 @@ function subtleDsa(alg, algorithm) {
16158
16096
  case 'ES384':
16159
16097
  case 'ES512':
16160
16098
  return { hash, name: 'ECDSA', namedCurve: algorithm.namedCurve };
16099
+ case 'Ed25519':
16100
+ return { name: 'Ed25519' };
16161
16101
  case 'EdDSA':
16162
16102
  return { name: algorithm.name };
16163
16103
  default:
@@ -16688,9 +16628,9 @@ class ApiError {
16688
16628
  constructor(error) {
16689
16629
  var _a, _b, _c, _d, _e, _f, _g;
16690
16630
  const e = error;
16691
- this.cause = (_d = (_b = (_a = e === null || e === undefined ? undefined : e.response) === null || _a === undefined ? undefined : _a.data.statusCode) !== null && _b !== undefined ? _b : (_c = e === null || e === undefined ? undefined : e.response) === null || _c === undefined ? undefined : _c.status) !== null && _d !== undefined ? _d : 0;
16631
+ this.cause = (_d = (_b = (_a = e === null || e === void 0 ? void 0 : e.response) === null || _a === void 0 ? void 0 : _a.data.statusCode) !== null && _b !== void 0 ? _b : (_c = e === null || e === void 0 ? void 0 : e.response) === null || _c === void 0 ? void 0 : _c.status) !== null && _d !== void 0 ? _d : 0;
16692
16632
  this.errorMessage =
16693
- (_g = (_f = (_e = e === null || e === undefined ? undefined : e.response) === null || _e === undefined ? undefined : _e.data.message) !== null && _f !== undefined ? _f : e === null || e === undefined ? undefined : e.message) !== null && _g !== undefined ? _g : `There's been an error related to the API request to LiquidCommerce RMN Services.`;
16633
+ (_g = (_f = (_e = e === null || e === void 0 ? void 0 : e.response) === null || _e === void 0 ? void 0 : _e.data.message) !== null && _f !== void 0 ? _f : e === null || e === void 0 ? void 0 : e.message) !== null && _g !== void 0 ? _g : `There's been an error related to the API request to LiquidCommerce RMN Services.`;
16694
16634
  }
16695
16635
  }
16696
16636
 
@@ -16805,12 +16745,12 @@ class BaseApi extends BaseApiAbstract {
16805
16745
  this.authInfo = auth;
16806
16746
  this.encryptedApi = EncryptedApi.getInstance(this.authInfo.apiKey);
16807
16747
  this.objectHelper = ObjectHelper.getInstance();
16808
- this.baseUrl = (_a = SDK_CONFIG.url[this.authInfo.env]) !== null && _a !== undefined ? _a : SDK_CONFIG.url.development;
16748
+ this.baseUrl = (_a = SDK_CONFIG.url[this.authInfo.env]) !== null && _a !== void 0 ? _a : SDK_CONFIG.url.development;
16809
16749
  const configHeaders = {
16810
16750
  [SDK_CONFIG.accessHeader]: `Bearer ${this.authInfo.token}`,
16811
16751
  };
16812
16752
  const partnerSite = this.getPartnerSite();
16813
- const isPartnerSiteValid = partnerSite === null || partnerSite === undefined ? undefined : partnerSite.startsWith('http');
16753
+ const isPartnerSiteValid = partnerSite === null || partnerSite === void 0 ? void 0 : partnerSite.startsWith('http');
16814
16754
  if (partnerSite && isPartnerSiteValid) {
16815
16755
  configHeaders[REQUEST_CLOUD_PARTNER_SITE] = partnerSite;
16816
16756
  }
@@ -16866,7 +16806,7 @@ class BaseApi extends BaseApiAbstract {
16866
16806
  configOverrides = {
16867
16807
  ...configOverrides,
16868
16808
  headers: {
16869
- ...configOverrides === null || configOverrides === undefined ? undefined : configOverrides.headers,
16809
+ ...configOverrides === null || configOverrides === void 0 ? void 0 : configOverrides.headers,
16870
16810
  [REQUEST_CLOUD_PROTECTED_KEY]: 'true',
16871
16811
  [REQUEST_CLOUD_PROTECTED_TIMESTAMP]: timestamp,
16872
16812
  [SDK_CONFIG.apiHeader]: this.authInfo.apiKey,
@@ -16903,7 +16843,7 @@ class BaseApi extends BaseApiAbstract {
16903
16843
  * @returns {AxiosRequestConfig} - The merged Axios request configuration.
16904
16844
  */
16905
16845
  createFullConfig(configOverrides) {
16906
- return this.objectHelper.merge(this.getConfig(), configOverrides !== null && configOverrides !== undefined ? configOverrides : {});
16846
+ return this.objectHelper.merge(this.getConfig(), configOverrides !== null && configOverrides !== void 0 ? configOverrides : {});
16907
16847
  }
16908
16848
  /**
16909
16849
  * Sends a request to the specified URL with the given configuration.
@@ -16927,17 +16867,17 @@ class BaseApi extends BaseApiAbstract {
16927
16867
  */
16928
16868
  async getResponse(response) {
16929
16869
  var _a, _b, _c, _d, _e, _f, _g;
16930
- let responseData = (response === null || response === undefined ? undefined : response.data) ? response.data : null;
16870
+ let responseData = (response === null || response === void 0 ? void 0 : response.data) ? response.data : null;
16931
16871
  let isEncrypted = false;
16932
16872
  let timestamp = 0;
16933
- if ((response === null || response === undefined ? undefined : response.headers) &&
16934
- ((_a = response === null || response === undefined ? undefined : response.headers) === null || _a === undefined ? undefined : _a.has) &&
16935
- ((_b = response === null || response === undefined ? undefined : response.headers) === null || _b === undefined ? undefined : _b.has(REQUEST_CLOUD_PROTECTED_KEY)) &&
16936
- ((_c = response === null || response === undefined ? undefined : response.headers) === null || _c === undefined ? undefined : _c.has(REQUEST_CLOUD_PROTECTED_TIMESTAMP)) &&
16937
- ((_d = response === null || response === undefined ? undefined : response.headers) === null || _d === undefined ? undefined : _d.get)) {
16938
- isEncrypted = ((_e = response === null || response === undefined ? undefined : response.headers) === null || _e === undefined ? undefined : _e.get(REQUEST_CLOUD_PROTECTED_KEY)) === 'true';
16939
- timestamp = ((_f = response === null || response === undefined ? undefined : response.headers) === null || _f === undefined ? undefined : _f.get(REQUEST_CLOUD_PROTECTED_TIMESTAMP))
16940
- ? Number((_g = response === null || response === undefined ? undefined : response.headers) === null || _g === undefined ? undefined : _g.get(REQUEST_CLOUD_PROTECTED_TIMESTAMP))
16873
+ if ((response === null || response === void 0 ? void 0 : response.headers) &&
16874
+ ((_a = response === null || response === void 0 ? void 0 : response.headers) === null || _a === void 0 ? void 0 : _a.has) &&
16875
+ ((_b = response === null || response === void 0 ? void 0 : response.headers) === null || _b === void 0 ? void 0 : _b.has(REQUEST_CLOUD_PROTECTED_KEY)) &&
16876
+ ((_c = response === null || response === void 0 ? void 0 : response.headers) === null || _c === void 0 ? void 0 : _c.has(REQUEST_CLOUD_PROTECTED_TIMESTAMP)) &&
16877
+ ((_d = response === null || response === void 0 ? void 0 : response.headers) === null || _d === void 0 ? void 0 : _d.get)) {
16878
+ isEncrypted = ((_e = response === null || response === void 0 ? void 0 : response.headers) === null || _e === void 0 ? void 0 : _e.get(REQUEST_CLOUD_PROTECTED_KEY)) === 'true';
16879
+ timestamp = ((_f = response === null || response === void 0 ? void 0 : response.headers) === null || _f === void 0 ? void 0 : _f.get(REQUEST_CLOUD_PROTECTED_TIMESTAMP))
16880
+ ? Number((_g = response === null || response === void 0 ? void 0 : response.headers) === null || _g === void 0 ? void 0 : _g.get(REQUEST_CLOUD_PROTECTED_TIMESTAMP))
16941
16881
  : 0;
16942
16882
  }
16943
16883
  if (responseData &&
@@ -16946,7 +16886,7 @@ class BaseApi extends BaseApiAbstract {
16946
16886
  timestamp > 0) {
16947
16887
  const { t: encryptedPayload } = responseData;
16948
16888
  const decryptedData = await this.encryptedApi.handleDecryption(encryptedPayload, timestamp);
16949
- if (decryptedData === null || decryptedData === undefined ? undefined : decryptedData.payload) {
16889
+ if (decryptedData === null || decryptedData === void 0 ? void 0 : decryptedData.payload) {
16950
16890
  delete decryptedData.payload.exp;
16951
16891
  delete decryptedData.payload.iat;
16952
16892
  responseData = decryptedData.payload;
@@ -17000,9 +16940,9 @@ class AuthService extends BaseApi {
17000
16940
  },
17001
16941
  });
17002
16942
  if (isErr) {
17003
- throw new Error(`There was an error during authentication: (${isErr === null || isErr === undefined ? undefined : isErr.errorMessage})`);
16943
+ throw new Error(`There was an error during authentication: (${isErr === null || isErr === void 0 ? void 0 : isErr.errorMessage})`);
17004
16944
  }
17005
- if (isOk && (val === null || val === undefined ? undefined : val.data.token)) {
16945
+ if (isOk && (val === null || val === void 0 ? void 0 : val.data.token)) {
17006
16946
  this.authInfo.token = val.data.token;
17007
16947
  this.authInfo.authenticated = true;
17008
16948
  }
@@ -17142,7 +17082,7 @@ class BaseSpotComponent extends BaseElement {
17142
17082
  const isMobileNewValue = e.matches;
17143
17083
  if (this._isMobileDevice !== isMobileNewValue) {
17144
17084
  this._isMobileDevice = isMobileNewValue;
17145
- (_a = this.onDeviceChange) === null || _a === undefined ? undefined : _a.call(this, this._isMobileDevice);
17085
+ (_a = this.onDeviceChange) === null || _a === void 0 ? void 0 : _a.call(this, this._isMobileDevice);
17146
17086
  if (this.reRenderOnDeviceChange) {
17147
17087
  this.render();
17148
17088
  }
@@ -17163,13 +17103,13 @@ class BaseSpotComponent extends BaseElement {
17163
17103
  this.render();
17164
17104
  this.setupDeviceDetection();
17165
17105
  }
17166
- (_a = this.connected) === null || _a === undefined ? undefined : _a.call(this);
17106
+ (_a = this.connected) === null || _a === void 0 ? void 0 : _a.call(this);
17167
17107
  }
17168
17108
  disconnectedCallback() {
17169
17109
  var _a;
17170
17110
  if (!isBrowser)
17171
17111
  return;
17172
- (_a = this.disconnected) === null || _a === undefined ? undefined : _a.call(this);
17112
+ (_a = this.disconnected) === null || _a === void 0 ? void 0 : _a.call(this);
17173
17113
  }
17174
17114
  }
17175
17115
 
@@ -17212,11 +17152,11 @@ class LocalStorageService {
17212
17152
  setSpot(spotId, data) {
17213
17153
  var _a, _b, _c, _d, _e;
17214
17154
  data.createdAt = Date.now();
17215
- const isExistentSpot = (_a = this.spots) === null || _a === undefined ? undefined : _a.has(spotId);
17155
+ const isExistentSpot = (_a = this.spots) === null || _a === void 0 ? void 0 : _a.has(spotId);
17216
17156
  if (isExistentSpot) {
17217
- data.firedEvents = (_d = (_c = (_b = this.spots) === null || _b === undefined ? undefined : _b.get(spotId)) === null || _c === undefined ? undefined : _c.firedEvents) !== null && _d !== undefined ? _d : [];
17157
+ data.firedEvents = (_d = (_c = (_b = this.spots) === null || _b === void 0 ? void 0 : _b.get(spotId)) === null || _c === void 0 ? void 0 : _c.firedEvents) !== null && _d !== void 0 ? _d : [];
17218
17158
  }
17219
- (_e = this.spots) === null || _e === undefined ? undefined : _e.set(spotId, data);
17159
+ (_e = this.spots) === null || _e === void 0 ? void 0 : _e.set(spotId, data);
17220
17160
  this.updateLocalStorage();
17221
17161
  }
17222
17162
  // public removeSpot(spotId: string): void {
@@ -17261,12 +17201,12 @@ class LocalStorageService {
17261
17201
  setUserId() {
17262
17202
  var _a;
17263
17203
  const prefix = LocalStorageService.localStorageKeyPrefix;
17264
- const existingKeys = Object.keys((_a = window.localStorage) !== null && _a !== undefined ? _a : {}).filter((key) => key.startsWith(prefix));
17204
+ const existingKeys = Object.keys((_a = window.localStorage) !== null && _a !== void 0 ? _a : {}).filter((key) => key.startsWith(prefix));
17265
17205
  const setNewKey = () => {
17266
17206
  var _a;
17267
17207
  const uniqueId = UniqueIdGenerator.generate();
17268
17208
  const newLocalStorageKey = `${prefix}_${uniqueId}`;
17269
- (_a = window.localStorage) === null || _a === undefined ? undefined : _a.setItem(newLocalStorageKey, '');
17209
+ (_a = window.localStorage) === null || _a === void 0 ? void 0 : _a.setItem(newLocalStorageKey, '');
17270
17210
  LocalStorageService.localStorageKey = newLocalStorageKey;
17271
17211
  };
17272
17212
  if (existingKeys.length === 0) {
@@ -17278,7 +17218,7 @@ class LocalStorageService {
17278
17218
  existingKeys.forEach((key) => {
17279
17219
  var _a;
17280
17220
  if (key !== validKey) {
17281
- (_a = window.localStorage) === null || _a === undefined ? undefined : _a.removeItem(key);
17221
+ (_a = window.localStorage) === null || _a === void 0 ? void 0 : _a.removeItem(key);
17282
17222
  }
17283
17223
  });
17284
17224
  if (validKey) {
@@ -17294,7 +17234,7 @@ class LocalStorageService {
17294
17234
  // ======================== Utility functions ======================== //
17295
17235
  syncLocalStorage() {
17296
17236
  var _a;
17297
- const localStorageData = (_a = window.localStorage) === null || _a === undefined ? undefined : _a.getItem(LocalStorageService.localStorageKey);
17237
+ const localStorageData = (_a = window.localStorage) === null || _a === void 0 ? void 0 : _a.getItem(LocalStorageService.localStorageKey);
17298
17238
  if (localStorageData) {
17299
17239
  try {
17300
17240
  const decryptedData = this.decryptData(localStorageData);
@@ -17333,15 +17273,15 @@ class LocalStorageService {
17333
17273
  }
17334
17274
  clearLocalStorage() {
17335
17275
  var _a;
17336
- (_a = window.localStorage) === null || _a === undefined ? undefined : _a.removeItem(LocalStorageService.localStorageKey);
17276
+ (_a = window.localStorage) === null || _a === void 0 ? void 0 : _a.removeItem(LocalStorageService.localStorageKey);
17337
17277
  }
17338
17278
  removeExpiredSpots() {
17339
17279
  var _a;
17340
17280
  const currentTime = Date.now();
17341
- (_a = this.spots) === null || _a === undefined ? undefined : _a.forEach((spot, spotId) => {
17281
+ (_a = this.spots) === null || _a === void 0 ? void 0 : _a.forEach((spot, spotId) => {
17342
17282
  var _a, _b;
17343
- if (currentTime - ((_a = spot.createdAt) !== null && _a !== undefined ? _a : 0) > LocalStorageService.spotExpirationTime) {
17344
- (_b = this.spots) === null || _b === undefined ? undefined : _b.delete(spotId);
17283
+ if (currentTime - ((_a = spot.createdAt) !== null && _a !== void 0 ? _a : 0) > LocalStorageService.spotExpirationTime) {
17284
+ (_b = this.spots) === null || _b === void 0 ? void 0 : _b.delete(spotId);
17345
17285
  }
17346
17286
  });
17347
17287
  this.updateLocalStorage();
@@ -17377,9 +17317,9 @@ class LocalStorageService {
17377
17317
  obj.spotId,
17378
17318
  obj.spotType,
17379
17319
  this.spotEventObjectToArray(obj.events),
17380
- (_b = (_a = obj.firedEvents) === null || _a === undefined ? undefined : _a.map((event) => [event.productId, event.event])) !== null && _b !== undefined ? _b : [],
17320
+ (_b = (_a = obj.firedEvents) === null || _a === void 0 ? void 0 : _a.map((event) => [event.productId, event.event])) !== null && _b !== void 0 ? _b : [],
17381
17321
  obj.productIds,
17382
- (_c = obj.createdAt) !== null && _c !== undefined ? _c : 0,
17322
+ (_c = obj.createdAt) !== null && _c !== void 0 ? _c : 0,
17383
17323
  ];
17384
17324
  }
17385
17325
  /**
@@ -17449,8 +17389,8 @@ class ProximityObserver {
17449
17389
  this.targetIds = new Set(elementIds);
17450
17390
  this.processedIds = new Set();
17451
17391
  this.callback = callback;
17452
- this.proximityThreshold = (_a = options.proximityThreshold) !== null && _a !== undefined ? _a : 500;
17453
- this.intersectionMargin = (_b = options.intersectionMargin) !== null && _b !== undefined ? _b : '2000px';
17392
+ this.proximityThreshold = (_a = options.proximityThreshold) !== null && _a !== void 0 ? _a : 500;
17393
+ this.intersectionMargin = (_b = options.intersectionMargin) !== null && _b !== void 0 ? _b : '2000px';
17454
17394
  this.initializeObservers();
17455
17395
  this.observeExistingElements();
17456
17396
  }
@@ -17491,7 +17431,7 @@ class ProximityObserver {
17491
17431
  });
17492
17432
  // Start observing DOM changes
17493
17433
  if (document.body) {
17494
- (_a = this.mutationObserver) === null || _a === undefined ? undefined : _a.observe(document.body, {
17434
+ (_a = this.mutationObserver) === null || _a === void 0 ? void 0 : _a.observe(document.body, {
17495
17435
  childList: true,
17496
17436
  subtree: true,
17497
17437
  });
@@ -17501,13 +17441,13 @@ class ProximityObserver {
17501
17441
  var _a;
17502
17442
  if (element.id && this.processedIds.has(element.id)) {
17503
17443
  this.processedIds.delete(element.id);
17504
- (_a = this.intersectionObserver) === null || _a === undefined ? undefined : _a.unobserve(element);
17444
+ (_a = this.intersectionObserver) === null || _a === void 0 ? void 0 : _a.unobserve(element);
17505
17445
  }
17506
17446
  }
17507
17447
  checkElement(element) {
17508
17448
  var _a;
17509
17449
  if (element.id && this.targetIds.has(element.id) && !this.processedIds.has(element.id)) {
17510
- (_a = this.intersectionObserver) === null || _a === undefined ? undefined : _a.observe(element);
17450
+ (_a = this.intersectionObserver) === null || _a === void 0 ? void 0 : _a.observe(element);
17511
17451
  }
17512
17452
  }
17513
17453
  findNearbyTargetIds(element) {
@@ -17554,7 +17494,7 @@ class ProximityObserver {
17554
17494
  this.processedIds.add(id);
17555
17495
  const el = document.getElementById(id);
17556
17496
  if (el)
17557
- (_a = this.intersectionObserver) === null || _a === undefined ? undefined : _a.unobserve(el);
17497
+ (_a = this.intersectionObserver) === null || _a === void 0 ? void 0 : _a.unobserve(el);
17558
17498
  });
17559
17499
  // Trigger callback with the group
17560
17500
  this.callback(groupIdsToProcess);
@@ -17677,7 +17617,7 @@ class ResizeObserverService {
17677
17617
  this.container = element.parentElement;
17678
17618
  this.setDimensions(maxSize, minScale);
17679
17619
  this.resizeObserver = new ResizeObserver(() => this.updateElementSize());
17680
- (_a = this.resizeObserver) === null || _a === undefined ? undefined : _a.observe(this.container);
17620
+ (_a = this.resizeObserver) === null || _a === void 0 ? void 0 : _a.observe(this.container);
17681
17621
  // Initial size update
17682
17622
  this.updateElementSize();
17683
17623
  }
@@ -17733,7 +17673,7 @@ class ResizeObserverService {
17733
17673
  }
17734
17674
  disconnect() {
17735
17675
  var _a;
17736
- (_a = this.resizeObserver) === null || _a === undefined ? undefined : _a.disconnect();
17676
+ (_a = this.resizeObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
17737
17677
  }
17738
17678
  }
17739
17679
 
@@ -17793,7 +17733,7 @@ function importFonts(...fonts) {
17793
17733
  ].join('');
17794
17734
  }
17795
17735
  function renderElement(tag, className, content) {
17796
- return (content === null || content === undefined ? undefined : content.trim()) ? `<${tag} class="${className}">${content}</${tag}>` : '';
17736
+ return (content === null || content === void 0 ? void 0 : content.trim()) ? `<${tag} class="${className}">${content}</${tag}>` : '';
17797
17737
  }
17798
17738
 
17799
17739
  class BillboardV1SE extends BaseSpotComponent {
@@ -17807,7 +17747,7 @@ class BillboardV1SE extends BaseSpotComponent {
17807
17747
  disconnected() {
17808
17748
  var _a;
17809
17749
  this.removeEventListener('spotSizeChanged', this.handleSpotSizeChanged);
17810
- (_a = this.resizeObserver) === null || _a === undefined ? undefined : _a.disconnect();
17750
+ (_a = this.resizeObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
17811
17751
  }
17812
17752
  setupResizeObserver() {
17813
17753
  if (!this._config.fluid) {
@@ -17830,7 +17770,7 @@ class BillboardV1SE extends BaseSpotComponent {
17830
17770
  var _a;
17831
17771
  // Find all text elements within the shadow root
17832
17772
  const selectors = ['h2', 'p', 'span'].join(', ');
17833
- const elements = (_a = this.shadowRoot) === null || _a === undefined ? undefined : _a.querySelectorAll(selectors);
17773
+ const elements = (_a = this.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelectorAll(selectors);
17834
17774
  if (!elements)
17835
17775
  return;
17836
17776
  const scaleFactor = calculateScaleFactor(elementScale);
@@ -18114,7 +18054,6 @@ class RbHomepageHeroFullImageSE extends BaseSpotComponent {
18114
18054
  background-size: cover;
18115
18055
  background-repeat: no-repeat;
18116
18056
  background-position: center;
18117
- padding: 3%;
18118
18057
  box-sizing: border-box;
18119
18058
  color: ${textColor};
18120
18059
  cursor: pointer;
@@ -18126,7 +18065,6 @@ class RbHomepageHeroFullImageSE extends BaseSpotComponent {
18126
18065
  flex-direction: column;
18127
18066
  justify-content: flex-start;
18128
18067
  align-items: flex-start;
18129
- width: 100%;
18130
18068
  height: fit-content;
18131
18069
  gap: 8px;
18132
18070
  position: absolute;
@@ -18136,12 +18074,14 @@ class RbHomepageHeroFullImageSE extends BaseSpotComponent {
18136
18074
  .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.TOP_LEFT} {
18137
18075
  top: 3%;
18138
18076
  left: 3%;
18077
+ right: 3%;
18139
18078
  align-items: flex-start;
18140
18079
  text-align: left;
18141
18080
  }
18142
18081
 
18143
18082
  .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.TOP_RIGHT} {
18144
18083
  top: 3%;
18084
+ left: 3%;
18145
18085
  right: 3%;
18146
18086
  align-items: flex-end;
18147
18087
  text-align: right;
@@ -18150,6 +18090,7 @@ class RbHomepageHeroFullImageSE extends BaseSpotComponent {
18150
18090
  .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.MIDDLE_LEFT} {
18151
18091
  top: 50%;
18152
18092
  left: 3%;
18093
+ right: 3%;
18153
18094
  transform: translateY(-50%);
18154
18095
  align-items: flex-start;
18155
18096
  text-align: left;
@@ -18157,6 +18098,7 @@ class RbHomepageHeroFullImageSE extends BaseSpotComponent {
18157
18098
 
18158
18099
  .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.MIDDLE_RIGHT} {
18159
18100
  top: 50%;
18101
+ left: 3%;
18160
18102
  right: 3%;
18161
18103
  transform: translateY(-50%);
18162
18104
  align-items: flex-end;
@@ -18166,12 +18108,14 @@ class RbHomepageHeroFullImageSE extends BaseSpotComponent {
18166
18108
  .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_LEFT} {
18167
18109
  bottom: 3%;
18168
18110
  left: 3%;
18111
+ right: 3%;
18169
18112
  align-items: flex-start;
18170
18113
  text-align: left;
18171
18114
  }
18172
18115
 
18173
18116
  .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_RIGHT} {
18174
18117
  bottom: 3%;
18118
+ left: 3%;
18175
18119
  right: 3%;
18176
18120
  align-items: flex-end;
18177
18121
  text-align: right;
@@ -18237,12 +18181,14 @@ class RbHomepageHeroFullImageSE extends BaseSpotComponent {
18237
18181
  .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.TOP_LEFT} {
18238
18182
  top: 3%;
18239
18183
  left: 3%;
18184
+ right: 3%;
18240
18185
  align-items: flex-start;
18241
18186
  text-align: left;
18242
18187
  }
18243
18188
 
18244
18189
  .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.TOP_RIGHT} {
18245
18190
  top: 3%;
18191
+ left: 3%;
18246
18192
  right: 3%;
18247
18193
  align-items: flex-end;
18248
18194
  text-align: right;
@@ -18251,6 +18197,7 @@ class RbHomepageHeroFullImageSE extends BaseSpotComponent {
18251
18197
  .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.MIDDLE_LEFT} {
18252
18198
  top: 50%;
18253
18199
  left: 3%;
18200
+ right: 3%;
18254
18201
  transform: translateY(-50%);
18255
18202
  align-items: flex-start;
18256
18203
  text-align: left;
@@ -18258,6 +18205,7 @@ class RbHomepageHeroFullImageSE extends BaseSpotComponent {
18258
18205
 
18259
18206
  .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.MIDDLE_RIGHT} {
18260
18207
  top: 50%;
18208
+ left: 3%;
18261
18209
  right: 3%;
18262
18210
  transform: translateY(-50%);
18263
18211
  align-items: flex-end;
@@ -18267,12 +18215,14 @@ class RbHomepageHeroFullImageSE extends BaseSpotComponent {
18267
18215
  .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_LEFT} {
18268
18216
  bottom: 3%;
18269
18217
  left: 3%;
18218
+ right: 3%;
18270
18219
  align-items: flex-start;
18271
18220
  text-align: left;
18272
18221
  }
18273
18222
 
18274
18223
  .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_RIGHT} {
18275
18224
  bottom: 3%;
18225
+ left: 3%;
18276
18226
  right: 3%;
18277
18227
  align-items: flex-end;
18278
18228
  text-align: right;
@@ -19295,7 +19245,6 @@ class RbLongToutTallSE extends BaseSpotComponent {
19295
19245
  background-size: cover;
19296
19246
  background-repeat: no-repeat;
19297
19247
  background-position: center;
19298
- padding: 3%;
19299
19248
  box-sizing: border-box;
19300
19249
  color: ${textColor};
19301
19250
  cursor: pointer;
@@ -19307,7 +19256,6 @@ class RbLongToutTallSE extends BaseSpotComponent {
19307
19256
  flex-direction: column;
19308
19257
  justify-content: flex-start;
19309
19258
  align-items: flex-start;
19310
- width: 100%;
19311
19259
  height: fit-content;
19312
19260
  gap: 8px;
19313
19261
  position: absolute;
@@ -19317,12 +19265,14 @@ class RbLongToutTallSE extends BaseSpotComponent {
19317
19265
  .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.TOP_LEFT} {
19318
19266
  top: 3%;
19319
19267
  left: 3%;
19268
+ right: 3%;
19320
19269
  align-items: flex-start;
19321
19270
  text-align: left;
19322
19271
  }
19323
19272
 
19324
19273
  .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.TOP_RIGHT} {
19325
19274
  top: 3%;
19275
+ left: 3%;
19326
19276
  right: 3%;
19327
19277
  align-items: flex-end;
19328
19278
  text-align: right;
@@ -19331,6 +19281,7 @@ class RbLongToutTallSE extends BaseSpotComponent {
19331
19281
  .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.MIDDLE_LEFT} {
19332
19282
  top: 50%;
19333
19283
  left: 3%;
19284
+ right: 3%;
19334
19285
  transform: translateY(-50%);
19335
19286
  align-items: flex-start;
19336
19287
  text-align: left;
@@ -19338,6 +19289,7 @@ class RbLongToutTallSE extends BaseSpotComponent {
19338
19289
 
19339
19290
  .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.MIDDLE_RIGHT} {
19340
19291
  top: 50%;
19292
+ left: 3%;
19341
19293
  right: 3%;
19342
19294
  transform: translateY(-50%);
19343
19295
  align-items: flex-end;
@@ -19347,12 +19299,14 @@ class RbLongToutTallSE extends BaseSpotComponent {
19347
19299
  .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_LEFT} {
19348
19300
  bottom: 3%;
19349
19301
  left: 3%;
19302
+ right: 3%;
19350
19303
  align-items: flex-start;
19351
19304
  text-align: left;
19352
19305
  }
19353
19306
 
19354
19307
  .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_RIGHT} {
19355
19308
  bottom: 3%;
19309
+ left: 3%;
19356
19310
  right: 3%;
19357
19311
  align-items: flex-end;
19358
19312
  text-align: right;
@@ -19373,12 +19327,14 @@ class RbLongToutTallSE extends BaseSpotComponent {
19373
19327
  .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.TOP_LEFT} {
19374
19328
  top: 3%;
19375
19329
  left: 3%;
19330
+ right: 3%;
19376
19331
  align-items: flex-start;
19377
19332
  text-align: left;
19378
19333
  }
19379
19334
 
19380
19335
  .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.TOP_RIGHT} {
19381
19336
  top: 3%;
19337
+ left: 3%;
19382
19338
  right: 3%;
19383
19339
  align-items: flex-end;
19384
19340
  text-align: right;
@@ -19387,6 +19343,7 @@ class RbLongToutTallSE extends BaseSpotComponent {
19387
19343
  .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.MIDDLE_LEFT} {
19388
19344
  top: 50%;
19389
19345
  left: 3%;
19346
+ right: 3%;
19390
19347
  transform: translateY(-50%);
19391
19348
  align-items: flex-start;
19392
19349
  text-align: left;
@@ -19394,6 +19351,7 @@ class RbLongToutTallSE extends BaseSpotComponent {
19394
19351
 
19395
19352
  .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.MIDDLE_RIGHT} {
19396
19353
  top: 50%;
19354
+ left: 3%;
19397
19355
  right: 3%;
19398
19356
  transform: translateY(-50%);
19399
19357
  align-items: flex-end;
@@ -19403,12 +19361,14 @@ class RbLongToutTallSE extends BaseSpotComponent {
19403
19361
  .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_LEFT} {
19404
19362
  bottom: 3%;
19405
19363
  left: 3%;
19364
+ right: 3%;
19406
19365
  align-items: flex-start;
19407
19366
  text-align: left;
19408
19367
  }
19409
19368
 
19410
19369
  .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_RIGHT} {
19411
19370
  bottom: 3%;
19371
+ left: 3%;
19412
19372
  right: 3%;
19413
19373
  align-items: flex-end;
19414
19374
  text-align: right;
@@ -19787,6 +19747,7 @@ class RbSmallDiscoverToutSE extends BaseSpotComponent {
19787
19747
  class RbVideoPlayerSE extends BaseSpotComponent {
19788
19748
  constructor() {
19789
19749
  super();
19750
+ this.reRenderOnDeviceChange = true;
19790
19751
  this.videoSelector = () => `.${this._config.prefix}__video-element`;
19791
19752
  this.muteButtonSelector = () => `.${this._config.prefix}__mute-button`;
19792
19753
  this.video = null;
@@ -19844,62 +19805,106 @@ class RbVideoPlayerSE extends BaseSpotComponent {
19844
19805
  if (!this.video)
19845
19806
  return;
19846
19807
  const muteButton = this._container.querySelector(this.muteButtonSelector());
19847
- muteButton === null || muteButton === undefined ? undefined : muteButton.addEventListener('click', this.handleMuteToggle);
19808
+ muteButton === null || muteButton === void 0 ? void 0 : muteButton.addEventListener('click', this.handleMuteToggle);
19848
19809
  }
19849
19810
  removeEventListeners() {
19850
19811
  if (!this.video)
19851
19812
  return;
19852
19813
  const muteButton = this._container.querySelector(this.muteButtonSelector());
19853
- muteButton === null || muteButton === undefined ? undefined : muteButton.removeEventListener('click', this.handleMuteToggle);
19814
+ muteButton === null || muteButton === void 0 ? void 0 : muteButton.removeEventListener('click', this.handleMuteToggle);
19815
+ }
19816
+ getGradientDirection(position) {
19817
+ switch (position) {
19818
+ case exports.ENUM_TEXT_BLOCK_POSITION.TOP_LEFT:
19819
+ case exports.ENUM_TEXT_BLOCK_POSITION.TOP_RIGHT:
19820
+ return 'to bottom';
19821
+ case exports.ENUM_TEXT_BLOCK_POSITION.MIDDLE_LEFT:
19822
+ return 'to right';
19823
+ case exports.ENUM_TEXT_BLOCK_POSITION.MIDDLE_RIGHT:
19824
+ return 'to left';
19825
+ case exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_LEFT:
19826
+ case exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_RIGHT:
19827
+ return 'to top';
19828
+ default:
19829
+ return 'to top';
19830
+ }
19831
+ }
19832
+ get hasContent() {
19833
+ const { header, mobileHeader, description, mobileDescription,
19834
+ // eslint-disable-next-line @typescript-eslint/naming-convention
19835
+ enableMobileTexts = false, } = this._data;
19836
+ const content = this._isMobileDevice && enableMobileTexts
19837
+ ? {
19838
+ header: mobileHeader,
19839
+ description: mobileDescription,
19840
+ }
19841
+ : { header, description };
19842
+ return Object.values(content).some(Boolean);
19854
19843
  }
19855
19844
  template() {
19856
19845
  const prefix = this._config.prefix;
19857
- const { url, posterTitle, posterDescription } = this._data.video;
19846
+ const { header, mobileHeader, description, mobileDescription, textBlockPosition = exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_LEFT, mobileTextBlockPosition = textBlockPosition,
19847
+ // eslint-disable-next-line @typescript-eslint/naming-convention
19848
+ enableMobileTexts = false, } = this._data;
19849
+ // eslint-disable-next-line @typescript-eslint/naming-convention
19850
+ const { url, mobileUrl = url, mute = true, showMute = true } = this._data.video;
19858
19851
  if (!url) {
19859
19852
  return '<p>Please provide a video source</p>';
19860
19853
  }
19861
19854
  const renderOverlay = () => {
19862
- if (!posterTitle && !posterDescription)
19855
+ if (!this.hasContent)
19863
19856
  return '';
19857
+ const content = this._isMobileDevice && enableMobileTexts
19858
+ ? {
19859
+ header: mobileHeader,
19860
+ description: mobileDescription,
19861
+ }
19862
+ : { header, description };
19863
+ const elements = [
19864
+ renderElement('h2', `${prefix}__header`, content.header),
19865
+ renderElement('p', `${prefix}__description`, content.description),
19866
+ ];
19864
19867
  return `
19865
- <div class="${prefix}__overlay">
19866
- <div class="${prefix}__overlay-text">
19867
- ${posterTitle ? `<h2 class="${prefix}__title">${posterTitle}</h2>` : ''}
19868
- ${posterDescription ? `<p class="${prefix}__description">${posterDescription}</p>` : ''}
19869
- </div>
19868
+ <div class="${prefix}__text ${prefix}__text-block--${textBlockPosition} ${prefix}__text-block-mobile--${mobileTextBlockPosition}">
19869
+ ${elements.join('')}
19870
19870
  </div>
19871
19871
  `;
19872
19872
  };
19873
19873
  const renderVideo = () => `
19874
- <div class="${prefix}__video-container">
19875
- <video
19876
- class="${prefix}__video-element"
19877
- src="${url}"
19878
- autoplay
19879
- muted
19880
- loop
19881
- preload="metadata"
19882
- >
19883
- Your browser doesn't support HTML5 video playback.
19884
- </video>
19885
- </div>
19886
- `;
19887
- const renderMuteButton = () => `
19888
- <button type="button" class="${prefix}__mute-button">
19889
- <span class="${prefix}__mute-icon">
19890
- ${this.getMuteIcon()}
19891
- </span>
19892
- </button>
19893
- `;
19894
- const renderControls = () => `
19895
- <div class="${prefix}__controls">
19896
- ${renderMuteButton()}
19874
+ <div class="${prefix}__video-wrapper">
19875
+ <div class="${prefix}__video-container">
19876
+ <video
19877
+ class="${prefix}__video-element"
19878
+ src="${this._isMobileDevice ? mobileUrl : url}"
19879
+ autoplay
19880
+ ${mute ? 'muted' : ''}
19881
+ loop
19882
+ preload="metadata"
19883
+ playsinline
19884
+ >
19885
+ Your browser doesn't support HTML5 video playback.
19886
+ </video>
19887
+ </div>
19897
19888
  </div>
19898
19889
  `;
19890
+ const renderMuteButton = () => showMute
19891
+ ? `
19892
+ <button type="button" class="${prefix}__mute-button">
19893
+ <span class="${prefix}__mute-icon">
19894
+ ${this.getMuteIcon()}
19895
+ </span>
19896
+ </button>
19897
+ `
19898
+ : '';
19899
+ const renderControls = () => showMute
19900
+ ? `
19901
+ <div class="${prefix}__controls">
19902
+ ${renderMuteButton()}
19903
+ </div>
19904
+ `
19905
+ : '';
19899
19906
  return `
19900
- ${GFONT_PRECONNECT}
19901
- ${GFONT_SOURCE_SANS_3}
19902
- ${GFONT_CORMORANT}
19907
+ ${importFonts()}
19903
19908
  <div class="${prefix}">
19904
19909
  ${renderOverlay()}
19905
19910
  ${renderVideo()}
@@ -19909,67 +19914,228 @@ class RbVideoPlayerSE extends BaseSpotComponent {
19909
19914
  }
19910
19915
  styles() {
19911
19916
  const prefix = this._config.prefix;
19917
+ const { width, height, textBlockPosition = exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_LEFT, mobileTextBlockPosition = textBlockPosition, textColor = '#ffffff', } = this._data;
19918
+ const { aspectRatio = '16:9' } = this._data.video;
19919
+ const desktopGradientDirection = this.getGradientDirection(textBlockPosition);
19920
+ const mobileGradientDirection = this.getGradientDirection(mobileTextBlockPosition);
19921
+ const linearGradient = generateGradientColor(this._config.overlay, 'rgba(0, 0, 0, 1) 0%, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0) 40%');
19922
+ const hostSelector = this._config.useShadowDom ? ':host' : this.tagName.toLowerCase();
19912
19923
  return `
19924
+ ${hostSelector} {
19925
+ width: 100%;
19926
+ height: 100%;
19927
+ max-width: ${width}px;
19928
+ max-height: ${height}px};
19929
+ }
19930
+
19913
19931
  .${prefix} {
19914
19932
  width: 100%;
19915
19933
  height: 100%;
19916
- background: #000;
19934
+ background: #fff;
19917
19935
  overflow: hidden;
19918
19936
  position: relative;
19919
19937
  }
19920
19938
 
19921
- .${prefix}__overlay {
19939
+ .${prefix}::before {
19940
+ content: '';
19922
19941
  position: absolute;
19923
19942
  top: 0;
19924
19943
  left: 0;
19925
19944
  right: 0;
19926
- z-index: 2;
19945
+ bottom: 0;
19946
+ z-index: 1;
19947
+ pointer-events: none;
19948
+ }
19949
+
19950
+ .${prefix}__video-wrapper {
19951
+ width: 100%;
19952
+ height: 100%;
19953
+ position: relative;
19954
+ overflow: hidden;
19955
+ }
19956
+
19957
+ .${prefix}__video-container {
19958
+ position: relative;
19927
19959
  width: 100%;
19928
19960
  height: 100%;
19929
19961
  display: flex;
19930
- flex-direction: column;
19931
- justify-content: flex-end;
19932
- background-image: linear-gradient(to top, rgba(0, 0, 0, 1) 0%, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0) 40%);
19962
+ justify-content: center;
19963
+ align-items: center;
19964
+ aspect-ratio: ${aspectRatio.replace(':', '/')};
19933
19965
  }
19934
19966
 
19935
- .${prefix}__overlay-text {
19936
- padding: 3rem;
19967
+ .${prefix}__video-element {
19968
+ position: absolute;
19969
+ top: 50%;
19970
+ left: 50%;
19971
+ transform: translate(-50%, -50%);
19972
+ width: 100%;
19973
+ height: 100%;
19974
+ object-fit: contain;
19975
+ }
19976
+
19977
+ @media (max-aspect-ratio: 16/9) {
19978
+ .${prefix}__video-element {
19979
+ width: 100%;
19980
+ height: auto;
19981
+ }
19982
+ }
19983
+
19984
+ @media (min-aspect-ratio: 16/9) {
19985
+ .${prefix}__video-element {
19986
+ width: auto;
19987
+ height: 100%;
19988
+ }
19989
+ }
19990
+
19991
+ .${prefix}__text {
19937
19992
  display: flex;
19938
19993
  flex-direction: column;
19994
+ justify-content: flex-start;
19995
+ align-items: flex-start;
19996
+ height: fit-content;
19939
19997
  gap: 8px;
19998
+ position: absolute;
19999
+ color: ${textColor};
20000
+ z-index: 10;
19940
20001
  }
19941
20002
 
19942
- .${prefix}__title {
19943
- color: #fff;
19944
- font-size: 26px;
19945
- margin: 0;
19946
- font-family: "Cormorant", system-ui;
19947
- font-style: normal;
19948
- font-weight: 300;
19949
- line-height: normal;
20003
+ @container (max-width: 639px) {
20004
+ .${prefix}::before {
20005
+ ${this.hasContent
20006
+ ? `background: linear-gradient(${mobileGradientDirection}, ${linearGradient});`
20007
+ : ``}
20008
+ }
20009
+
20010
+ .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.TOP_LEFT} {
20011
+ top: 3%;
20012
+ left: 3%;
20013
+ right: 3%;
20014
+ align-items: flex-start;
20015
+ text-align: left;
20016
+ }
20017
+
20018
+ .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.TOP_RIGHT} {
20019
+ top: 3%;
20020
+ left: 3%;
20021
+ right: 3%;
20022
+ align-items: flex-end;
20023
+ text-align: right;
20024
+ }
20025
+
20026
+ .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.MIDDLE_LEFT} {
20027
+ top: 50%;
20028
+ left: 3%;
20029
+ right: 3%;
20030
+ transform: translateY(-50%);
20031
+ align-items: flex-start;
20032
+ text-align: left;
20033
+ }
20034
+
20035
+ .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.MIDDLE_RIGHT} {
20036
+ top: 50%;
20037
+ left: 3%;
20038
+ right: 3%;
20039
+ transform: translateY(-50%);
20040
+ align-items: flex-end;
20041
+ text-align: right;
20042
+ }
20043
+
20044
+ .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_LEFT} {
20045
+ bottom: 3%;
20046
+ left: 3%;
20047
+ right: 3%;
20048
+ align-items: flex-start;
20049
+ text-align: left;
20050
+ }
20051
+
20052
+ .${prefix}__text-block-mobile--${exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_RIGHT} {
20053
+ bottom: 3%;
20054
+ left: 3%;
20055
+ right: 3%;
20056
+ align-items: flex-end;
20057
+ text-align: right;
20058
+ }
19950
20059
  }
19951
20060
 
19952
- .${prefix}__description {
19953
- color: #ccc;
19954
- margin: 0;
19955
- font-size: 13px;
19956
- font-family: "Source Sans 3", system-ui;
19957
- font-style: normal;
19958
- font-weight: 400;
19959
- line-height: 20px;
20061
+ @container (min-width: 640px) {
20062
+ .${prefix}::before {
20063
+ ${this.hasContent
20064
+ ? `background: linear-gradient(${desktopGradientDirection}, ${linearGradient});`
20065
+ : ``}
20066
+ }
20067
+
20068
+ .${prefix}__text {
20069
+ width: 70%;
20070
+ }
20071
+
20072
+ .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.TOP_LEFT} {
20073
+ top: 3%;
20074
+ left: 3%;
20075
+ right: 3%;
20076
+ align-items: flex-start;
20077
+ text-align: left;
20078
+ }
20079
+
20080
+ .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.TOP_RIGHT} {
20081
+ top: 3%;
20082
+ left: 3%;
20083
+ right: 3%;
20084
+ align-items: flex-end;
20085
+ text-align: right;
20086
+ }
20087
+
20088
+ .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.MIDDLE_LEFT} {
20089
+ top: 50%;
20090
+ left: 3%;
20091
+ right: 3%;
20092
+ transform: translateY(-50%);
20093
+ align-items: flex-start;
20094
+ text-align: left;
20095
+ }
20096
+
20097
+ .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.MIDDLE_RIGHT} {
20098
+ top: 50%;
20099
+ left: 3%;
20100
+ right: 3%;
20101
+ transform: translateY(-50%);
20102
+ align-items: flex-end;
20103
+ text-align: right;
20104
+ }
20105
+
20106
+ .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_LEFT} {
20107
+ bottom: 3%;
20108
+ left: 3%;
20109
+ right: 3%;
20110
+ align-items: flex-start;
20111
+ text-align: left;
20112
+ }
20113
+
20114
+ .${prefix}__text-block--${exports.ENUM_TEXT_BLOCK_POSITION.BOTTOM_RIGHT} {
20115
+ bottom: 3%;
20116
+ left: 3%;
20117
+ right: 3%;
20118
+ align-items: flex-end;
20119
+ text-align: right;
20120
+ }
19960
20121
  }
19961
20122
 
19962
- .${prefix}__video-container {
19963
- position: relative;
19964
- width: 100%;
19965
- height: 100%;
20123
+ .${prefix}__header {
20124
+ font-size: 24px;
20125
+ margin: 0;
20126
+ font-family: "Cormorant", system-ui;
20127
+ font-style: normal;
20128
+ font-weight: 300;
20129
+ line-height: normal;
19966
20130
  }
19967
20131
 
19968
- .${prefix}__video-element {
19969
- width: 100%;
19970
- height: 100%;
19971
- object-fit: cover;
19972
- display: block;
20132
+ .${prefix}__description {
20133
+ font-size: 10px;
20134
+ font-family: "Source Sans 3", system-ui;
20135
+ font-style: normal;
20136
+ font-weight: 400;
20137
+ line-height: 20px;
20138
+ margin: 0;
19973
20139
  }
19974
20140
 
19975
20141
  .${prefix}__controls {
@@ -19982,7 +20148,7 @@ class RbVideoPlayerSE extends BaseSpotComponent {
19982
20148
  align-items: center;
19983
20149
  opacity: 0;
19984
20150
  transition: opacity 0.3s;
19985
- z-index: 3;
20151
+ z-index: 100;
19986
20152
  width: fit-content;
19987
20153
  border-radius: 50%;
19988
20154
  }
@@ -19991,7 +20157,7 @@ class RbVideoPlayerSE extends BaseSpotComponent {
19991
20157
  opacity: 1;
19992
20158
  }
19993
20159
 
19994
- .${prefix}__mute-button {
20160
+ .${prefix}__mute-button {
19995
20161
  background: none;
19996
20162
  border: none;
19997
20163
  color: white;
@@ -20012,6 +20178,38 @@ class RbVideoPlayerSE extends BaseSpotComponent {
20012
20178
  .${prefix}__mute-button:hover {
20013
20179
  opacity: 0.8;
20014
20180
  }
20181
+
20182
+ @container (min-width: 640px) {
20183
+ .${prefix}__text {
20184
+ width: 70%;
20185
+ }
20186
+ }
20187
+
20188
+ @container (min-width: 768px) {
20189
+ .${prefix}__description {
20190
+ font-size: 12px;
20191
+ }
20192
+ }
20193
+
20194
+ @container (min-width: 1024px) {
20195
+ .${prefix}__header {
20196
+ font-size: 26px;
20197
+ }
20198
+
20199
+ .${prefix}__description {
20200
+ font-size: 13px;
20201
+ }
20202
+ }
20203
+
20204
+ @container (min-width: 1280px) {
20205
+ .${prefix}__header {
20206
+ font-size: 28px;
20207
+ }
20208
+
20209
+ .${prefix}__description {
20210
+ font-size: 14px;
20211
+ }
20212
+ }
20015
20213
  `;
20016
20214
  }
20017
20215
  }
@@ -20029,7 +20227,7 @@ class SpotTemplateService {
20029
20227
  const variantClasses = this.isRbSpot(spotType) ? this.rbTemplates : this.iabTemplates;
20030
20228
  if (!variantClasses)
20031
20229
  return null;
20032
- const spotClass = ((_a = variantClasses[spotType]) === null || _a === undefined ? undefined : _a[spotVariant]) || null;
20230
+ const spotClass = ((_a = variantClasses[spotType]) === null || _a === void 0 ? void 0 : _a[spotVariant]) || null;
20033
20231
  if (!spotClass)
20034
20232
  return null;
20035
20233
  return spotClass;
@@ -20363,7 +20561,7 @@ if (typeof window !== 'undefined' && typeof window.customElements !== 'undefined
20363
20561
  disconnectedCallback() {
20364
20562
  var _a;
20365
20563
  this.cleanupEventListeners();
20366
- (_a = this.resizeObserver) === null || _a === undefined ? undefined : _a.disconnect();
20564
+ (_a = this.resizeObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
20367
20565
  }
20368
20566
  setupResizeObserver() {
20369
20567
  if (this.data && !this.data.fluid) {
@@ -20384,14 +20582,14 @@ if (typeof window !== 'undefined' && typeof window.customElements !== 'undefined
20384
20582
  */
20385
20583
  initializeState() {
20386
20584
  var _a, _b, _c, _d, _e, _f, _g, _h;
20387
- this.state.useDots = Boolean((_a = this.data) === null || _a === undefined ? undefined : _a.useDots);
20388
- this.state.useButtons = Boolean((_b = this.data) === null || _b === undefined ? undefined : _b.useButtons);
20389
- this.state.autoplay = (_d = (_c = this.data) === null || _c === undefined ? undefined : _c.autoplay) !== null && _d !== undefined ? _d : true;
20390
- this.state.interval = (_f = (_e = this.data) === null || _e === undefined ? undefined : _e.interval) !== null && _f !== undefined ? _f : CustomCarouselElement.defaultConfigs.interval;
20391
- if (typeof ((_g = this.data) === null || _g === undefined ? undefined : _g.useDots) === 'object') {
20585
+ this.state.useDots = Boolean((_a = this.data) === null || _a === void 0 ? void 0 : _a.useDots);
20586
+ this.state.useButtons = Boolean((_b = this.data) === null || _b === void 0 ? void 0 : _b.useButtons);
20587
+ this.state.autoplay = (_d = (_c = this.data) === null || _c === void 0 ? void 0 : _c.autoplay) !== null && _d !== void 0 ? _d : true;
20588
+ this.state.interval = (_f = (_e = this.data) === null || _e === void 0 ? void 0 : _e.interval) !== null && _f !== void 0 ? _f : CustomCarouselElement.defaultConfigs.interval;
20589
+ if (typeof ((_g = this.data) === null || _g === void 0 ? void 0 : _g.useDots) === 'object') {
20392
20590
  this.state.dots = { ...this.state.dots, ...this.data.useDots };
20393
20591
  }
20394
- if (typeof ((_h = this.data) === null || _h === undefined ? undefined : _h.useButtons) === 'object') {
20592
+ if (typeof ((_h = this.data) === null || _h === void 0 ? void 0 : _h.useButtons) === 'object') {
20395
20593
  this.state.buttons = { ...this.state.buttons, ...this.data.useButtons };
20396
20594
  }
20397
20595
  this.validateConfiguration();
@@ -20855,7 +21053,7 @@ if (typeof window !== 'undefined' && typeof window.customElements !== 'undefined
20855
21053
  }
20856
21054
  this.state.isVirtualizing = false;
20857
21055
  // Force reflow to ensure the style change takes effect immediately
20858
- void ((_a = this.elements.slidesContainer) === null || _a === undefined ? undefined : _a.offsetHeight);
21056
+ void ((_a = this.elements.slidesContainer) === null || _a === void 0 ? void 0 : _a.offsetHeight);
20859
21057
  }
20860
21058
  /**
20861
21059
  * Updates dot active states
@@ -20964,8 +21162,8 @@ if (typeof window !== 'undefined' && typeof window.customElements !== 'undefined
20964
21162
  });
20965
21163
  }
20966
21164
  if (this.state.useButtons) {
20967
- (_a = this.elements.prevButton) === null || _a === undefined ? undefined : _a.addEventListener('click', () => this.handleNavigation('prev'));
20968
- (_b = this.elements.nextButton) === null || _b === undefined ? undefined : _b.addEventListener('click', () => this.handleNavigation('next'));
21165
+ (_a = this.elements.prevButton) === null || _a === void 0 ? void 0 : _a.addEventListener('click', () => this.handleNavigation('prev'));
21166
+ (_b = this.elements.nextButton) === null || _b === void 0 ? void 0 : _b.addEventListener('click', () => this.handleNavigation('next'));
20969
21167
  }
20970
21168
  }
20971
21169
  /**
@@ -21152,7 +21350,7 @@ class ElementService {
21152
21350
  const dimensions = SPOT_DIMENSIONS[params.spotType];
21153
21351
  skeleton.data = {
21154
21352
  spotType: params.spotType,
21155
- fluid: (params === null || params === undefined ? undefined : params.fluid) === undefined ? false : params.fluid,
21353
+ fluid: (params === null || params === void 0 ? void 0 : params.fluid) === undefined ? false : params.fluid,
21156
21354
  ...dimensions,
21157
21355
  };
21158
21356
  return skeleton;
@@ -21242,16 +21440,16 @@ class DataLayerMonitor {
21242
21440
  }
21243
21441
  extractProductData(event) {
21244
21442
  var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
21245
- const items = ((_a = event === null || event === undefined ? undefined : event.value) === null || _a === undefined ? undefined : _a.items) ||
21246
- ((_b = event === null || event === undefined ? undefined : event.ecommerce) === null || _b === undefined ? undefined : _b.items) ||
21247
- ((_c = event === null || event === undefined ? undefined : event.ecommerce) === null || _c === undefined ? undefined : _c.products) ||
21248
- ((_e = (_d = event === null || event === undefined ? undefined : event.ecommerce) === null || _d === undefined ? undefined : _d.detail) === null || _e === undefined ? undefined : _e.products) ||
21249
- ((_g = (_f = event === null || event === undefined ? undefined : event.ecommerce) === null || _f === undefined ? undefined : _f.checkout) === null || _g === undefined ? undefined : _g.products) ||
21250
- ((_j = (_h = event === null || event === undefined ? undefined : event.ecommerce) === null || _h === undefined ? undefined : _h.purchase) === null || _j === undefined ? undefined : _j.products) ||
21251
- ((_l = (_k = event === null || event === undefined ? undefined : event.ecommerce) === null || _k === undefined ? undefined : _k.add) === null || _l === undefined ? undefined : _l.products) ||
21252
- ((_o = (_m = event === null || event === undefined ? undefined : event.ecommerce) === null || _m === undefined ? undefined : _m.remove) === null || _o === undefined ? undefined : _o.products) ||
21253
- ((_q = (_p = event === null || event === undefined ? undefined : event.ecommerce) === null || _p === undefined ? undefined : _p.click) === null || _q === undefined ? undefined : _q.products) ||
21254
- (event === null || event === undefined ? undefined : event.products) ||
21443
+ const items = ((_a = event === null || event === void 0 ? void 0 : event.value) === null || _a === void 0 ? void 0 : _a.items) ||
21444
+ ((_b = event === null || event === void 0 ? void 0 : event.ecommerce) === null || _b === void 0 ? void 0 : _b.items) ||
21445
+ ((_c = event === null || event === void 0 ? void 0 : event.ecommerce) === null || _c === void 0 ? void 0 : _c.products) ||
21446
+ ((_e = (_d = event === null || event === void 0 ? void 0 : event.ecommerce) === null || _d === void 0 ? void 0 : _d.detail) === null || _e === void 0 ? void 0 : _e.products) ||
21447
+ ((_g = (_f = event === null || event === void 0 ? void 0 : event.ecommerce) === null || _f === void 0 ? void 0 : _f.checkout) === null || _g === void 0 ? void 0 : _g.products) ||
21448
+ ((_j = (_h = event === null || event === void 0 ? void 0 : event.ecommerce) === null || _h === void 0 ? void 0 : _h.purchase) === null || _j === void 0 ? void 0 : _j.products) ||
21449
+ ((_l = (_k = event === null || event === void 0 ? void 0 : event.ecommerce) === null || _k === void 0 ? void 0 : _k.add) === null || _l === void 0 ? void 0 : _l.products) ||
21450
+ ((_o = (_m = event === null || event === void 0 ? void 0 : event.ecommerce) === null || _m === void 0 ? void 0 : _m.remove) === null || _o === void 0 ? void 0 : _o.products) ||
21451
+ ((_q = (_p = event === null || event === void 0 ? void 0 : event.ecommerce) === null || _p === void 0 ? void 0 : _p.click) === null || _q === void 0 ? void 0 : _q.products) ||
21452
+ (event === null || event === void 0 ? void 0 : event.products) ||
21255
21453
  [];
21256
21454
  return items.map((item) => {
21257
21455
  const data = {
@@ -21307,7 +21505,7 @@ class MonitorService {
21307
21505
  return;
21308
21506
  this.implementedMonitor.setListener(async (eventData) => {
21309
21507
  var _a;
21310
- await this.matchAndFireEvent(eventData, (_a = this.localStorageService) === null || _a === undefined ? undefined : _a.getSpots());
21508
+ await this.matchAndFireEvent(eventData, (_a = this.localStorageService) === null || _a === void 0 ? void 0 : _a.getSpots());
21311
21509
  });
21312
21510
  this.implementedMonitor.start();
21313
21511
  }
@@ -21323,14 +21521,14 @@ class MonitorService {
21323
21521
  continue;
21324
21522
  }
21325
21523
  const firedEvents = spot.firedEvents || [];
21326
- const eventProductId = (_a = this.normalizeStringHelper) === null || _a === undefined ? undefined : _a.normalize(String(data.id));
21524
+ const eventProductId = (_a = this.normalizeStringHelper) === null || _a === void 0 ? void 0 : _a.normalize(String(data.id));
21327
21525
  const isEventAlreadyFired = firedEvents.some((event) => event.productId === eventProductId && event.event === eventData.event);
21328
21526
  if (isEventAlreadyFired) {
21329
21527
  continue;
21330
21528
  }
21331
- const spotRelatedProductIdsSet = new Set(spot.productIds.map((id) => { var _a; return (_a = this.normalizeStringHelper) === null || _a === undefined ? undefined : _a.normalize(String(id)); }));
21332
- const eventProductBrand = (_b = this.normalizeStringHelper) === null || _b === undefined ? undefined : _b.normalize(String(data.brand));
21333
- const eventVariantBrand = (_c = this.normalizeStringHelper) === null || _c === undefined ? undefined : _c.normalize(String(data.variant));
21529
+ const spotRelatedProductIdsSet = new Set(spot.productIds.map((id) => { var _a; return (_a = this.normalizeStringHelper) === null || _a === void 0 ? void 0 : _a.normalize(String(id)); }));
21530
+ const eventProductBrand = (_b = this.normalizeStringHelper) === null || _b === void 0 ? void 0 : _b.normalize(String(data.brand));
21531
+ const eventVariantBrand = (_c = this.normalizeStringHelper) === null || _c === void 0 ? void 0 : _c.normalize(String(data.variant));
21334
21532
  const isProductMatch = [eventProductId, eventProductBrand, eventVariantBrand].some((id) => spotRelatedProductIdsSet.has(id));
21335
21533
  if (!isProductMatch) {
21336
21534
  continue;
@@ -21361,7 +21559,7 @@ class MonitorService {
21361
21559
  event: eventData.event,
21362
21560
  });
21363
21561
  // Update the spots in the local storage
21364
- (_d = this.localStorageService) === null || _d === undefined ? undefined : _d.setSpot(spot.spotId, {
21562
+ (_d = this.localStorageService) === null || _d === void 0 ? void 0 : _d.setSpot(spot.spotId, {
21365
21563
  placementId: spot.placementId,
21366
21564
  spotId: spot.spotId,
21367
21565
  spotType: spot.spotType,
@@ -21425,9 +21623,9 @@ class SelectionService extends BaseApi {
21425
21623
  }
21426
21624
  const { isOk, val, isErr } = await this.post(SELECTION_API_PATH, data, {});
21427
21625
  if (isErr) {
21428
- return { error: `There was an error during spot selection: (${isErr === null || isErr === undefined ? undefined : isErr.errorMessage})` };
21626
+ return { error: `There was an error during spot selection: (${isErr === null || isErr === void 0 ? void 0 : isErr.errorMessage})` };
21429
21627
  }
21430
- if (isOk && val && val.data && (val === null || val === undefined ? undefined : val.refresh.token)) {
21628
+ if (isOk && val && val.data && (val === null || val === void 0 ? void 0 : val.refresh.token)) {
21431
21629
  this.authInfo.authenticated = true;
21432
21630
  this.authInfo.token = val.refresh.token;
21433
21631
  return val.data.spots;
@@ -21542,7 +21740,7 @@ class SpotManagerService {
21542
21740
  spotId: spot.id,
21543
21741
  spotType: spot.spot,
21544
21742
  events: spot.events,
21545
- productIds: (_a = spot.productIds) !== null && _a !== undefined ? _a : [],
21743
+ productIds: (_a = spot.productIds) !== null && _a !== void 0 ? _a : [],
21546
21744
  });
21547
21745
  }
21548
21746
  async handleClickEvent({ placementId, spot }) {
@@ -21555,7 +21753,7 @@ class SpotManagerService {
21555
21753
  await fireEvent({
21556
21754
  spotType: spot.spot,
21557
21755
  event: exports.RMN_SPOT_EVENT.CLICK,
21558
- eventUrl: (_b = (_a = spot.events.find((event) => event.event === exports.RMN_SPOT_EVENT.CLICK)) === null || _a === undefined ? undefined : _a.url) !== null && _b !== undefined ? _b : '',
21756
+ eventUrl: (_b = (_a = spot.events.find((event) => event.event === exports.RMN_SPOT_EVENT.CLICK)) === null || _a === void 0 ? void 0 : _a.url) !== null && _b !== void 0 ? _b : '',
21559
21757
  });
21560
21758
  }
21561
21759
  handleImpressionEvent(placementId, spot) {
@@ -21569,7 +21767,7 @@ class SpotManagerService {
21569
21767
  await fireEvent({
21570
21768
  spotType: spot.spot,
21571
21769
  event: exports.RMN_SPOT_EVENT.IMPRESSION,
21572
- eventUrl: (_b = (_a = spot.events.find((event) => event.event === exports.RMN_SPOT_EVENT.IMPRESSION)) === null || _a === undefined ? undefined : _a.url) !== null && _b !== undefined ? _b : '',
21770
+ eventUrl: (_b = (_a = spot.events.find((event) => event.event === exports.RMN_SPOT_EVENT.IMPRESSION)) === null || _a === void 0 ? void 0 : _a.url) !== null && _b !== void 0 ? _b : '',
21573
21771
  });
21574
21772
  })();
21575
21773
  }
@@ -21644,7 +21842,7 @@ function validateInjectData(inject) {
21644
21842
  */
21645
21843
  function clearPlacement(placementId) {
21646
21844
  var _a;
21647
- (_a = document.getElementById(placementId)) === null || _a === undefined ? undefined : _a.replaceChildren();
21845
+ (_a = document.getElementById(placementId)) === null || _a === void 0 ? void 0 : _a.replaceChildren();
21648
21846
  }
21649
21847
  /**
21650
21848
  * Prepares the spot placement for rendering by taking care of its styling.
@@ -21678,10 +21876,10 @@ function overrideSpotColors(spot, colors) {
21678
21876
  const { textColor, backgroundColor, ctaTextColor, ctaBorderColor } = colors;
21679
21877
  return {
21680
21878
  ...spot,
21681
- textColor: textColor !== null && textColor !== undefined ? textColor : spot.textColor,
21682
- backgroundColor: backgroundColor !== null && backgroundColor !== undefined ? backgroundColor : spot.backgroundColor,
21683
- ctaTextColor: ctaTextColor !== null && ctaTextColor !== undefined ? ctaTextColor : spot.ctaTextColor,
21684
- ctaBorderColor: ctaBorderColor !== null && ctaBorderColor !== undefined ? ctaBorderColor : spot.ctaBorderColor,
21879
+ textColor: textColor !== null && textColor !== void 0 ? textColor : spot.textColor,
21880
+ backgroundColor: backgroundColor !== null && backgroundColor !== void 0 ? backgroundColor : spot.backgroundColor,
21881
+ ctaTextColor: ctaTextColor !== null && ctaTextColor !== void 0 ? ctaTextColor : spot.ctaTextColor,
21882
+ ctaBorderColor: ctaBorderColor !== null && ctaBorderColor !== void 0 ? ctaBorderColor : spot.ctaBorderColor,
21685
21883
  };
21686
21884
  }
21687
21885
  // Sets the id for the user who is browsing the website
@@ -21801,7 +21999,7 @@ class BrowserRmnClient {
21801
21999
  }, false);
21802
22000
  prepareSpotPlacement(placement);
21803
22001
  const skeletonElement = this.elementService.createSkeletonElement({
21804
- fluid: (_b = (_a = injectData === null || injectData === undefined ? undefined : injectData.config) === null || _a === undefined ? undefined : _a.fluid) !== null && _b !== undefined ? _b : globalConfig === null || globalConfig === undefined ? undefined : globalConfig.fluid,
22002
+ fluid: (_b = (_a = injectData === null || injectData === void 0 ? void 0 : injectData.config) === null || _a === void 0 ? void 0 : _a.fluid) !== null && _b !== void 0 ? _b : globalConfig === null || globalConfig === void 0 ? void 0 : globalConfig.fluid,
21805
22003
  spotType: injectData.spotType,
21806
22004
  });
21807
22005
  if (!skeletonElement) {
@@ -21813,7 +22011,7 @@ class BrowserRmnClient {
21813
22011
  });
21814
22012
  }
21815
22013
  if (skeletonElement) {
21816
- placement === null || placement === undefined ? undefined : placement.replaceChildren(skeletonElement);
22014
+ placement === null || placement === void 0 ? void 0 : placement.replaceChildren(skeletonElement);
21817
22015
  }
21818
22016
  validPlacements.set(placementId, placement);
21819
22017
  this.spotManagerService.updateSpotLifecycleState(injectData.placementId, {
@@ -21856,9 +22054,9 @@ class BrowserRmnClient {
21856
22054
  validPlacements.forEach((placement, placementId) => {
21857
22055
  var _a;
21858
22056
  const injectData = injectMap.get(placementId);
21859
- const itemConfig = (_a = injectData === null || injectData === undefined ? undefined : injectData.config) !== null && _a !== undefined ? _a : globalConfig;
22057
+ const itemConfig = (_a = injectData === null || injectData === void 0 ? void 0 : injectData.config) !== null && _a !== void 0 ? _a : globalConfig;
21860
22058
  const spots = response[placementId];
21861
- if (!(spots === null || spots === undefined ? undefined : spots.length)) {
22059
+ if (!(spots === null || spots === void 0 ? void 0 : spots.length)) {
21862
22060
  this.spotManagerService.updateSpotLifecycleState(injectData.placementId, {
21863
22061
  state: {
21864
22062
  error: `No spots found for type "${injectData.spotType}".`,
@@ -21904,12 +22102,12 @@ class BrowserRmnClient {
21904
22102
  isCarouselItem: false,
21905
22103
  },
21906
22104
  });
21907
- const spotData = overrideSpotColors(spot, config === null || config === undefined ? undefined : config.colors);
22105
+ const spotData = overrideSpotColors(spot, config === null || config === void 0 ? void 0 : config.colors);
21908
22106
  const spotElement = this.elementService.createSpotElement({
21909
22107
  spot: spotData,
21910
22108
  config: {
21911
22109
  prefix: '',
21912
- fluid: spot.spot === exports.RMN_SPOT_TYPE.RB_IN_TEXT ? true : ((_a = config === null || config === undefined ? undefined : config.fluid) !== null && _a !== undefined ? _a : false),
22110
+ fluid: spot.spot === exports.RMN_SPOT_TYPE.RB_IN_TEXT ? true : ((_a = config === null || config === void 0 ? void 0 : config.fluid) !== null && _a !== void 0 ? _a : false),
21913
22111
  useShadowDom: true,
21914
22112
  },
21915
22113
  });
@@ -21929,8 +22127,8 @@ class BrowserRmnClient {
21929
22127
  placementId,
21930
22128
  spotElement,
21931
22129
  });
21932
- placement === null || placement === undefined ? undefined : placement.replaceChildren(spotElement);
21933
- if (config === null || config === undefined ? undefined : config.listenRenderedSpotData) {
22130
+ placement === null || placement === void 0 ? void 0 : placement.replaceChildren(spotElement);
22131
+ if (config === null || config === void 0 ? void 0 : config.listenRenderedSpotData) {
21934
22132
  this.spotManagerService.publish(exports.RMN_EVENT.RENDERED_SPOT_DATA, {
21935
22133
  placementId,
21936
22134
  data: [spotData],
@@ -21974,7 +22172,7 @@ class BrowserRmnClient {
21974
22172
  isCarouselItem: true,
21975
22173
  },
21976
22174
  });
21977
- const spot = overrideSpotColors(spotItem, config === null || config === undefined ? undefined : config.colors);
22175
+ const spot = overrideSpotColors(spotItem, config === null || config === void 0 ? void 0 : config.colors);
21978
22176
  const spotElement = this.elementService.createSpotElement({
21979
22177
  spot,
21980
22178
  config: {
@@ -22010,11 +22208,11 @@ class BrowserRmnClient {
22010
22208
  const carouselElement = this.elementService.createCarouselElement({
22011
22209
  slides: carouselSlides,
22012
22210
  config: {
22013
- fluid: config === null || config === undefined ? undefined : config.fluid,
22211
+ fluid: config === null || config === void 0 ? void 0 : config.fluid,
22014
22212
  width: maxWidth,
22015
22213
  height: maxHeight,
22016
- minScale: (_a = config === null || config === undefined ? undefined : config.minScale) !== null && _a !== undefined ? _a : 0.25, // Scale down to 25% of the original size
22017
- ...config === null || config === undefined ? undefined : config.carousel,
22214
+ minScale: (_a = config === null || config === void 0 ? void 0 : config.minScale) !== null && _a !== void 0 ? _a : 0.25, // Scale down to 25% of the original size
22215
+ ...config === null || config === void 0 ? void 0 : config.carousel,
22018
22216
  },
22019
22217
  });
22020
22218
  if (!carouselElement) {
@@ -22028,8 +22226,8 @@ class BrowserRmnClient {
22028
22226
  clearPlacement(placementId);
22029
22227
  return;
22030
22228
  }
22031
- placement === null || placement === undefined ? undefined : placement.replaceChildren(carouselElement);
22032
- if (config === null || config === undefined ? undefined : config.listenRenderedSpotData) {
22229
+ placement === null || placement === void 0 ? void 0 : placement.replaceChildren(carouselElement);
22230
+ if (config === null || config === void 0 ? void 0 : config.listenRenderedSpotData) {
22033
22231
  this.spotManagerService.publish(exports.RMN_EVENT.RENDERED_SPOT_DATA, {
22034
22232
  placementId,
22035
22233
  data: spots,
@@ -22059,11 +22257,11 @@ class BrowserRmnClient {
22059
22257
  const spots = inject.map((item) => ({
22060
22258
  placementId: item.placementId,
22061
22259
  spot: item.spotType,
22062
- count: item === null || item === undefined ? undefined : item.count,
22063
- ...item === null || item === undefined ? undefined : item.filter,
22260
+ count: item === null || item === void 0 ? void 0 : item.count,
22261
+ ...item === null || item === void 0 ? void 0 : item.filter,
22064
22262
  }));
22065
22263
  const request = {
22066
- url: config === null || config === undefined ? undefined : config.url,
22264
+ url: config === null || config === void 0 ? void 0 : config.url,
22067
22265
  filter,
22068
22266
  spots,
22069
22267
  };