@plasmicpkgs/commerce 0.0.209 → 0.0.210

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.
@@ -13,6 +13,101 @@ var host = require('@plasmicapp/host');
13
13
  var Cookies = _interopDefault(require('js-cookie'));
14
14
  var debounce = _interopDefault(require('debounce'));
15
15
 
16
+ function _arrayLikeToArray(r, a) {
17
+ (null == a || a > r.length) && (a = r.length);
18
+ for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
19
+ return n;
20
+ }
21
+ function asyncGeneratorStep(n, t, e, r, o, a, c) {
22
+ try {
23
+ var i = n[a](c),
24
+ u = i.value;
25
+ } catch (n) {
26
+ return void e(n);
27
+ }
28
+ i.done ? t(u) : Promise.resolve(u).then(r, o);
29
+ }
30
+ function _asyncToGenerator(n) {
31
+ return function () {
32
+ var t = this,
33
+ e = arguments;
34
+ return new Promise(function (r, o) {
35
+ var a = n.apply(t, e);
36
+ function _next(n) {
37
+ asyncGeneratorStep(a, r, o, _next, _throw, "next", n);
38
+ }
39
+ function _throw(n) {
40
+ asyncGeneratorStep(a, r, o, _next, _throw, "throw", n);
41
+ }
42
+ _next(void 0);
43
+ });
44
+ };
45
+ }
46
+ function _construct(t, e, r) {
47
+ if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments);
48
+ var o = [null];
49
+ o.push.apply(o, e);
50
+ var p = new (t.bind.apply(t, o))();
51
+ return r && _setPrototypeOf(p, r.prototype), p;
52
+ }
53
+ function _createForOfIteratorHelperLoose(r, e) {
54
+ var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
55
+ if (t) return (t = t.call(r)).next.bind(t);
56
+ if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) {
57
+ t && (r = t);
58
+ var o = 0;
59
+ return function () {
60
+ return o >= r.length ? {
61
+ done: !0
62
+ } : {
63
+ done: !1,
64
+ value: r[o++]
65
+ };
66
+ };
67
+ }
68
+ throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
69
+ }
70
+ function _extends() {
71
+ return _extends = Object.assign ? Object.assign.bind() : function (n) {
72
+ for (var e = 1; e < arguments.length; e++) {
73
+ var t = arguments[e];
74
+ for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]);
75
+ }
76
+ return n;
77
+ }, _extends.apply(null, arguments);
78
+ }
79
+ function _getPrototypeOf(t) {
80
+ return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) {
81
+ return t.__proto__ || Object.getPrototypeOf(t);
82
+ }, _getPrototypeOf(t);
83
+ }
84
+ function _inheritsLoose(t, o) {
85
+ t.prototype = Object.create(o.prototype), t.prototype.constructor = t, _setPrototypeOf(t, o);
86
+ }
87
+ function _isNativeFunction(t) {
88
+ try {
89
+ return -1 !== Function.toString.call(t).indexOf("[native code]");
90
+ } catch (n) {
91
+ return "function" == typeof t;
92
+ }
93
+ }
94
+ function _isNativeReflectConstruct() {
95
+ try {
96
+ var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
97
+ } catch (t) {}
98
+ return (_isNativeReflectConstruct = function () {
99
+ return !!t;
100
+ })();
101
+ }
102
+ function _objectWithoutPropertiesLoose(r, e) {
103
+ if (null == r) return {};
104
+ var t = {};
105
+ for (var n in r) if ({}.hasOwnProperty.call(r, n)) {
106
+ if (-1 !== e.indexOf(n)) continue;
107
+ t[n] = r[n];
108
+ }
109
+ return t;
110
+ }
16
111
  function _regeneratorRuntime() {
17
112
  _regeneratorRuntime = function () {
18
113
  return e;
@@ -121,7 +216,7 @@ function _regeneratorRuntime() {
121
216
  function makeInvokeMethod(e, r, n) {
122
217
  var o = h;
123
218
  return function (i, a) {
124
- if (o === f) throw new Error("Generator is already running");
219
+ if (o === f) throw Error("Generator is already running");
125
220
  if (o === s) {
126
221
  if ("throw" === i) throw a;
127
222
  return {
@@ -263,7 +358,7 @@ function _regeneratorRuntime() {
263
358
  } else if (c) {
264
359
  if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
265
360
  } else {
266
- if (!u) throw new Error("try statement without catch or finally");
361
+ if (!u) throw Error("try statement without catch or finally");
267
362
  if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
268
363
  }
269
364
  }
@@ -303,7 +398,7 @@ function _regeneratorRuntime() {
303
398
  return o;
304
399
  }
305
400
  }
306
- throw new Error("illegal catch attempt");
401
+ throw Error("illegal catch attempt");
307
402
  },
308
403
  delegateYield: function (e, r, n) {
309
404
  return this.delegate = {
@@ -314,165 +409,39 @@ function _regeneratorRuntime() {
314
409
  }
315
410
  }, e;
316
411
  }
317
- function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
318
- try {
319
- var info = gen[key](arg);
320
- var value = info.value;
321
- } catch (error) {
322
- reject(error);
323
- return;
324
- }
325
- if (info.done) {
326
- resolve(value);
327
- } else {
328
- Promise.resolve(value).then(_next, _throw);
329
- }
412
+ function _setPrototypeOf(t, e) {
413
+ return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) {
414
+ return t.__proto__ = e, t;
415
+ }, _setPrototypeOf(t, e);
330
416
  }
331
- function _asyncToGenerator(fn) {
332
- return function () {
333
- var self = this,
334
- args = arguments;
335
- return new Promise(function (resolve, reject) {
336
- var gen = fn.apply(self, args);
337
- function _next(value) {
338
- asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value);
339
- }
340
- function _throw(err) {
341
- asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err);
342
- }
343
- _next(undefined);
344
- });
345
- };
346
- }
347
- function _extends() {
348
- _extends = Object.assign ? Object.assign.bind() : function (target) {
349
- for (var i = 1; i < arguments.length; i++) {
350
- var source = arguments[i];
351
- for (var key in source) {
352
- if (Object.prototype.hasOwnProperty.call(source, key)) {
353
- target[key] = source[key];
354
- }
355
- }
356
- }
357
- return target;
358
- };
359
- return _extends.apply(this, arguments);
360
- }
361
- function _inheritsLoose(subClass, superClass) {
362
- subClass.prototype = Object.create(superClass.prototype);
363
- subClass.prototype.constructor = subClass;
364
- _setPrototypeOf(subClass, superClass);
365
- }
366
- function _getPrototypeOf(o) {
367
- _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) {
368
- return o.__proto__ || Object.getPrototypeOf(o);
369
- };
370
- return _getPrototypeOf(o);
371
- }
372
- function _setPrototypeOf(o, p) {
373
- _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {
374
- o.__proto__ = p;
375
- return o;
376
- };
377
- return _setPrototypeOf(o, p);
378
- }
379
- function _isNativeReflectConstruct() {
380
- if (typeof Reflect === "undefined" || !Reflect.construct) return false;
381
- if (Reflect.construct.sham) return false;
382
- if (typeof Proxy === "function") return true;
383
- try {
384
- Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
385
- return true;
386
- } catch (e) {
387
- return false;
417
+ function _unsupportedIterableToArray(r, a) {
418
+ if (r) {
419
+ if ("string" == typeof r) return _arrayLikeToArray(r, a);
420
+ var t = {}.toString.call(r).slice(8, -1);
421
+ return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0;
388
422
  }
389
423
  }
390
- function _construct(Parent, args, Class) {
391
- if (_isNativeReflectConstruct()) {
392
- _construct = Reflect.construct.bind();
393
- } else {
394
- _construct = function _construct(Parent, args, Class) {
395
- var a = [null];
396
- a.push.apply(a, args);
397
- var Constructor = Function.bind.apply(Parent, a);
398
- var instance = new Constructor();
399
- if (Class) _setPrototypeOf(instance, Class.prototype);
400
- return instance;
401
- };
402
- }
403
- return _construct.apply(null, arguments);
404
- }
405
- function _isNativeFunction(fn) {
406
- return Function.toString.call(fn).indexOf("[native code]") !== -1;
407
- }
408
- function _wrapNativeSuper(Class) {
409
- var _cache = typeof Map === "function" ? new Map() : undefined;
410
- _wrapNativeSuper = function _wrapNativeSuper(Class) {
411
- if (Class === null || !_isNativeFunction(Class)) return Class;
412
- if (typeof Class !== "function") {
413
- throw new TypeError("Super expression must either be null or a function");
414
- }
415
- if (typeof _cache !== "undefined") {
416
- if (_cache.has(Class)) return _cache.get(Class);
417
- _cache.set(Class, Wrapper);
424
+ function _wrapNativeSuper(t) {
425
+ var r = "function" == typeof Map ? new Map() : void 0;
426
+ return _wrapNativeSuper = function (t) {
427
+ if (null === t || !_isNativeFunction(t)) return t;
428
+ if ("function" != typeof t) throw new TypeError("Super expression must either be null or a function");
429
+ if (void 0 !== r) {
430
+ if (r.has(t)) return r.get(t);
431
+ r.set(t, Wrapper);
418
432
  }
419
433
  function Wrapper() {
420
- return _construct(Class, arguments, _getPrototypeOf(this).constructor);
434
+ return _construct(t, arguments, _getPrototypeOf(this).constructor);
421
435
  }
422
- Wrapper.prototype = Object.create(Class.prototype, {
436
+ return Wrapper.prototype = Object.create(t.prototype, {
423
437
  constructor: {
424
438
  value: Wrapper,
425
- enumerable: false,
426
- writable: true,
427
- configurable: true
439
+ enumerable: !1,
440
+ writable: !0,
441
+ configurable: !0
428
442
  }
429
- });
430
- return _setPrototypeOf(Wrapper, Class);
431
- };
432
- return _wrapNativeSuper(Class);
433
- }
434
- function _objectWithoutPropertiesLoose(source, excluded) {
435
- if (source == null) return {};
436
- var target = {};
437
- var sourceKeys = Object.keys(source);
438
- var key, i;
439
- for (i = 0; i < sourceKeys.length; i++) {
440
- key = sourceKeys[i];
441
- if (excluded.indexOf(key) >= 0) continue;
442
- target[key] = source[key];
443
- }
444
- return target;
445
- }
446
- function _unsupportedIterableToArray(o, minLen) {
447
- if (!o) return;
448
- if (typeof o === "string") return _arrayLikeToArray(o, minLen);
449
- var n = Object.prototype.toString.call(o).slice(8, -1);
450
- if (n === "Object" && o.constructor) n = o.constructor.name;
451
- if (n === "Map" || n === "Set") return Array.from(o);
452
- if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
453
- }
454
- function _arrayLikeToArray(arr, len) {
455
- if (len == null || len > arr.length) len = arr.length;
456
- for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
457
- return arr2;
458
- }
459
- function _createForOfIteratorHelperLoose(o, allowArrayLike) {
460
- var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"];
461
- if (it) return (it = it.call(o)).next.bind(it);
462
- if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") {
463
- if (it) o = it;
464
- var i = 0;
465
- return function () {
466
- if (i >= o.length) return {
467
- done: true
468
- };
469
- return {
470
- done: false,
471
- value: o[i++]
472
- };
473
- };
474
- }
475
- throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
443
+ }), _setPrototypeOf(Wrapper, t);
444
+ }, _wrapNativeSuper(t);
476
445
  }
477
446
 
478
447
  var _excluded = ["children"];