@entur-partner/app-shell 6.1.6-alpha.0 → 6.1.6-alpha.2

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.
@@ -9,6 +9,31 @@ import React, { useState, useEffect, useContext, createContext, useCallback } fr
9
9
  import postHog from 'posthog-js';
10
10
  import { PostHogProvider } from 'posthog-js/react';
11
11
 
12
+ function asyncGeneratorStep(n, t, e, r, o, a, c) {
13
+ try {
14
+ var i = n[a](c),
15
+ u = i.value;
16
+ } catch (n) {
17
+ return void e(n);
18
+ }
19
+ i.done ? t(u) : Promise.resolve(u).then(r, o);
20
+ }
21
+ function _asyncToGenerator(n) {
22
+ return function () {
23
+ var t = this,
24
+ e = arguments;
25
+ return new Promise(function (r, o) {
26
+ var a = n.apply(t, e);
27
+ function _next(n) {
28
+ asyncGeneratorStep(a, r, o, _next, _throw, "next", n);
29
+ }
30
+ function _throw(n) {
31
+ asyncGeneratorStep(a, r, o, _next, _throw, "throw", n);
32
+ }
33
+ _next(void 0);
34
+ });
35
+ };
36
+ }
12
37
  function _construct(t, e, r) {
13
38
  if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments);
14
39
  var o = [null];
@@ -16,6 +41,30 @@ function _construct(t, e, r) {
16
41
  var p = new (t.bind.apply(t, o))();
17
42
  return r && _setPrototypeOf(p, r.prototype), p;
18
43
  }
44
+ function _extends() {
45
+ return _extends = Object.assign ? Object.assign.bind() : function (n) {
46
+ for (var e = 1; e < arguments.length; e++) {
47
+ var t = arguments[e];
48
+ for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]);
49
+ }
50
+ return n;
51
+ }, _extends.apply(null, arguments);
52
+ }
53
+ function _getPrototypeOf(t) {
54
+ return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) {
55
+ return t.__proto__ || Object.getPrototypeOf(t);
56
+ }, _getPrototypeOf(t);
57
+ }
58
+ function _inheritsLoose(t, o) {
59
+ t.prototype = Object.create(o.prototype), t.prototype.constructor = t, _setPrototypeOf(t, o);
60
+ }
61
+ function _isNativeFunction(t) {
62
+ try {
63
+ return -1 !== Function.toString.call(t).indexOf("[native code]");
64
+ } catch (n) {
65
+ return "function" == typeof t;
66
+ }
67
+ }
19
68
  function _isNativeReflectConstruct() {
20
69
  try {
21
70
  var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
@@ -24,413 +73,149 @@ function _isNativeReflectConstruct() {
24
73
  return !!t;
25
74
  })();
26
75
  }
27
- function _regeneratorRuntime() {
28
- _regeneratorRuntime = function () {
29
- return e;
30
- };
31
- var t,
32
- e = {},
33
- r = Object.prototype,
34
- n = r.hasOwnProperty,
35
- o = Object.defineProperty || function (t, e, r) {
36
- t[e] = r.value;
37
- },
38
- i = "function" == typeof Symbol ? Symbol : {},
39
- a = i.iterator || "@@iterator",
40
- c = i.asyncIterator || "@@asyncIterator",
41
- u = i.toStringTag || "@@toStringTag";
42
- function define(t, e, r) {
43
- return Object.defineProperty(t, e, {
44
- value: r,
45
- enumerable: !0,
46
- configurable: !0,
47
- writable: !0
48
- }), t[e];
49
- }
50
- try {
51
- define({}, "");
52
- } catch (t) {
53
- define = function (t, e, r) {
54
- return t[e] = r;
55
- };
56
- }
57
- function wrap(t, e, r, n) {
58
- var i = e && e.prototype instanceof Generator ? e : Generator,
59
- a = Object.create(i.prototype),
60
- c = new Context(n || []);
61
- return o(a, "_invoke", {
62
- value: makeInvokeMethod(t, r, c)
63
- }), a;
64
- }
65
- function tryCatch(t, e, r) {
66
- try {
67
- return {
68
- type: "normal",
69
- arg: t.call(e, r)
70
- };
71
- } catch (t) {
72
- return {
73
- type: "throw",
74
- arg: t
75
- };
76
- }
76
+ function _objectWithoutPropertiesLoose(r, e) {
77
+ if (null == r) return {};
78
+ var t = {};
79
+ for (var n in r) if ({}.hasOwnProperty.call(r, n)) {
80
+ if (-1 !== e.indexOf(n)) continue;
81
+ t[n] = r[n];
77
82
  }
78
- e.wrap = wrap;
79
- var h = "suspendedStart",
80
- l = "suspendedYield",
81
- f = "executing",
82
- s = "completed",
83
- y = {};
84
- function Generator() {}
85
- function GeneratorFunction() {}
86
- function GeneratorFunctionPrototype() {}
87
- var p = {};
88
- define(p, a, function () {
89
- return this;
90
- });
91
- var d = Object.getPrototypeOf,
92
- v = d && d(d(values([])));
93
- v && v !== r && n.call(v, a) && (p = v);
94
- var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p);
95
- function defineIteratorMethods(t) {
96
- ["next", "throw", "return"].forEach(function (e) {
97
- define(t, e, function (t) {
98
- return this._invoke(e, t);
99
- });
100
- });
101
- }
102
- function AsyncIterator(t, e) {
103
- function invoke(r, o, i, a) {
104
- var c = tryCatch(t[r], t, o);
105
- if ("throw" !== c.type) {
106
- var u = c.arg,
107
- h = u.value;
108
- return h && "object" == typeof h && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) {
109
- invoke("next", t, i, a);
110
- }, function (t) {
111
- invoke("throw", t, i, a);
112
- }) : e.resolve(h).then(function (t) {
113
- u.value = t, i(u);
114
- }, function (t) {
115
- return invoke("throw", t, i, a);
116
- });
117
- }
118
- a(c.arg);
119
- }
120
- var r;
121
- o(this, "_invoke", {
122
- value: function (t, n) {
123
- function callInvokeWithMethodAndArg() {
124
- return new e(function (e, r) {
125
- invoke(t, n, e, r);
126
- });
83
+ return t;
84
+ }
85
+ function _regenerator() {
86
+ /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */
87
+ var e,
88
+ t,
89
+ r = "function" == typeof Symbol ? Symbol : {},
90
+ n = r.iterator || "@@iterator",
91
+ o = r.toStringTag || "@@toStringTag";
92
+ function i(r, n, o, i) {
93
+ var c = n && n.prototype instanceof Generator ? n : Generator,
94
+ u = Object.create(c.prototype);
95
+ return _regeneratorDefine(u, "_invoke", function (r, n, o) {
96
+ var i,
97
+ c,
98
+ u,
99
+ f = 0,
100
+ p = o || [],
101
+ y = !1,
102
+ G = {
103
+ p: 0,
104
+ n: 0,
105
+ v: e,
106
+ a: d,
107
+ f: d.bind(e, 4),
108
+ d: function (t, r) {
109
+ return i = t, c = 0, u = e, G.n = r, a;
110
+ }
111
+ };
112
+ function d(r, n) {
113
+ for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) {
114
+ var o,
115
+ i = p[t],
116
+ d = G.p,
117
+ l = i[2];
118
+ r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0));
127
119
  }
128
- return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
120
+ if (o || r > 1) return a;
121
+ throw y = !0, n;
129
122
  }
130
- });
131
- }
132
- function makeInvokeMethod(e, r, n) {
133
- var o = h;
134
- return function (i, a) {
135
- if (o === f) throw Error("Generator is already running");
136
- if (o === s) {
137
- if ("throw" === i) throw a;
123
+ return function (o, p, l) {
124
+ if (f > 1) throw TypeError("Generator is already running");
125
+ for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) {
126
+ i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u);
127
+ try {
128
+ if (f = 2, i) {
129
+ if (c || (o = "next"), t = i[o]) {
130
+ if (!(t = t.call(i, u))) throw TypeError("iterator result is not an object");
131
+ if (!t.done) return t;
132
+ u = t.value, c < 2 && (c = 0);
133
+ } else 1 === c && (t = i.return) && t.call(i), c < 2 && (u = TypeError("The iterator does not provide a '" + o + "' method"), c = 1);
134
+ i = e;
135
+ } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break;
136
+ } catch (t) {
137
+ i = e, c = 1, u = t;
138
+ } finally {
139
+ f = 1;
140
+ }
141
+ }
138
142
  return {
139
143
  value: t,
140
- done: !0
144
+ done: y
141
145
  };
142
- }
143
- for (n.method = i, n.arg = a;;) {
144
- var c = n.delegate;
145
- if (c) {
146
- var u = maybeInvokeDelegate(c, n);
147
- if (u) {
148
- if (u === y) continue;
149
- return u;
150
- }
151
- }
152
- if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) {
153
- if (o === h) throw o = s, n.arg;
154
- n.dispatchException(n.arg);
155
- } else "return" === n.method && n.abrupt("return", n.arg);
156
- o = f;
157
- var p = tryCatch(e, r, n);
158
- if ("normal" === p.type) {
159
- if (o = n.done ? s : l, p.arg === y) continue;
160
- return {
161
- value: p.arg,
162
- done: n.done
163
- };
164
- }
165
- "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg);
166
- }
167
- };
168
- }
169
- function maybeInvokeDelegate(e, r) {
170
- var n = r.method,
171
- o = e.iterator[n];
172
- if (o === t) return r.delegate = null, "throw" === n && e.iterator.return && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y;
173
- var i = tryCatch(o, e.iterator, r.arg);
174
- if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y;
175
- var a = i.arg;
176
- return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y);
177
- }
178
- function pushTryEntry(t) {
179
- var e = {
180
- tryLoc: t[0]
181
- };
182
- 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e);
183
- }
184
- function resetTryEntry(t) {
185
- var e = t.completion || {};
186
- e.type = "normal", delete e.arg, t.completion = e;
187
- }
188
- function Context(t) {
189
- this.tryEntries = [{
190
- tryLoc: "root"
191
- }], t.forEach(pushTryEntry, this), this.reset(!0);
146
+ };
147
+ }(r, o, i), !0), u;
192
148
  }
193
- function values(e) {
194
- if (e || "" === e) {
195
- var r = e[a];
196
- if (r) return r.call(e);
197
- if ("function" == typeof e.next) return e;
198
- if (!isNaN(e.length)) {
199
- var o = -1,
200
- i = function next() {
201
- for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next;
202
- return next.value = t, next.done = !0, next;
203
- };
204
- return i.next = i;
205
- }
206
- }
207
- throw new TypeError(typeof e + " is not iterable");
149
+ var a = {};
150
+ function Generator() {}
151
+ function GeneratorFunction() {}
152
+ function GeneratorFunctionPrototype() {}
153
+ t = Object.getPrototypeOf;
154
+ var c = [][n] ? t(t([][n]())) : (_regeneratorDefine(t = {}, n, function () {
155
+ return this;
156
+ }), t),
157
+ u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c);
158
+ function f(e) {
159
+ return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine(e, o, "GeneratorFunction")), e.prototype = Object.create(u), e;
208
160
  }
209
- return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", {
210
- value: GeneratorFunctionPrototype,
211
- configurable: !0
212
- }), o(GeneratorFunctionPrototype, "constructor", {
213
- value: GeneratorFunction,
214
- configurable: !0
215
- }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) {
216
- var e = "function" == typeof t && t.constructor;
217
- return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name));
218
- }, e.mark = function (t) {
219
- return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t;
220
- }, e.awrap = function (t) {
221
- return {
222
- __await: t
223
- };
224
- }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () {
161
+ return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine(u, "constructor", GeneratorFunctionPrototype), _regeneratorDefine(GeneratorFunctionPrototype, "constructor", GeneratorFunction), GeneratorFunction.displayName = "GeneratorFunction", _regeneratorDefine(GeneratorFunctionPrototype, o, "GeneratorFunction"), _regeneratorDefine(u), _regeneratorDefine(u, o, "Generator"), _regeneratorDefine(u, n, function () {
225
162
  return this;
226
- }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) {
227
- void 0 === i && (i = Promise);
228
- var a = new AsyncIterator(wrap(t, r, n, o), i);
229
- return e.isGeneratorFunction(r) ? a : a.next().then(function (t) {
230
- return t.done ? t.value : a.next();
231
- });
232
- }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () {
233
- return this;
234
- }), define(g, "toString", function () {
163
+ }), _regeneratorDefine(u, "toString", function () {
235
164
  return "[object Generator]";
236
- }), e.keys = function (t) {
237
- var e = Object(t),
238
- r = [];
239
- for (var n in e) r.push(n);
240
- return r.reverse(), function next() {
241
- for (; r.length;) {
242
- var t = r.pop();
243
- if (t in e) return next.value = t, next.done = !1, next;
244
- }
245
- return next.done = !0, next;
165
+ }), (_regenerator = function () {
166
+ return {
167
+ w: i,
168
+ m: f
246
169
  };
247
- }, e.values = values, Context.prototype = {
248
- constructor: Context,
249
- reset: function (e) {
250
- if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t);
251
- },
252
- stop: function () {
253
- this.done = !0;
254
- var t = this.tryEntries[0].completion;
255
- if ("throw" === t.type) throw t.arg;
256
- return this.rval;
257
- },
258
- dispatchException: function (e) {
259
- if (this.done) throw e;
260
- var r = this;
261
- function handle(n, o) {
262
- return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o;
263
- }
264
- for (var o = this.tryEntries.length - 1; o >= 0; --o) {
265
- var i = this.tryEntries[o],
266
- a = i.completion;
267
- if ("root" === i.tryLoc) return handle("end");
268
- if (i.tryLoc <= this.prev) {
269
- var c = n.call(i, "catchLoc"),
270
- u = n.call(i, "finallyLoc");
271
- if (c && u) {
272
- if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
273
- if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
274
- } else if (c) {
275
- if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
276
- } else {
277
- if (!u) throw Error("try statement without catch or finally");
278
- if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
279
- }
280
- }
281
- }
282
- },
283
- abrupt: function (t, e) {
284
- for (var r = this.tryEntries.length - 1; r >= 0; --r) {
285
- var o = this.tryEntries[r];
286
- if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) {
287
- var i = o;
288
- break;
289
- }
290
- }
291
- i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null);
292
- var a = i ? i.completion : {};
293
- return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a);
294
- },
295
- complete: function (t, e) {
296
- if ("throw" === t.type) throw t.arg;
297
- return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y;
298
- },
299
- finish: function (t) {
300
- for (var e = this.tryEntries.length - 1; e >= 0; --e) {
301
- var r = this.tryEntries[e];
302
- if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y;
303
- }
304
- },
305
- catch: function (t) {
306
- for (var e = this.tryEntries.length - 1; e >= 0; --e) {
307
- var r = this.tryEntries[e];
308
- if (r.tryLoc === t) {
309
- var n = r.completion;
310
- if ("throw" === n.type) {
311
- var o = n.arg;
312
- resetTryEntry(r);
313
- }
314
- return o;
315
- }
316
- }
317
- throw Error("illegal catch attempt");
318
- },
319
- delegateYield: function (e, r, n) {
320
- return this.delegate = {
321
- iterator: values(e),
322
- resultName: r,
323
- nextLoc: n
324
- }, "next" === this.method && (this.arg = t), y;
325
- }
326
- }, e;
170
+ })();
327
171
  }
328
- function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
172
+ function _regeneratorDefine(e, r, n, t) {
173
+ var i = Object.defineProperty;
329
174
  try {
330
- var info = gen[key](arg);
331
- var value = info.value;
332
- } catch (error) {
333
- reject(error);
334
- return;
335
- }
336
- if (info.done) {
337
- resolve(value);
338
- } else {
339
- Promise.resolve(value).then(_next, _throw);
175
+ i({}, "", {});
176
+ } catch (e) {
177
+ i = 0;
340
178
  }
341
- }
342
- function _asyncToGenerator(fn) {
343
- return function () {
344
- var self = this,
345
- args = arguments;
346
- return new Promise(function (resolve, reject) {
347
- var gen = fn.apply(self, args);
348
- function _next(value) {
349
- asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value);
350
- }
351
- function _throw(err) {
352
- asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err);
353
- }
354
- _next(undefined);
355
- });
356
- };
357
- }
358
- function _extends() {
359
- _extends = Object.assign ? Object.assign.bind() : function (target) {
360
- for (var i = 1; i < arguments.length; i++) {
361
- var source = arguments[i];
362
- for (var key in source) {
363
- if (Object.prototype.hasOwnProperty.call(source, key)) {
364
- target[key] = source[key];
365
- }
366
- }
179
+ _regeneratorDefine = function (e, r, n, t) {
180
+ function o(r, n) {
181
+ _regeneratorDefine(e, r, function (e) {
182
+ return this._invoke(r, n, e);
183
+ });
367
184
  }
368
- return target;
369
- };
370
- return _extends.apply(this, arguments);
371
- }
372
- function _inheritsLoose(subClass, superClass) {
373
- subClass.prototype = Object.create(superClass.prototype);
374
- subClass.prototype.constructor = subClass;
375
- _setPrototypeOf(subClass, superClass);
376
- }
377
- function _getPrototypeOf(o) {
378
- _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) {
379
- return o.__proto__ || Object.getPrototypeOf(o);
380
- };
381
- return _getPrototypeOf(o);
382
- }
383
- function _setPrototypeOf(o, p) {
384
- _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {
385
- o.__proto__ = p;
386
- return o;
387
- };
388
- return _setPrototypeOf(o, p);
185
+ r ? i ? i(e, r, {
186
+ value: n,
187
+ enumerable: !t,
188
+ configurable: !t,
189
+ writable: !t
190
+ }) : e[r] = n : (o("next", 0), o("throw", 1), o("return", 2));
191
+ }, _regeneratorDefine(e, r, n, t);
389
192
  }
390
- function _isNativeFunction(fn) {
391
- try {
392
- return Function.toString.call(fn).indexOf("[native code]") !== -1;
393
- } catch (e) {
394
- return typeof fn === "function";
395
- }
193
+ function _setPrototypeOf(t, e) {
194
+ return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) {
195
+ return t.__proto__ = e, t;
196
+ }, _setPrototypeOf(t, e);
396
197
  }
397
- function _wrapNativeSuper(Class) {
398
- var _cache = typeof Map === "function" ? new Map() : undefined;
399
- _wrapNativeSuper = function _wrapNativeSuper(Class) {
400
- if (Class === null || !_isNativeFunction(Class)) return Class;
401
- if (typeof Class !== "function") {
402
- throw new TypeError("Super expression must either be null or a function");
403
- }
404
- if (typeof _cache !== "undefined") {
405
- if (_cache.has(Class)) return _cache.get(Class);
406
- _cache.set(Class, Wrapper);
198
+ function _wrapNativeSuper(t) {
199
+ var r = "function" == typeof Map ? new Map() : void 0;
200
+ return _wrapNativeSuper = function (t) {
201
+ if (null === t || !_isNativeFunction(t)) return t;
202
+ if ("function" != typeof t) throw new TypeError("Super expression must either be null or a function");
203
+ if (void 0 !== r) {
204
+ if (r.has(t)) return r.get(t);
205
+ r.set(t, Wrapper);
407
206
  }
408
207
  function Wrapper() {
409
- return _construct(Class, arguments, _getPrototypeOf(this).constructor);
208
+ return _construct(t, arguments, _getPrototypeOf(this).constructor);
410
209
  }
411
- Wrapper.prototype = Object.create(Class.prototype, {
210
+ return Wrapper.prototype = Object.create(t.prototype, {
412
211
  constructor: {
413
212
  value: Wrapper,
414
- enumerable: false,
415
- writable: true,
416
- configurable: true
213
+ enumerable: !1,
214
+ writable: !0,
215
+ configurable: !0
417
216
  }
418
- });
419
- return _setPrototypeOf(Wrapper, Class);
420
- };
421
- return _wrapNativeSuper(Class);
422
- }
423
- function _objectWithoutPropertiesLoose(source, excluded) {
424
- if (source == null) return {};
425
- var target = {};
426
- var sourceKeys = Object.keys(source);
427
- var key, i;
428
- for (i = 0; i < sourceKeys.length; i++) {
429
- key = sourceKeys[i];
430
- if (excluded.indexOf(key) >= 0) continue;
431
- target[key] = source[key];
432
- }
433
- return target;
217
+ }), _setPrototypeOf(Wrapper, t);
218
+ }, _wrapNativeSuper(t);
434
219
  }
435
220
 
436
221
  var EnvironmentBanner = function EnvironmentBanner(_ref) {
@@ -477,32 +262,31 @@ var Authenticate = function Authenticate(_ref) {
477
262
  error = _useAuth.error;
478
263
  useEffect(function () {
479
264
  var fetchUserData = /*#__PURE__*/function () {
480
- var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
481
- var token, decoratedUser;
482
- return _regeneratorRuntime().wrap(function _callee$(_context) {
483
- while (1) switch (_context.prev = _context.next) {
265
+ var _ref2 = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {
266
+ var token, decoratedUser, _t;
267
+ return _regenerator().w(function (_context) {
268
+ while (1) switch (_context.p = _context.n) {
484
269
  case 0:
485
- _context.prev = 0;
486
- _context.next = 3;
270
+ _context.p = 0;
271
+ _context.n = 1;
487
272
  return getAccessTokenSilently();
488
- case 3:
489
- token = _context.sent;
490
- _context.next = 6;
273
+ case 1:
274
+ token = _context.v;
275
+ _context.n = 2;
491
276
  return decorateUser(user, token);
492
- case 6:
493
- decoratedUser = _context.sent;
277
+ case 2:
278
+ decoratedUser = _context.v;
494
279
  setUserWithPermission(decoratedUser);
495
- _context.next = 13;
280
+ _context.n = 4;
496
281
  break;
497
- case 10:
498
- _context.prev = 10;
499
- _context.t0 = _context["catch"](0);
500
- console.error("Error fetching user data:", _context.t0);
501
- case 13:
502
- case "end":
503
- return _context.stop();
282
+ case 3:
283
+ _context.p = 3;
284
+ _t = _context.v;
285
+ console.error("Error fetching user data:", _t);
286
+ case 4:
287
+ return _context.a(2);
504
288
  }
505
- }, _callee, null, [[0, 10]]);
289
+ }, _callee, null, [[0, 3]]);
506
290
  }));
507
291
  return function fetchUserData() {
508
292
  return _ref2.apply(this, arguments);
@@ -668,24 +452,23 @@ var ConsentManagerProvider = function ConsentManagerProvider(_ref) {
668
452
  // Listen for Usercentrics consent events and update consent manager state
669
453
  useEffect(function () {
670
454
  var handleConsentEvent = /*#__PURE__*/function () {
671
- var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(event) {
455
+ var _ref2 = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee(event) {
672
456
  var customEvent, services, updatedConsentManager;
673
- return _regeneratorRuntime().wrap(function _callee$(_context) {
674
- while (1) switch (_context.prev = _context.next) {
457
+ return _regenerator().w(function (_context) {
458
+ while (1) switch (_context.n) {
675
459
  case 0:
676
460
  if (!(typeof window === "undefined")) {
677
- _context.next = 2;
461
+ _context.n = 1;
678
462
  break;
679
463
  }
680
- return _context.abrupt("return");
681
- case 2:
464
+ return _context.a(2);
465
+ case 1:
682
466
  customEvent = event;
683
467
  services = Object.values(customEvent.detail.services);
684
468
  updatedConsentManager = convertUCServicesToConsents(services);
685
469
  setConsentManager(updatedConsentManager);
686
- case 6:
687
- case "end":
688
- return _context.stop();
470
+ case 2:
471
+ return _context.a(2);
689
472
  }
690
473
  }, _callee);
691
474
  }));
@@ -874,7 +657,7 @@ var OrganisationsError = /*#__PURE__*/function (_Error) {
874
657
  }
875
658
  _inheritsLoose(OrganisationsError, _Error);
876
659
  return OrganisationsError;
877
- }( /*#__PURE__*/_wrapNativeSuper(Error));
660
+ }(/*#__PURE__*/_wrapNativeSuper(Error));
878
661
 
879
662
  var _excluded = ["getToken", "getOrganisations", "selectedOrganisationId", "onChange"];
880
663
  var OrganisationSelector = function OrganisationSelector(_ref) {
@@ -893,20 +676,20 @@ var OrganisationSelector = function OrganisationSelector(_ref) {
893
676
  setStatus = _useState2[1];
894
677
  useEffect(function () {
895
678
  var fetchOrganisations = /*#__PURE__*/function () {
896
- var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
679
+ var _ref2 = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {
897
680
  var token, organisations;
898
- return _regeneratorRuntime().wrap(function _callee$(_context) {
899
- while (1) switch (_context.prev = _context.next) {
681
+ return _regenerator().w(function (_context) {
682
+ while (1) switch (_context.n) {
900
683
  case 0:
901
- _context.next = 2;
684
+ _context.n = 1;
902
685
  return getToken();
903
- case 2:
904
- token = _context.sent;
686
+ case 1:
687
+ token = _context.v;
905
688
  if (!(typeof getOrganisations === "string")) {
906
- _context.next = 9;
689
+ _context.n = 3;
907
690
  break;
908
691
  }
909
- _context.next = 6;
692
+ _context.n = 2;
910
693
  return fetch(getOrganisations, {
911
694
  headers: {
912
695
  Authorization: "Bearer " + token,
@@ -915,21 +698,20 @@ var OrganisationSelector = function OrganisationSelector(_ref) {
915
698
  }).then(function (response) {
916
699
  return response.json();
917
700
  });
918
- case 6:
919
- organisations = _context.sent;
920
- _context.next = 12;
701
+ case 2:
702
+ organisations = _context.v;
703
+ _context.n = 5;
921
704
  break;
922
- case 9:
923
- _context.next = 11;
705
+ case 3:
706
+ _context.n = 4;
924
707
  return getOrganisations(token);
925
- case 11:
926
- organisations = _context.sent;
927
- case 12:
708
+ case 4:
709
+ organisations = _context.v;
710
+ case 5:
928
711
  setOrganisations(organisations);
929
712
  setStatus("SUCCESS");
930
- case 14:
931
- case "end":
932
- return _context.stop();
713
+ case 6:
714
+ return _context.a(2);
933
715
  }
934
716
  }, _callee);
935
717
  }));