@commercetools-frontend-extensions/import-resources-modal 2.3.0 → 2.3.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.
@@ -36,6 +36,7 @@ var _mapInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instan
36
36
  var _sliceInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/slice');
37
37
  var _styled = require('@emotion/styled/base');
38
38
  require('@emotion/react');
39
+ var _Object$assign = require('@babel/runtime-corejs3/core-js-stable/object/assign');
39
40
  var i18n = require('@commercetools-frontend/i18n');
40
41
 
41
42
  function _interopDefault (e) { return e && e.__esModule ? e : { 'default': e }; }
@@ -54,6 +55,7 @@ var _Reflect$construct__default = /*#__PURE__*/_interopDefault(_Reflect$construc
54
55
  var _mapInstanceProperty__default = /*#__PURE__*/_interopDefault(_mapInstanceProperty);
55
56
  var _sliceInstanceProperty__default = /*#__PURE__*/_interopDefault(_sliceInstanceProperty);
56
57
  var _styled__default = /*#__PURE__*/_interopDefault(_styled);
58
+ var _Object$assign__default = /*#__PURE__*/_interopDefault(_Object$assign);
57
59
 
58
60
  let CurrentStep$1 = /*#__PURE__*/function (CurrentStep) {
59
61
  CurrentStep["Upload"] = "upload";
@@ -479,20 +481,6 @@ var messages$6 = reactIntl.defineMessages({
479
481
  }
480
482
  });
481
483
 
482
- function _callSuper$1(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$1() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
483
- function _isNativeReflectConstruct$1() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct$1 = function () { return !!t; })(); }
484
- let UnexpectedResourceTypeError = /*#__PURE__*/function (_Error) {
485
- function UnexpectedResourceTypeError(resourceType) {
486
- var _this;
487
- _classCallCheck(this, UnexpectedResourceTypeError);
488
- _this = _callSuper$1(this, UnexpectedResourceTypeError, [`Unexpected resource type "${resourceType}"`]);
489
- _this.name = 'UnexpectedResourceTypeError';
490
- return _this;
491
- }
492
- _inherits(UnexpectedResourceTypeError, _Error);
493
- return _createClass(UnexpectedResourceTypeError);
494
- }(/*#__PURE__*/_wrapNativeSuper(Error));
495
-
496
484
  function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
497
485
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function () { return !!t; })(); }
498
486
  let MissingImportResourceProviderError = /*#__PURE__*/function (_Error) {
@@ -683,184 +671,7 @@ var sharedMessages = reactIntl.defineMessages({
683
671
  id: 'ImportResourcesModal.delimiterTab',
684
672
  description: 'Label for the delimiter name tab',
685
673
  defaultMessage: 'tab'
686
- },
687
- // Resource types
688
- product: {
689
- id: 'ImportResourcesModal.product',
690
- description: 'Label for the product resource type',
691
- defaultMessage: 'Product'
692
- },
693
- products: {
694
- id: 'ImportResourcesModal.products',
695
- description: 'Label for the products resource type',
696
- defaultMessage: 'Products'
697
- },
698
- inventory: {
699
- id: 'ImportResourcesModal.inventory',
700
- description: 'Label for the inventory entry resource type',
701
- defaultMessage: 'Inventory'
702
- },
703
- inventories: {
704
- id: 'ImportResourcesModal.inventories',
705
- description: 'Label for the inventories entry resource type',
706
- defaultMessage: 'Inventories'
707
- },
708
- category: {
709
- id: 'ImportResourcesModal.category',
710
- description: 'Label for the category resource type',
711
- defaultMessage: 'Category'
712
- },
713
- categories: {
714
- id: 'ImportResourcesModal.categories',
715
- description: 'Label for the categories resource type',
716
- defaultMessage: 'Categories'
717
- },
718
- 'custom-object': {
719
- id: 'ImportResourcesModal.custom-object',
720
- description: 'Label for the custom-object resource type',
721
- defaultMessage: 'Custom object'
722
- },
723
- 'custom-objects': {
724
- id: 'ImportResourcesModal.custom-objects',
725
- description: 'Label for the custom-objects resource type',
726
- defaultMessage: 'Custom objects'
727
- },
728
- customer: {
729
- id: 'ImportResourcesModal.customer',
730
- description: 'Label for the customer resource type',
731
- defaultMessage: 'Customer'
732
- },
733
- customers: {
734
- id: 'ImportResourcesModal.customers',
735
- description: 'Label for the customers resource type',
736
- defaultMessage: 'Customers'
737
- },
738
- order: {
739
- id: 'ImportResourcesModal.order',
740
- description: 'Label for the order resource type',
741
- defaultMessage: 'Order'
742
- },
743
- orders: {
744
- id: 'ImportResourcesModal.orders',
745
- description: 'Label for the orders resource type',
746
- defaultMessage: 'Orders'
747
- },
748
- 'order-patch': {
749
- id: 'ImportResourcesModal.order-patch',
750
- description: 'Label for the order-patch resource type',
751
- defaultMessage: 'Order patch'
752
- },
753
- 'order-patches': {
754
- id: 'ImportResourcesModal.order-patches',
755
- description: 'Label for the order-patches resource type',
756
- defaultMessage: 'Order patches'
757
- },
758
- price: {
759
- id: 'ImportResourcesModal.price',
760
- description: 'Label for the price resource type',
761
- defaultMessage: 'Price'
762
- },
763
- prices: {
764
- id: 'ImportResourcesModal.prices',
765
- description: 'Label for the prices resource type',
766
- defaultMessage: 'Prices'
767
- },
768
- 'product-draft': {
769
- id: 'ImportResourcesModal.product-draft',
770
- description: 'Label for the product-draft resource type',
771
- defaultMessage: 'Product draft'
772
- },
773
- 'product-drafts': {
774
- id: 'ImportResourcesModal.product-drafts',
775
- description: 'Label for the product-drafts resource type',
776
- defaultMessage: 'Product drafts'
777
- },
778
- 'product-type': {
779
- id: 'ImportResourcesModal.product-type',
780
- description: 'Label for the product-type resource type',
781
- defaultMessage: 'Product type'
782
- },
783
- 'product-types': {
784
- id: 'ImportResourcesModal.product-types',
785
- description: 'Label for the product-types resource type',
786
- defaultMessage: 'Product types'
787
- },
788
- 'product-variant': {
789
- id: 'ImportResourcesModal.product-variant',
790
- description: 'Label for the product-variant resource type',
791
- defaultMessage: 'Product variant'
792
- },
793
- 'product-variants': {
794
- id: 'ImportResourcesModal.product-variants',
795
- description: 'Label for the product-variants resource type',
796
- defaultMessage: 'Product variants'
797
- },
798
- 'product-variant-patch': {
799
- id: 'ImportResourcesModal.product-variant-patch',
800
- description: 'Label for the product-variant-patch resource type',
801
- defaultMessage: 'Product variant patch'
802
- },
803
- 'product-variant-patches': {
804
- id: 'ImportResourcesModal.product-variant-patches',
805
- description: 'Label for the product-variant-patches resource type',
806
- defaultMessage: 'Product variant patches'
807
- },
808
- 'standalone-price': {
809
- id: 'ImportResourcesModal.standalone-price',
810
- description: 'Label for the standalone-price resource type',
811
- defaultMessage: 'Standalone price'
812
- },
813
- 'standalone-prices': {
814
- id: 'ImportResourcesModal.standalone-prices',
815
- description: 'Label for the standalone-prices resource type',
816
- defaultMessage: 'Standalone prices'
817
- },
818
- type: {
819
- id: 'ImportResourcesModal.type',
820
- description: 'Label for the type resource type',
821
- defaultMessage: 'Type'
822
- },
823
- types: {
824
- id: 'ImportResourcesModal.types',
825
- description: 'Label for the types resource type',
826
- defaultMessage: 'Types'
827
- },
828
- 'discount-code': {
829
- id: 'ImportResourcesModal.discount-code',
830
- description: 'Label for the discount-code resource type',
831
- defaultMessage: 'Discount code'
832
- },
833
- 'discount-codes': {
834
- id: 'ImportResourcesModal.discount-codes',
835
- description: 'Label for the discount-codes resource type',
836
- defaultMessage: 'Discount codes'
837
- },
838
- 'business-unit': {
839
- id: 'ImportResourcesModal.business-unit',
840
- description: 'Label for the business-unit resource type',
841
- defaultMessage: 'Business unit'
842
- },
843
- 'business-units': {
844
- id: 'ImportResourcesModal.business-units',
845
- description: 'Label for the business-units resource type',
846
- defaultMessage: 'Business units'
847
- },
848
- 'product-tailoring': {
849
- id: 'ImportResourcesModal.product-tailoring',
850
- description: 'Label for the product-tailoring resource type',
851
- defaultMessage: 'Tailored product'
852
- },
853
- 'product-tailorings': {
854
- id: 'ImportResourcesModal.product-tailorings',
855
- description: 'Label for the product-tailorings resource type',
856
- defaultMessage: 'Tailored products'
857
- },
858
- unknownResourceType: {
859
- id: 'ImportResourcesModal.unknown-resource-type',
860
- description: 'Label for the unknown resource type',
861
- defaultMessage: 'Unknown resource type'
862
674
  }
863
- //
864
675
  });
865
676
 
866
677
  const formatAllowedDelimitersForMessageDisplay = intl => {
@@ -893,60 +704,6 @@ const formatAllowedDelimitersForMessageDisplay = intl => {
893
704
  return `${descriptions.join(', ')} ${localizedOr} ${lastDescription}`;
894
705
  };
895
706
 
896
- function resourceTypeToMessage(resourceType) {
897
- const resourceTypeMap = {
898
- category: sharedMessages.category,
899
- product: sharedMessages.product,
900
- 'product-type': sharedMessages['product-type'],
901
- order: sharedMessages.order,
902
- customer: sharedMessages.customer,
903
- 'discount-code': sharedMessages['discount-code'],
904
- inventory: sharedMessages.inventory,
905
- 'inventory-entry': sharedMessages.inventory,
906
- 'order-patch': sharedMessages['order-patch'],
907
- price: sharedMessages.price,
908
- 'product-draft': sharedMessages['product-draft'],
909
- 'product-variant': sharedMessages['product-variant'],
910
- 'product-variant-patch': sharedMessages['product-variant-patch'],
911
- 'standalone-price': sharedMessages['standalone-price'],
912
- 'custom-object': sharedMessages['custom-object'],
913
- 'business-unit': sharedMessages['business-unit'],
914
- type: sharedMessages.type
915
- };
916
- const message = resourceTypeMap[resourceType];
917
- if (!message) {
918
- console.warn(new UnexpectedResourceTypeError(resourceType));
919
- return sharedMessages.unknownResourceType;
920
- }
921
- return message;
922
- }
923
- function resourceTypeToPluralMessage(resourceType) {
924
- const resourceTypePluralMap = {
925
- category: sharedMessages.categories,
926
- 'custom-object': sharedMessages['custom-objects'],
927
- product: sharedMessages.products,
928
- 'product-type': sharedMessages['product-types'],
929
- order: sharedMessages.orders,
930
- customer: sharedMessages.customers,
931
- 'discount-code': sharedMessages['discount-codes'],
932
- inventory: sharedMessages.inventories,
933
- 'inventory-entry': sharedMessages.inventories,
934
- 'order-patch': sharedMessages['order-patches'],
935
- price: sharedMessages.prices,
936
- 'product-draft': sharedMessages['product-drafts'],
937
- 'product-variant': sharedMessages['product-variants'],
938
- 'product-variant-patch': sharedMessages['product-variant-patches'],
939
- 'standalone-price': sharedMessages['standalone-prices'],
940
- 'business-unit': sharedMessages['business-units']
941
- };
942
- const message = resourceTypePluralMap[resourceType];
943
- if (!message) {
944
- console.warn(new UnexpectedResourceTypeError(resourceType));
945
- return sharedMessages.unknownResourceType;
946
- }
947
- return message;
948
- }
949
-
950
707
  function ownKeys$8(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
951
708
  function _objectSpread$8(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$8(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$8(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
952
709
  const useUpload = () => {
@@ -1832,9 +1589,9 @@ function UploadPreviewModal() {
1832
1589
  actions = _useImportResourcesCo2.actions,
1833
1590
  onClose = _useImportResourcesCo2.onClose;
1834
1591
  if (!state.resourceType || !state.uploadFileResponse) return null;
1835
- const resourceTypeMessage = resourceTypeToMessage(state.resourceType);
1592
+ const resourceTypeMessage = operations.resourceTypeToMessage(state.resourceType);
1836
1593
  const resourceType = intl.formatMessage(resourceTypeMessage).toLowerCase();
1837
- const resourceTypePluralMessage = resourceTypeToPluralMessage(state.resourceType);
1594
+ const resourceTypePluralMessage = operations.resourceTypeToPluralMessage(state.resourceType);
1838
1595
  const resourceTypePlural = intl.formatMessage(resourceTypePluralMessage).toLowerCase();
1839
1596
  const ignoredFields = state.uploadFileResponse.ignoredFields;
1840
1597
  const validatedFields = operations.getValidatedColumns(state.uploadFileResponse.fields, ignoredFields);
@@ -2280,10 +2037,10 @@ const getChunkImport = locale => {
2280
2037
  };
2281
2038
  const loadMessages = async locale => {
2282
2039
  try {
2040
+ const operationsSharedMessages = await operations.loadOperationsSharedMessages(locale);
2283
2041
  const chunkImport = await getChunkImport(locale);
2284
- return i18n.parseChunkImport(chunkImport);
2042
+ return _Object$assign__default["default"]({}, operationsSharedMessages, i18n.parseChunkImport(chunkImport));
2285
2043
  } catch (error) {
2286
- // eslint-disable-next-line no-console
2287
2044
  console.warn(`Something went wrong while loading the import-resources-modal messages for ${locale}`, error);
2288
2045
  sentry.reportErrorToSentry(new Error(`Something went wrong while loading the import-resources-modal messages for ${locale}`), {
2289
2046
  extra: error
@@ -36,6 +36,7 @@ var _mapInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instan
36
36
  var _sliceInstanceProperty = require('@babel/runtime-corejs3/core-js-stable/instance/slice');
37
37
  var _styled = require('@emotion/styled/base');
38
38
  require('@emotion/react');
39
+ var _Object$assign = require('@babel/runtime-corejs3/core-js-stable/object/assign');
39
40
  var i18n = require('@commercetools-frontend/i18n');
40
41
 
41
42
  function _interopDefault (e) { return e && e.__esModule ? e : { 'default': e }; }
@@ -54,6 +55,7 @@ var _Reflect$construct__default = /*#__PURE__*/_interopDefault(_Reflect$construc
54
55
  var _mapInstanceProperty__default = /*#__PURE__*/_interopDefault(_mapInstanceProperty);
55
56
  var _sliceInstanceProperty__default = /*#__PURE__*/_interopDefault(_sliceInstanceProperty);
56
57
  var _styled__default = /*#__PURE__*/_interopDefault(_styled);
58
+ var _Object$assign__default = /*#__PURE__*/_interopDefault(_Object$assign);
57
59
 
58
60
  let CurrentStep$1 = /*#__PURE__*/function (CurrentStep) {
59
61
  CurrentStep["Upload"] = "upload";
@@ -479,20 +481,6 @@ var messages$6 = reactIntl.defineMessages({
479
481
  }
480
482
  });
481
483
 
482
- function _callSuper$1(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$1() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
483
- function _isNativeReflectConstruct$1() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct$1 = function () { return !!t; })(); }
484
- let UnexpectedResourceTypeError = /*#__PURE__*/function (_Error) {
485
- function UnexpectedResourceTypeError(resourceType) {
486
- var _this;
487
- _classCallCheck(this, UnexpectedResourceTypeError);
488
- _this = _callSuper$1(this, UnexpectedResourceTypeError, [`Unexpected resource type "${resourceType}"`]);
489
- _this.name = 'UnexpectedResourceTypeError';
490
- return _this;
491
- }
492
- _inherits(UnexpectedResourceTypeError, _Error);
493
- return _createClass(UnexpectedResourceTypeError);
494
- }(/*#__PURE__*/_wrapNativeSuper(Error));
495
-
496
484
  function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? _Reflect$construct__default["default"](o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
497
485
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct__default["default"](Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function () { return !!t; })(); }
498
486
  let MissingImportResourceProviderError = /*#__PURE__*/function (_Error) {
@@ -683,184 +671,7 @@ var sharedMessages = reactIntl.defineMessages({
683
671
  id: 'ImportResourcesModal.delimiterTab',
684
672
  description: 'Label for the delimiter name tab',
685
673
  defaultMessage: 'tab'
686
- },
687
- // Resource types
688
- product: {
689
- id: 'ImportResourcesModal.product',
690
- description: 'Label for the product resource type',
691
- defaultMessage: 'Product'
692
- },
693
- products: {
694
- id: 'ImportResourcesModal.products',
695
- description: 'Label for the products resource type',
696
- defaultMessage: 'Products'
697
- },
698
- inventory: {
699
- id: 'ImportResourcesModal.inventory',
700
- description: 'Label for the inventory entry resource type',
701
- defaultMessage: 'Inventory'
702
- },
703
- inventories: {
704
- id: 'ImportResourcesModal.inventories',
705
- description: 'Label for the inventories entry resource type',
706
- defaultMessage: 'Inventories'
707
- },
708
- category: {
709
- id: 'ImportResourcesModal.category',
710
- description: 'Label for the category resource type',
711
- defaultMessage: 'Category'
712
- },
713
- categories: {
714
- id: 'ImportResourcesModal.categories',
715
- description: 'Label for the categories resource type',
716
- defaultMessage: 'Categories'
717
- },
718
- 'custom-object': {
719
- id: 'ImportResourcesModal.custom-object',
720
- description: 'Label for the custom-object resource type',
721
- defaultMessage: 'Custom object'
722
- },
723
- 'custom-objects': {
724
- id: 'ImportResourcesModal.custom-objects',
725
- description: 'Label for the custom-objects resource type',
726
- defaultMessage: 'Custom objects'
727
- },
728
- customer: {
729
- id: 'ImportResourcesModal.customer',
730
- description: 'Label for the customer resource type',
731
- defaultMessage: 'Customer'
732
- },
733
- customers: {
734
- id: 'ImportResourcesModal.customers',
735
- description: 'Label for the customers resource type',
736
- defaultMessage: 'Customers'
737
- },
738
- order: {
739
- id: 'ImportResourcesModal.order',
740
- description: 'Label for the order resource type',
741
- defaultMessage: 'Order'
742
- },
743
- orders: {
744
- id: 'ImportResourcesModal.orders',
745
- description: 'Label for the orders resource type',
746
- defaultMessage: 'Orders'
747
- },
748
- 'order-patch': {
749
- id: 'ImportResourcesModal.order-patch',
750
- description: 'Label for the order-patch resource type',
751
- defaultMessage: 'Order patch'
752
- },
753
- 'order-patches': {
754
- id: 'ImportResourcesModal.order-patches',
755
- description: 'Label for the order-patches resource type',
756
- defaultMessage: 'Order patches'
757
- },
758
- price: {
759
- id: 'ImportResourcesModal.price',
760
- description: 'Label for the price resource type',
761
- defaultMessage: 'Price'
762
- },
763
- prices: {
764
- id: 'ImportResourcesModal.prices',
765
- description: 'Label for the prices resource type',
766
- defaultMessage: 'Prices'
767
- },
768
- 'product-draft': {
769
- id: 'ImportResourcesModal.product-draft',
770
- description: 'Label for the product-draft resource type',
771
- defaultMessage: 'Product draft'
772
- },
773
- 'product-drafts': {
774
- id: 'ImportResourcesModal.product-drafts',
775
- description: 'Label for the product-drafts resource type',
776
- defaultMessage: 'Product drafts'
777
- },
778
- 'product-type': {
779
- id: 'ImportResourcesModal.product-type',
780
- description: 'Label for the product-type resource type',
781
- defaultMessage: 'Product type'
782
- },
783
- 'product-types': {
784
- id: 'ImportResourcesModal.product-types',
785
- description: 'Label for the product-types resource type',
786
- defaultMessage: 'Product types'
787
- },
788
- 'product-variant': {
789
- id: 'ImportResourcesModal.product-variant',
790
- description: 'Label for the product-variant resource type',
791
- defaultMessage: 'Product variant'
792
- },
793
- 'product-variants': {
794
- id: 'ImportResourcesModal.product-variants',
795
- description: 'Label for the product-variants resource type',
796
- defaultMessage: 'Product variants'
797
- },
798
- 'product-variant-patch': {
799
- id: 'ImportResourcesModal.product-variant-patch',
800
- description: 'Label for the product-variant-patch resource type',
801
- defaultMessage: 'Product variant patch'
802
- },
803
- 'product-variant-patches': {
804
- id: 'ImportResourcesModal.product-variant-patches',
805
- description: 'Label for the product-variant-patches resource type',
806
- defaultMessage: 'Product variant patches'
807
- },
808
- 'standalone-price': {
809
- id: 'ImportResourcesModal.standalone-price',
810
- description: 'Label for the standalone-price resource type',
811
- defaultMessage: 'Standalone price'
812
- },
813
- 'standalone-prices': {
814
- id: 'ImportResourcesModal.standalone-prices',
815
- description: 'Label for the standalone-prices resource type',
816
- defaultMessage: 'Standalone prices'
817
- },
818
- type: {
819
- id: 'ImportResourcesModal.type',
820
- description: 'Label for the type resource type',
821
- defaultMessage: 'Type'
822
- },
823
- types: {
824
- id: 'ImportResourcesModal.types',
825
- description: 'Label for the types resource type',
826
- defaultMessage: 'Types'
827
- },
828
- 'discount-code': {
829
- id: 'ImportResourcesModal.discount-code',
830
- description: 'Label for the discount-code resource type',
831
- defaultMessage: 'Discount code'
832
- },
833
- 'discount-codes': {
834
- id: 'ImportResourcesModal.discount-codes',
835
- description: 'Label for the discount-codes resource type',
836
- defaultMessage: 'Discount codes'
837
- },
838
- 'business-unit': {
839
- id: 'ImportResourcesModal.business-unit',
840
- description: 'Label for the business-unit resource type',
841
- defaultMessage: 'Business unit'
842
- },
843
- 'business-units': {
844
- id: 'ImportResourcesModal.business-units',
845
- description: 'Label for the business-units resource type',
846
- defaultMessage: 'Business units'
847
- },
848
- 'product-tailoring': {
849
- id: 'ImportResourcesModal.product-tailoring',
850
- description: 'Label for the product-tailoring resource type',
851
- defaultMessage: 'Tailored product'
852
- },
853
- 'product-tailorings': {
854
- id: 'ImportResourcesModal.product-tailorings',
855
- description: 'Label for the product-tailorings resource type',
856
- defaultMessage: 'Tailored products'
857
- },
858
- unknownResourceType: {
859
- id: 'ImportResourcesModal.unknown-resource-type',
860
- description: 'Label for the unknown resource type',
861
- defaultMessage: 'Unknown resource type'
862
674
  }
863
- //
864
675
  });
865
676
 
866
677
  const formatAllowedDelimitersForMessageDisplay = intl => {
@@ -893,60 +704,6 @@ const formatAllowedDelimitersForMessageDisplay = intl => {
893
704
  return `${descriptions.join(', ')} ${localizedOr} ${lastDescription}`;
894
705
  };
895
706
 
896
- function resourceTypeToMessage(resourceType) {
897
- const resourceTypeMap = {
898
- category: sharedMessages.category,
899
- product: sharedMessages.product,
900
- 'product-type': sharedMessages['product-type'],
901
- order: sharedMessages.order,
902
- customer: sharedMessages.customer,
903
- 'discount-code': sharedMessages['discount-code'],
904
- inventory: sharedMessages.inventory,
905
- 'inventory-entry': sharedMessages.inventory,
906
- 'order-patch': sharedMessages['order-patch'],
907
- price: sharedMessages.price,
908
- 'product-draft': sharedMessages['product-draft'],
909
- 'product-variant': sharedMessages['product-variant'],
910
- 'product-variant-patch': sharedMessages['product-variant-patch'],
911
- 'standalone-price': sharedMessages['standalone-price'],
912
- 'custom-object': sharedMessages['custom-object'],
913
- 'business-unit': sharedMessages['business-unit'],
914
- type: sharedMessages.type
915
- };
916
- const message = resourceTypeMap[resourceType];
917
- if (!message) {
918
- console.warn(new UnexpectedResourceTypeError(resourceType));
919
- return sharedMessages.unknownResourceType;
920
- }
921
- return message;
922
- }
923
- function resourceTypeToPluralMessage(resourceType) {
924
- const resourceTypePluralMap = {
925
- category: sharedMessages.categories,
926
- 'custom-object': sharedMessages['custom-objects'],
927
- product: sharedMessages.products,
928
- 'product-type': sharedMessages['product-types'],
929
- order: sharedMessages.orders,
930
- customer: sharedMessages.customers,
931
- 'discount-code': sharedMessages['discount-codes'],
932
- inventory: sharedMessages.inventories,
933
- 'inventory-entry': sharedMessages.inventories,
934
- 'order-patch': sharedMessages['order-patches'],
935
- price: sharedMessages.prices,
936
- 'product-draft': sharedMessages['product-drafts'],
937
- 'product-variant': sharedMessages['product-variants'],
938
- 'product-variant-patch': sharedMessages['product-variant-patches'],
939
- 'standalone-price': sharedMessages['standalone-prices'],
940
- 'business-unit': sharedMessages['business-units']
941
- };
942
- const message = resourceTypePluralMap[resourceType];
943
- if (!message) {
944
- console.warn(new UnexpectedResourceTypeError(resourceType));
945
- return sharedMessages.unknownResourceType;
946
- }
947
- return message;
948
- }
949
-
950
707
  function ownKeys$8(e, r) { var t = _Object$keys__default["default"](e); if (_Object$getOwnPropertySymbols__default["default"]) { var o = _Object$getOwnPropertySymbols__default["default"](e); r && (o = _filterInstanceProperty__default["default"](o).call(o, function (r) { return _Object$getOwnPropertyDescriptor__default["default"](e, r).enumerable; })), t.push.apply(t, o); } return t; }
951
708
  function _objectSpread$8(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty__default["default"](_context = ownKeys$8(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors__default["default"] ? _Object$defineProperties__default["default"](e, _Object$getOwnPropertyDescriptors__default["default"](t)) : _forEachInstanceProperty__default["default"](_context2 = ownKeys$8(Object(t))).call(_context2, function (r) { _Object$defineProperty__default["default"](e, r, _Object$getOwnPropertyDescriptor__default["default"](t, r)); }); } return e; }
952
709
  const useUpload = () => {
@@ -1817,9 +1574,9 @@ function UploadPreviewModal() {
1817
1574
  actions = _useImportResourcesCo2.actions,
1818
1575
  onClose = _useImportResourcesCo2.onClose;
1819
1576
  if (!state.resourceType || !state.uploadFileResponse) return null;
1820
- const resourceTypeMessage = resourceTypeToMessage(state.resourceType);
1577
+ const resourceTypeMessage = operations.resourceTypeToMessage(state.resourceType);
1821
1578
  const resourceType = intl.formatMessage(resourceTypeMessage).toLowerCase();
1822
- const resourceTypePluralMessage = resourceTypeToPluralMessage(state.resourceType);
1579
+ const resourceTypePluralMessage = operations.resourceTypeToPluralMessage(state.resourceType);
1823
1580
  const resourceTypePlural = intl.formatMessage(resourceTypePluralMessage).toLowerCase();
1824
1581
  const ignoredFields = state.uploadFileResponse.ignoredFields;
1825
1582
  const validatedFields = operations.getValidatedColumns(state.uploadFileResponse.fields, ignoredFields);
@@ -2256,10 +2013,10 @@ const getChunkImport = locale => {
2256
2013
  };
2257
2014
  const loadMessages = async locale => {
2258
2015
  try {
2016
+ const operationsSharedMessages = await operations.loadOperationsSharedMessages(locale);
2259
2017
  const chunkImport = await getChunkImport(locale);
2260
- return i18n.parseChunkImport(chunkImport);
2018
+ return _Object$assign__default["default"]({}, operationsSharedMessages, i18n.parseChunkImport(chunkImport));
2261
2019
  } catch (error) {
2262
- // eslint-disable-next-line no-console
2263
2020
  console.warn(`Something went wrong while loading the import-resources-modal messages for ${locale}`, error);
2264
2021
  sentry.reportErrorToSentry(new Error(`Something went wrong while loading the import-resources-modal messages for ${locale}`), {
2265
2022
  extra: error
@@ -10,7 +10,7 @@ import _defineProperty from '@babel/runtime-corejs3/helpers/esm/defineProperty';
10
10
  import _everyInstanceProperty from '@babel/runtime-corejs3/core-js-stable/instance/every';
11
11
  import { defineMessages, useIntl, FormattedMessage, IntlProvider } from 'react-intl';
12
12
  import { useApplicationContext } from '@commercetools-frontend/application-shell-connectors';
13
- import { deleteImportContainer, FileDroppedArea, DisabledDropArea, EnabledDropArea, ActiveDragDropArea, COLUMN_DELIMITERS, useFileUpload, isPublishableResourceType, validateDelimiter, getRowCount, toBytes, IMPORT_MAX_FILE_SIZE_MB, IMPORT_MAX_ITEM_COUNT, isAbortError, HttpError, formatKeys, PollingTimeoutError, isError, assertResourceType, FileDropArea as FileDropArea$1, InfoBox, CT_API_DOCS_URL, UploadSeparator, UploadSettings, getPublishCheckboxTrackingTarget, useFetchFileImportJobRecords, mapUploadFileErrorsResponseToUploadFileErrorRows, UnexpectedColumnError, extractErrorDescriptionFromValidationMessage, formatErrorCode, RESOURCE_TYPE_DOCUMENTATION_LINKS, mapFileUploadErrorsToUploadFileErrorRows, getValidatedColumns, processFileImportJob, processUploadedFile, UploadingModal, UnexpectedResourceTypeError as UnexpectedResourceTypeError$1, RESOURCE_TYPE_TEMPLATE_DOWNLOAD_LINKS, isResourceType } from '@commercetools-frontend-extensions/operations';
13
+ import { deleteImportContainer, FileDroppedArea, DisabledDropArea, EnabledDropArea, ActiveDragDropArea, COLUMN_DELIMITERS, useFileUpload, isPublishableResourceType, validateDelimiter, getRowCount, toBytes, IMPORT_MAX_FILE_SIZE_MB, IMPORT_MAX_ITEM_COUNT, isAbortError, HttpError, formatKeys, PollingTimeoutError, isError, assertResourceType, FileDropArea as FileDropArea$1, InfoBox, CT_API_DOCS_URL, UploadSeparator, UploadSettings, getPublishCheckboxTrackingTarget, useFetchFileImportJobRecords, mapUploadFileErrorsResponseToUploadFileErrorRows, UnexpectedColumnError, extractErrorDescriptionFromValidationMessage, formatErrorCode, RESOURCE_TYPE_DOCUMENTATION_LINKS, mapFileUploadErrorsToUploadFileErrorRows, resourceTypeToMessage, resourceTypeToPluralMessage, getValidatedColumns, processFileImportJob, processUploadedFile, UploadingModal, UnexpectedResourceTypeError, RESOURCE_TYPE_TEMPLATE_DOWNLOAD_LINKS, loadOperationsSharedMessages, isResourceType } from '@commercetools-frontend-extensions/operations';
14
14
  import _slicedToArray from '@babel/runtime-corejs3/helpers/esm/slicedToArray';
15
15
  import React, { useContext, useMemo, useState, useEffect } from 'react';
16
16
  import { jsx, jsxs, Fragment } from '@emotion/react/jsx-runtime';
@@ -32,6 +32,7 @@ import _mapInstanceProperty from '@babel/runtime-corejs3/core-js-stable/instance
32
32
  import _sliceInstanceProperty from '@babel/runtime-corejs3/core-js-stable/instance/slice';
33
33
  import _styled from '@emotion/styled/base';
34
34
  import '@emotion/react';
35
+ import _Object$assign from '@babel/runtime-corejs3/core-js-stable/object/assign';
35
36
  import { parseChunkImport, mapLocaleToIntlLocale } from '@commercetools-frontend/i18n';
36
37
 
37
38
  let CurrentStep$1 = /*#__PURE__*/function (CurrentStep) {
@@ -458,20 +459,6 @@ var messages$6 = defineMessages({
458
459
  }
459
460
  });
460
461
 
461
- function _callSuper$1(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct$1() ? _Reflect$construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
462
- function _isNativeReflectConstruct$1() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct$1 = function () { return !!t; })(); }
463
- let UnexpectedResourceTypeError = /*#__PURE__*/function (_Error) {
464
- function UnexpectedResourceTypeError(resourceType) {
465
- var _this;
466
- _classCallCheck(this, UnexpectedResourceTypeError);
467
- _this = _callSuper$1(this, UnexpectedResourceTypeError, [`Unexpected resource type "${resourceType}"`]);
468
- _this.name = 'UnexpectedResourceTypeError';
469
- return _this;
470
- }
471
- _inherits(UnexpectedResourceTypeError, _Error);
472
- return _createClass(UnexpectedResourceTypeError);
473
- }(/*#__PURE__*/_wrapNativeSuper(Error));
474
-
475
462
  function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? _Reflect$construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
476
463
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(_Reflect$construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function () { return !!t; })(); }
477
464
  let MissingImportResourceProviderError = /*#__PURE__*/function (_Error) {
@@ -662,184 +649,7 @@ var sharedMessages = defineMessages({
662
649
  id: 'ImportResourcesModal.delimiterTab',
663
650
  description: 'Label for the delimiter name tab',
664
651
  defaultMessage: 'tab'
665
- },
666
- // Resource types
667
- product: {
668
- id: 'ImportResourcesModal.product',
669
- description: 'Label for the product resource type',
670
- defaultMessage: 'Product'
671
- },
672
- products: {
673
- id: 'ImportResourcesModal.products',
674
- description: 'Label for the products resource type',
675
- defaultMessage: 'Products'
676
- },
677
- inventory: {
678
- id: 'ImportResourcesModal.inventory',
679
- description: 'Label for the inventory entry resource type',
680
- defaultMessage: 'Inventory'
681
- },
682
- inventories: {
683
- id: 'ImportResourcesModal.inventories',
684
- description: 'Label for the inventories entry resource type',
685
- defaultMessage: 'Inventories'
686
- },
687
- category: {
688
- id: 'ImportResourcesModal.category',
689
- description: 'Label for the category resource type',
690
- defaultMessage: 'Category'
691
- },
692
- categories: {
693
- id: 'ImportResourcesModal.categories',
694
- description: 'Label for the categories resource type',
695
- defaultMessage: 'Categories'
696
- },
697
- 'custom-object': {
698
- id: 'ImportResourcesModal.custom-object',
699
- description: 'Label for the custom-object resource type',
700
- defaultMessage: 'Custom object'
701
- },
702
- 'custom-objects': {
703
- id: 'ImportResourcesModal.custom-objects',
704
- description: 'Label for the custom-objects resource type',
705
- defaultMessage: 'Custom objects'
706
- },
707
- customer: {
708
- id: 'ImportResourcesModal.customer',
709
- description: 'Label for the customer resource type',
710
- defaultMessage: 'Customer'
711
- },
712
- customers: {
713
- id: 'ImportResourcesModal.customers',
714
- description: 'Label for the customers resource type',
715
- defaultMessage: 'Customers'
716
- },
717
- order: {
718
- id: 'ImportResourcesModal.order',
719
- description: 'Label for the order resource type',
720
- defaultMessage: 'Order'
721
- },
722
- orders: {
723
- id: 'ImportResourcesModal.orders',
724
- description: 'Label for the orders resource type',
725
- defaultMessage: 'Orders'
726
- },
727
- 'order-patch': {
728
- id: 'ImportResourcesModal.order-patch',
729
- description: 'Label for the order-patch resource type',
730
- defaultMessage: 'Order patch'
731
- },
732
- 'order-patches': {
733
- id: 'ImportResourcesModal.order-patches',
734
- description: 'Label for the order-patches resource type',
735
- defaultMessage: 'Order patches'
736
- },
737
- price: {
738
- id: 'ImportResourcesModal.price',
739
- description: 'Label for the price resource type',
740
- defaultMessage: 'Price'
741
- },
742
- prices: {
743
- id: 'ImportResourcesModal.prices',
744
- description: 'Label for the prices resource type',
745
- defaultMessage: 'Prices'
746
- },
747
- 'product-draft': {
748
- id: 'ImportResourcesModal.product-draft',
749
- description: 'Label for the product-draft resource type',
750
- defaultMessage: 'Product draft'
751
- },
752
- 'product-drafts': {
753
- id: 'ImportResourcesModal.product-drafts',
754
- description: 'Label for the product-drafts resource type',
755
- defaultMessage: 'Product drafts'
756
- },
757
- 'product-type': {
758
- id: 'ImportResourcesModal.product-type',
759
- description: 'Label for the product-type resource type',
760
- defaultMessage: 'Product type'
761
- },
762
- 'product-types': {
763
- id: 'ImportResourcesModal.product-types',
764
- description: 'Label for the product-types resource type',
765
- defaultMessage: 'Product types'
766
- },
767
- 'product-variant': {
768
- id: 'ImportResourcesModal.product-variant',
769
- description: 'Label for the product-variant resource type',
770
- defaultMessage: 'Product variant'
771
- },
772
- 'product-variants': {
773
- id: 'ImportResourcesModal.product-variants',
774
- description: 'Label for the product-variants resource type',
775
- defaultMessage: 'Product variants'
776
- },
777
- 'product-variant-patch': {
778
- id: 'ImportResourcesModal.product-variant-patch',
779
- description: 'Label for the product-variant-patch resource type',
780
- defaultMessage: 'Product variant patch'
781
- },
782
- 'product-variant-patches': {
783
- id: 'ImportResourcesModal.product-variant-patches',
784
- description: 'Label for the product-variant-patches resource type',
785
- defaultMessage: 'Product variant patches'
786
- },
787
- 'standalone-price': {
788
- id: 'ImportResourcesModal.standalone-price',
789
- description: 'Label for the standalone-price resource type',
790
- defaultMessage: 'Standalone price'
791
- },
792
- 'standalone-prices': {
793
- id: 'ImportResourcesModal.standalone-prices',
794
- description: 'Label for the standalone-prices resource type',
795
- defaultMessage: 'Standalone prices'
796
- },
797
- type: {
798
- id: 'ImportResourcesModal.type',
799
- description: 'Label for the type resource type',
800
- defaultMessage: 'Type'
801
- },
802
- types: {
803
- id: 'ImportResourcesModal.types',
804
- description: 'Label for the types resource type',
805
- defaultMessage: 'Types'
806
- },
807
- 'discount-code': {
808
- id: 'ImportResourcesModal.discount-code',
809
- description: 'Label for the discount-code resource type',
810
- defaultMessage: 'Discount code'
811
- },
812
- 'discount-codes': {
813
- id: 'ImportResourcesModal.discount-codes',
814
- description: 'Label for the discount-codes resource type',
815
- defaultMessage: 'Discount codes'
816
- },
817
- 'business-unit': {
818
- id: 'ImportResourcesModal.business-unit',
819
- description: 'Label for the business-unit resource type',
820
- defaultMessage: 'Business unit'
821
- },
822
- 'business-units': {
823
- id: 'ImportResourcesModal.business-units',
824
- description: 'Label for the business-units resource type',
825
- defaultMessage: 'Business units'
826
- },
827
- 'product-tailoring': {
828
- id: 'ImportResourcesModal.product-tailoring',
829
- description: 'Label for the product-tailoring resource type',
830
- defaultMessage: 'Tailored product'
831
- },
832
- 'product-tailorings': {
833
- id: 'ImportResourcesModal.product-tailorings',
834
- description: 'Label for the product-tailorings resource type',
835
- defaultMessage: 'Tailored products'
836
- },
837
- unknownResourceType: {
838
- id: 'ImportResourcesModal.unknown-resource-type',
839
- description: 'Label for the unknown resource type',
840
- defaultMessage: 'Unknown resource type'
841
652
  }
842
- //
843
653
  });
844
654
 
845
655
  const formatAllowedDelimitersForMessageDisplay = intl => {
@@ -872,60 +682,6 @@ const formatAllowedDelimitersForMessageDisplay = intl => {
872
682
  return `${descriptions.join(', ')} ${localizedOr} ${lastDescription}`;
873
683
  };
874
684
 
875
- function resourceTypeToMessage(resourceType) {
876
- const resourceTypeMap = {
877
- category: sharedMessages.category,
878
- product: sharedMessages.product,
879
- 'product-type': sharedMessages['product-type'],
880
- order: sharedMessages.order,
881
- customer: sharedMessages.customer,
882
- 'discount-code': sharedMessages['discount-code'],
883
- inventory: sharedMessages.inventory,
884
- 'inventory-entry': sharedMessages.inventory,
885
- 'order-patch': sharedMessages['order-patch'],
886
- price: sharedMessages.price,
887
- 'product-draft': sharedMessages['product-draft'],
888
- 'product-variant': sharedMessages['product-variant'],
889
- 'product-variant-patch': sharedMessages['product-variant-patch'],
890
- 'standalone-price': sharedMessages['standalone-price'],
891
- 'custom-object': sharedMessages['custom-object'],
892
- 'business-unit': sharedMessages['business-unit'],
893
- type: sharedMessages.type
894
- };
895
- const message = resourceTypeMap[resourceType];
896
- if (!message) {
897
- console.warn(new UnexpectedResourceTypeError(resourceType));
898
- return sharedMessages.unknownResourceType;
899
- }
900
- return message;
901
- }
902
- function resourceTypeToPluralMessage(resourceType) {
903
- const resourceTypePluralMap = {
904
- category: sharedMessages.categories,
905
- 'custom-object': sharedMessages['custom-objects'],
906
- product: sharedMessages.products,
907
- 'product-type': sharedMessages['product-types'],
908
- order: sharedMessages.orders,
909
- customer: sharedMessages.customers,
910
- 'discount-code': sharedMessages['discount-codes'],
911
- inventory: sharedMessages.inventories,
912
- 'inventory-entry': sharedMessages.inventories,
913
- 'order-patch': sharedMessages['order-patches'],
914
- price: sharedMessages.prices,
915
- 'product-draft': sharedMessages['product-drafts'],
916
- 'product-variant': sharedMessages['product-variants'],
917
- 'product-variant-patch': sharedMessages['product-variant-patches'],
918
- 'standalone-price': sharedMessages['standalone-prices'],
919
- 'business-unit': sharedMessages['business-units']
920
- };
921
- const message = resourceTypePluralMap[resourceType];
922
- if (!message) {
923
- console.warn(new UnexpectedResourceTypeError(resourceType));
924
- return sharedMessages.unknownResourceType;
925
- }
926
- return message;
927
- }
928
-
929
685
  function ownKeys$8(e, r) { var t = _Object$keys(e); if (_Object$getOwnPropertySymbols) { var o = _Object$getOwnPropertySymbols(e); r && (o = _filterInstanceProperty(o).call(o, function (r) { return _Object$getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
930
686
  function _objectSpread$8(e) { for (var r = 1; r < arguments.length; r++) { var _context, _context2; var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? _forEachInstanceProperty(_context = ownKeys$8(Object(t), !0)).call(_context, function (r) { _defineProperty(e, r, t[r]); }) : _Object$getOwnPropertyDescriptors ? _Object$defineProperties(e, _Object$getOwnPropertyDescriptors(t)) : _forEachInstanceProperty(_context2 = ownKeys$8(Object(t))).call(_context2, function (r) { _Object$defineProperty(e, r, _Object$getOwnPropertyDescriptor(t, r)); }); } return e; }
931
687
  const useUpload = () => {
@@ -2176,7 +1932,7 @@ const resourceTypeToDisplayName = resourceType => {
2176
1932
  case IMPORTABLE_RESOURCES.STANDALONE_PRICE:
2177
1933
  return messages$1.standalonePrices;
2178
1934
  default:
2179
- throw new UnexpectedResourceTypeError$1(resourceType);
1935
+ throw new UnexpectedResourceTypeError(resourceType);
2180
1936
  }
2181
1937
  };
2182
1938
  const ResourceTypeSelection = () => {
@@ -2259,10 +2015,10 @@ const getChunkImport = locale => {
2259
2015
  };
2260
2016
  const loadMessages = async locale => {
2261
2017
  try {
2018
+ const operationsSharedMessages = await loadOperationsSharedMessages(locale);
2262
2019
  const chunkImport = await getChunkImport(locale);
2263
- return parseChunkImport(chunkImport);
2020
+ return _Object$assign({}, operationsSharedMessages, parseChunkImport(chunkImport));
2264
2021
  } catch (error) {
2265
- // eslint-disable-next-line no-console
2266
2022
  console.warn(`Something went wrong while loading the import-resources-modal messages for ${locale}`, error);
2267
2023
  reportErrorToSentry(new Error(`Something went wrong while loading the import-resources-modal messages for ${locale}`), {
2268
2024
  extra: error
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@commercetools-frontend-extensions/import-resources-modal",
3
3
  "description": "Shared import modal for importing resources",
4
- "version": "2.3.0",
4
+ "version": "2.3.2",
5
5
  "license": "BSD-3-Clause",
6
6
  "publishConfig": {
7
7
  "access": "public"
@@ -31,7 +31,7 @@
31
31
  "pluralize": "8.0.0",
32
32
  "prop-types": "15.8.1",
33
33
  "ramda": "^0.32.0",
34
- "@commercetools-frontend-extensions/operations": "4.3.0"
34
+ "@commercetools-frontend-extensions/operations": "4.5.0"
35
35
  },
36
36
  "devDependencies": {
37
37
  "@commercetools-frontend/actions-global": "27.5.1",
@@ -60,7 +60,8 @@
60
60
  "react-intl": "7.1.4",
61
61
  "react-redux": "9.2.0",
62
62
  "redux": "5.0.1",
63
- "rimraf": "6.1.2"
63
+ "rimraf": "6.1.2",
64
+ "typescript": "5.4.5"
64
65
  },
65
66
  "peerDependencies": {
66
67
  "@commercetools-frontend/actions-global": "24.x || 25.x || 27.x",