@commercetools-frontend/application-config 22.35.1 → 22.36.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.
@@ -209,7 +209,7 @@
209
209
  "properties": {
210
210
  "locale": {
211
211
  "type": "string",
212
- "enum": ["en", "de", "es", "fr-FR", "pt-BR", "zh-CN"]
212
+ "enum": ["en", "de", "es", "fr-FR", "pt-BR"]
213
213
  },
214
214
  "value": {
215
215
  "type": "string"
@@ -255,7 +255,7 @@
255
255
  "properties": {
256
256
  "locale": {
257
257
  "type": "string",
258
- "enum": ["en", "de", "es", "fr-FR", "pt-BR", "zh-CN"]
258
+ "enum": ["en", "de", "es", "fr-FR", "pt-BR"]
259
259
  },
260
260
  "value": {
261
261
  "type": "string"
@@ -197,7 +197,7 @@
197
197
  "properties": {
198
198
  "locale": {
199
199
  "type": "string",
200
- "enum": ["en", "de", "es", "fr-FR", "pt-BR", "zh-CN"]
200
+ "enum": ["en", "de", "es", "fr-FR", "pt-BR"]
201
201
  },
202
202
  "value": {
203
203
  "type": "string"
@@ -87,34 +87,22 @@ const CLOUD_IDENTIFIERS = {
87
87
  /**
88
88
  * @deprecated: use `AWS_US` instead
89
89
  */
90
- AWS_OHIO: 'aws-ohio',
91
- /**
92
- * @deprecated: not supported anymore
93
- */
94
- AWS_CN: 'aws-cn',
95
- AZURE_US: 'azure-us',
96
- AZURE_EU: 'azure-eu'
90
+ AWS_OHIO: 'aws-ohio'
97
91
  };
98
92
  const MC_API_URLS = {
99
- GCP_AU: 'https://mc-api.australia-southeast1.gcp.commercetools.com',
100
- GCP_EU: 'https://mc-api.europe-west1.gcp.commercetools.com',
101
- GCP_US: 'https://mc-api.us-central1.gcp.commercetools.com',
102
- AWS_EU: 'https://mc-api.eu-central-1.aws.commercetools.com',
103
- AWS_US: 'https://mc-api.us-east-2.aws.commercetools.com',
93
+ [CLOUD_IDENTIFIERS.GCP_AU]: 'https://mc-api.australia-southeast1.gcp.commercetools.com',
94
+ [CLOUD_IDENTIFIERS.GCP_EU]: 'https://mc-api.europe-west1.gcp.commercetools.com',
95
+ [CLOUD_IDENTIFIERS.GCP_US]: 'https://mc-api.us-central1.gcp.commercetools.com',
96
+ [CLOUD_IDENTIFIERS.AWS_EU]: 'https://mc-api.eu-central-1.aws.commercetools.com',
97
+ [CLOUD_IDENTIFIERS.AWS_US]: 'https://mc-api.us-east-2.aws.commercetools.com',
104
98
  /**
105
99
  * @deprecated: use `AWS_EU` instead
106
100
  */
107
- AWS_FRA: 'https://mc-api.eu-central-1.aws.commercetools.com',
101
+ [CLOUD_IDENTIFIERS.AWS_FRA]: 'https://mc-api.eu-central-1.aws.commercetools.com',
108
102
  /**
109
103
  * @deprecated: use `AWS_US` instead
110
104
  */
111
- AWS_OHIO: 'https://mc-api.us-east-2.aws.commercetools.com',
112
- /**
113
- * @deprecated: not supported anymore
114
- */
115
- AWS_CN: 'https://mc-api.cn-northwest-1.aws.commercetools.cn',
116
- AZURE_US: 'https://mc-api.eastus.azure.commercetools.com',
117
- AZURE_EU: 'https://mc-api.germanywestcentral.azure.commercetools.com'
105
+ [CLOUD_IDENTIFIERS.AWS_OHIO]: 'https://mc-api.us-east-2.aws.commercetools.com'
118
106
  };
119
107
  const LOADED_CONFIG_TYPES = {
120
108
  CUSTOM_APPLICATION: 'custom-application',
@@ -537,8 +525,7 @@ var customApplicationSchemaJson = {
537
525
  "de",
538
526
  "es",
539
527
  "fr-FR",
540
- "pt-BR",
541
- "zh-CN"
528
+ "pt-BR"
542
529
  ]
543
530
  },
544
531
  value: {
@@ -600,8 +587,7 @@ var customApplicationSchemaJson = {
600
587
  "de",
601
588
  "es",
602
589
  "fr-FR",
603
- "pt-BR",
604
- "zh-CN"
590
+ "pt-BR"
605
591
  ]
606
592
  },
607
593
  value: {
@@ -878,8 +864,7 @@ var customViewSchemaJson = {
878
864
  "de",
879
865
  "es",
880
866
  "fr-FR",
881
- "pt-BR",
882
- "zh-CN"
867
+ "pt-BR"
883
868
  ]
884
869
  },
885
870
  value: {
@@ -1102,24 +1087,17 @@ function transformConfigurationToData(configType, configuration) {
1102
1087
  const mapCloudIdentifierToApiUrl = key => {
1103
1088
  switch (key) {
1104
1089
  case CLOUD_IDENTIFIERS.GCP_AU:
1105
- return MC_API_URLS.GCP_AU;
1090
+ return MC_API_URLS[CLOUD_IDENTIFIERS.GCP_AU];
1106
1091
  case CLOUD_IDENTIFIERS.GCP_EU:
1107
- return MC_API_URLS.GCP_EU;
1092
+ return MC_API_URLS[CLOUD_IDENTIFIERS.GCP_EU];
1108
1093
  case CLOUD_IDENTIFIERS.GCP_US:
1109
- return MC_API_URLS.GCP_US;
1094
+ return MC_API_URLS[CLOUD_IDENTIFIERS.GCP_US];
1110
1095
  case CLOUD_IDENTIFIERS.AWS_EU:
1111
1096
  case CLOUD_IDENTIFIERS.AWS_FRA:
1112
- return MC_API_URLS.AWS_EU;
1097
+ return MC_API_URLS[CLOUD_IDENTIFIERS.AWS_EU];
1113
1098
  case CLOUD_IDENTIFIERS.AWS_US:
1114
1099
  case CLOUD_IDENTIFIERS.AWS_OHIO:
1115
- return MC_API_URLS.AWS_US;
1116
- // TODO: remove it
1117
- case CLOUD_IDENTIFIERS.AWS_CN:
1118
- return MC_API_URLS.AWS_CN;
1119
- case CLOUD_IDENTIFIERS.AZURE_US:
1120
- return MC_API_URLS.AZURE_US;
1121
- case CLOUD_IDENTIFIERS.AZURE_EU:
1122
- return MC_API_URLS.AZURE_EU;
1100
+ return MC_API_URLS[CLOUD_IDENTIFIERS.AWS_US];
1123
1101
  default:
1124
1102
  // We would probably never get to this point, as the JSON schema validation
1125
1103
  // kicks in before.
@@ -87,34 +87,22 @@ const CLOUD_IDENTIFIERS = {
87
87
  /**
88
88
  * @deprecated: use `AWS_US` instead
89
89
  */
90
- AWS_OHIO: 'aws-ohio',
91
- /**
92
- * @deprecated: not supported anymore
93
- */
94
- AWS_CN: 'aws-cn',
95
- AZURE_US: 'azure-us',
96
- AZURE_EU: 'azure-eu'
90
+ AWS_OHIO: 'aws-ohio'
97
91
  };
98
92
  const MC_API_URLS = {
99
- GCP_AU: 'https://mc-api.australia-southeast1.gcp.commercetools.com',
100
- GCP_EU: 'https://mc-api.europe-west1.gcp.commercetools.com',
101
- GCP_US: 'https://mc-api.us-central1.gcp.commercetools.com',
102
- AWS_EU: 'https://mc-api.eu-central-1.aws.commercetools.com',
103
- AWS_US: 'https://mc-api.us-east-2.aws.commercetools.com',
93
+ [CLOUD_IDENTIFIERS.GCP_AU]: 'https://mc-api.australia-southeast1.gcp.commercetools.com',
94
+ [CLOUD_IDENTIFIERS.GCP_EU]: 'https://mc-api.europe-west1.gcp.commercetools.com',
95
+ [CLOUD_IDENTIFIERS.GCP_US]: 'https://mc-api.us-central1.gcp.commercetools.com',
96
+ [CLOUD_IDENTIFIERS.AWS_EU]: 'https://mc-api.eu-central-1.aws.commercetools.com',
97
+ [CLOUD_IDENTIFIERS.AWS_US]: 'https://mc-api.us-east-2.aws.commercetools.com',
104
98
  /**
105
99
  * @deprecated: use `AWS_EU` instead
106
100
  */
107
- AWS_FRA: 'https://mc-api.eu-central-1.aws.commercetools.com',
101
+ [CLOUD_IDENTIFIERS.AWS_FRA]: 'https://mc-api.eu-central-1.aws.commercetools.com',
108
102
  /**
109
103
  * @deprecated: use `AWS_US` instead
110
104
  */
111
- AWS_OHIO: 'https://mc-api.us-east-2.aws.commercetools.com',
112
- /**
113
- * @deprecated: not supported anymore
114
- */
115
- AWS_CN: 'https://mc-api.cn-northwest-1.aws.commercetools.cn',
116
- AZURE_US: 'https://mc-api.eastus.azure.commercetools.com',
117
- AZURE_EU: 'https://mc-api.germanywestcentral.azure.commercetools.com'
105
+ [CLOUD_IDENTIFIERS.AWS_OHIO]: 'https://mc-api.us-east-2.aws.commercetools.com'
118
106
  };
119
107
  const LOADED_CONFIG_TYPES = {
120
108
  CUSTOM_APPLICATION: 'custom-application',
@@ -537,8 +525,7 @@ var customApplicationSchemaJson = {
537
525
  "de",
538
526
  "es",
539
527
  "fr-FR",
540
- "pt-BR",
541
- "zh-CN"
528
+ "pt-BR"
542
529
  ]
543
530
  },
544
531
  value: {
@@ -600,8 +587,7 @@ var customApplicationSchemaJson = {
600
587
  "de",
601
588
  "es",
602
589
  "fr-FR",
603
- "pt-BR",
604
- "zh-CN"
590
+ "pt-BR"
605
591
  ]
606
592
  },
607
593
  value: {
@@ -878,8 +864,7 @@ var customViewSchemaJson = {
878
864
  "de",
879
865
  "es",
880
866
  "fr-FR",
881
- "pt-BR",
882
- "zh-CN"
867
+ "pt-BR"
883
868
  ]
884
869
  },
885
870
  value: {
@@ -1102,24 +1087,17 @@ function transformConfigurationToData(configType, configuration) {
1102
1087
  const mapCloudIdentifierToApiUrl = key => {
1103
1088
  switch (key) {
1104
1089
  case CLOUD_IDENTIFIERS.GCP_AU:
1105
- return MC_API_URLS.GCP_AU;
1090
+ return MC_API_URLS[CLOUD_IDENTIFIERS.GCP_AU];
1106
1091
  case CLOUD_IDENTIFIERS.GCP_EU:
1107
- return MC_API_URLS.GCP_EU;
1092
+ return MC_API_URLS[CLOUD_IDENTIFIERS.GCP_EU];
1108
1093
  case CLOUD_IDENTIFIERS.GCP_US:
1109
- return MC_API_URLS.GCP_US;
1094
+ return MC_API_URLS[CLOUD_IDENTIFIERS.GCP_US];
1110
1095
  case CLOUD_IDENTIFIERS.AWS_EU:
1111
1096
  case CLOUD_IDENTIFIERS.AWS_FRA:
1112
- return MC_API_URLS.AWS_EU;
1097
+ return MC_API_URLS[CLOUD_IDENTIFIERS.AWS_EU];
1113
1098
  case CLOUD_IDENTIFIERS.AWS_US:
1114
1099
  case CLOUD_IDENTIFIERS.AWS_OHIO:
1115
- return MC_API_URLS.AWS_US;
1116
- // TODO: remove it
1117
- case CLOUD_IDENTIFIERS.AWS_CN:
1118
- return MC_API_URLS.AWS_CN;
1119
- case CLOUD_IDENTIFIERS.AZURE_US:
1120
- return MC_API_URLS.AZURE_US;
1121
- case CLOUD_IDENTIFIERS.AZURE_EU:
1122
- return MC_API_URLS.AZURE_EU;
1100
+ return MC_API_URLS[CLOUD_IDENTIFIERS.AWS_US];
1123
1101
  default:
1124
1102
  // We would probably never get to this point, as the JSON schema validation
1125
1103
  // kicks in before.
@@ -55,34 +55,22 @@ const CLOUD_IDENTIFIERS = {
55
55
  /**
56
56
  * @deprecated: use `AWS_US` instead
57
57
  */
58
- AWS_OHIO: 'aws-ohio',
59
- /**
60
- * @deprecated: not supported anymore
61
- */
62
- AWS_CN: 'aws-cn',
63
- AZURE_US: 'azure-us',
64
- AZURE_EU: 'azure-eu'
58
+ AWS_OHIO: 'aws-ohio'
65
59
  };
66
60
  const MC_API_URLS = {
67
- GCP_AU: 'https://mc-api.australia-southeast1.gcp.commercetools.com',
68
- GCP_EU: 'https://mc-api.europe-west1.gcp.commercetools.com',
69
- GCP_US: 'https://mc-api.us-central1.gcp.commercetools.com',
70
- AWS_EU: 'https://mc-api.eu-central-1.aws.commercetools.com',
71
- AWS_US: 'https://mc-api.us-east-2.aws.commercetools.com',
61
+ [CLOUD_IDENTIFIERS.GCP_AU]: 'https://mc-api.australia-southeast1.gcp.commercetools.com',
62
+ [CLOUD_IDENTIFIERS.GCP_EU]: 'https://mc-api.europe-west1.gcp.commercetools.com',
63
+ [CLOUD_IDENTIFIERS.GCP_US]: 'https://mc-api.us-central1.gcp.commercetools.com',
64
+ [CLOUD_IDENTIFIERS.AWS_EU]: 'https://mc-api.eu-central-1.aws.commercetools.com',
65
+ [CLOUD_IDENTIFIERS.AWS_US]: 'https://mc-api.us-east-2.aws.commercetools.com',
72
66
  /**
73
67
  * @deprecated: use `AWS_EU` instead
74
68
  */
75
- AWS_FRA: 'https://mc-api.eu-central-1.aws.commercetools.com',
69
+ [CLOUD_IDENTIFIERS.AWS_FRA]: 'https://mc-api.eu-central-1.aws.commercetools.com',
76
70
  /**
77
71
  * @deprecated: use `AWS_US` instead
78
72
  */
79
- AWS_OHIO: 'https://mc-api.us-east-2.aws.commercetools.com',
80
- /**
81
- * @deprecated: not supported anymore
82
- */
83
- AWS_CN: 'https://mc-api.cn-northwest-1.aws.commercetools.cn',
84
- AZURE_US: 'https://mc-api.eastus.azure.commercetools.com',
85
- AZURE_EU: 'https://mc-api.germanywestcentral.azure.commercetools.com'
73
+ [CLOUD_IDENTIFIERS.AWS_OHIO]: 'https://mc-api.us-east-2.aws.commercetools.com'
86
74
  };
87
75
  const LOADED_CONFIG_TYPES = {
88
76
  CUSTOM_APPLICATION: 'custom-application',
@@ -505,8 +493,7 @@ var customApplicationSchemaJson = {
505
493
  "de",
506
494
  "es",
507
495
  "fr-FR",
508
- "pt-BR",
509
- "zh-CN"
496
+ "pt-BR"
510
497
  ]
511
498
  },
512
499
  value: {
@@ -568,8 +555,7 @@ var customApplicationSchemaJson = {
568
555
  "de",
569
556
  "es",
570
557
  "fr-FR",
571
- "pt-BR",
572
- "zh-CN"
558
+ "pt-BR"
573
559
  ]
574
560
  },
575
561
  value: {
@@ -846,8 +832,7 @@ var customViewSchemaJson = {
846
832
  "de",
847
833
  "es",
848
834
  "fr-FR",
849
- "pt-BR",
850
- "zh-CN"
835
+ "pt-BR"
851
836
  ]
852
837
  },
853
838
  value: {
@@ -1070,24 +1055,17 @@ function transformConfigurationToData(configType, configuration) {
1070
1055
  const mapCloudIdentifierToApiUrl = key => {
1071
1056
  switch (key) {
1072
1057
  case CLOUD_IDENTIFIERS.GCP_AU:
1073
- return MC_API_URLS.GCP_AU;
1058
+ return MC_API_URLS[CLOUD_IDENTIFIERS.GCP_AU];
1074
1059
  case CLOUD_IDENTIFIERS.GCP_EU:
1075
- return MC_API_URLS.GCP_EU;
1060
+ return MC_API_URLS[CLOUD_IDENTIFIERS.GCP_EU];
1076
1061
  case CLOUD_IDENTIFIERS.GCP_US:
1077
- return MC_API_URLS.GCP_US;
1062
+ return MC_API_URLS[CLOUD_IDENTIFIERS.GCP_US];
1078
1063
  case CLOUD_IDENTIFIERS.AWS_EU:
1079
1064
  case CLOUD_IDENTIFIERS.AWS_FRA:
1080
- return MC_API_URLS.AWS_EU;
1065
+ return MC_API_URLS[CLOUD_IDENTIFIERS.AWS_EU];
1081
1066
  case CLOUD_IDENTIFIERS.AWS_US:
1082
1067
  case CLOUD_IDENTIFIERS.AWS_OHIO:
1083
- return MC_API_URLS.AWS_US;
1084
- // TODO: remove it
1085
- case CLOUD_IDENTIFIERS.AWS_CN:
1086
- return MC_API_URLS.AWS_CN;
1087
- case CLOUD_IDENTIFIERS.AZURE_US:
1088
- return MC_API_URLS.AZURE_US;
1089
- case CLOUD_IDENTIFIERS.AZURE_EU:
1090
- return MC_API_URLS.AZURE_EU;
1068
+ return MC_API_URLS[CLOUD_IDENTIFIERS.AWS_US];
1091
1069
  default:
1092
1070
  // We would probably never get to this point, as the JSON schema validation
1093
1071
  // kicks in before.
@@ -12,33 +12,21 @@ export declare const CLOUD_IDENTIFIERS: {
12
12
  * @deprecated: use `AWS_US` instead
13
13
  */
14
14
  readonly AWS_OHIO: "aws-ohio";
15
- /**
16
- * @deprecated: not supported anymore
17
- */
18
- readonly AWS_CN: "aws-cn";
19
- readonly AZURE_US: "azure-us";
20
- readonly AZURE_EU: "azure-eu";
21
15
  };
22
16
  export declare const MC_API_URLS: {
23
- readonly GCP_AU: "https://mc-api.australia-southeast1.gcp.commercetools.com";
24
- readonly GCP_EU: "https://mc-api.europe-west1.gcp.commercetools.com";
25
- readonly GCP_US: "https://mc-api.us-central1.gcp.commercetools.com";
26
- readonly AWS_EU: "https://mc-api.eu-central-1.aws.commercetools.com";
27
- readonly AWS_US: "https://mc-api.us-east-2.aws.commercetools.com";
17
+ readonly "gcp-au": "https://mc-api.australia-southeast1.gcp.commercetools.com";
18
+ readonly "gcp-eu": "https://mc-api.europe-west1.gcp.commercetools.com";
19
+ readonly "gcp-us": "https://mc-api.us-central1.gcp.commercetools.com";
20
+ readonly "aws-eu": "https://mc-api.eu-central-1.aws.commercetools.com";
21
+ readonly "aws-us": "https://mc-api.us-east-2.aws.commercetools.com";
28
22
  /**
29
23
  * @deprecated: use `AWS_EU` instead
30
24
  */
31
- readonly AWS_FRA: "https://mc-api.eu-central-1.aws.commercetools.com";
25
+ readonly "aws-fra": "https://mc-api.eu-central-1.aws.commercetools.com";
32
26
  /**
33
27
  * @deprecated: use `AWS_US` instead
34
28
  */
35
- readonly AWS_OHIO: "https://mc-api.us-east-2.aws.commercetools.com";
36
- /**
37
- * @deprecated: not supported anymore
38
- */
39
- readonly AWS_CN: "https://mc-api.cn-northwest-1.aws.commercetools.cn";
40
- readonly AZURE_US: "https://mc-api.eastus.azure.commercetools.com";
41
- readonly AZURE_EU: "https://mc-api.germanywestcentral.azure.commercetools.com";
29
+ readonly "aws-ohio": "https://mc-api.us-east-2.aws.commercetools.com";
42
30
  };
43
31
  export declare const LOADED_CONFIG_TYPES: {
44
32
  readonly CUSTOM_APPLICATION: "custom-application";
@@ -125,7 +125,7 @@ export interface JSONSchemaForCustomApplicationConfigurationFiles {
125
125
  * See https://docs.commercetools.com/merchant-center-customizations/api-reference/custom-application-config#mainmenulinklabelalllocales
126
126
  */
127
127
  labelAllLocales: {
128
- locale: 'en' | 'de' | 'es' | 'fr-FR' | 'pt-BR' | 'zh-CN';
128
+ locale: 'en' | 'de' | 'es' | 'fr-FR' | 'pt-BR';
129
129
  value: string;
130
130
  }[];
131
131
  /**
@@ -150,7 +150,7 @@ export interface JSONSchemaForCustomApplicationConfigurationFiles {
150
150
  * See https://docs.commercetools.com/merchant-center-customizations/api-reference/custom-application-config#submenulinkslabelalllocales
151
151
  */
152
152
  labelAllLocales: {
153
- locale: 'en' | 'de' | 'es' | 'fr-FR' | 'pt-BR' | 'zh-CN';
153
+ locale: 'en' | 'de' | 'es' | 'fr-FR' | 'pt-BR';
154
154
  value: string;
155
155
  }[];
156
156
  /**
@@ -113,7 +113,7 @@ export interface JSONSchemaForCustomViewConfigurationFiles {
113
113
  * See https://docs.commercetools.com/TODO
114
114
  */
115
115
  labelAllLocales: {
116
- locale: 'en' | 'de' | 'es' | 'fr-FR' | 'pt-BR' | 'zh-CN';
116
+ locale: 'en' | 'de' | 'es' | 'fr-FR' | 'pt-BR';
117
117
  value: string;
118
118
  }[];
119
119
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@commercetools-frontend/application-config",
3
- "version": "22.35.1",
3
+ "version": "22.36.0",
4
4
  "description": "Configuration utilities for building Custom Applications",
5
5
  "bugs": "https://github.com/commercetools/merchant-center-application-kit/issues",
6
6
  "repository": {
@@ -45,8 +45,8 @@
45
45
  "@babel/register": "^7.22.15",
46
46
  "@babel/runtime": "^7.22.15",
47
47
  "@babel/runtime-corejs3": "^7.22.15",
48
- "@commercetools-frontend/babel-preset-mc-app": "22.35.1",
49
- "@commercetools-frontend/constants": "22.35.1",
48
+ "@commercetools-frontend/babel-preset-mc-app": "22.36.0",
49
+ "@commercetools-frontend/constants": "22.36.0",
50
50
  "@types/dompurify": "^2.4.0",
51
51
  "@types/lodash": "^4.14.198",
52
52
  "@types/react": "^17.0.80",
@@ -62,7 +62,7 @@
62
62
  "@types/jsdom": "^21.1.2",
63
63
  "json-schema-to-typescript": "13.1.2",
64
64
  "shelljs": "0.8.5",
65
- "@commercetools-frontend/assets": "22.35.1"
65
+ "@commercetools-frontend/assets": "22.36.0"
66
66
  },
67
67
  "engines": {
68
68
  "node": "16.x || >=18.0.0"