1 const LEGACY_ORDER_INJECTION_ZONES = [
2 "order.details.before",
3 "order.details.after",
4 "order.details.side.before",
5 "order.details.side.after",
6 "order.list.before",
7 "order.list.after",
8 ] as const
9
10 const ORDER_INJECTION_ZONES = [
11 "order.details",
12 "order.details.side",
13 "order.list",
14 ] as const
15
16 const LEGACY_CUSTOMER_INJECTION_ZONES = [
17 "customer.details.before",
18 "customer.details.after",
19 "customer.details.side.before",
20 "customer.details.side.after",
21 "customer.list.before",
22 "customer.list.after",
23 ] as const
24
25 const CUSTOMER_INJECTION_ZONES = [
26 "customer.details",
27 "customer.details.side",
28 "customer.list",
29 ] as const
30
31 const LEGACY_CUSTOMER_GROUP_INJECTION_ZONES = [
32 "customer_group.details.before",
33 "customer_group.details.after",
34 "customer_group.list.before",
35 "customer_group.list.after",
36 ] as const
37
38 const CUSTOMER_GROUP_INJECTION_ZONES = [
39 "customer_group.details",
40 "customer_group.list",
41 ] as const
42
43 const LEGACY_PRODUCT_INJECTION_ZONES = [
44 "product.details.before",
45 "product.details.after",
46 "product.list.before",
47 "product.list.after",
48 "product.details.side.before",
49 "product.details.side.after",
50 ] as const
51
52 const PRODUCT_INJECTION_ZONES = [
53 "product.details",
54 "product.list",
55 "product.details.side",
56 ] as const
57
58 const LEGACY_PRODUCT_VARIANT_INJECTION_ZONES = [
59 "product_variant.details.before",
60 "product_variant.details.after",
61 "product_variant.details.side.before",
62 "product_variant.details.side.after",
63 ] as const
64
65 const PRODUCT_VARIANT_INJECTION_ZONES = [
66 "product_variant.details",
67 "product_variant.details.side",
68 ] as const
69
70 const LEGACY_PRODUCT_COLLECTION_INJECTION_ZONES = [
71 "product_collection.details.before",
72 "product_collection.details.after",
73 "product_collection.list.before",
74 "product_collection.list.after",
75 ] as const
76
77 const PRODUCT_COLLECTION_INJECTION_ZONES = [
78 "product_collection.details",
79 "product_collection.list",
80 ] as const
81
82 const LEGACY_PRODUCT_CATEGORY_INJECTION_ZONES = [
83 "product_category.details.before",
84 "product_category.details.after",
85 "product_category.details.side.before",
86 "product_category.details.side.after",
87 "product_category.list.before",
88 "product_category.list.after",
89 ] as const
90
91 const PRODUCT_CATEGORY_INJECTION_ZONES = [
92 "product_category.details",
93 "product_category.details.side",
94 "product_category.list",
95 ] as const
96
97 const LEGACY_PRODUCT_OPTION_INJECTION_ZONES = [
98 "product_option.details.before",
99 "product_option.details.after",
100 "product_option.details.side.before",
101 "product_option.details.side.after",
102 "product_option.list.before",
103 "product_option.list.after",
104 ] as const
105
106 const PRODUCT_OPTION_INJECTION_ZONES = [
107 "product_option.details",
108 "product_option.list",
109 ] as const
110
111 const LEGACY_PRODUCT_OPTION_VALUE_INJECTION_ZONES = [
112 "product_option_value.details.before",
113 "product_option_value.details.after",
114 ] as const
115
116 const PRODUCT_OPTION_VALUE_INJECTION_ZONES = [
117 "product_option_value.details",
118 ] as const
119
120 const LEGACY_SHIPPING_OPTION_TYPE_INJECTION_ZONES = [
121 "shipping_option_type.details.before",
122 "shipping_option_type.details.after",
123 "shipping_option_type.list.before",
124 "shipping_option_type.list.after",
125 ] as const
126
127 const SHIPPING_OPTION_TYPE_INJECTION_ZONES = [
128 "shipping_option_type.details",
129 "shipping_option_type.list",
130 ] as const
131
132 const LEGACY_PRODUCT_TYPE_INJECTION_ZONES = [
133 "product_type.details.before",
134 "product_type.details.after",
135 "product_type.list.before",
136 "product_type.list.after",
137 ] as const
138
139 const PRODUCT_TYPE_INJECTION_ZONES = [
140 "product_type.details",
141 "product_type.list",
142 ] as const
143
144 const LEGACY_PRODUCT_TAG_INJECTION_ZONES = [
145 "product_tag.details.before",
146 "product_tag.details.after",
147 "product_tag.list.before",
148 "product_tag.list.after",
149 ] as const
150
151 const PRODUCT_TAG_INJECTION_ZONES = [
152 "product_tag.details",
153 "product_tag.list",
154 ] as const
155
156 const LEGACY_PRICE_LIST_INJECTION_ZONES = [
157 "price_list.details.before",
158 "price_list.details.after",
159 "price_list.details.side.before",
160 "price_list.details.side.after",
161 "price_list.list.before",
162 "price_list.list.after",
163 ] as const
164
165 const PRICE_LIST_INJECTION_ZONES = [
166 "price_list.details",
167 "price_list.details.side",
168 "price_list.list",
169 ] as const
170
171 const LEGACY_PROMOTION_INJECTION_ZONES = [
172 "promotion.details.before",
173 "promotion.details.after",
174 "promotion.details.side.before",
175 "promotion.details.side.after",
176 "promotion.list.before",
177 "promotion.list.after",
178 ] as const
179
180 const PROMOTION_INJECTION_ZONES = [
181 "promotion.details",
182 "promotion.details.side",
183 "promotion.list",
184 ] as const
185
186 const LEGACY_CAMPAIGN_INJECTION_ZONES = [
187 "campaign.details.before",
188 "campaign.details.after",
189 "campaign.details.side.before",
190 "campaign.details.side.after",
191 "campaign.list.before",
192 "campaign.list.after",
193 ] as const
194
195 const CAMPAIGN_INJECTION_ZONES = [
196 "campaign.details",
197 "campaign.details.side",
198 "campaign.list",
199 ] as const
200
201 const LEGACY_USER_INJECTION_ZONES = [
202 "user.details.before",
203 "user.details.after",
204 "user.list.before",
205 "user.list.after",
206 ] as const
207
208 const USER_INJECTION_ZONES = ["user.details", "user.list"] as const
209
210 const LEGACY_STORE_INJECTION_ZONES = [
211 "store.details.before",
212 "store.details.after",
213 ] as const
214
215 const STORE_INJECTION_ZONES = ["store.details"] as const
216
217 const LEGACY_PROFILE_INJECTION_ZONES = [
218 "profile.details.before",
219 "profile.details.after",
220 ] as const
221
222 const PROFILE_INJECTION_ZONES = ["profile.details"] as const
223
224 const LEGACY_REGION_INJECTION_ZONES = [
225 "region.details.before",
226 "region.details.after",
227 "region.list.before",
228 "region.list.after",
229 ] as const
230
231 const REGION_INJECTION_ZONES = ["region.details", "region.list"] as const
232
233 const LEGACY_SHIPPING_PROFILE_INJECTION_ZONES = [
234 "shipping_profile.details.before",
235 "shipping_profile.details.after",
236 "shipping_profile.list.before",
237 "shipping_profile.list.after",
238 ] as const
239
240 const SHIPPING_PROFILE_INJECTION_ZONES = [
241 "shipping_profile.details",
242 "shipping_profile.list",
243 ] as const
244
245 const LEGACY_LOCATION_INJECTION_ZONES = [
246 "location.details.before",
247 "location.details.after",
248 "location.details.side.before",
249 "location.details.side.after",
250 "location.list.before",
251 "location.list.after",
252 "location.list.side.before",
253 "location.list.side.after",
254 ] as const
255
256 const LOCATION_INJECTION_ZONES = [
257 "location.details",
258 "location.details.side",
259 "location.list",
260 "location.list.side",
261 ] as const
262
263 const LOGIN_INJECTION_ZONES = ["login.before", "login.after"] as const
264
265 const LEGACY_SALES_CHANNEL_INJECTION_ZONES = [
266 "sales_channel.details.before",
267 "sales_channel.details.after",
268 "sales_channel.list.before",
269 "sales_channel.list.after",
270 ] as const
271
272 const SALES_CHANNEL_INJECTION_ZONES = [
273 "sales_channel.details",
274 "sales_channel.list",
275 ] as const
276
277 const LEGACY_RESERVATION_INJECTION_ZONES = [
278 "reservation.details.before",
279 "reservation.details.after",
280 "reservation.details.side.before",
281 "reservation.details.side.after",
282 "reservation.list.before",
283 "reservation.list.after",
284 ] as const
285
286 const RESERVATION_INJECTION_ZONES = [
287 "reservation.details",
288 "reservation.details.side",
289 "reservation.list",
290 ] as const
291
292 const LEGACY_API_KEY_INJECTION_ZONES = [
293 "api_key.details.before",
294 "api_key.details.after",
295 "api_key.list.before",
296 "api_key.list.after",
297 ] as const
298
299 const API_KEY_INJECTION_ZONES = ["api_key.details", "api_key.list"] as const
300
301 const LEGACY_WORKFLOW_INJECTION_ZONES = [
302 "workflow.details.before",
303 "workflow.details.after",
304 "workflow.list.before",
305 "workflow.list.after",
306 ] as const
307
308 const WORKFLOW_INJECTION_ZONES = ["workflow.details", "workflow.list"] as const
309
310 const SEARCH_INJECTION_ZONES = ["search.list"] as const
311
312 const LEGACY_TAX_INJECTION_ZONES = [
313 "tax.details.before",
314 "tax.details.after",
315 "tax.list.before",
316 "tax.list.after",
317 ] as const
318
319 const TAX_INJECTION_ZONES = ["tax.details", "tax.list"] as const
320
321 const LEGACY_RETURN_REASON_INJECTION_ZONES = [
322 "return_reason.list.before",
323 "return_reason.list.after",
324 ] as const
325
326 const RETURN_REASON_INJECTION_ZONES = ["return_reason.list"] as const
327
328 const LEGACY_REFUND_REASON_INJECTION_ZONES = [
329 "refund_reason.list.before",
330 "refund_reason.list.after",
331 ] as const
332
333 const REFUND_REASON_INJECTION_ZONES = ["refund_reason.list"] as const
334
335 const LEGACY_INVENTORY_ITEM_INJECTION_ZONES = [
336 "inventory_item.details.before",
337 "inventory_item.details.after",
338 "inventory_item.details.side.before",
339 "inventory_item.details.side.after",
340 "inventory_item.list.before",
341 "inventory_item.list.after",
342 ] as const
343
344 const INVENTORY_ITEM_INJECTION_ZONES = [
345 "inventory_item.details",
346 "inventory_item.details.side",
347 "inventory_item.list",
348 ] as const
349
350 const LEGACY_ROLE_INJECTION_ZONES = [
351 "role.details.before",
352 "role.details.after",
353 "role.list.before",
354 "role.list.after",
355 ] as const
356
357 const ROLE_INJECTION_ZONES = ["role.details", "role.list"] as const
358
359 const LEGACY_POLICY_INJECTION_ZONES = [
360 "policy.details.before",
361 "policy.details.after",
362 "policy.list.before",
363 "policy.list.after",
364 ] as const
365
366 const POLICY_INJECTION_ZONES = ["policy.details", "policy.list"] as const
367
368 const LEGACY_DRAFT_ORDER_INJECTION_ZONES = [
369 "draft_order.details.before",
370 "draft_order.details.after",
371 "draft_order.details.side.before",
372 "draft_order.details.side.after",
373 "draft_order.list.before",
374 "draft_order.list.after",
375 ] as const
376
377 const DRAFT_ORDER_INJECTION_ZONES = [
378 "draft_order.details",
379 "draft_order.details.side",
380 "draft_order.list",
381 ] as const
382
383 const LEGACY_STORE_CREDIT_ACCOUNT_INJECTION_ZONES = [
384 "store_credit_account.details.before",
385 "store_credit_account.details.after",
386 "store_credit_account.details.side.before",
387 "store_credit_account.details.side.after",
388 "store_credit_account.list.before",
389 "store_credit_account.list.after",
390 ] as const
391
392 const STORE_CREDIT_ACCOUNT_INJECTION_ZONES = [
393 "store_credit_account.details",
394 "store_credit_account.details.side",
395 "store_credit_account.list",
396 ] as const
397
398 const LEGACY_GIFT_CARD_INJECTION_ZONES = [
399 "gift_card.details.before",
400 "gift_card.details.after",
401 "gift_card.details.side.before",
402 "gift_card.details.side.after",
403 "gift_card.list.before",
404 "gift_card.list.after",
405 "gift_card.list.side.before",
406 "gift_card.list.side.after",
407 ] as const
408
409 const GIFT_CARD_INJECTION_ZONES = [
410 "gift_card.details",
411 "gift_card.details.side",
412 "gift_card.list",
413 "gift_card.list.side",
414 ] as const
415
416 const LEGACY_GIFT_CARD_PRODUCT_INJECTION_ZONES = [
417 "gift_card_product.details.before",
418 "gift_card_product.details.after",
419 "gift_card_product.details.side.before",
420 "gift_card_product.details.side.after",
421 "gift_card_product.list.before",
422 "gift_card_product.list.after",
423 ] as const
424
425 const GIFT_CARD_PRODUCT_INJECTION_ZONES = [
426 "gift_card_product.details",
427 "gift_card_product.details.side",
428 "gift_card_product.list",
429 ] as const
430
431 const PROPERTY_LABEL_INJECTION_ZONES = ["property_label.list"] as const
432
433 const TOPBAR_INJECTION_ZONES = ["topbar"] as const
434
435 /**
436 * All valid injection zones in the admin panel. An injection zone is a specific place
437 * in the admin panel where a plugin can inject custom widgets.
438 */
439 export const INJECTION_ZONES = [
440 ...LEGACY_ORDER_INJECTION_ZONES,
441 ...ORDER_INJECTION_ZONES,
442 ...LEGACY_CUSTOMER_INJECTION_ZONES,
443 ...CUSTOMER_INJECTION_ZONES,
444 ...LEGACY_CUSTOMER_GROUP_INJECTION_ZONES,
445 ...CUSTOMER_GROUP_INJECTION_ZONES,
446 ...LEGACY_PRODUCT_INJECTION_ZONES,
447 ...PRODUCT_INJECTION_ZONES,
448 ...LEGACY_PRODUCT_VARIANT_INJECTION_ZONES,
449 ...PRODUCT_VARIANT_INJECTION_ZONES,
450 ...LEGACY_PRODUCT_COLLECTION_INJECTION_ZONES,
451 ...PRODUCT_COLLECTION_INJECTION_ZONES,
452 ...LEGACY_PRODUCT_CATEGORY_INJECTION_ZONES,
453 ...PRODUCT_CATEGORY_INJECTION_ZONES,
454 ...LEGACY_PRODUCT_TYPE_INJECTION_ZONES,
455 ...PRODUCT_TYPE_INJECTION_ZONES,
456 ...LEGACY_PRODUCT_OPTION_INJECTION_ZONES,
457 ...PRODUCT_OPTION_INJECTION_ZONES,
458 ...LEGACY_PRODUCT_OPTION_VALUE_INJECTION_ZONES,
459 ...PRODUCT_OPTION_VALUE_INJECTION_ZONES,
460 ...LEGACY_SHIPPING_OPTION_TYPE_INJECTION_ZONES,
461 ...SHIPPING_OPTION_TYPE_INJECTION_ZONES,
462 ...LEGACY_PRODUCT_TAG_INJECTION_ZONES,
463 ...PRODUCT_TAG_INJECTION_ZONES,
464 ...LEGACY_PRICE_LIST_INJECTION_ZONES,
465 ...PRICE_LIST_INJECTION_ZONES,
466 ...LEGACY_PROMOTION_INJECTION_ZONES,
467 ...PROMOTION_INJECTION_ZONES,
468 ...LEGACY_USER_INJECTION_ZONES,
469 ...USER_INJECTION_ZONES,
470 ...LEGACY_STORE_INJECTION_ZONES,
471 ...STORE_INJECTION_ZONES,
472 ...LEGACY_PROFILE_INJECTION_ZONES,
473 ...PROFILE_INJECTION_ZONES,
474 ...LEGACY_REGION_INJECTION_ZONES,
475 ...REGION_INJECTION_ZONES,
476 ...LEGACY_SHIPPING_PROFILE_INJECTION_ZONES,
477 ...SHIPPING_PROFILE_INJECTION_ZONES,
478 ...LEGACY_LOCATION_INJECTION_ZONES,
479 ...LOCATION_INJECTION_ZONES,
480 ...LOGIN_INJECTION_ZONES,
481 ...LEGACY_SALES_CHANNEL_INJECTION_ZONES,
482 ...SALES_CHANNEL_INJECTION_ZONES,
483 ...LEGACY_RESERVATION_INJECTION_ZONES,
484 ...RESERVATION_INJECTION_ZONES,
485 ...LEGACY_API_KEY_INJECTION_ZONES,
486 ...API_KEY_INJECTION_ZONES,
487 ...LEGACY_WORKFLOW_INJECTION_ZONES,
488 ...WORKFLOW_INJECTION_ZONES,
489 ...SEARCH_INJECTION_ZONES,
490 ...LEGACY_CAMPAIGN_INJECTION_ZONES,
491 ...CAMPAIGN_INJECTION_ZONES,
492 ...LEGACY_TAX_INJECTION_ZONES,
493 ...TAX_INJECTION_ZONES,
494 ...LEGACY_RETURN_REASON_INJECTION_ZONES,
495 ...RETURN_REASON_INJECTION_ZONES,
496 ...LEGACY_REFUND_REASON_INJECTION_ZONES,
497 ...REFUND_REASON_INJECTION_ZONES,
498 ...LEGACY_INVENTORY_ITEM_INJECTION_ZONES,
499 ...INVENTORY_ITEM_INJECTION_ZONES,
500 ...LEGACY_ROLE_INJECTION_ZONES,
501 ...ROLE_INJECTION_ZONES,
502 ...LEGACY_POLICY_INJECTION_ZONES,
503 ...POLICY_INJECTION_ZONES,
504 ...LEGACY_DRAFT_ORDER_INJECTION_ZONES,
505 ...DRAFT_ORDER_INJECTION_ZONES,
506 ...LEGACY_STORE_CREDIT_ACCOUNT_INJECTION_ZONES,
507 ...STORE_CREDIT_ACCOUNT_INJECTION_ZONES,
508 ...LEGACY_GIFT_CARD_INJECTION_ZONES,
509 ...GIFT_CARD_INJECTION_ZONES,
510 ...LEGACY_GIFT_CARD_PRODUCT_INJECTION_ZONES,
511 ...GIFT_CARD_PRODUCT_INJECTION_ZONES,
512 ...TOPBAR_INJECTION_ZONES,
513 ...PROPERTY_LABEL_INJECTION_ZONES,
514 ] as const