@one-commerce/sdk-core 1.16.0 → 1.17.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -686,41 +686,71 @@
686
686
 
687
687
  return ShopCart;
688
688
  }(BaseCallClass);
689
- var ShopUtils = /*#__PURE__*/function (_BaseCallClass4) {
690
- _inherits(ShopUtils, _BaseCallClass4);
689
+ var ShopAuthorization = /*#__PURE__*/function (_BaseCallClass4) {
690
+ _inherits(ShopAuthorization, _BaseCallClass4);
691
691
 
692
- var _super4 = _createSuper(ShopUtils);
692
+ var _super4 = _createSuper(ShopAuthorization);
693
693
 
694
- function ShopUtils(call) {
694
+ function ShopAuthorization() {
695
695
  var _this4;
696
696
 
697
+ _classCallCheck(this, ShopAuthorization);
698
+
699
+ for (var _len4 = arguments.length, args = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
700
+ args[_key4] = arguments[_key4];
701
+ }
702
+
703
+ _this4 = _super4.call.apply(_super4, [this].concat(args));
704
+
705
+ _defineProperty(_assertThisInitialized(_this4), "serviceName", 'authorization');
706
+
707
+ return _this4;
708
+ }
709
+
710
+ _createClass(ShopAuthorization, [{
711
+ key: "getAuthToken",
712
+ value: function getAuthToken() {
713
+ return this.call('getAuthToken');
714
+ }
715
+ }]);
716
+
717
+ return ShopAuthorization;
718
+ }(BaseCallClass);
719
+ var ShopUtils = /*#__PURE__*/function (_BaseCallClass5) {
720
+ _inherits(ShopUtils, _BaseCallClass5);
721
+
722
+ var _super5 = _createSuper(ShopUtils);
723
+
724
+ function ShopUtils(call) {
725
+ var _this5;
726
+
697
727
  _classCallCheck(this, ShopUtils);
698
728
 
699
- _this4 = _super4.call(this, call);
729
+ _this5 = _super5.call(this, call);
700
730
 
701
- _defineProperty(_assertThisInitialized(_this4), "serviceName", 'utils');
731
+ _defineProperty(_assertThisInitialized(_this5), "serviceName", 'utils');
702
732
 
703
- _defineProperty(_assertThisInitialized(_this4), "currency", void 0);
733
+ _defineProperty(_assertThisInitialized(_this5), "currency", void 0);
704
734
 
705
- _defineProperty(_assertThisInitialized(_this4), "isAnonymousAndPurchaseDisabled", void 0);
735
+ _defineProperty(_assertThisInitialized(_this5), "isAnonymousAndPurchaseDisabled", void 0);
706
736
 
707
- _defineProperty(_assertThisInitialized(_this4), "isB2B", void 0);
737
+ _defineProperty(_assertThisInitialized(_this5), "isB2B", void 0);
708
738
 
709
- _defineProperty(_assertThisInitialized(_this4), "isB2BAndPlatformIsNotOpened", void 0);
739
+ _defineProperty(_assertThisInitialized(_this5), "isB2BAndPlatformIsNotOpened", void 0);
710
740
 
711
- _defineProperty(_assertThisInitialized(_this4), "isIndexPage", void 0);
741
+ _defineProperty(_assertThisInitialized(_this5), "isIndexPage", void 0);
712
742
 
713
- _defineProperty(_assertThisInitialized(_this4), "isPurchaseEnabledOrAuthenticated", void 0);
743
+ _defineProperty(_assertThisInitialized(_this5), "isPurchaseEnabledOrAuthenticated", void 0);
714
744
 
715
- _defineProperty(_assertThisInitialized(_this4), "routes", void 0);
745
+ _defineProperty(_assertThisInitialized(_this5), "routes", void 0);
716
746
 
717
- _this4.routes = {
718
- getCategoryPath: _this4.getCategoryPath,
719
- getManufacturerSearchUrl: _this4.getManufacturerSearchUrl,
720
- getProductUrl: _this4.getProductUrl,
721
- isExternalUrl: _this4.isExternalUrl
747
+ _this5.routes = {
748
+ getCategoryPath: _this5.getCategoryPath,
749
+ getManufacturerSearchUrl: _this5.getManufacturerSearchUrl,
750
+ getProductUrl: _this5.getProductUrl,
751
+ isExternalUrl: _this5.isExternalUrl
722
752
  };
723
- return _this4;
753
+ return _this5;
724
754
  }
725
755
 
726
756
  _createClass(ShopUtils, [{
@@ -747,43 +777,43 @@
747
777
 
748
778
  return ShopUtils;
749
779
  }(BaseCallClass);
750
- var ShopConfig = /*#__PURE__*/function (_BaseCallClass5) {
751
- _inherits(ShopConfig, _BaseCallClass5);
780
+ var ShopConfig = /*#__PURE__*/function (_BaseCallClass6) {
781
+ _inherits(ShopConfig, _BaseCallClass6);
752
782
 
753
- var _super5 = _createSuper(ShopConfig);
783
+ var _super6 = _createSuper(ShopConfig);
754
784
 
755
785
  function ShopConfig() {
756
- var _this5;
786
+ var _this6;
757
787
 
758
788
  _classCallCheck(this, ShopConfig);
759
789
 
760
- for (var _len4 = arguments.length, args = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
761
- args[_key4] = arguments[_key4];
790
+ for (var _len5 = arguments.length, args = new Array(_len5), _key5 = 0; _key5 < _len5; _key5++) {
791
+ args[_key5] = arguments[_key5];
762
792
  }
763
793
 
764
- _this5 = _super5.call.apply(_super5, [this].concat(args));
794
+ _this6 = _super6.call.apply(_super6, [this].concat(args));
765
795
 
766
- _defineProperty(_assertThisInitialized(_this5), "serviceName", 'config');
796
+ _defineProperty(_assertThisInitialized(_this6), "serviceName", 'config');
767
797
 
768
- _defineProperty(_assertThisInitialized(_this5), "accessMode", void 0);
798
+ _defineProperty(_assertThisInitialized(_this6), "accessMode", void 0);
769
799
 
770
- _defineProperty(_assertThisInitialized(_this5), "isB2CRegistrationEnabled", void 0);
800
+ _defineProperty(_assertThisInitialized(_this6), "isB2CRegistrationEnabled", void 0);
771
801
 
772
- _defineProperty(_assertThisInitialized(_this5), "isCatalogOpened", void 0);
802
+ _defineProperty(_assertThisInitialized(_this6), "isCatalogOpened", void 0);
773
803
 
774
- _defineProperty(_assertThisInitialized(_this5), "isGrossSelected", void 0);
804
+ _defineProperty(_assertThisInitialized(_this6), "isGrossSelected", void 0);
775
805
 
776
- _defineProperty(_assertThisInitialized(_this5), "isPlatformClosed", void 0);
806
+ _defineProperty(_assertThisInitialized(_this6), "isPlatformClosed", void 0);
777
807
 
778
- _defineProperty(_assertThisInitialized(_this5), "isPlatformOpened", void 0);
808
+ _defineProperty(_assertThisInitialized(_this6), "isPlatformOpened", void 0);
779
809
 
780
- _defineProperty(_assertThisInitialized(_this5), "isPurchaseEnabled", void 0);
810
+ _defineProperty(_assertThisInitialized(_this6), "isPurchaseEnabled", void 0);
781
811
 
782
- _defineProperty(_assertThisInitialized(_this5), "isRegistrationEnabled", void 0);
812
+ _defineProperty(_assertThisInitialized(_this6), "isRegistrationEnabled", void 0);
783
813
 
784
- _defineProperty(_assertThisInitialized(_this5), "currency", void 0);
814
+ _defineProperty(_assertThisInitialized(_this6), "currency", void 0);
785
815
 
786
- return _this5;
816
+ return _this6;
787
817
  }
788
818
 
789
819
  return _createClass(ShopConfig);
@@ -1077,6 +1107,7 @@
1077
1107
  hash: '',
1078
1108
  query: {}
1079
1109
  },
1110
+ authorization: new ShopAuthorization(_this6.callFunction.bind(_assertThisInitialized(_this6))),
1080
1111
  cart: new ShopCart(_this6.callFunction.bind(_assertThisInitialized(_this6))),
1081
1112
  catalog: new ShopCatalog(_this6.callFunction.bind(_assertThisInitialized(_this6))),
1082
1113
  account: new ShopAccount(_this6.callFunction.bind(_assertThisInitialized(_this6))),