@medusajs/dashboard 3.0.0-snapshot-20251211173847 → 3.0.0-snapshot-20251211180009

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.
Files changed (248) hide show
  1. package/dist/{add-campaign-promotions-JQKPED4U.mjs → add-campaign-promotions-PHAHMGXP.mjs} +2 -2
  2. package/dist/{adjust-inventory-2MFA656V.mjs → adjust-inventory-I5VYMAI4.mjs} +2 -2
  3. package/dist/{api-key-management-create-ZUVF3SLR.mjs → api-key-management-create-CVRFY4PL.mjs} +2 -2
  4. package/dist/{api-key-management-detail-I45X6X64.mjs → api-key-management-detail-G7O7TDPW.mjs} +6 -6
  5. package/dist/{api-key-management-edit-42HNUSXL.mjs → api-key-management-edit-JMU3WEPX.mjs} +2 -2
  6. package/dist/{api-key-management-sales-channels-7FVABESO.mjs → api-key-management-sales-channels-4OU5VGIG.mjs} +2 -2
  7. package/dist/app.css +35 -0
  8. package/dist/app.js +13072 -12057
  9. package/dist/app.mjs +4 -4
  10. package/dist/{campaign-budget-edit-6DMZGUCI.mjs → campaign-budget-edit-B5MSE26J.mjs} +2 -2
  11. package/dist/{campaign-configuration-UNFRB5HR.mjs → campaign-configuration-QOE3D2BE.mjs} +2 -2
  12. package/dist/{campaign-create-QXG7PD3S.mjs → campaign-create-FJOECKGT.mjs} +3 -3
  13. package/dist/{campaign-detail-P3CSDHZN.mjs → campaign-detail-I2N5WUEC.mjs} +3 -3
  14. package/dist/{campaign-edit-HN4US7DV.mjs → campaign-edit-K2POQH7M.mjs} +2 -2
  15. package/dist/{categories-metadata-BCZ463KN.mjs → categories-metadata-DNVBNWAJ.mjs} +6 -6
  16. package/dist/{category-create-FFIBWXAH.mjs → category-create-L2KJCHPO.mjs} +2 -2
  17. package/dist/{category-detail-VDUHW3QT.mjs → category-detail-XEFMQSZG.mjs} +24 -8
  18. package/dist/{category-edit-74MZ6TXN.mjs → category-edit-U6SLZSAX.mjs} +2 -2
  19. package/dist/{category-list-AH2EGTI7.mjs → category-list-W7JW4PWA.mjs} +16 -1
  20. package/dist/{category-organize-B6EFBFKB.mjs → category-organize-LLSVAO3U.mjs} +2 -2
  21. package/dist/{category-products-VOD3XRPG.mjs → category-products-LF7P7MBF.mjs} +8 -8
  22. package/dist/{chunk-PNPT4W2F.mjs → chunk-3BJLNORD.mjs} +1 -1
  23. package/dist/{chunk-QPKW37WR.mjs → chunk-3ESSTIV2.mjs} +188 -13
  24. package/dist/{chunk-F5NZDW7L.mjs → chunk-4VNR7DND.mjs} +2 -2
  25. package/dist/chunk-4Y2NYEXF.mjs +0 -0
  26. package/dist/{chunk-Q6MSICBU.mjs → chunk-6GLZIACV.mjs} +1 -1
  27. package/dist/{chunk-M4Z2YEYB.mjs → chunk-7GJ5T4R3.mjs} +9 -9
  28. package/dist/{chunk-YAPTGHGP.mjs → chunk-AFXODJBA.mjs} +1 -1
  29. package/dist/{chunk-3YPRDSZ6.mjs → chunk-BZKI5J2M.mjs} +1 -1
  30. package/dist/{chunk-UM4OIJZ3.mjs → chunk-CFQNWTZV.mjs} +1 -1
  31. package/dist/{chunk-42OOM4DJ.mjs → chunk-D6UW7URG.mjs} +23 -6
  32. package/dist/{chunk-HFT7Q5Y5.mjs → chunk-DCYB22MH.mjs} +1 -1
  33. package/dist/{chunk-LHNU4DYZ.mjs → chunk-DS5IRNJY.mjs} +2 -2
  34. package/dist/{chunk-B3AOQW2B.mjs → chunk-EQBVGH3N.mjs} +1 -1
  35. package/dist/{chunk-EQTBJSBZ.mjs → chunk-F5I264Q3.mjs} +3 -0
  36. package/dist/{chunk-W7SLPIO2.mjs → chunk-FEB3ZGTL.mjs} +214 -17
  37. package/dist/{chunk-Z6NHG5LQ.mjs → chunk-FIFVOKTK.mjs} +1 -1
  38. package/dist/{chunk-4YAPXPLM.mjs → chunk-FPBKWWSI.mjs} +1 -1
  39. package/dist/{chunk-RU4ZS47V.mjs → chunk-GN6OCHP4.mjs} +1 -11
  40. package/dist/{chunk-YWLAUILP.mjs → chunk-HPPR6PXK.mjs} +4 -4
  41. package/dist/{chunk-HWKLNKOY.mjs → chunk-I6C52ARQ.mjs} +1 -1
  42. package/dist/{chunk-F63F3FIT.mjs → chunk-JJGE3EV6.mjs} +2 -2
  43. package/dist/chunk-JQBWAJQZ.mjs +0 -0
  44. package/dist/{chunk-KF7ZWW4K.mjs → chunk-LCEKY54O.mjs} +2 -2
  45. package/dist/{chunk-D4J3CEWH.mjs → chunk-N3SAXQVR.mjs} +2 -2
  46. package/dist/{chunk-EI27JC4V.mjs → chunk-PS5T2R6J.mjs} +3 -3
  47. package/dist/{chunk-MY6I7UJG.mjs → chunk-R2EBIESZ.mjs} +1 -1
  48. package/dist/{chunk-25UWYEJX.mjs → chunk-RKUXD6IZ.mjs} +1 -1
  49. package/dist/{chunk-SKA4AJO4.mjs → chunk-UEJOY5PF.mjs} +3 -3
  50. package/dist/{chunk-XXBP2Z5M.mjs → chunk-WVA4O7QS.mjs} +1 -1
  51. package/dist/{chunk-L4NOVTH5.mjs → chunk-YIOBBZUB.mjs} +2 -2
  52. package/dist/{chunk-GTPX2T3A.mjs → chunk-ZADXDNB3.mjs} +234 -202
  53. package/dist/{collection-add-products-P5B564HQ.mjs → collection-add-products-EM7SAFEH.mjs} +8 -8
  54. package/dist/{collection-create-DCRW344Z.mjs → collection-create-4JX4YE47.mjs} +2 -2
  55. package/dist/{collection-detail-PCL3HYPB.mjs → collection-detail-UQXMMKRW.mjs} +22 -7
  56. package/dist/{collection-edit-UNFEW6HT.mjs → collection-edit-MXL35GQQ.mjs} +2 -2
  57. package/dist/{collection-list-ANPFZOFP.mjs → collection-list-EO56ZH4Q.mjs} +29 -14
  58. package/dist/{collection-metadata-P4A5DXBQ.mjs → collection-metadata-UXEYXJY4.mjs} +6 -6
  59. package/dist/{customer-create-XCLZENJS.mjs → customer-create-IA56MXE6.mjs} +2 -2
  60. package/dist/{customer-create-address-4HZUIAM7.mjs → customer-create-address-27M25HTO.mjs} +2 -2
  61. package/dist/{customer-detail-ENPJO3DW.mjs → customer-detail-OD5I5YWW.mjs} +6 -6
  62. package/dist/{customer-edit-BW5GVTQI.mjs → customer-edit-XQ5NWIVX.mjs} +2 -2
  63. package/dist/{customer-group-add-customers-A7OGFFJ4.mjs → customer-group-add-customers-FRJP6RCY.mjs} +5 -5
  64. package/dist/{customer-group-create-6YV7W6TI.mjs → customer-group-create-RY4FVEIW.mjs} +2 -2
  65. package/dist/{customer-group-detail-DVNRFZX5.mjs → customer-group-detail-SOWUWFJ4.mjs} +6 -6
  66. package/dist/{customer-group-edit-7NXU34BQ.mjs → customer-group-edit-MQWARIQZ.mjs} +2 -2
  67. package/dist/{customer-group-list-P2QX5AO4.mjs → customer-group-list-A5LER6CN.mjs} +3 -3
  68. package/dist/{customer-group-metadata-WK2BGEGO.mjs → customer-group-metadata-JQJRLLXG.mjs} +3 -3
  69. package/dist/{customer-metadata-ZUWCUTM7.mjs → customer-metadata-HN2DYD5I.mjs} +3 -3
  70. package/dist/{customers-add-customer-group-RVR476OP.mjs → customers-add-customer-group-75EEIDW6.mjs} +8 -8
  71. package/dist/{edit-inventory-item-Y5W6VTHJ.mjs → edit-inventory-item-RATTNP2Y.mjs} +2 -2
  72. package/dist/{edit-inventory-item-attributes-NAAZDFEJ.mjs → edit-inventory-item-attributes-JHH5GSNL.mjs} +2 -2
  73. package/dist/{edit-reservation-2UD4RZJX.mjs → edit-reservation-UZCSNLHY.mjs} +2 -2
  74. package/dist/{edit-rules-2W3BXEXR.mjs → edit-rules-IKV4MGHV.mjs} +5 -5
  75. package/dist/en.json +12 -12
  76. package/dist/{inventory-create-VQEK7C5T.mjs → inventory-create-DBD7EA7N.mjs} +6 -6
  77. package/dist/{inventory-detail-UYDDNO24.mjs → inventory-detail-Q2HAUD2Y.mjs} +3 -3
  78. package/dist/{inventory-metadata-X52VGHA7.mjs → inventory-metadata-NQXJBGAQ.mjs} +6 -6
  79. package/dist/{inventory-stock-EKTOYN2F.mjs → inventory-stock-WAZ7CXTY.mjs} +7 -7
  80. package/dist/{invite-VKHAAF4Z.mjs → invite-WISVECE2.mjs} +3 -2
  81. package/dist/{location-create-RPLEXUZR.mjs → location-create-WZ43K3W7.mjs} +2 -2
  82. package/dist/{location-detail-UVWYE6Q2.mjs → location-detail-2LKEMZ3X.mjs} +11 -9
  83. package/dist/{location-edit-L4ISEQHX.mjs → location-edit-VCS7GVWQ.mjs} +2 -2
  84. package/dist/{location-fulfillment-providers-3BGI2NNW.mjs → location-fulfillment-providers-6WNUCXQL.mjs} +6 -6
  85. package/dist/{location-list-Z42ZYHUF.mjs → location-list-UK3WRDL5.mjs} +3 -2
  86. package/dist/{location-sales-channels-YMABMECM.mjs → location-sales-channels-NKNM5TQK.mjs} +2 -2
  87. package/dist/{location-service-zone-create-NSMZCD5N.mjs → location-service-zone-create-3FWF3DG5.mjs} +3 -3
  88. package/dist/{location-service-zone-edit-6OUAFEZD.mjs → location-service-zone-edit-KHHMSPXD.mjs} +2 -2
  89. package/dist/{location-service-zone-manage-areas-SEC6LKCZ.mjs → location-service-zone-manage-areas-YFEAZUUN.mjs} +3 -3
  90. package/dist/{location-service-zone-shipping-option-create-M7G4SKNP.mjs → location-service-zone-shipping-option-create-DSLYSNY4.mjs} +7 -7
  91. package/dist/{location-service-zone-shipping-option-edit-M2HJAASG.mjs → location-service-zone-shipping-option-edit-QCURIIGL.mjs} +5 -5
  92. package/dist/{location-service-zone-shipping-option-pricing-23QLNSBT.mjs → location-service-zone-shipping-option-pricing-Z5IFOLFJ.mjs} +4 -4
  93. package/dist/{login-NSCAMAU6.mjs → login-2DAZRDSC.mjs} +6 -5
  94. package/dist/{manage-locations-JD6FSBOT.mjs → manage-locations-MLNMPQ5I.mjs} +2 -2
  95. package/dist/{order-allocate-items-5T57NZOB.mjs → order-allocate-items-I5KMPZY5.mjs} +3 -3
  96. package/dist/{order-create-claim-JLCXZNHU.mjs → order-create-claim-E543W2TJ.mjs} +7 -7
  97. package/dist/{order-create-edit-QB6LIWSF.mjs → order-create-edit-HDWLEUKF.mjs} +6 -6
  98. package/dist/{order-create-exchange-GOU4AJXP.mjs → order-create-exchange-HBQWTMXR.mjs} +13 -13
  99. package/dist/{order-create-fulfillment-SRRP6X64.mjs → order-create-fulfillment-PN3HLLB2.mjs} +5 -5
  100. package/dist/{order-create-refund-PTOM65QK.mjs → order-create-refund-EC7XRI5O.mjs} +5 -5
  101. package/dist/{order-create-return-3EOY7TOC.mjs → order-create-return-LTGYASZZ.mjs} +4 -4
  102. package/dist/{order-create-shipment-HNILNFXB.mjs → order-create-shipment-CPEAPIJU.mjs} +5 -5
  103. package/dist/{order-detail-BCBUUVU7.mjs → order-detail-MPNBAUUI.mjs} +11 -11
  104. package/dist/{order-edit-billing-address-3IO7GXIK.mjs → order-edit-billing-address-KMV6RJ6F.mjs} +5 -5
  105. package/dist/{order-edit-email-QIAEOUBV.mjs → order-edit-email-377D6O22.mjs} +5 -5
  106. package/dist/{order-edit-shipping-address-QGGMHGBC.mjs → order-edit-shipping-address-HEFMKAJP.mjs} +5 -5
  107. package/dist/{order-list-BPCVUIVY.mjs → order-list-QOYJFYD5.mjs} +71 -29
  108. package/dist/{order-metadata-ZBDTMBHZ.mjs → order-metadata-QABOWLXK.mjs} +6 -6
  109. package/dist/{order-receive-return-V42FTCFY.mjs → order-receive-return-4WFBZ2T7.mjs} +6 -6
  110. package/dist/{order-request-transfer-A6NNIN2O.mjs → order-request-transfer-ISZSSGKO.mjs} +5 -5
  111. package/dist/{price-list-configuration-54D4JW6G.mjs → price-list-configuration-WZFAJ7ZM.mjs} +4 -4
  112. package/dist/{price-list-create-5DI6QXFL.mjs → price-list-create-DQFXQ247.mjs} +15 -15
  113. package/dist/{price-list-detail-7XY3MDV5.mjs → price-list-detail-WWJPFIT2.mjs} +6 -6
  114. package/dist/{price-list-edit-SW7YIR3Z.mjs → price-list-edit-I5QNCWJP.mjs} +2 -2
  115. package/dist/{price-list-prices-add-UA2DT4AM.mjs → price-list-prices-add-6BCDF4DE.mjs} +10 -10
  116. package/dist/{price-list-prices-edit-C6SX2TLJ.mjs → price-list-prices-edit-Z4YJ4YBY.mjs} +4 -4
  117. package/dist/{product-attributes-56UMJAVF.mjs → product-attributes-RKEXUYKR.mjs} +6 -6
  118. package/dist/{product-create-NWQ7IXC6.mjs → product-create-S7YVI2MR.mjs} +7 -7
  119. package/dist/{product-create-option-GEGQNSMQ.mjs → product-create-option-UMZKRNTC.mjs} +2 -2
  120. package/dist/{product-create-variant-WI6D5CDG.mjs → product-create-variant-JRKDSU6D.mjs} +6 -6
  121. package/dist/{product-detail-VYXHGYKI.mjs → product-detail-G7ZVDV46.mjs} +52 -10
  122. package/dist/{product-edit-N4VRGX43.mjs → product-edit-CMHKUDQP.mjs} +6 -6
  123. package/dist/{product-edit-option-HBIOBQTS.mjs → product-edit-option-ZMTSLRG5.mjs} +2 -2
  124. package/dist/{product-export-CPL66H6S.mjs → product-export-H7KYYMGI.mjs} +15 -15
  125. package/dist/{product-image-variants-edit-X3LUMPLJ.mjs → product-image-variants-edit-HU6NVV6T.mjs} +5 -5
  126. package/dist/{product-import-43UXKCL3.mjs → product-import-5PKTI7YC.mjs} +5 -5
  127. package/dist/{product-list-47T2IZ3F.mjs → product-list-ABFSFWKV.mjs} +19 -7
  128. package/dist/{product-media-EGK66SRX.mjs → product-media-ULNJ7JJY.mjs} +2 -2
  129. package/dist/{product-metadata-55CAQTPS.mjs → product-metadata-GHL5HV37.mjs} +6 -6
  130. package/dist/{product-organization-YVMSAFBV.mjs → product-organization-Z7SXABDX.mjs} +6 -6
  131. package/dist/{product-prices-WQDE4XYT.mjs → product-prices-5WCCQDS6.mjs} +3 -3
  132. package/dist/{product-sales-channels-ZICOOOKY.mjs → product-sales-channels-2PN4L7II.mjs} +2 -2
  133. package/dist/{product-shipping-profile-KIDRTPWA.mjs → product-shipping-profile-45XXB7FM.mjs} +2 -2
  134. package/dist/{product-stock-22S2HGMM.mjs → product-stock-NHC7WD6Z.mjs} +7 -7
  135. package/dist/{product-tag-create-7GPE246H.mjs → product-tag-create-MQ6AUCQM.mjs} +5 -5
  136. package/dist/{product-tag-detail-BQG2LJK6.mjs → product-tag-detail-CGURSGJE.mjs} +31 -16
  137. package/dist/{product-tag-edit-WA6FGSIP.mjs → product-tag-edit-TOJYTW4H.mjs} +5 -5
  138. package/dist/{product-tag-list-PW7WDCQH.mjs → product-tag-list-2U4CIGK5.mjs} +31 -16
  139. package/dist/{product-tag-metadata-EJ7FEXSE.mjs → product-tag-metadata-JMFWGTR3.mjs} +6 -6
  140. package/dist/{product-type-create-HBDROTGB.mjs → product-type-create-KHSNCQCV.mjs} +2 -2
  141. package/dist/{product-type-detail-TJQS4BVU.mjs → product-type-detail-UY6Y3T3G.mjs} +22 -7
  142. package/dist/{product-type-edit-H3JCMVRV.mjs → product-type-edit-3LRBWZ3S.mjs} +2 -2
  143. package/dist/{product-type-list-7WQ5D2KV.mjs → product-type-list-XU6DADMO.mjs} +19 -4
  144. package/dist/{product-type-metadata-Q6W5GL7Z.mjs → product-type-metadata-EGMTZ622.mjs} +6 -6
  145. package/dist/{product-variant-detail-LYGQDASG.mjs → product-variant-detail-5EKVJXUT.mjs} +21 -5
  146. package/dist/{product-variant-edit-BW7QMHC5.mjs → product-variant-edit-KKLHPWXO.mjs} +5 -5
  147. package/dist/{product-variant-manage-inventory-items-BLHCH6QD.mjs → product-variant-manage-inventory-items-OGM64KYP.mjs} +2 -2
  148. package/dist/{product-variant-media-KLSUISGH.mjs → product-variant-media-C3KCFODU.mjs} +2 -2
  149. package/dist/{product-variant-metadata-GDMVC4MZ.mjs → product-variant-metadata-LBOIYBBF.mjs} +6 -6
  150. package/dist/{profile-edit-5EEKOEO5.mjs → profile-edit-YZCUGEXF.mjs} +2 -2
  151. package/dist/{promotion-add-campaign-JRTM7WBR.mjs → promotion-add-campaign-DO67QK6M.mjs} +3 -3
  152. package/dist/{promotion-create-HF6DTKCC.mjs → promotion-create-U6CJPBYU.mjs} +12 -12
  153. package/dist/{promotion-detail-MDVDMQUM.mjs → promotion-detail-BYXN4YXZ.mjs} +3 -3
  154. package/dist/{promotion-edit-details-AREFQ6O5.mjs → promotion-edit-details-6BSOOWQN.mjs} +2 -2
  155. package/dist/{refund-reason-create-RKIH46D6.mjs → refund-reason-create-TFC4T4GK.mjs} +5 -5
  156. package/dist/{refund-reason-edit-V3KC6NMO.mjs → refund-reason-edit-WTM7WR5V.mjs} +5 -5
  157. package/dist/{refund-reason-list-FR7POQS5.mjs → refund-reason-list-7Q6WDYH6.mjs} +4 -4
  158. package/dist/{region-add-countries-AFWXMQ6W.mjs → region-add-countries-7U4J5RW6.mjs} +2 -2
  159. package/dist/{region-create-YC4VZ4AS.mjs → region-create-IUGX33M5.mjs} +2 -2
  160. package/dist/{region-edit-5GO25GDF.mjs → region-edit-WAU347DP.mjs} +2 -2
  161. package/dist/{region-metadata-5NGUNAXZ.mjs → region-metadata-EGOMWMMB.mjs} +6 -6
  162. package/dist/{reservation-create-Z2SUMBGT.mjs → reservation-create-C6HTEF3R.mjs} +2 -2
  163. package/dist/{reservation-detail-JH77TQHN.mjs → reservation-detail-FYS6LFU6.mjs} +3 -3
  164. package/dist/{reservation-metadata-ERCWXYVL.mjs → reservation-metadata-LZJV35OW.mjs} +6 -6
  165. package/dist/{reset-password-5TAYQEUV.mjs → reset-password-XKX43KUT.mjs} +3 -2
  166. package/dist/{return-reason-create-NXWDC6AC.mjs → return-reason-create-HM54WRJY.mjs} +2 -2
  167. package/dist/{return-reason-edit-M6IKNNKB.mjs → return-reason-edit-VSIRHVQ6.mjs} +2 -2
  168. package/dist/return-reason-list-IFFIDA5O.mjs +1 -1
  169. package/dist/{sales-channel-add-products-SPGDWA44.mjs → sales-channel-add-products-XPS4JTBL.mjs} +8 -8
  170. package/dist/{sales-channel-create-E7BDTPWD.mjs → sales-channel-create-4XLJDVJO.mjs} +2 -2
  171. package/dist/{sales-channel-detail-D7VNPSCN.mjs → sales-channel-detail-5YUELAQ5.mjs} +6 -6
  172. package/dist/{sales-channel-edit-HMPA3Y3L.mjs → sales-channel-edit-UZGSXD5X.mjs} +2 -2
  173. package/dist/{sales-channel-list-QGWQVXVW.mjs → sales-channel-list-N3KDOVBS.mjs} +3 -3
  174. package/dist/{sales-channel-metadata-CMZN74K7.mjs → sales-channel-metadata-MU4BVKOJ.mjs} +6 -6
  175. package/dist/{shipping-option-type-create-4BN2GBHP.mjs → shipping-option-type-create-AS4AVWZV.mjs} +5 -5
  176. package/dist/{shipping-option-type-detail-YB3TCED2.mjs → shipping-option-type-detail-MCFL4BJE.mjs} +4 -4
  177. package/dist/{shipping-option-type-edit-MDO7ALAU.mjs → shipping-option-type-edit-PJOD3TA4.mjs} +5 -5
  178. package/dist/{shipping-option-type-list-6TPD3AMM.mjs → shipping-option-type-list-VD567MQD.mjs} +4 -4
  179. package/dist/{shipping-profile-create-752TMBBE.mjs → shipping-profile-create-26R64I3Z.mjs} +2 -2
  180. package/dist/{shipping-profile-metadata-HQI7PCPU.mjs → shipping-profile-metadata-6MHI75CB.mjs} +6 -6
  181. package/dist/{store-add-currencies-3VMLZ6KB.mjs → store-add-currencies-ZFS3WZHG.mjs} +2 -2
  182. package/dist/{store-add-locales-XJJCEO6Q.mjs → store-add-locales-ERJXWD4L.mjs} +4 -4
  183. package/dist/{store-detail-DNK76PXP.mjs → store-detail-EGDXIVWC.mjs} +3 -3
  184. package/dist/{store-edit-EPAHLLKP.mjs → store-edit-AB5CDUTK.mjs} +2 -2
  185. package/dist/{store-metadata-ZJD23O4D.mjs → store-metadata-ZBUQ62YT.mjs} +6 -6
  186. package/dist/{tax-region-create-NCO2OQ3I.mjs → tax-region-create-N4YVNQKV.mjs} +5 -5
  187. package/dist/{tax-region-detail-C42CLE64.mjs → tax-region-detail-UJASYH57.mjs} +23 -22
  188. package/dist/{tax-region-edit-YZALLSZY.mjs → tax-region-edit-W3B5EUCJ.mjs} +5 -5
  189. package/dist/{tax-region-list-BXZBUXRJ.mjs → tax-region-list-4MQMCMKY.mjs} +4 -3
  190. package/dist/{tax-region-province-create-5JP3PVID.mjs → tax-region-province-create-GKJ7WMRS.mjs} +2 -2
  191. package/dist/{tax-region-province-detail-G2DPC6XM.mjs → tax-region-province-detail-K4PDPHXP.mjs} +22 -21
  192. package/dist/{tax-region-tax-override-create-WIVKENVO.mjs → tax-region-tax-override-create-NUI4Z76X.mjs} +16 -16
  193. package/dist/{tax-region-tax-override-edit-UDEO3UIY.mjs → tax-region-tax-override-edit-Q4GJHUMJ.mjs} +17 -17
  194. package/dist/{tax-region-tax-rate-create-O2SDSXCH.mjs → tax-region-tax-rate-create-MECFGVPL.mjs} +2 -2
  195. package/dist/{tax-region-tax-rate-edit-W62VEVKT.mjs → tax-region-tax-rate-edit-7DYSPYOD.mjs} +2 -2
  196. package/dist/translation-list-5ZOAGLCT.mjs +146 -0
  197. package/dist/translations-edit-QPJLE55N.mjs +390 -0
  198. package/dist/{user-edit-LXQCTDGA.mjs → user-edit-ZBB4RMTP.mjs} +2 -2
  199. package/dist/{user-invite-2OKB7SCF.mjs → user-invite-XB635N26.mjs} +2 -2
  200. package/dist/{user-metadata-4WOICEE7.mjs → user-metadata-2FTA4EB3.mjs} +6 -6
  201. package/dist/{workflow-execution-detail-OKM6P4SX.mjs → workflow-execution-detail-MGIZSKVA.mjs} +3 -3
  202. package/package.json +9 -9
  203. package/src/components/common/icon-avatar/icon-avatar.tsx +4 -0
  204. package/src/components/data-grid/components/data-grid-textarea-modal-cell.tsx +233 -0
  205. package/src/components/data-grid/components/index.ts +1 -0
  206. package/src/components/data-grid/data-grid.tsx +2 -0
  207. package/src/components/layout/settings-layout/settings-layout.tsx +11 -1
  208. package/src/components/modals/route-focus-modal/route-focus-modal.tsx +8 -3
  209. package/src/components/modals/route-modal-form/route-modal-form.tsx +6 -1
  210. package/src/components/modals/route-modal-provider/route-provider.tsx +16 -4
  211. package/src/dashboard-app/routes/get-route.map.tsx +20 -6
  212. package/src/hooks/api/index.ts +1 -0
  213. package/src/hooks/api/orders.tsx +1 -18
  214. package/src/hooks/api/product-variants.tsx +7 -1
  215. package/src/hooks/api/translations.tsx +254 -0
  216. package/src/i18n/translations/$schema.json +36 -40
  217. package/src/i18n/translations/en.json +12 -12
  218. package/src/i18n/translations/es.json +12 -0
  219. package/src/routes/categories/category-detail/components/category-general-section/category-general-section.tsx +16 -1
  220. package/src/routes/categories/category-list/components/category-list-table/category-list-table.tsx +16 -1
  221. package/src/routes/collections/collection-detail/components/collection-general-section/collection-general-section.tsx +16 -1
  222. package/src/routes/collections/collection-list/components/collection-list-table/collection-row-actions.tsx +16 -1
  223. package/src/routes/orders/order-list/components/order-list-table/configurable-order-list-table.tsx +0 -10
  224. package/src/routes/orders/order-list/components/order-list-table/order-list-table.tsx +2 -8
  225. package/src/routes/product-tags/product-tag-detail/components/product-tag-general-section/product-tag-general-section.tsx +16 -1
  226. package/src/routes/product-tags/product-tag-list/components/product-tag-list-table/product-tag-list-table.tsx +16 -1
  227. package/src/routes/product-types/product-type-detail/components/product-type-general-section/product-type-general-section.tsx +16 -1
  228. package/src/routes/product-types/product-type-list/components/product-type-list-table/product-table-row-actions.tsx +16 -1
  229. package/src/routes/product-variants/product-variant-detail/components/variant-general-section/variant-general-section.tsx +16 -1
  230. package/src/routes/products/product-detail/components/product-general-section/product-general-section.tsx +16 -1
  231. package/src/routes/products/product-detail/components/product-variant-section/product-variant-section.tsx +32 -1
  232. package/src/routes/products/product-list/components/product-list-table/product-list-table.tsx +15 -1
  233. package/src/routes/translations/translation-list/index.tsx +1 -0
  234. package/src/routes/translations/translation-list/translation-list.tsx +131 -0
  235. package/src/routes/translations/translations-edit/components/translations-edit-form/index.ts +1 -0
  236. package/src/routes/translations/translations-edit/components/translations-edit-form/translations-edit-form.tsx +423 -0
  237. package/src/routes/translations/translations-edit/index.ts +1 -0
  238. package/src/routes/translations/translations-edit/translations-edit.tsx +67 -0
  239. package/src/routes/translations/translations-edit/utils/index.ts +1 -0
  240. package/src/routes/translations/translations-edit/utils/reference-label-map.ts +10 -0
  241. package/dist/chunk-35LSPN2U.mjs +0 -66
  242. package/dist/order-export-LPAWHHSK.mjs +0 -121
  243. package/src/routes/orders/order-export/components/export-filters.tsx +0 -22
  244. package/src/routes/orders/order-export/index.ts +0 -1
  245. package/src/routes/orders/order-export/order-export.tsx +0 -66
  246. package/dist/{chunk-6WKBBTKM.mjs → chunk-CTUJXJYA.mjs} +0 -0
  247. package/dist/{customer-list-TG4D4QOT.mjs → customer-list-ZXCGIXJC.mjs} +3 -3
  248. package/dist/{region-list-JAQXIBYD.mjs → region-list-XQRIBDMF.mjs} +3 -3
@@ -0,0 +1,423 @@
1
+ import { zodResolver } from "@hookform/resolvers/zod"
2
+ import { AdminStoreLocale, HttpTypes } from "@medusajs/types"
3
+ import { Button, ProgressTabs, toast } from "@medusajs/ui"
4
+ import { ColumnDef } from "@tanstack/react-table"
5
+ import { useMemo, useRef } from "react"
6
+ import { useForm } from "react-hook-form"
7
+ import { useTranslation } from "react-i18next"
8
+ import { z } from "zod"
9
+
10
+ import {
11
+ createDataGridHelper,
12
+ DataGrid,
13
+ } from "../../../../../components/data-grid"
14
+ import {
15
+ RouteFocusModal,
16
+ useRouteModal,
17
+ } from "../../../../../components/modals"
18
+ import { KeyboundForm } from "../../../../../components/utilities/keybound-form"
19
+ import { useBatchTranslations } from "../../../../../hooks/api/translations"
20
+ import { useDocumentDirection } from "../../../../../hooks/use-document-direction"
21
+ import { REFERENCE_LABEL_MAP } from "../../utils"
22
+
23
+ /**
24
+ * Schema for a single locale translation (subrow in DataGrid).
25
+ */
26
+ const LocaleTranslationSchema = z.object({
27
+ id: z.string().nullish(),
28
+ locale_code: z.string(),
29
+ fields: z.record(z.string().optional()),
30
+ })
31
+ export type LocaleTranslationSchema = z.infer<typeof LocaleTranslationSchema>
32
+
33
+ /**
34
+ * Schema for an entity's translations (parent row in DataGrid).
35
+ * Contains all locale translations for that entity.
36
+ */
37
+ const EntityTranslationsSchema = z.object({
38
+ locales: z.record(LocaleTranslationSchema),
39
+ })
40
+ export type EntityTranslationsSchema = z.infer<typeof EntityTranslationsSchema>
41
+
42
+ /**
43
+ * Form schema
44
+ * Maps each reference_id to their corresponding translations for each locale
45
+ */
46
+ export const TranslationsFormSchema = z.object({
47
+ entities: z.record(EntityTranslationsSchema),
48
+ })
49
+ export type TranslationsFormSchema = z.infer<typeof TranslationsFormSchema>
50
+
51
+ /**
52
+ * Row types for the DataGrid.
53
+ * Parent rows are entities, subrows are locale translations.
54
+ */
55
+ export type TranslationRow = EntityRow | LocaleRow
56
+
57
+ export type EntityRow = {
58
+ _type: "entity"
59
+ reference_id: string
60
+ subRows: LocaleRow[]
61
+ }
62
+
63
+ export type LocaleRow = {
64
+ _type: "locale"
65
+ reference_id: string
66
+ locale_code: string
67
+ locale_name: string
68
+ id?: string
69
+ }
70
+
71
+ export function isEntityRow(row: TranslationRow): row is EntityRow {
72
+ return row._type === "entity"
73
+ }
74
+
75
+ export function isLocaleRow(row: TranslationRow): row is LocaleRow {
76
+ return row._type === "locale"
77
+ }
78
+
79
+ function initTranslationsFormState(
80
+ translations: HttpTypes.AdminTranslation[],
81
+ references: { id: string; [key: string]: string }[],
82
+ availableLocales: AdminStoreLocale[],
83
+ translatableFields: string[]
84
+ ): TranslationsFormSchema {
85
+ const existingMap = new Map<string, HttpTypes.AdminTranslation>()
86
+ for (const t of translations) {
87
+ existingMap.set(`${t.reference_id}:${t.locale_code}`, t)
88
+ }
89
+
90
+ const entitiesTranslationState: Record<string, EntityTranslationsSchema> = {}
91
+
92
+ for (const reference of references) {
93
+ const locales: Record<string, LocaleTranslationSchema> = {}
94
+
95
+ for (const locale of availableLocales) {
96
+ const key = `${reference.id}:${locale.locale_code}`
97
+ const existing = existingMap.get(key)
98
+ const isDefaultLocale = locale.is_default
99
+
100
+ const fields: Record<string, string> = {}
101
+ for (const fieldName of translatableFields) {
102
+ const fieldValue = isDefaultLocale
103
+ ? (existing?.translations?.[fieldName] as string) ??
104
+ reference[fieldName]
105
+ : (existing?.translations?.[fieldName] as string) ?? ""
106
+ fields[fieldName] = fieldValue
107
+ }
108
+
109
+ locales[locale.locale_code] = {
110
+ id: existing?.id ?? null,
111
+ locale_code: locale.locale_code,
112
+ fields,
113
+ }
114
+ }
115
+
116
+ entitiesTranslationState[reference.id] = { locales }
117
+ }
118
+
119
+ return {
120
+ entities: entitiesTranslationState,
121
+ }
122
+ }
123
+
124
+ function buildTranslationRows(
125
+ references: { id: string; [key: string]: string }[],
126
+ availableLocales: AdminStoreLocale[],
127
+ translations: HttpTypes.AdminTranslation[]
128
+ ): TranslationRow[] {
129
+ // Index existing translations by reference_id:locale_code
130
+ const existingMap = new Map<string, HttpTypes.AdminTranslation>()
131
+ for (const t of translations) {
132
+ existingMap.set(`${t.reference_id}:${t.locale_code}`, t)
133
+ }
134
+
135
+ return references.map((reference) => ({
136
+ _type: "entity" as const,
137
+ reference_id: reference.id,
138
+ subRows: availableLocales.map((locale) => {
139
+ const key = `${reference.id}:${locale.locale_code}`
140
+ const existing = existingMap.get(key)
141
+ return {
142
+ _type: "locale" as const,
143
+ reference_id: reference.id,
144
+ locale_code: locale.locale_code,
145
+ locale_name: locale.locale.name,
146
+ id: existing?.id,
147
+ }
148
+ }),
149
+ }))
150
+ }
151
+
152
+ function transformToBatchPayload(
153
+ currentState: TranslationsFormSchema,
154
+ initialState: TranslationsFormSchema,
155
+ entityType: string
156
+ ): Required<HttpTypes.AdminBatchTranslations> {
157
+ const payload: Required<HttpTypes.AdminBatchTranslations> = {
158
+ create: [],
159
+ update: [],
160
+ delete: [],
161
+ }
162
+
163
+ for (const [entityId, entityData] of Object.entries(currentState.entities)) {
164
+ for (const [localeCode, localeTranslations] of Object.entries(
165
+ entityData.locales
166
+ )) {
167
+ const initial = initialState.entities[entityId]?.locales[localeCode]
168
+ const hasContent = Object.values(localeTranslations.fields).some(
169
+ (v) => v !== undefined && v.trim() !== ""
170
+ )
171
+ const hadContent =
172
+ initial &&
173
+ Object.values(initial.fields).some(
174
+ (v) => v !== undefined && v.trim() !== ""
175
+ )
176
+
177
+ if (!localeTranslations.id && hasContent) {
178
+ payload.create.push({
179
+ reference_id: entityId,
180
+ reference: entityType,
181
+ locale_code: localeTranslations.locale_code,
182
+ translations: localeTranslations.fields,
183
+ })
184
+ } else if (localeTranslations.id && hasContent) {
185
+ // UPDATE: Has ID and has content - check if changed
186
+ const hasChanged =
187
+ !initial ||
188
+ JSON.stringify(localeTranslations.fields) !==
189
+ JSON.stringify(initial.fields)
190
+
191
+ if (hasChanged) {
192
+ payload.update.push({
193
+ id: localeTranslations.id,
194
+ translations: localeTranslations.fields,
195
+ })
196
+ }
197
+ } else if (localeTranslations.id && !hasContent && hadContent) {
198
+ payload.delete.push(localeTranslations.id)
199
+ }
200
+ }
201
+ }
202
+
203
+ return payload
204
+ }
205
+
206
+ const columnHelper = createDataGridHelper<
207
+ TranslationRow,
208
+ TranslationsFormSchema
209
+ >()
210
+
211
+ function useTranslationsGridColumns({
212
+ translatableFields,
213
+ modalFields = [],
214
+ }: {
215
+ translatableFields: string[]
216
+ modalFields?: string[]
217
+ }) {
218
+ const { t } = useTranslation()
219
+
220
+ const columns: ColumnDef<TranslationRow>[] = useMemo(() => {
221
+ return [
222
+ columnHelper.column({
223
+ id: "locale",
224
+ header: t("translations.bulk.mainColumn"),
225
+ cell: (context) => {
226
+ const row = context.row.original
227
+
228
+ if (isEntityRow(row)) {
229
+ return (
230
+ <DataGrid.ReadonlyCell context={context}></DataGrid.ReadonlyCell>
231
+ )
232
+ }
233
+
234
+ return (
235
+ <DataGrid.ReadonlyCell context={context} color="normal">
236
+ <div className="flex h-full w-full items-center gap-x-2 overflow-hidden">
237
+ <span className="truncate">{row.locale_name}</span>
238
+ </div>
239
+ </DataGrid.ReadonlyCell>
240
+ )
241
+ },
242
+ disableHiding: true,
243
+ }),
244
+ ...translatableFields.map((fieldName) => {
245
+ const useModal = modalFields.includes(fieldName)
246
+
247
+ return columnHelper.column({
248
+ id: fieldName,
249
+ header: t(`fields.${fieldName}`, { defaultValue: fieldName }),
250
+ cell: (context) => {
251
+ const row = context.row.original
252
+
253
+ if (isEntityRow(row)) {
254
+ return (
255
+ <DataGrid.ReadonlyCell context={context}>
256
+ <span className="text-ui-fg-muted">—</span>
257
+ </DataGrid.ReadonlyCell>
258
+ )
259
+ }
260
+
261
+ if (useModal) {
262
+ return (
263
+ <DataGrid.ExpandableTextCell
264
+ context={context}
265
+ fieldLabel={fieldName}
266
+ />
267
+ )
268
+ }
269
+
270
+ return <DataGrid.TextCell context={context} />
271
+ },
272
+ field: (context) => {
273
+ const row = context.row.original
274
+
275
+ if (isEntityRow(row)) {
276
+ return null
277
+ }
278
+
279
+ return `entities.${row.reference_id}.locales.${row.locale_code}.fields.${fieldName}`
280
+ },
281
+ type: "text",
282
+ })
283
+ }),
284
+ ]
285
+ }, [t, translatableFields, modalFields])
286
+
287
+ return columns
288
+ }
289
+
290
+ type TranslationsEditFormProps = {
291
+ translations: HttpTypes.AdminTranslation[]
292
+ references: { id: string; [key: string]: string }[]
293
+ entityType: string
294
+ availableLocales: AdminStoreLocale[]
295
+ translatableFields: string[]
296
+ modalFields?: string[]
297
+ }
298
+
299
+ export const TranslationsEditForm = ({
300
+ translations,
301
+ references,
302
+ entityType,
303
+ availableLocales,
304
+ translatableFields,
305
+ modalFields = [],
306
+ }: TranslationsEditFormProps) => {
307
+ const { t } = useTranslation()
308
+ const { handleSuccess, setCloseOnEscape } = useRouteModal()
309
+ const direction = useDocumentDirection()
310
+
311
+ const entities = useMemo(() => references, [references])
312
+
313
+ const initialState = useRef(
314
+ initTranslationsFormState(
315
+ translations,
316
+ entities,
317
+ availableLocales,
318
+ translatableFields
319
+ )
320
+ )
321
+
322
+ const form = useForm<TranslationsFormSchema>({
323
+ resolver: zodResolver(TranslationsFormSchema),
324
+ defaultValues: initialState.current,
325
+ })
326
+
327
+ const rows = useMemo(
328
+ () => buildTranslationRows(entities, availableLocales, translations),
329
+ [entities, availableLocales, translations]
330
+ )
331
+
332
+ const { mutateAsync, isPending } = useBatchTranslations(entityType)
333
+
334
+ const handleSubmit = form.handleSubmit(async (values) => {
335
+ const payload = transformToBatchPayload(
336
+ values,
337
+ initialState.current,
338
+ entityType
339
+ )
340
+
341
+ if (
342
+ payload.create.length === 0 &&
343
+ payload.update.length === 0 &&
344
+ payload.delete.length === 0
345
+ ) {
346
+ toast.info(
347
+ t("translations.noChanges", { defaultValue: "No changes to save" })
348
+ )
349
+ return
350
+ }
351
+
352
+ await mutateAsync(payload, {
353
+ onSuccess: () => {
354
+ toast.success(
355
+ t("translations.edit.successToast", {
356
+ defaultValue: "Translations updated successfully",
357
+ })
358
+ )
359
+ handleSuccess()
360
+ },
361
+ onError: (error) => {
362
+ toast.error(error.message)
363
+ },
364
+ })
365
+ })
366
+
367
+ const columns = useTranslationsGridColumns({
368
+ translatableFields,
369
+ modalFields,
370
+ })
371
+
372
+ return (
373
+ <RouteFocusModal.Form form={form}>
374
+ <KeyboundForm onSubmit={handleSubmit} className="flex h-full flex-col">
375
+ <ProgressTabs
376
+ dir={direction}
377
+ defaultValue={entityType}
378
+ className="flex h-full flex-col overflow-hidden"
379
+ >
380
+ <RouteFocusModal.Header>
381
+ <div className="-my-2 w-full border-l">
382
+ <ProgressTabs.List className="justify-start-start flex w-full items-center">
383
+ <ProgressTabs.Trigger value={entityType}>
384
+ {REFERENCE_LABEL_MAP[entityType]}
385
+ </ProgressTabs.Trigger>
386
+ </ProgressTabs.List>
387
+ </div>
388
+ </RouteFocusModal.Header>
389
+ <RouteFocusModal.Body className="size-full overflow-hidden">
390
+ <ProgressTabs.Content
391
+ value={entityType}
392
+ className="size-full overflow-y-auto"
393
+ >
394
+ <DataGrid
395
+ columns={columns}
396
+ data={rows}
397
+ getSubRows={(row) => {
398
+ if (isEntityRow(row)) {
399
+ return row.subRows
400
+ }
401
+ }}
402
+ state={form}
403
+ onEditingChange={(editing) => setCloseOnEscape(!editing)}
404
+ />
405
+ </ProgressTabs.Content>
406
+ </RouteFocusModal.Body>
407
+ <RouteFocusModal.Footer>
408
+ <div className="flex items-center justify-end gap-x-2">
409
+ <RouteFocusModal.Close asChild>
410
+ <Button size="small" variant="secondary">
411
+ {t("actions.cancel")}
412
+ </Button>
413
+ </RouteFocusModal.Close>
414
+ <Button size="small" type="submit" isLoading={isPending}>
415
+ {t("actions.save")}
416
+ </Button>
417
+ </div>
418
+ </RouteFocusModal.Footer>
419
+ </ProgressTabs>
420
+ </KeyboundForm>
421
+ </RouteFocusModal.Form>
422
+ )
423
+ }
@@ -0,0 +1 @@
1
+ export { TranslationsEdit as Component } from "./translations-edit"
@@ -0,0 +1,67 @@
1
+ import { useNavigate, useSearchParams } from "react-router-dom"
2
+ import { useReferenceTranslations, useStore } from "../../../hooks/api"
3
+ import { TranslationsEditForm } from "./components/translations-edit-form"
4
+ import { useEffect } from "react"
5
+ import { RouteFocusModal } from "../../../components/modals"
6
+ import { useFeatureFlag } from "../../../providers/feature-flag-provider"
7
+
8
+ export const TranslationsEdit = () => {
9
+ const isTranslationsEnabled = useFeatureFlag("translation")
10
+ const navigate = useNavigate()
11
+ const [searchParams] = useSearchParams()
12
+ const reference = searchParams.get("reference")
13
+ const referenceIdParam = searchParams.getAll("reference_id")
14
+
15
+ useEffect(() => {
16
+ if (!reference || !isTranslationsEnabled) {
17
+ navigate(-1)
18
+ return
19
+ }
20
+ }, [reference, navigate, isTranslationsEnabled])
21
+
22
+ const {
23
+ translations,
24
+ references,
25
+ translatableFields,
26
+ isPending,
27
+ isError,
28
+ error,
29
+ } = useReferenceTranslations(reference!, referenceIdParam, {
30
+ enabled: !!reference,
31
+ })
32
+
33
+ const {
34
+ store,
35
+ isPending: isStorePending,
36
+ isError: isStoreError,
37
+ error: storeError,
38
+ } = useStore()
39
+
40
+ const ready =
41
+ !isPending &&
42
+ !!translations &&
43
+ !!translatableFields &&
44
+ !!references &&
45
+ !isStorePending &&
46
+ !!store
47
+
48
+ if (isError || isStoreError) {
49
+ throw error || storeError
50
+ }
51
+
52
+ return (
53
+ <RouteFocusModal prev={referenceIdParam.length ? -1 : ".."}>
54
+ {ready && (
55
+ <TranslationsEditForm
56
+ translations={translations}
57
+ references={references}
58
+ entityType={reference!}
59
+ availableLocales={store?.supported_locales ?? []}
60
+ // TODO: change this to get it from the entity translation config when we have it
61
+ translatableFields={translatableFields}
62
+ modalFields={translatableFields}
63
+ />
64
+ )}
65
+ </RouteFocusModal>
66
+ )
67
+ }
@@ -0,0 +1 @@
1
+ export * from "./reference-label-map"
@@ -0,0 +1,10 @@
1
+ export const REFERENCE_LABEL_MAP: Record<string, string> = {
2
+ product: "Products",
3
+ product_variant: "Product Variants",
4
+ product_category: "Product Categories",
5
+ product_collection: "Product Collections",
6
+ product_type: "Product Types",
7
+ product_tag: "Product Tags",
8
+ product_option: "Product Options",
9
+ product_option_value: "Product Option Values",
10
+ }
@@ -1,66 +0,0 @@
1
- import {
2
- useSalesChannels
3
- } from "./chunk-N3FCYZV6.mjs";
4
- import {
5
- useRegions
6
- } from "./chunk-HP2JH45P.mjs";
7
-
8
- // src/routes/orders/order-list/components/order-list-table/use-order-table-filters.tsx
9
- import { useMemo } from "react";
10
- import { useTranslation } from "react-i18next";
11
- var useOrderTableFilters = () => {
12
- const { t } = useTranslation();
13
- const { regions } = useRegions({
14
- limit: 1e3,
15
- fields: "id,name"
16
- });
17
- const { sales_channels } = useSalesChannels({
18
- limit: 1e3,
19
- fields: "id,name"
20
- });
21
- return useMemo(() => {
22
- const filters = [
23
- {
24
- key: "created_at",
25
- label: t("fields.createdAt"),
26
- type: "date"
27
- },
28
- {
29
- key: "updated_at",
30
- label: t("fields.updatedAt"),
31
- type: "date"
32
- }
33
- ];
34
- if (regions?.length) {
35
- filters.push({
36
- key: "region_id",
37
- label: t("fields.region"),
38
- type: "select",
39
- multiple: true,
40
- searchable: true,
41
- options: regions.map((r) => ({
42
- label: r.name,
43
- value: r.id
44
- }))
45
- });
46
- }
47
- if (sales_channels?.length) {
48
- filters.push({
49
- key: "sales_channel_id",
50
- label: t("fields.salesChannel"),
51
- type: "select",
52
- multiple: true,
53
- searchable: true,
54
- options: sales_channels.map((s) => ({
55
- label: s.name,
56
- value: s.id
57
- }))
58
- });
59
- }
60
- return filters;
61
- }, [regions, sales_channels, t]);
62
- };
63
-
64
- export {
65
- useOrderTableFilters
66
- };
@@ -1,121 +0,0 @@
1
- import {
2
- useOrderTableFilters
3
- } from "./chunk-35LSPN2U.mjs";
4
- import "./chunk-MFALVTRQ.mjs";
5
- import "./chunk-RIV7FKGN.mjs";
6
- import "./chunk-TDK3JDOB.mjs";
7
- import "./chunk-FHSC5X62.mjs";
8
- import "./chunk-XR4GEMGR.mjs";
9
- import "./chunk-WRSGHGAT.mjs";
10
- import "./chunk-MOSRJHJ3.mjs";
11
- import "./chunk-OMC5JCQH.mjs";
12
- import {
13
- useOrderTableQuery
14
- } from "./chunk-IW4TACOD.mjs";
15
- import "./chunk-R65S6ZZV.mjs";
16
- import {
17
- DataTableFilter
18
- } from "./chunk-GU5PJRPM.mjs";
19
- import "./chunk-C76H5USB.mjs";
20
- import "./chunk-DZWH2RV6.mjs";
21
- import {
22
- RouteDrawer
23
- } from "./chunk-XXBP2Z5M.mjs";
24
- import {
25
- useRouteModal
26
- } from "./chunk-42OOM4DJ.mjs";
27
- import "./chunk-SUYYSKCB.mjs";
28
- import "./chunk-OBQI23QM.mjs";
29
- import "./chunk-QPKW37WR.mjs";
30
- import "./chunk-I4OBEAOJ.mjs";
31
- import "./chunk-HI6URQ7H.mjs";
32
- import "./chunk-6CLQKVAU.mjs";
33
- import "./chunk-KI7TOXBR.mjs";
34
- import "./chunk-HKIF5HVL.mjs";
35
- import "./chunk-XIVBRONM.mjs";
36
- import "./chunk-WAXMT4IY.mjs";
37
- import "./chunk-DYDGGABK.mjs";
38
- import "./chunk-LGNTHZ5Y.mjs";
39
- import "./chunk-CN7JXSGW.mjs";
40
- import "./chunk-5BQQRHQS.mjs";
41
- import "./chunk-Y5UO73CH.mjs";
42
- import "./chunk-5AFMB7XQ.mjs";
43
- import "./chunk-NHDFPGQ3.mjs";
44
- import "./chunk-A63RZVX6.mjs";
45
- import "./chunk-HBXV7ENS.mjs";
46
- import "./chunk-CDORR33H.mjs";
47
- import {
48
- useExportOrders
49
- } from "./chunk-RU4ZS47V.mjs";
50
- import "./chunk-N4O5FAUC.mjs";
51
- import "./chunk-7AX6R6G6.mjs";
52
- import "./chunk-N3FCYZV6.mjs";
53
- import "./chunk-3BF5SC66.mjs";
54
- import "./chunk-VCSSQVPD.mjs";
55
- import "./chunk-HP2JH45P.mjs";
56
- import "./chunk-SQDIZZDW.mjs";
57
- import "./chunk-LEJUZW3P.mjs";
58
- import "./chunk-FXYH54JP.mjs";
59
- import "./chunk-774WSTCC.mjs";
60
- import "./chunk-NFEK63OE.mjs";
61
- import "./chunk-QZ7TP4HQ.mjs";
62
-
63
- // src/routes/orders/order-export/order-export.tsx
64
- import { Button, Heading as Heading2, toast } from "@medusajs/ui";
65
- import { useTranslation as useTranslation2 } from "react-i18next";
66
-
67
- // src/routes/orders/order-export/components/export-filters.tsx
68
- import { Heading, Text } from "@medusajs/ui";
69
- import { useTranslation } from "react-i18next";
70
- import { jsx, jsxs } from "react/jsx-runtime";
71
- var ExportFilters = () => {
72
- const { t } = useTranslation();
73
- const filters = useOrderTableFilters();
74
- return /* @__PURE__ */ jsxs("div", { children: [
75
- /* @__PURE__ */ jsx(Heading, { level: "h2", children: t("orders.export.filters.title") }),
76
- /* @__PURE__ */ jsx(Text, { size: "small", className: "text-ui-fg-subtle", children: t("orders.export.filters.description") }),
77
- /* @__PURE__ */ jsx("div", { className: "mt-4", children: /* @__PURE__ */ jsx(DataTableFilter, { filters, readonly: true }) })
78
- ] });
79
- };
80
-
81
- // src/routes/orders/order-export/order-export.tsx
82
- import { Fragment, jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
83
- var OrderExport = () => {
84
- const { t } = useTranslation2();
85
- return /* @__PURE__ */ jsxs2(RouteDrawer, { children: [
86
- /* @__PURE__ */ jsxs2(RouteDrawer.Header, { children: [
87
- /* @__PURE__ */ jsx2(RouteDrawer.Title, { asChild: true, children: /* @__PURE__ */ jsx2(Heading2, { children: t("orders.export.header") }) }),
88
- /* @__PURE__ */ jsx2(RouteDrawer.Description, { className: "sr-only", children: t("orders.export.description") })
89
- ] }),
90
- /* @__PURE__ */ jsx2(OrderExportContent, {})
91
- ] });
92
- };
93
- var OrderExportContent = () => {
94
- const { t } = useTranslation2();
95
- const { searchParams } = useOrderTableQuery({});
96
- const { mutateAsync } = useExportOrders(searchParams);
97
- const { handleSuccess } = useRouteModal();
98
- const handleExportRequest = async () => {
99
- await mutateAsync(searchParams, {
100
- onSuccess: () => {
101
- toast.info(t("orders.export.success.title"), {
102
- description: t("orders.export.success.description")
103
- });
104
- handleSuccess();
105
- },
106
- onError: (err) => {
107
- toast.error(err.message);
108
- }
109
- });
110
- };
111
- return /* @__PURE__ */ jsxs2(Fragment, { children: [
112
- /* @__PURE__ */ jsx2(RouteDrawer.Body, { children: /* @__PURE__ */ jsx2(ExportFilters, {}) }),
113
- /* @__PURE__ */ jsx2(RouteDrawer.Footer, { children: /* @__PURE__ */ jsxs2("div", { className: "flex items-center gap-x-2", children: [
114
- /* @__PURE__ */ jsx2(RouteDrawer.Close, { asChild: true, children: /* @__PURE__ */ jsx2(Button, { size: "small", variant: "secondary", children: t("actions.cancel") }) }),
115
- /* @__PURE__ */ jsx2(Button, { onClick: handleExportRequest, size: "small", children: t("actions.export") })
116
- ] }) })
117
- ] });
118
- };
119
- export {
120
- OrderExport as Component
121
- };