@mercurjs/vendor 2.2.1 → 2.3.0-canary.1

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 (217) hide show
  1. package/dist/[id]-3TCOLUQH.js +197 -0
  2. package/dist/{[id]-YB3DBBXT.js → [id]-4QVLDR3S.js} +13 -10
  3. package/dist/{[id]-RJRAZN3T.js → [id]-4VX7CTRZ.js} +8 -6
  4. package/dist/{[id]-OE5TUWNF.js → [id]-5FP6JZM3.js} +9 -7
  5. package/dist/[id]-6FEVCKQU.js +949 -0
  6. package/dist/{[id]-47SUX5X3.js → [id]-7QVJAIDU.js} +13 -10
  7. package/dist/{[id]-BHU5BSQT.js → [id]-CFVBH66J.js} +20 -17
  8. package/dist/{[id]-SKU5SFBG.js → [id]-HAJ3735Z.js} +137 -204
  9. package/dist/{[id]-NGRV5I2A.js → [id]-PBNGQSNY.js} +9 -7
  10. package/dist/[id]-QGZ26C6D.js +286 -0
  11. package/dist/{[id]-ZD5HBP2R.js → [id]-RAJUZUNH.js} +13 -10
  12. package/dist/[id]-RJ3MUR4M.js +697 -0
  13. package/dist/{[id]-PIB2DEVI.js → [id]-RRVYKA7U.js} +12 -9
  14. package/dist/{[id]-BPQNQFVE.js → [id]-Y4HRAAV2.js} +75 -124
  15. package/dist/{[province_id]-CUWKNPBW.js → [province_id]-VWN4OOGM.js} +9 -7
  16. package/dist/{add-MYV5IOGP.js → add-57LM6WKL.js} +157 -227
  17. package/dist/{add-YEUSE5QA.js → add-7HIVF77P.js} +10 -8
  18. package/dist/{add-customer-groups-Q3F357F2.js → add-customer-groups-VJYI5J5Z.js} +8 -6
  19. package/dist/{add-products-WVNYODC6.js → add-products-XWU5ZUTZ.js} +13 -10
  20. package/dist/{add-promotions-F62YE3BE.js → add-promotions-DOJS6CEE.js} +27 -9
  21. package/dist/{add-to-campaign-WBSCTSKW.js → add-to-campaign-B3PGGNFA.js} +3 -2
  22. package/dist/{address-ZMZ4ST5T.js → address-X4TXBPUG.js} +7 -5
  23. package/dist/{adjust-inventory-QUGKDXOC.js → adjust-inventory-2OKDFVLK.js} +2 -3
  24. package/dist/{allocate-items-7NSBGXSF.js → allocate-items-QAYROQMK.js} +4 -2
  25. package/dist/{areas-EJCZBY2E.js → areas-WQ44GWQO.js} +2 -2
  26. package/dist/{breadcrumb-M657ZCG6.js → breadcrumb-4I7MU2QY.js} +1 -1
  27. package/dist/{breadcrumb-KNBZ3JNR.js → breadcrumb-7ZFC43R4.js} +1 -1
  28. package/dist/{breadcrumb-C7M5PG2Q.js → breadcrumb-HMW2K4DW.js} +7 -5
  29. package/dist/{breadcrumb-KLNC72RI.js → breadcrumb-MH2L34OD.js} +2 -2
  30. package/dist/{breadcrumb-QPV566YX.js → breadcrumb-Q7FS3IDL.js} +8 -6
  31. package/dist/{breadcrumb-JWFTKHLE.js → breadcrumb-RQ52GELM.js} +2 -1
  32. package/dist/{breadcrumb-M6NW3DRQ.js → breadcrumb-WBUUK3AP.js} +1 -1
  33. package/dist/breadcrumb-XCPUUZUO.js +26 -0
  34. package/dist/{breadcrumb-MXYWEBK6.js → breadcrumb-Z2QUGZM3.js} +7 -5
  35. package/dist/{campaigns-BPLAE6QQ.js → campaigns-LIPKZKI7.js} +5 -4
  36. package/dist/{categories-H2XAJCGC.js → categories-D2U6VLH5.js} +2 -2
  37. package/dist/{chunk-4RVWITM2.js → chunk-3JWHERV7.js} +76 -23
  38. package/dist/{chunk-BCXREBMV.js → chunk-4ATO577Q.js} +1 -1
  39. package/dist/{chunk-VHFKJLDH.js → chunk-4JVORTN4.js} +1 -1
  40. package/dist/{chunk-HHD2VUED.js → chunk-4UKAKFKL.js} +1 -1
  41. package/dist/{chunk-3L7WHWKB.js → chunk-5DRYAIOY.js} +3 -3
  42. package/dist/{chunk-7TIZP4YG.js → chunk-5RWK4U4V.js} +26 -0
  43. package/dist/{chunk-XQUF3WIS.js → chunk-5ZHZVKNQ.js} +4 -0
  44. package/dist/{chunk-IWAL74YU.js → chunk-6GQLSWOO.js} +1 -1
  45. package/dist/{chunk-HCUIYIIY.js → chunk-6OZQTHCR.js} +1 -1
  46. package/dist/chunk-6XMUN2BZ.js +0 -0
  47. package/dist/{chunk-RLRWDHME.js → chunk-6YQR2AWM.js} +3 -20
  48. package/dist/{chunk-26OOAKQ6.js → chunk-7H6NMQ6U.js} +8 -1
  49. package/dist/{chunk-OKJHUQBY.js → chunk-7JVJIAWS.js} +17 -29
  50. package/dist/chunk-7LIENHWP.js +26 -0
  51. package/dist/{chunk-EPSRO7C5.js → chunk-7LIT4GXO.js} +2 -2
  52. package/dist/chunk-7POOMBIN.js +108 -0
  53. package/dist/{chunk-PF7R7LMW.js → chunk-AHR2FIMC.js} +22 -0
  54. package/dist/{chunk-EJBOBB4B.js → chunk-AQT2G6K2.js} +46 -46
  55. package/dist/{chunk-UEKRQS5Q.js → chunk-ATYOOL7K.js} +2 -2
  56. package/dist/chunk-BR6PEFXX.js +27 -0
  57. package/dist/{chunk-SDFZUBS3.js → chunk-CDZALZ5E.js} +1 -1
  58. package/dist/{chunk-3XW55FZY.js → chunk-CRVVPIFZ.js} +6 -6
  59. package/dist/{chunk-72HQFLZI.js → chunk-CSEB2RNO.js} +1 -1
  60. package/dist/{chunk-X6ZQMFCT.js → chunk-DAOSTHVB.js} +44 -25
  61. package/dist/{chunk-UUBGLS7U.js → chunk-EWJTXSKI.js} +211 -36
  62. package/dist/chunk-FKKI62AC.js +282 -0
  63. package/dist/{chunk-VBKW4GWP.js → chunk-FPBXQIFJ.js} +1 -1
  64. package/dist/{chunk-SI55QRZ4.js → chunk-G5NNOOHR.js} +59 -6
  65. package/dist/chunk-G6J5ZKM3.js +31 -0
  66. package/dist/{chunk-U5V6HNVW.js → chunk-GL3XVUAY.js} +1 -1
  67. package/dist/{chunk-RJE4MAYB.js → chunk-GYLRZXWS.js} +1 -1
  68. package/dist/{chunk-SVYBMLVN.js → chunk-HHCLMWXT.js} +1 -1
  69. package/dist/{chunk-YUQA6TUA.js → chunk-JOCO7JOB.js} +3 -3
  70. package/dist/{chunk-OGUTFP6B.js → chunk-JYUHDM23.js} +13 -51
  71. package/dist/{chunk-QB7BI4B7.js → chunk-K2DXXPNA.js} +153 -86
  72. package/dist/{chunk-XG76XXM2.js → chunk-KKMA6VPG.js} +1 -1
  73. package/dist/chunk-KVAD5JGS.js +11 -0
  74. package/dist/{chunk-YRZ53SAN.js → chunk-L26J5MO2.js} +2 -2
  75. package/dist/{chunk-63XYNXUL.js → chunk-LYP7XK5O.js} +1 -1
  76. package/dist/chunk-MVVFD2JT.js +51 -0
  77. package/dist/{chunk-RVFPWOR2.js → chunk-MY5H7C3A.js} +2 -2
  78. package/dist/{chunk-3GSR455R.js → chunk-NQMHP2LC.js} +1 -1
  79. package/dist/{chunk-2S2WK2OG.js → chunk-NV2RZAHW.js} +1 -10
  80. package/dist/{chunk-4IIATKG7.js → chunk-O7OWHKWA.js} +6 -6
  81. package/dist/{chunk-GIKVFOQL.js → chunk-OJCMHDZI.js} +2 -2
  82. package/dist/chunk-QLOJNFUE.js +53 -0
  83. package/dist/{chunk-GTNCNKTC.js → chunk-RBWIHKUF.js} +1 -1
  84. package/dist/{chunk-XVBONKRV.js → chunk-RCMKDW6O.js} +1 -1
  85. package/dist/{chunk-WJF24CGA.js → chunk-RDLVH6CM.js} +33 -5
  86. package/dist/chunk-SF5N2HX4.js +268 -0
  87. package/dist/{chunk-MQR26KYT.js → chunk-SYHA2RVL.js} +1 -1
  88. package/dist/{chunk-ZXDMPIXN.js → chunk-U3OEGBHH.js} +2 -2
  89. package/dist/chunk-UTGI6R2X.js +334 -0
  90. package/dist/{chunk-VBRTC2VU.js → chunk-VAFGNDAP.js} +4 -3
  91. package/dist/{chunk-4UQMRTSC.js → chunk-VH3TGSWE.js} +46 -2
  92. package/dist/{chunk-ZEKV7LGF.js → chunk-VV2K3EBF.js} +1 -1
  93. package/dist/{chunk-S2VYK3YC.js → chunk-WI2ZAFZF.js} +1 -1
  94. package/dist/chunk-WP3B4NEU.js +32 -0
  95. package/dist/{chunk-DY3XQPHC.js → chunk-WW2XYOHJ.js} +5 -3
  96. package/dist/{chunk-IVYIMGQC.js → chunk-X44P463Q.js} +45 -10
  97. package/dist/{chunk-FEVCBT24.js → chunk-X4G64W5Q.js} +2 -2
  98. package/dist/{chunk-R5KN6IFB.js → chunk-XHWBTV72.js} +2 -2
  99. package/dist/{chunk-OVHIUZ3K.js → chunk-XQ47NZJC.js} +1 -1
  100. package/dist/{chunk-LN7XHEPJ.js → chunk-YT4RAUWM.js} +2 -2
  101. package/dist/{chunk-6VKJM537.js → chunk-ZK4DIDXG.js} +1 -1
  102. package/dist/{collections-52DJLHWW.js → collections-5TH7H2QP.js} +14 -13
  103. package/dist/{configuration-UMRBE5RQ.js → configuration-QK2FW2CV.js} +2 -2
  104. package/dist/{configuration-QEDVL2WF.js → configuration-RYH3VUBV.js} +15 -48
  105. package/dist/{create-ALUKAFJS.js → create-5M66YUYY.js} +2 -2
  106. package/dist/{create-ABRPUMHQ.js → create-A6KZEZMH.js} +7 -6
  107. package/dist/{create-LYNWCP2N.js → create-BTODQ4T4.js} +6 -5
  108. package/dist/{create-2I3GAX4C.js → create-FI6H4AJE.js} +16 -7
  109. package/dist/{create-6IRD2CVC.js → create-GF76Z5I7.js} +15 -13
  110. package/dist/create-ICCAEOSA.js +343 -0
  111. package/dist/{create-NTZH45DW.js → create-JZLU44WB.js} +14 -12
  112. package/dist/{create-GEYXN6SW.js → create-ME43PNL6.js} +7 -5
  113. package/dist/{create-MFGMTZ5A.js → create-MIYJCLAJ.js} +8 -6
  114. package/dist/{create-7SJ5DSQK.js → create-PRDQJ5WI.js} +20 -17
  115. package/dist/{create-S7VYYTUD.js → create-Q6B6JR4K.js} +10 -8
  116. package/dist/{create-5RQ32XPT.js → create-SKQAJNDF.js} +287 -287
  117. package/dist/{create-7FT7N2NH.js → create-WPN3OUJU.js} +3 -2
  118. package/dist/{create-H77ZUZG5.js → create-XBGN6XEF.js} +10 -8
  119. package/dist/{create-G76MVCJU.js → create-ZVGYET6W.js} +5 -4
  120. package/dist/customer-availability-VAOKKCTK.js +164 -0
  121. package/dist/{customer-group-add-customers-T7OYWJCB.js → customer-group-add-customers-BSMUKWVO.js} +1 -1
  122. package/dist/{customer-group-detail-E7HRZ3LE.js → customer-group-detail-QCPC2YWK.js} +2 -2
  123. package/dist/{customer-groups-26HJ55MF.js → customer-groups-6WGUNFHG.js} +2 -2
  124. package/dist/{customers-EXFRZX5F.js → customers-7OGYQSGA.js} +2 -2
  125. package/dist/edit-2BKYNGYL.js +262 -0
  126. package/dist/{edit-WHGYNDEB.js → edit-3S3EH372.js} +20 -17
  127. package/dist/{edit-MPOTIGUY.js → edit-4WP5SGH6.js} +23 -39
  128. package/dist/{edit-QBUYHSE7.js → edit-7D2OZBJS.js} +8 -6
  129. package/dist/{edit-2RN3OT27.js → edit-7T2JMZG3.js} +7 -56
  130. package/dist/edit-AK4E63X6.js +179 -0
  131. package/dist/{edit-NB5VN2E4.js → edit-DRT6VOAA.js} +5 -4
  132. package/dist/{edit-EGBVEWXS.js → edit-GBDHDJK4.js} +9 -7
  133. package/dist/{edit-TIBQEQVV.js → edit-P7FNRVGB.js} +10 -8
  134. package/dist/{edit-6VJWRZHQ.js → edit-PZN7UAJI.js} +7 -5
  135. package/dist/{edit-M4AP65HO.js → edit-RNSXXJVU.js} +8 -6
  136. package/dist/edit-SKRFQ4WN.js +81 -0
  137. package/dist/{edit-H5FJ45ZT.js → edit-ZM7NJVRE.js} +1 -1
  138. package/dist/{edit-budget-PYPHUJPW.js → edit-budget-MOZETGZV.js} +1 -1
  139. package/dist/{edit-inventory-item-BCVECCLT.js → edit-inventory-item-HFGHS732.js} +17 -14
  140. package/dist/{edit-inventory-item-attributes-GWEMP67O.js → edit-inventory-item-attributes-5ORZJF4I.js} +18 -1
  141. package/dist/{edit-price-GLAEAO7R.js → edit-price-KY7LX5QA.js} +2 -2
  142. package/dist/edit-reservation-LSYQUDYQ.js +294 -0
  143. package/dist/{edit-stock-E3PM2YOP.js → edit-stock-77VKJR4Z.js} +2 -2
  144. package/dist/extension-targets.d.ts +6 -3
  145. package/dist/{fulfillment-HDU7GATG.js → fulfillment-DEGKZL42.js} +7 -5
  146. package/dist/{fulfillment-providers-6RZNNT7U.js → fulfillment-providers-LDFPZGNX.js} +12 -11
  147. package/dist/index.css +17 -14
  148. package/dist/index.js +265 -155
  149. package/dist/{inventory-XJ2E6DPC.js → inventory-CMIRAJJY.js} +2 -2
  150. package/dist/{inventory-CKA34HWM.js → inventory-RKAUTQAU.js} +2 -2
  151. package/dist/{invite-755AJC3M.js → invite-KAHF2MCE.js} +7 -5
  152. package/dist/{invite-FD2TXZTW.js → invite-S5O7LFEY.js} +10 -8
  153. package/dist/{loader-UUSAVCK6.js → loader-3BXYSKPT.js} +1 -1
  154. package/dist/{loader-B4T2VBGV.js → loader-CF54CDM6.js} +2 -2
  155. package/dist/{login-UGKYRKMD.js → login-CRSALS6Y.js} +9 -7
  156. package/dist/manage-items-63FPRK7Z.js +302 -0
  157. package/dist/{manage-locations-PRQI5TI4.js → manage-locations-5B4HP6NQ.js} +24 -5
  158. package/dist/{media-TGFAHFBV.js → media-74PEXOLV.js} +8 -6
  159. package/dist/{media-2KEHXPRU.js → media-NKCXFG6X.js} +11 -9
  160. package/dist/{metadata-7JWZ4VFM.js → metadata-22BCBKVE.js} +7 -5
  161. package/dist/{metadata-BQQFHVKF.js → metadata-E3BDAMIO.js} +7 -5
  162. package/dist/{metadata-5TVRCKWX.js → metadata-FRXIY35J.js} +7 -5
  163. package/dist/{metadata-4ZZ4ZIWJ.js → metadata-L6IA2Z26.js} +7 -5
  164. package/dist/metadata-WN6Y35RV.js +69 -0
  165. package/dist/{metadata-G73TILNE.js → metadata-ZZMJNWS3.js} +7 -5
  166. package/dist/{offer-create-page-PPXRYET4.js → offer-create-page-N5CKYGSS.js} +12 -9
  167. package/dist/{offer-detail-page-BFGKAS4L.js → offer-detail-page-AJG6TMJC.js} +3 -3
  168. package/dist/{offer-variant-detail-page-BLHRF4MK.js → offer-variant-detail-page-CEOS2MVM.js} +40 -8
  169. package/dist/{offers-7I67VSHI.js → offers-WFJ6UGVG.js} +15 -11
  170. package/dist/{onboarding-7MURQYXX.js → onboarding-2AZ2KEWJ.js} +7 -5
  171. package/dist/{orders-D7NZNDUS.js → orders-NWYLN6BE.js} +13 -12
  172. package/dist/{organization-T6ZTYMMW.js → organization-PAWIWKHV.js} +9 -7
  173. package/dist/pages/index.d.ts +9 -1
  174. package/dist/pages/index.js +57 -48
  175. package/dist/{payment-details-UQ65D5AY.js → payment-details-O57HNHWS.js} +7 -5
  176. package/dist/{payouts-A336D2HG.js → payouts-26ZOYDRP.js} +2 -2
  177. package/dist/{price-lists-3WRT4TR2.js → price-lists-U5ASDHMI.js} +5 -8
  178. package/dist/{pricing-3NLEJYRP.js → pricing-C425JTFQ.js} +2 -2
  179. package/dist/{pricing-CPPIL627.js → pricing-PDOCJEDS.js} +9 -7
  180. package/dist/{product-tags-7DTA73YT.js → product-tags-MMQ4ZR4W.js} +20 -17
  181. package/dist/{product-types-OB26NF2D.js → product-types-CMI33S32.js} +3 -4
  182. package/dist/{product-variant-detail-4DDE6RJ5.js → product-variant-detail-D73ILATK.js} +7 -5
  183. package/dist/{product-variant-edit-SAZUI4E3.js → product-variant-edit-XN6WGKI2.js} +10 -8
  184. package/dist/{products-RYXTZFGT.js → products-OZJHGW2K.js} +19 -16
  185. package/dist/{products-GJ2KTGBZ.js → products-VWH5TAFY.js} +13 -10
  186. package/dist/{professional-details-UN5B4YDJ.js → professional-details-ZJT6YKZB.js} +7 -5
  187. package/dist/{profile-6MIDTK52.js → profile-EU46MXFW.js} +7 -5
  188. package/dist/{promotions-SQ47TCZL.js → promotions-ALWQ7J7A.js} +5 -5
  189. package/dist/{receive-ZG6FFN7H.js → receive-RRZK3FP2.js} +4 -3
  190. package/dist/{refund-KJX74N6T.js → refund-FLCZAMPR.js} +3 -2
  191. package/dist/{register-RDSK4E4D.js → register-C6ON6OL2.js} +9 -7
  192. package/dist/reservations-C326XEVA.js +350 -0
  193. package/dist/{reset-password-C462PDN2.js → reset-password-ASLKY3GK.js} +1 -1
  194. package/dist/respond-IPRDCH57.js +132 -0
  195. package/dist/{return-reasons-MY63HNF6.js → return-reasons-2BUKIQBO.js} +9 -7
  196. package/dist/reviews-LBLCFBRQ.js +14 -0
  197. package/dist/{settings-TJ6HPHMK.js → settings-Q5GAL2LK.js} +28 -25
  198. package/dist/{shipment-6CTA2GHU.js → shipment-XOU6F7AS.js} +7 -5
  199. package/dist/{shipping-TKKMYQHJ.js → shipping-IMCP7UDV.js} +2 -2
  200. package/dist/{shipping-profile-CFISOMTE.js → shipping-profile-7P3RPEIJ.js} +1 -1
  201. package/dist/{shipping-profiles-5UAZNYKJ.js → shipping-profiles-647FLCNK.js} +9 -7
  202. package/dist/{stock-465GEUY3.js → stock-D3HCV5UR.js} +22 -8
  203. package/dist/{store-2PQB2XWE.js → store-XBNFP6O4.js} +8 -6
  204. package/dist/{store-closure-DYW54VHB.js → store-closure-55EUSKE4.js} +7 -5
  205. package/dist/{store-select-6A5YR7WH.js → store-select-DEOEGT2O.js} +8 -6
  206. package/dist/{team-GXEBC57M.js → team-7MJ3NJUT.js} +10 -8
  207. package/package.json +12 -9
  208. package/dist/[id]-HEVGSOAV.js +0 -598
  209. package/dist/[id]-MU7A6SZO.js +0 -526
  210. package/dist/chunk-2ZFELO2L.js +0 -13
  211. package/dist/chunk-6IJMSVC6.js +0 -16
  212. package/dist/chunk-BNOKKKUU.js +0 -88
  213. package/dist/chunk-BX3JE7IE.js +0 -247
  214. package/dist/edit-4B364HGZ.js +0 -222
  215. package/dist/edit-735HBYH2.js +0 -103
  216. package/dist/edit-SQU5UOGE.js +0 -105
  217. package/dist/{chunk-CYE7HVAV.js → chunk-SCJBJQCL.js} +3 -3
@@ -7,7 +7,7 @@ import {
7
7
  import {
8
8
  _DataTable,
9
9
  useDataTable
10
- } from "./chunk-IWAL74YU.js";
10
+ } from "./chunk-6GQLSWOO.js";
11
11
  import {
12
12
  useQueryParams
13
13
  } from "./chunk-THHRRYRS.js";
@@ -52,6 +52,7 @@ var InventoryListCreateButton = () => {
52
52
  };
53
53
 
54
54
  // src/pages/inventory/_components/inventory-list-data-table.tsx
55
+ import { Buildings } from "@medusajs/icons";
55
56
  import { useExtendableTable, useLinkQuery } from "@mercurjs/dashboard-shared";
56
57
  import { useMemo as useMemo2, useState } from "react";
57
58
  import { useTranslation as useTranslation5 } from "react-i18next";
@@ -68,7 +69,7 @@ import { useTranslation as useTranslation3 } from "react-i18next";
68
69
 
69
70
  // src/pages/inventory/_components/inventory-actions.tsx
70
71
  import { PencilSquare, Trash } from "@medusajs/icons";
71
- import { usePrompt } from "@medusajs/ui";
72
+ import { toast, usePrompt } from "@medusajs/ui";
72
73
  import { useTranslation as useTranslation2 } from "react-i18next";
73
74
  import { jsx as jsx2 } from "react/jsx-runtime";
74
75
  var InventoryActions = ({ item }) => {
@@ -77,15 +78,18 @@ var InventoryActions = ({ item }) => {
77
78
  const { mutateAsync } = useDeleteInventoryItem(item.id);
78
79
  const handleDelete = async () => {
79
80
  const res = await prompt({
80
- title: t("general.areYouSure"),
81
- description: t("inventory.deleteWarning"),
81
+ title: t("inventory.item.deleteTitle"),
82
+ description: t("inventory.item.deleteDescription"),
82
83
  confirmText: t("actions.delete"),
83
84
  cancelText: t("actions.cancel")
84
85
  });
85
86
  if (!res) {
86
87
  return;
87
88
  }
88
- await mutateAsync();
89
+ await mutateAsync(void 0, {
90
+ onSuccess: () => toast.success(t("inventory.toast.deleteItem")),
91
+ onError: (e) => toast.error(e.message)
92
+ });
89
93
  };
90
94
  return /* @__PURE__ */ jsx2(
91
95
  ActionMenu,
@@ -109,7 +113,8 @@ var InventoryActions = ({ item }) => {
109
113
  }
110
114
  ]
111
115
  }
112
- ]
116
+ ],
117
+ "data-testid": `inventory-item-actions-${item.id}`
113
118
  }
114
119
  );
115
120
  };
@@ -128,7 +133,8 @@ var useInventoryTableColumns = () => {
128
133
  Checkbox,
129
134
  {
130
135
  checked: table.getIsSomePageRowsSelected() ? "indeterminate" : table.getIsAllPageRowsSelected(),
131
- onCheckedChange: (value) => table.toggleAllPageRowsSelected(!!value)
136
+ onCheckedChange: (value) => table.toggleAllPageRowsSelected(!!value),
137
+ "data-testid": "inventory-table-header-select-checkbox"
132
138
  }
133
139
  );
134
140
  },
@@ -140,61 +146,143 @@ var useInventoryTableColumns = () => {
140
146
  onCheckedChange: (value) => row.toggleSelected(!!value),
141
147
  onClick: (e) => {
142
148
  e.stopPropagation();
143
- }
149
+ },
150
+ "data-testid": `inventory-table-cell-${row.id}-select-checkbox`
144
151
  }
145
152
  );
146
153
  }
147
154
  }),
148
155
  columnHelper.accessor("title", {
149
- header: t("fields.title"),
150
- cell: ({ getValue }) => {
156
+ header: () => /* @__PURE__ */ jsx3(
157
+ "div",
158
+ {
159
+ className: "flex h-full w-full items-center",
160
+ "data-testid": "inventory-table-header-title",
161
+ children: /* @__PURE__ */ jsx3("span", { "data-testid": "inventory-table-header-title-text", children: t("fields.title") })
162
+ }
163
+ ),
164
+ cell: ({ getValue, row }) => {
151
165
  const title = getValue();
152
166
  if (!title) {
153
167
  return /* @__PURE__ */ jsx3(PlaceholderCell, {});
154
168
  }
155
- return /* @__PURE__ */ jsx3("div", { className: "flex size-full items-center overflow-hidden", children: /* @__PURE__ */ jsx3("span", { className: "truncate", children: title }) });
169
+ return /* @__PURE__ */ jsx3("div", { className: "flex size-full items-center overflow-hidden", children: /* @__PURE__ */ jsx3(
170
+ "span",
171
+ {
172
+ className: "truncate",
173
+ "data-testid": `inventory-table-cell-${row.id}-title-value`,
174
+ children: title
175
+ }
176
+ ) });
156
177
  }
157
178
  }),
158
179
  columnHelper.accessor("sku", {
159
- header: t("fields.sku"),
160
- cell: ({ getValue }) => {
180
+ header: () => /* @__PURE__ */ jsx3(
181
+ "div",
182
+ {
183
+ className: "flex h-full w-full items-center",
184
+ "data-testid": "inventory-table-header-sku",
185
+ children: /* @__PURE__ */ jsx3("span", { "data-testid": "inventory-table-header-sku-text", children: t("fields.sku") })
186
+ }
187
+ ),
188
+ cell: ({ getValue, row }) => {
161
189
  const sku = getValue();
162
190
  if (!sku) {
163
191
  return /* @__PURE__ */ jsx3(PlaceholderCell, {});
164
192
  }
165
- return /* @__PURE__ */ jsx3("div", { className: "flex size-full items-center overflow-hidden", children: /* @__PURE__ */ jsx3("span", { className: "truncate", children: sku }) });
193
+ return /* @__PURE__ */ jsx3("div", { className: "flex size-full items-center overflow-hidden", children: /* @__PURE__ */ jsx3(
194
+ "span",
195
+ {
196
+ className: "truncate",
197
+ "data-testid": `inventory-table-cell-${row.id}-sku-value`,
198
+ children: sku
199
+ }
200
+ ) });
166
201
  }
167
202
  }),
168
- columnHelper.accessor("location_levels", {
169
- header: t("inventory.reserved"),
170
- cell: ({ getValue }) => {
171
- const locations = getValue();
172
- const totalReserved = locations.reduce(
173
- (sum, level) => sum + level.reserved_quantity,
174
- 0
175
- );
176
- if (Number.isNaN(totalReserved)) {
203
+ columnHelper.display({
204
+ id: "product",
205
+ header: () => /* @__PURE__ */ jsx3(
206
+ "div",
207
+ {
208
+ className: "flex h-full w-full items-center",
209
+ "data-testid": "inventory-table-header-product",
210
+ children: /* @__PURE__ */ jsx3("span", { "data-testid": "inventory-table-header-product-text", children: t("fields.product") })
211
+ }
212
+ ),
213
+ cell: ({ row }) => {
214
+ const productTitle = row.original.offers?.[0]?.product_variant?.product?.title;
215
+ if (!productTitle) {
177
216
  return /* @__PURE__ */ jsx3(PlaceholderCell, {});
178
217
  }
179
- return /* @__PURE__ */ jsx3("div", { className: "flex size-full items-center overflow-hidden", children: /* @__PURE__ */ jsx3("span", { className: "truncate", children: totalReserved }) });
218
+ return /* @__PURE__ */ jsx3("div", { className: "flex size-full items-center overflow-hidden", children: /* @__PURE__ */ jsx3(
219
+ "span",
220
+ {
221
+ className: "truncate",
222
+ "data-testid": `inventory-table-cell-${row.id}-product-value`,
223
+ children: productTitle
224
+ }
225
+ ) });
180
226
  }
181
227
  }),
182
- columnHelper.accessor("location_levels", {
183
- header: t("fields.inStock"),
184
- cell: ({ getValue }) => {
185
- const locations = getValue();
186
- const totalAvailable = locations.reduce(
187
- (sum, level) => sum + level.available_quantity,
188
- 0
189
- );
190
- if (Number.isNaN(totalAvailable)) {
228
+ columnHelper.accessor("stocked_quantity", {
229
+ header: () => /* @__PURE__ */ jsx3(
230
+ "div",
231
+ {
232
+ className: "flex h-full w-full items-center",
233
+ "data-testid": "inventory-table-header-stocked-quantity",
234
+ children: /* @__PURE__ */ jsx3("span", { "data-testid": "inventory-table-header-stocked-quantity-text", children: t("fields.inStock") })
235
+ }
236
+ ),
237
+ cell: ({ getValue, row }) => {
238
+ const quantity = getValue();
239
+ if (Number.isNaN(quantity)) {
191
240
  return /* @__PURE__ */ jsx3(PlaceholderCell, {});
192
241
  }
193
- return /* @__PURE__ */ jsx3("div", { className: "flex size-full items-center overflow-hidden", children: /* @__PURE__ */ jsx3("span", { className: "truncate", children: totalAvailable }) });
242
+ return /* @__PURE__ */ jsx3("div", { className: "flex size-full items-center overflow-hidden", children: /* @__PURE__ */ jsx3(
243
+ "span",
244
+ {
245
+ className: "truncate",
246
+ "data-testid": `inventory-table-cell-${row.id}-stocked_quantity-value`,
247
+ children: quantity
248
+ }
249
+ ) });
250
+ }
251
+ }),
252
+ columnHelper.accessor("reserved_quantity", {
253
+ header: () => /* @__PURE__ */ jsx3(
254
+ "div",
255
+ {
256
+ className: "flex h-full w-full items-center",
257
+ "data-testid": "inventory-table-header-reserved-quantity",
258
+ children: /* @__PURE__ */ jsx3("span", { "data-testid": "inventory-table-header-reserved-quantity-text", children: t("inventory.reserved") })
259
+ }
260
+ ),
261
+ cell: ({ getValue, row }) => {
262
+ const quantity = getValue();
263
+ if (Number.isNaN(quantity)) {
264
+ return /* @__PURE__ */ jsx3(PlaceholderCell, {});
265
+ }
266
+ return /* @__PURE__ */ jsx3("div", { className: "flex size-full items-center overflow-hidden", children: /* @__PURE__ */ jsx3(
267
+ "span",
268
+ {
269
+ className: "truncate",
270
+ "data-testid": `inventory-table-cell-${row.id}-reserved_quantity-value`,
271
+ children: quantity
272
+ }
273
+ ) });
194
274
  }
195
275
  }),
196
276
  columnHelper.display({
197
277
  id: "actions",
278
+ header: () => /* @__PURE__ */ jsx3(
279
+ "div",
280
+ {
281
+ className: "flex h-full w-full items-center",
282
+ "data-testid": "inventory-table-header-actions",
283
+ children: /* @__PURE__ */ jsx3("span", { "data-testid": "inventory-table-header-actions-text" })
284
+ }
285
+ ),
198
286
  cell: ({ row }) => /* @__PURE__ */ jsx3(InventoryActions, { item: row.original })
199
287
  })
200
288
  ],
@@ -210,6 +298,11 @@ var useInventoryTableFilters = () => {
210
298
  limit: 1e3
211
299
  });
212
300
  const filters = [];
301
+ filters.push({
302
+ type: "string",
303
+ key: "sku",
304
+ label: t("fields.sku")
305
+ });
213
306
  if (stock_locations) {
214
307
  const stockLocationFilter = {
215
308
  type: "select",
@@ -223,21 +316,6 @@ var useInventoryTableFilters = () => {
223
316
  };
224
317
  filters.push(stockLocationFilter);
225
318
  }
226
- filters.push({
227
- type: "string",
228
- key: "material",
229
- label: t("fields.material")
230
- });
231
- filters.push({
232
- type: "string",
233
- key: "sku",
234
- label: t("fields.sku")
235
- });
236
- filters.push({
237
- type: "string",
238
- key: "mid_code",
239
- label: t("fields.midCode")
240
- });
241
319
  filters.push({
242
320
  type: "number",
243
321
  key: "height",
@@ -249,24 +327,14 @@ var useInventoryTableFilters = () => {
249
327
  label: t("fields.width")
250
328
  });
251
329
  filters.push({
252
- type: "number",
253
- key: "length",
254
- label: t("fields.length")
255
- });
256
- filters.push({
257
- type: "number",
258
- key: "weight",
259
- label: t("fields.weight")
330
+ type: "string",
331
+ key: "mid_code",
332
+ label: t("fields.midCode")
260
333
  });
261
334
  filters.push({
262
- type: "select",
263
- options: [
264
- { label: t("fields.true"), value: "true" },
265
- { label: t("fields.false"), value: "false" }
266
- ],
267
- key: "requires_shipping",
268
- multiple: false,
269
- label: t("fields.requiresShipping")
335
+ type: "string",
336
+ key: "material",
337
+ label: t("fields.material")
270
338
  });
271
339
  return filters;
272
340
  };
@@ -282,41 +350,25 @@ var useInventoryTableQuery = ({
282
350
  "location_id",
283
351
  "q",
284
352
  "order",
285
- "requires_shipping",
286
353
  "offset",
287
354
  "sku",
288
- "origin_country",
289
355
  "material",
290
356
  "mid_code",
291
357
  "hs_code",
292
- "order",
293
- "weight",
294
358
  "width",
295
- "length",
296
359
  "height"
297
360
  ],
298
361
  prefix
299
362
  );
300
- const {
301
- offset,
302
- weight,
303
- width,
304
- length,
305
- height,
306
- requires_shipping,
307
- ...params
308
- } = raw;
363
+ const { offset, width, height, ...params } = raw;
309
364
  const searchParams = {
310
365
  limit: pageSize,
311
366
  offset: offset ? parseInt(offset) : void 0,
312
- weight: weight ? JSON.parse(weight) : void 0,
313
367
  width: width ? JSON.parse(width) : void 0,
314
- length: length ? JSON.parse(length) : void 0,
315
368
  height: height ? JSON.parse(height) : void 0,
316
- requires_shipping: requires_shipping ? JSON.parse(requires_shipping) : void 0,
317
369
  q: params.q,
318
370
  sku: params.sku,
319
- order: params.order,
371
+ order: params.order || "title",
320
372
  mid_code: params.mid_code,
321
373
  hs_code: params.hs_code,
322
374
  material: params.material,
@@ -351,7 +403,10 @@ var InventoryListDataTable = () => {
351
403
  } = useInventoryItems(
352
404
  {
353
405
  ...searchParams,
354
- ...useLinkQuery("inventory_item")
406
+ ...useLinkQuery(
407
+ "inventory_item",
408
+ "+offers.product_variant.product.title"
409
+ )
355
410
  },
356
411
  {
357
412
  placeholderData: keepPreviousData
@@ -359,10 +414,15 @@ var InventoryListDataTable = () => {
359
414
  );
360
415
  const baseFilters = useInventoryTableFilters();
361
416
  const baseColumns = useInventoryTableColumns();
362
- const { columns, filters: extFilters } = useExtendableTable({
417
+ const actionsColumn = baseColumns[baseColumns.length - 1];
418
+ const { columns: extended, filters: extFilters } = useExtendableTable({
363
419
  model: "inventory_item",
364
- columns: baseColumns
420
+ columns: baseColumns.slice(0, -1)
365
421
  });
422
+ const columns = useMemo2(
423
+ () => [...extended, actionsColumn],
424
+ [extended, actionsColumn]
425
+ );
366
426
  const filters = useMemo2(
367
427
  () => [...baseFilters, ...extFilters],
368
428
  [baseFilters, extFilters]
@@ -401,6 +461,13 @@ var InventoryListDataTable = () => {
401
461
  { key: "stocked_quantity", label: t("fields.inStock") },
402
462
  { key: "reserved_quantity", label: t("inventory.reserved") }
403
463
  ],
464
+ defaultOrder: "title",
465
+ noRecords: {
466
+ icon: /* @__PURE__ */ jsx4(Buildings, { className: "text-ui-fg-subtle" }),
467
+ title: t("inventory.list.noRecordsTitle"),
468
+ message: t("inventory.list.noRecordsMessage"),
469
+ action: { to: "create", label: t("actions.create") }
470
+ },
404
471
  navigateTo: (row) => `${row.id}`,
405
472
  commands: [
406
473
  {
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  useProductTag
3
- } from "./chunk-RLRWDHME.js";
3
+ } from "./chunk-6YQR2AWM.js";
4
4
 
5
5
  // src/pages/settings/product-tags/[id]/breadcrumb.tsx
6
6
  import { jsx } from "react/jsx-runtime";
@@ -0,0 +1,11 @@
1
+ // src/pages/price-lists/common/utils.ts
2
+ import {
3
+ extractPricesFromOffers,
4
+ getPriceListStatus,
5
+ isProductRow
6
+ } from "@mercurjs/dashboard-shared";
7
+
8
+ export {
9
+ extractPricesFromOffers,
10
+ getPriceListStatus
11
+ };
@@ -13,10 +13,10 @@ import {
13
13
  import {
14
14
  _DataTable,
15
15
  useDataTable
16
- } from "./chunk-IWAL74YU.js";
16
+ } from "./chunk-6GQLSWOO.js";
17
17
  import {
18
18
  useOrders
19
- } from "./chunk-OGUTFP6B.js";
19
+ } from "./chunk-JYUHDM23.js";
20
20
 
21
21
  // src/pages/orders/order-list-page.tsx
22
22
  import { Children as Children3 } from "react";
@@ -17,7 +17,7 @@ import {
17
17
  import {
18
18
  _DataTable,
19
19
  useDataTable
20
- } from "./chunk-IWAL74YU.js";
20
+ } from "./chunk-6GQLSWOO.js";
21
21
  import {
22
22
  useQueryParams
23
23
  } from "./chunk-THHRRYRS.js";
@@ -0,0 +1,51 @@
1
+ import {
2
+ queryClient
3
+ } from "./chunk-RHKRREUU.js";
4
+ import {
5
+ queryKeysFactory
6
+ } from "./chunk-ZA2KFUFR.js";
7
+ import {
8
+ sdk
9
+ } from "./chunk-DTGEFKK4.js";
10
+
11
+ // src/hooks/api/reviews.tsx
12
+ import {
13
+ useMutation,
14
+ useQuery
15
+ } from "@tanstack/react-query";
16
+ var REVIEWS_QUERY_KEY = "reviews";
17
+ var reviewsQueryKeys = queryKeysFactory(REVIEWS_QUERY_KEY);
18
+ var useReviews = (query, options) => {
19
+ const { data, ...rest } = useQuery({
20
+ queryKey: reviewsQueryKeys.list(query),
21
+ queryFn: async () => sdk.vendor.reviews.query({ ...query }),
22
+ ...options
23
+ });
24
+ return { ...data, ...rest };
25
+ };
26
+ var useReview = (id, query, options) => {
27
+ const { data, ...rest } = useQuery({
28
+ queryKey: reviewsQueryKeys.detail(id, query),
29
+ queryFn: async () => sdk.vendor.reviews.$id.query({ $id: id, ...query }),
30
+ ...options
31
+ });
32
+ return { ...data, ...rest };
33
+ };
34
+ var useRespondReview = (id, options) => {
35
+ return useMutation({
36
+ mutationFn: (payload) => sdk.vendor.reviews.$id.mutate({ $id: id, ...payload }),
37
+ onSuccess: (data, variables, context) => {
38
+ queryClient.invalidateQueries({ queryKey: reviewsQueryKeys.lists() });
39
+ queryClient.invalidateQueries({ queryKey: reviewsQueryKeys.detail(id) });
40
+ options?.onSuccess?.(data, variables, context);
41
+ },
42
+ ...options
43
+ });
44
+ };
45
+
46
+ export {
47
+ reviewsQueryKeys,
48
+ useReviews,
49
+ useReview,
50
+ useRespondReview
51
+ };
@@ -12,10 +12,10 @@ import {
12
12
  } from "./chunk-3QSRE5LS.js";
13
13
  import {
14
14
  require_dist
15
- } from "./chunk-4UQMRTSC.js";
15
+ } from "./chunk-VH3TGSWE.js";
16
16
  import {
17
17
  useFeatureFlags
18
- } from "./chunk-RLRWDHME.js";
18
+ } from "./chunk-6YQR2AWM.js";
19
19
  import {
20
20
  useSignInWithEmailPass
21
21
  } from "./chunk-K5324KIX.js";
@@ -3,7 +3,7 @@ import {
3
3
  CategoryHeader,
4
4
  ProductStatusCell,
5
5
  ProductStatusHeader
6
- } from "./chunk-S2VYK3YC.js";
6
+ } from "./chunk-WI2ZAFZF.js";
7
7
  import {
8
8
  ProductCell,
9
9
  ProductHeader
@@ -106,14 +106,6 @@ var usePriceListLinkProducts = (id, options) => {
106
106
  ...options
107
107
  });
108
108
  };
109
- var usePriceListProducts = (id, query, options) => {
110
- const { data, ...rest } = useQuery({
111
- queryFn: () => sdk.vendor.products.query({ price_list_id: [id], ...query }),
112
- queryKey: [PRICE_LISTS_QUERY_KEY, id, "products"],
113
- ...options
114
- });
115
- return { ...data, ...rest };
116
- };
117
109
 
118
110
  export {
119
111
  priceListsQueryKeys,
@@ -123,6 +115,5 @@ export {
123
115
  useUpdatePriceList,
124
116
  useDeletePriceList,
125
117
  useBatchPriceListPrices,
126
- usePriceListLinkProducts,
127
- usePriceListProducts
118
+ usePriceListLinkProducts
128
119
  };
@@ -24,22 +24,22 @@ import {
24
24
  import {
25
25
  useCollectionTableFilters,
26
26
  useProductTagTableFilters
27
- } from "./chunk-HHD2VUED.js";
27
+ } from "./chunk-4UKAKFKL.js";
28
28
  import {
29
29
  useProductTypeTableFilters
30
- } from "./chunk-2ZFELO2L.js";
30
+ } from "./chunk-7H6NMQ6U.js";
31
31
  import {
32
32
  useCustomerGroupTableFilters
33
33
  } from "./chunk-CMHI2RPL.js";
34
34
  import {
35
35
  useProductTableColumns
36
- } from "./chunk-3GSR455R.js";
36
+ } from "./chunk-NQMHP2LC.js";
37
37
  import {
38
38
  useProductTableQuery
39
39
  } from "./chunk-BEPAXQMU.js";
40
40
  import {
41
41
  useProductTableFilters
42
- } from "./chunk-ZXDMPIXN.js";
42
+ } from "./chunk-U3OEGBHH.js";
43
43
  import {
44
44
  StackedDrawer,
45
45
  StackedFocusModal
@@ -47,10 +47,10 @@ import {
47
47
  import {
48
48
  _DataTable,
49
49
  useDataTable
50
- } from "./chunk-IWAL74YU.js";
50
+ } from "./chunk-6GQLSWOO.js";
51
51
  import {
52
52
  useProductTags
53
- } from "./chunk-RLRWDHME.js";
53
+ } from "./chunk-6YQR2AWM.js";
54
54
  import {
55
55
  useProductTypes
56
56
  } from "./chunk-L2NJPDUD.js";
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  Combobox
3
- } from "./chunk-VBRTC2VU.js";
3
+ } from "./chunk-VAFGNDAP.js";
4
4
  import {
5
5
  require_dist
6
- } from "./chunk-4UQMRTSC.js";
6
+ } from "./chunk-VH3TGSWE.js";
7
7
  import {
8
8
  __toESM
9
9
  } from "./chunk-NBMM2TZK.js";
@@ -0,0 +1,53 @@
1
+ // src/components/common/badge-list-summary/badge-list-summary.tsx
2
+ import { Badge, Tooltip, clx } from "@medusajs/ui";
3
+ import { useTranslation } from "react-i18next";
4
+ import { jsx, jsxs } from "react/jsx-runtime";
5
+ var BadgeListSummary = ({
6
+ list,
7
+ className,
8
+ inline,
9
+ rounded = false,
10
+ n = 2
11
+ }) => {
12
+ const { t } = useTranslation();
13
+ const title = t("general.plusCount", {
14
+ count: list.length - n
15
+ });
16
+ return /* @__PURE__ */ jsxs(
17
+ "div",
18
+ {
19
+ className: clx(
20
+ "text-ui-fg-subtle txt-compact-small gap-x-2 overflow-hidden",
21
+ {
22
+ "inline-flex": inline,
23
+ flex: !inline
24
+ },
25
+ className
26
+ ),
27
+ children: [
28
+ list.slice(0, n).map((item) => {
29
+ return /* @__PURE__ */ jsx(Badge, { rounded: rounded ? "full" : "base", size: "2xsmall", children: item }, item);
30
+ }),
31
+ list.length > n && /* @__PURE__ */ jsx("div", { className: "whitespace-nowrap", children: /* @__PURE__ */ jsx(
32
+ Tooltip,
33
+ {
34
+ content: /* @__PURE__ */ jsx("ul", { children: list.slice(n).map((c) => /* @__PURE__ */ jsx("li", { children: c }, c)) }),
35
+ children: /* @__PURE__ */ jsx(
36
+ Badge,
37
+ {
38
+ rounded: rounded ? "full" : "base",
39
+ size: "2xsmall",
40
+ className: "cursor-default whitespace-nowrap",
41
+ children: title
42
+ }
43
+ )
44
+ }
45
+ ) })
46
+ ]
47
+ }
48
+ );
49
+ };
50
+
51
+ export {
52
+ BadgeListSummary
53
+ };
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  i18n
3
- } from "./chunk-UUBGLS7U.js";
3
+ } from "./chunk-EWJTXSKI.js";
4
4
 
5
5
  // src/lib/promotions.ts
6
6
  var promotionStatusMap = {
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  ordersQueryKeys
3
- } from "./chunk-OGUTFP6B.js";
3
+ } from "./chunk-JYUHDM23.js";
4
4
  import {
5
5
  queryClient
6
6
  } from "./chunk-RHKRREUU.js";