@mercurjs/admin 2.3.6-canary.6 → 2.3.6-canary.7
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.
- package/dist/{add-campaign-promotions-6OB7BUPK.js → add-campaign-promotions-LGCLOFOD.js} +13 -8
- package/dist/{adjust-inventory-32UZ4BZC.js → adjust-inventory-H46YCNLT.js} +7 -2
- package/dist/{api-key-management-detail-ULNXV7YJ.js → api-key-management-detail-Z4KSJHUC.js} +5 -7
- package/dist/{api-key-management-list-KPWCB7NX.js → api-key-management-list-QZIRPINF.js} +5 -5
- package/dist/{api-key-management-sales-channels-RBK66ZGC.js → api-key-management-sales-channels-RGZ3QITG.js} +9 -7
- package/dist/{attribute-create-UWLP2DZY.js → attribute-create-OFTZRQCO.js} +3 -2
- package/dist/{attribute-detail-7PIMBKEE.js → attribute-detail-WVN5KOH2.js} +13 -7
- package/dist/{attribute-list-FLTRNSFI.js → attribute-list-ZC3CG5LS.js} +6 -6
- package/dist/{campaign-detail-WBWGUSMW.js → campaign-detail-MGDL2TQC.js} +10 -10
- package/dist/{campaign-list-M24QK43I.js → campaign-list-XCO4FJDZ.js} +5 -5
- package/dist/{categories-metadata-6F6EFZRQ.js → categories-metadata-QYH5U77W.js} +2 -2
- package/dist/{category-detail-3YY7FVY4.js → category-detail-FAP76OQB.js} +6 -7
- package/dist/{category-list-AT66O7HI.js → category-list-XDOYTQ4X.js} +5 -5
- package/dist/{category-products-RTOFMB25.js → category-products-35ZZYVWJ.js} +12 -5
- package/dist/{chunk-PH7TEL5B.js → chunk-23CSVCQK.js} +26 -15
- package/dist/{chunk-G4L2EPKT.js → chunk-25TWJMWE.js} +2 -2
- package/dist/{chunk-YJJ6YXFA.js → chunk-26REB3B6.js} +2 -1
- package/dist/{chunk-36C3CNJC.js → chunk-2IOADJUM.js} +27 -9
- package/dist/{chunk-ZH6TIKKW.js → chunk-2MOTQNEG.js} +1 -0
- package/dist/{chunk-4RKWEFNY.js → chunk-2XBNM6TM.js} +2 -2
- package/dist/{chunk-5KTSSLBG.js → chunk-3BKRMIWA.js} +21 -10
- package/dist/chunk-3UOYBH5O.js +8 -0
- package/dist/{chunk-T3AKFW7T.js → chunk-473QGQSA.js} +6 -3
- package/dist/{chunk-FV7B2OWJ.js → chunk-4AOVNA5G.js} +29 -18
- package/dist/{chunk-5LK5NAGN.js → chunk-4J4JAXXQ.js} +5 -3
- package/dist/{chunk-IKAUNMRC.js → chunk-4J74G7N2.js} +15 -3
- package/dist/{chunk-WIDHYDJQ.js → chunk-4JQDYQSX.js} +20 -10
- package/dist/{chunk-QPHY3XXC.js → chunk-4W77EUYY.js} +4 -2
- package/dist/{chunk-VKDZAXLK.js → chunk-5K4WEF2N.js} +19 -8
- package/dist/{chunk-AGO4ROOR.js → chunk-5OIFUF7R.js} +1 -1
- package/dist/{chunk-4CYHJ72Y.js → chunk-5QW3GY37.js} +25 -12
- package/dist/{chunk-BVKPOXLT.js → chunk-72DFLNNI.js} +9 -3
- package/dist/{chunk-X22JPPG6.js → chunk-7GCMYYFL.js} +5 -2
- package/dist/{chunk-AYKMFPKF.js → chunk-7LUKMT5J.js} +4 -2
- package/dist/{chunk-L3GVDREC.js → chunk-7OTRTHLL.js} +4 -2
- package/dist/{chunk-IZ77JV46.js → chunk-AUCCE46Q.js} +6 -3
- package/dist/{chunk-545HIUP3.js → chunk-AW4RL2SA.js} +58 -31
- package/dist/{chunk-62YRQVR7.js → chunk-AZV22U4V.js} +20 -5
- package/dist/{chunk-ZSXF4PEE.js → chunk-CX5XB56X.js} +4 -3
- package/dist/{chunk-J4SYK3RT.js → chunk-DGRHDZQO.js} +15 -5
- package/dist/{chunk-7UHN2CW7.js → chunk-DM52HEOD.js} +1 -1
- package/dist/{chunk-LMBIFEA5.js → chunk-DUKOOIQD.js} +3 -2
- package/dist/{chunk-VM35P6LF.js → chunk-DVFILGNQ.js} +7 -5
- package/dist/{chunk-5H4KS6M3.js → chunk-DWPBJEEM.js} +18 -5
- package/dist/{chunk-B4MSCLHO.js → chunk-E43YJQ2B.js} +42 -18
- package/dist/{chunk-NUMVOUQQ.js → chunk-EHLCUND7.js} +8 -6
- package/dist/{chunk-DBCNRZZE.js → chunk-EIPTLSNT.js} +3 -1
- package/dist/{chunk-7SHPS72O.js → chunk-EVYQCNVT.js} +4 -2
- package/dist/{chunk-VWK3K2CI.js → chunk-FCAJQFYT.js} +30 -10
- package/dist/{chunk-MKVEDGJ2.js → chunk-G63BL5AB.js} +5 -2
- package/dist/{chunk-BZPOERWW.js → chunk-GIV6KSQX.js} +18 -9
- package/dist/{chunk-QOMIRTO4.js → chunk-GQGCXLVP.js} +30 -11
- package/dist/{chunk-GWOZSV7A.js → chunk-GQYB3OOC.js} +105 -62
- package/dist/{chunk-IFG5ONPV.js → chunk-GZUXEIEB.js} +2 -2
- package/dist/{chunk-VOXWLJHA.js → chunk-H3TOETGJ.js} +11 -6
- package/dist/{chunk-B6XGTGMP.js → chunk-H4TJZB26.js} +24 -16
- package/dist/{chunk-AUTG5JEE.js → chunk-HHAM76HD.js} +41 -23
- package/dist/{chunk-XAQLGDAI.js → chunk-HPMMGA5B.js} +1 -1
- package/dist/{chunk-2IPSJDRD.js → chunk-I3RGMOTM.js} +18 -10
- package/dist/{chunk-4OCANHUL.js → chunk-IQRFJO4N.js} +3 -1
- package/dist/{chunk-WJPWYQYV.js → chunk-JFRYC6GK.js} +15 -8
- package/dist/{chunk-FOWWGEP7.js → chunk-JS2DAWKO.js} +9 -6
- package/dist/{chunk-ESVFENTS.js → chunk-K6OBX6ZR.js} +5 -4
- package/dist/{chunk-TN3HCAJ2.js → chunk-KB3BTLIB.js} +4 -2
- package/dist/{chunk-VIHLAFDA.js → chunk-KYOZ4CCY.js} +61 -29
- package/dist/{chunk-UFFLSUK4.js → chunk-LCUAIH7P.js} +4 -2
- package/dist/{chunk-3CLWBE4O.js → chunk-M7VHCFCW.js} +7 -5
- package/dist/{chunk-EVCAR6GP.js → chunk-MAEUKXZ4.js} +8 -5
- package/dist/{chunk-RU5IUJC2.js → chunk-MFGLOUTZ.js} +32 -10
- package/dist/{chunk-HFCJJJKP.js → chunk-MKKOAF2W.js} +26 -12
- package/dist/{chunk-AJCCPN5R.js → chunk-MNKJHZZT.js} +8 -4
- package/dist/{chunk-XV4YW4GE.js → chunk-NDS246VB.js} +20 -12
- package/dist/{chunk-ZPNRNL4X.js → chunk-NHZU2M7Z.js} +6 -4
- package/dist/{chunk-3JXOVOJI.js → chunk-NJ2NRKAJ.js} +55 -12
- package/dist/{chunk-CFQX7HAW.js → chunk-OCDZIJBM.js} +11 -5
- package/dist/{chunk-HBQ7EHHM.js → chunk-OGTWBHJC.js} +1 -1
- package/dist/{chunk-CBLCX5UK.js → chunk-Q2XWHI6K.js} +4 -1
- package/dist/{chunk-YWZQKODL.js → chunk-R55XYG6Y.js} +28 -15
- package/dist/{chunk-UZ2FWDJO.js → chunk-RAD3UMQ3.js} +4 -2
- package/dist/{chunk-WA3UZTKD.js → chunk-RUGB47D3.js} +1 -1
- package/dist/{chunk-ZOU25JF6.js → chunk-SU36MZXC.js} +11 -3
- package/dist/{chunk-SJEMUTO2.js → chunk-SW46WBFA.js} +29 -14
- package/dist/{chunk-NOK2356Y.js → chunk-SZSAJHN7.js} +4 -3
- package/dist/{chunk-QFYTIG3H.js → chunk-TPWSE5HE.js} +14 -9
- package/dist/{chunk-7ECQXPOG.js → chunk-TVCHVG2A.js} +3 -3
- package/dist/{chunk-ZPHVFD4N.js → chunk-TXZWIFWX.js} +1 -0
- package/dist/{chunk-HJACC6KV.js → chunk-UKQ6FES4.js} +6 -3
- package/dist/{chunk-7Y7YN7KG.js → chunk-USEE6QNQ.js} +65 -25
- package/dist/{chunk-JL3NKSLJ.js → chunk-USO2SWZV.js} +9 -4
- package/dist/{chunk-7C7YLUYT.js → chunk-V3UQOU5W.js} +4 -2
- package/dist/{chunk-HUJIVGX3.js → chunk-VD2CKAYG.js} +19 -8
- package/dist/{chunk-D3KEKNYN.js → chunk-VHO6ZXW2.js} +9 -5
- package/dist/{chunk-C4XKPQ6T.js → chunk-VLNTJXXO.js} +16 -3
- package/dist/{chunk-D3RDR3D3.js → chunk-W3LCOK3O.js} +153 -124
- package/dist/{chunk-IAMX7JMM.js → chunk-WD5XBWAN.js} +118 -53
- package/dist/chunk-WSK532ZA.js +236 -0
- package/dist/{chunk-RX7RU7VV.js → chunk-XI4SB5YZ.js} +120 -81
- package/dist/{chunk-KMLQ2ENL.js → chunk-XNGTE2VC.js} +1 -1
- package/dist/{chunk-TXEOM3WC.js → chunk-XUOGIKEE.js} +3 -3
- package/dist/{chunk-R22UAHRF.js → chunk-YDESULL7.js} +3 -1
- package/dist/{chunk-JODADMJ6.js → chunk-YN4KTMRA.js} +7 -5
- package/dist/{chunk-IVWSTXBV.js → chunk-YUKJJHI7.js} +8 -5
- package/dist/{chunk-4EQSS3YZ.js → chunk-Z2FX5GG4.js} +22 -10
- package/dist/{chunk-JQEAWWRP.js → chunk-ZPJOSHV7.js} +23 -12
- package/dist/{chunk-FX7HVGV5.js → chunk-ZQZFY3UY.js} +6 -4
- package/dist/{chunk-U2RBSUMY.js → chunk-ZU76OTV3.js} +2 -2
- package/dist/{collection-add-products-O5ILXKFY.js → collection-add-products-IIBLH7XQ.js} +12 -5
- package/dist/{collection-detail-N7VZKBIJ.js → collection-detail-IYZKDR4L.js} +6 -7
- package/dist/{collection-list-QQJAESFN.js → collection-list-EIDV4DEH.js} +11 -11
- package/dist/{collection-metadata-QUMWZABV.js → collection-metadata-IKYBHHEU.js} +2 -2
- package/dist/{commission-rule-create-CDLLQIY4.js → commission-rule-create-QDNXXBTV.js} +64 -30
- package/dist/{commission-rule-detail-CIE6TPXW.js → commission-rule-detail-QYJIK375.js} +3 -5
- package/dist/{commission-rule-edit-5CFKPI7U.js → commission-rule-edit-HICDPDLK.js} +58 -24
- package/dist/{commissions-list-US6OMDVL.js → commissions-list-AQUW636T.js} +6 -6
- package/dist/{customer-detail-CGKGZE2N.js → customer-detail-TBGKTNQQ.js} +8 -8
- package/dist/{customer-group-add-customers-XYWJSXKS.js → customer-group-add-customers-RWJOA2NJ.js} +3 -3
- package/dist/{customer-group-detail-JMBR3D72.js → customer-group-detail-47IPD337.js} +6 -7
- package/dist/{customer-group-list-GYEQ2GTL.js → customer-group-list-Q2AYIVO4.js} +6 -7
- package/dist/{customer-group-metadata-UQ2SCLOK.js → customer-group-metadata-T3WFBL7U.js} +2 -2
- package/dist/{customer-list-6X6RQDLK.js → customer-list-JOPTF4QB.js} +5 -6
- package/dist/{customer-metadata-UEQSIGLT.js → customer-metadata-YSMWL4L3.js} +2 -2
- package/dist/{customers-add-customer-group-AZYAIQ7E.js → customers-add-customer-group-AVRYBS6Q.js} +13 -6
- package/dist/{edit-inventory-item-ENA2OFSQ.js → edit-inventory-item-7M7Q6HL4.js} +1 -1
- package/dist/{edit-inventory-item-attributes-Z26UDTSH.js → edit-inventory-item-attributes-E7J2WFPF.js} +1 -1
- package/dist/{edit-reservation-W3THLKKK.js → edit-reservation-S3QTQRPY.js} +11 -3
- package/dist/{edit-rules-3DCWA5UF.js → edit-rules-NRF7U4AT.js} +1 -1
- package/dist/{home-RT4EIJFM.js → home-KKOF4FWS.js} +3 -3
- package/dist/index.css +3 -0
- package/dist/index.d.ts +10 -28
- package/dist/index.js +431 -545
- package/dist/{inventory-detail-PMJN4E2D.js → inventory-detail-U6TRGZRY.js} +6 -6
- package/dist/{inventory-list-XS3OFHLW.js → inventory-list-JWA7U2LB.js} +4 -5
- package/dist/{inventory-metadata-OGS7JMZ5.js → inventory-metadata-KO622YEI.js} +2 -2
- package/dist/{inventory-stock-LDBJQCJF.js → inventory-stock-WWXYVFK2.js} +20 -10
- package/dist/{location-detail-DKBNATDD.js → location-detail-27FBZML7.js} +4 -6
- package/dist/{location-fulfillment-providers-JGJOTGMZ.js → location-fulfillment-providers-XTYJWAVP.js} +19 -11
- package/dist/{location-list-JJN42JSH.js → location-list-RMHT36AO.js} +4 -6
- package/dist/{location-sales-channels-FT6TFVXJ.js → location-sales-channels-JB5OIMXE.js} +13 -6
- package/dist/{location-service-zone-create-KPM4RSCF.js → location-service-zone-create-JKAKZCZ2.js} +3 -3
- package/dist/{location-service-zone-manage-areas-NW5JUTCH.js → location-service-zone-manage-areas-K2BMFI5Y.js} +3 -3
- package/dist/{location-service-zone-shipping-option-create-RYAIECRU.js → location-service-zone-shipping-option-create-WJOLO6A3.js} +3 -3
- package/dist/{location-service-zone-shipping-option-edit-UUIR7B5S.js → location-service-zone-shipping-option-edit-I7BJGH76.js} +23 -10
- package/dist/{location-service-zone-shipping-option-pricing-Z5HCXRHG.js → location-service-zone-shipping-option-pricing-47Y3CP4U.js} +36 -12
- package/dist/{login-72TAMW53.js → login-ISNIWXU2.js} +1 -1
- package/dist/{manage-locations-TCMY6A4J.js → manage-locations-5FKFNJQN.js} +13 -2
- package/dist/{marketplace-add-currencies-Z6FUIAU5.js → marketplace-add-currencies-34XKWMI7.js} +33 -9
- package/dist/{marketplace-detail-UYBZIFQW.js → marketplace-detail-A76FTENH.js} +6 -6
- package/dist/{marketplace-edit-G7YNGABC.js → marketplace-edit-KXKUECZQ.js} +61 -30
- package/dist/{marketplace-metadata-2TZTRDRJ.js → marketplace-metadata-364KJG43.js} +2 -2
- package/dist/{offer-detail-page-XU6XK6YR.js → offer-detail-page-BDDDZSPL.js} +19 -8
- package/dist/{offer-variant-detail-page-FVJE5WLV.js → offer-variant-detail-page-HQU4HMZH.js} +4 -5
- package/dist/{offers-RS4UORI3.js → offers-OVX5AAQL.js} +6 -7
- package/dist/{order-create-claim-PPUQXVYH.js → order-create-claim-4ERPSGPD.js} +103 -59
- package/dist/{order-create-edit-QH25BOIU.js → order-create-edit-BGLNMKKI.js} +15 -8
- package/dist/{order-create-exchange-5PCJ25LK.js → order-create-exchange-TOPPZZGS.js} +104 -60
- package/dist/{order-create-refund-ZWMXQGUA.js → order-create-refund-M3K5MZDM.js} +38 -23
- package/dist/{order-create-return-ECGHPLEZ.js → order-create-return-64GZ2LCL.js} +107 -68
- package/dist/{order-detail-XYHRY25Y.js → order-detail-DIUKR6ZJ.js} +7 -7
- package/dist/{order-edit-billing-address-V6QS5DYF.js → order-edit-billing-address-CCRTK5E2.js} +2 -2
- package/dist/{order-edit-email-AGJU7YHU.js → order-edit-email-V45SEUCO.js} +1 -1
- package/dist/{order-edit-shipping-address-TKLEEHOE.js → order-edit-shipping-address-45Z6TNHL.js} +1 -1
- package/dist/{order-list-L2WZX5ED.js → order-list-C7PHMQ64.js} +5 -5
- package/dist/{order-metadata-NVC3A3A5.js → order-metadata-7245QRUQ.js} +2 -2
- package/dist/{order-request-transfer-7EZX5UOQ.js → order-request-transfer-JYPDXCY2.js} +27 -13
- package/dist/pages/index.d.ts +2 -2
- package/dist/pages/index.js +88 -88
- package/dist/{payout-list-WZ6QMJJY.js → payout-list-KILGQ4XP.js} +3 -3
- package/dist/{price-list-create-DRKZIV2D.js → price-list-create-UZRCHVU7.js} +9 -9
- package/dist/{price-list-customer-availability-WU2OGO37.js → price-list-customer-availability-CQY55U4O.js} +31 -14
- package/dist/{price-list-detail-AML5XNDJ.js → price-list-detail-IL7VSABK.js} +6 -7
- package/dist/{price-list-list-FPCLLS33.js → price-list-list-TD5JIO7L.js} +5 -5
- package/dist/{price-list-prices-add-HAYZV2XV.js → price-list-prices-add-DSRYUJUT.js} +8 -8
- package/dist/{price-list-prices-edit-S4V5ACN3.js → price-list-prices-edit-WELHT4O4.js} +18 -9
- package/dist/{product-add-existing-attributes-VWM3LNIO.js → product-add-existing-attributes-RPIHTSCE.js} +7 -5
- package/dist/{product-create-73WXVANY.js → product-create-PMV3LO62.js} +9 -9
- package/dist/{product-detail-ZKQXB7PH.js → product-detail-KVLZYO76.js} +6 -7
- package/dist/{product-edit-attribute-W3AS47FM.js → product-edit-attribute-URHTZ2EQ.js} +9 -3
- package/dist/{product-list-SYMPZR6W.js → product-list-M6B42KCG.js} +6 -7
- package/dist/{product-media-6XS74AU3.js → product-media-R2FIBFR5.js} +2 -2
- package/dist/{product-metadata-GKQUURAL.js → product-metadata-SC5BXN66.js} +2 -2
- package/dist/{product-organization-3PIQ4IY2.js → product-organization-BSPYZYZR.js} +87 -43
- package/dist/{product-sales-channels-PJNEIY4J.js → product-sales-channels-MNAFJKAI.js} +10 -5
- package/dist/{product-shipping-profile-SWB5FK7S.js → product-shipping-profile-G4NCDKSR.js} +25 -11
- package/dist/{product-tag-create-SYOFR5EK.js → product-tag-create-PX7Q2AXU.js} +1 -1
- package/dist/{product-tag-detail-Q3CKJBVX.js → product-tag-detail-LXO43RMB.js} +11 -11
- package/dist/{product-tag-edit-FJPBCFBH.js → product-tag-edit-PXSZMCCT.js} +1 -1
- package/dist/{product-tag-list-BNNJS67H.js → product-tag-list-XWTZGQTT.js} +11 -11
- package/dist/{product-tag-metadata-WQEGISQ5.js → product-tag-metadata-2SO7ICOZ.js} +2 -2
- package/dist/{product-type-detail-WZLA27WI.js → product-type-detail-NO4PKFYQ.js} +6 -7
- package/dist/{product-type-list-PAAE6ZSR.js → product-type-list-JXU3446J.js} +5 -5
- package/dist/{product-type-metadata-WCGB3U4N.js → product-type-metadata-7D3J3NSO.js} +2 -2
- package/dist/{product-variant-detail-7B26FRNG.js → product-variant-detail-VQ55W7PD.js} +3 -5
- package/dist/{product-variant-edit-UC34WTO7.js → product-variant-edit-3WSHMGDI.js} +1 -1
- package/dist/{product-variant-metadata-CTKNNNLM.js → product-variant-metadata-KFLIOCU2.js} +2 -2
- package/dist/{profile-detail-GDQQJUWF.js → profile-detail-SQZ6JFAN.js} +3 -5
- package/dist/{profile-edit-ZBD6N5SC.js → profile-edit-IVU3SBQA.js} +3 -3
- package/dist/{promotion-add-campaign-VAF3HTLK.js → promotion-add-campaign-SWTS4TM5.js} +2 -1
- package/dist/{promotion-create-FKRGXGI4.js → promotion-create-6TMK6PEP.js} +4 -3
- package/dist/{promotion-detail-HOXUK5VG.js → promotion-detail-WBTMSCTX.js} +6 -8
- package/dist/{promotion-list-LJKKLZNU.js → promotion-list-FPOTDLHX.js} +9 -9
- package/dist/{refund-reason-create-TOH2D225.js → refund-reason-create-HZOBFOPB.js} +1 -1
- package/dist/{refund-reason-edit-B32E4WHH.js → refund-reason-edit-KS6NMC22.js} +1 -1
- package/dist/{refund-reason-list-3YLXKHJX.js → refund-reason-list-4T7DIRZV.js} +5 -6
- package/dist/{region-add-countries-4CTAVHYW.js → region-add-countries-47QLUMX7.js} +2 -2
- package/dist/{region-create-S2WUJ4RA.js → region-create-7DI3QEPU.js} +25 -11
- package/dist/{region-detail-YTB7OEQU.js → region-detail-S5OT2PGL.js} +4 -5
- package/dist/{region-edit-NUMG2V5L.js → region-edit-IXCS3MRH.js} +32 -14
- package/dist/{region-list-JP3CZISQ.js → region-list-2MWAGD2D.js} +4 -5
- package/dist/{region-metadata-NAHNXAHQ.js → region-metadata-ADPG7OLJ.js} +2 -2
- package/dist/{reservation-create-H3T3AHTK.js → reservation-create-YEICXID2.js} +67 -44
- package/dist/{reservation-detail-M42OB6BC.js → reservation-detail-EBIDXEVF.js} +3 -5
- package/dist/{reservation-list-FQAWE7S5.js → reservation-list-5QNXC2WU.js} +4 -5
- package/dist/{reservation-metadata-AKR6FRG5.js → reservation-metadata-TWJE777O.js} +2 -2
- package/dist/{reset-password-RJ5VSBQV.js → reset-password-3YLCNWLP.js} +1 -1
- package/dist/{return-reason-list-PKAJDA6A.js → return-reason-list-BDR7VUEV.js} +5 -5
- package/dist/{review-detail-K555FECH.js → review-detail-NPB3OKCE.js} +2 -4
- package/dist/{review-list-5NGJJH23.js → review-list-NXBVRP5T.js} +4 -5
- package/dist/{sales-channel-add-products-RRTMXVAT.js → sales-channel-add-products-VAHBFZP3.js} +15 -6
- package/dist/{sales-channel-detail-7GAGHWEP.js → sales-channel-detail-A7HHMQVX.js} +6 -7
- package/dist/{sales-channel-list-BCL62DTX.js → sales-channel-list-246V7NV3.js} +4 -6
- package/dist/{sales-channel-metadata-BKNILVQ2.js → sales-channel-metadata-PMLMQIKU.js} +2 -2
- package/dist/settings-UYGKDTNO.js +63 -0
- package/dist/{shipping-option-type-create-ZVOMA222.js → shipping-option-type-create-NOFP2DOM.js} +1 -1
- package/dist/{shipping-option-type-detail-2VDQWYDS.js → shipping-option-type-detail-47AZVCFP.js} +3 -5
- package/dist/{shipping-option-type-edit-CZFRAZPJ.js → shipping-option-type-edit-42JILKHX.js} +1 -1
- package/dist/{shipping-option-type-list-2XUYXURQ.js → shipping-option-type-list-TTAA63ZN.js} +6 -6
- package/dist/{shipping-profile-detail-7SE5GLQZ.js → shipping-profile-detail-RGB67K3C.js} +2 -4
- package/dist/{shipping-profile-metadata-UEZYRBZQ.js → shipping-profile-metadata-GXMY5E57.js} +2 -2
- package/dist/{shipping-profiles-list-GC6AK77V.js → shipping-profiles-list-DD3G2THE.js} +4 -5
- package/dist/{store-create-JBY2MAIT.js → store-create-UQ333C5F.js} +36 -14
- package/dist/{store-details-MPTCI4VG.js → store-details-OAONJZHB.js} +8 -9
- package/dist/{store-edit-BXWV5H4Z.js → store-edit-6Q3GLLJE.js} +2 -2
- package/dist/{store-list-LPKSZF2E.js → store-list-PANSKKVA.js} +10 -11
- package/dist/{store-member-invite-A2WAB5GK.js → store-member-invite-235YGK55.js} +14 -5
- package/dist/{tax-region-create-OGVIIVMO.js → tax-region-create-ECRRD74Z.js} +2 -2
- package/dist/{tax-region-detail-3CMIPIKA.js → tax-region-detail-PU4Q42KO.js} +7 -8
- package/dist/{tax-region-edit-DUBTSOQ4.js → tax-region-edit-P4L2CUFV.js} +1 -1
- package/dist/{tax-region-list-U5JRCQZI.js → tax-region-list-PUNXDH34.js} +5 -6
- package/dist/{tax-region-metadata-KHODQCDW.js → tax-region-metadata-EDZ7YGYR.js} +2 -2
- package/dist/{tax-region-province-detail-XTPJ6DZZ.js → tax-region-province-detail-3ZQOCKZ2.js} +6 -7
- package/dist/{tax-region-tax-override-create-NMLHLS7J.js → tax-region-tax-override-create-CPWWLRMI.js} +10 -10
- package/dist/{tax-region-tax-override-edit-4SJ3DRAF.js → tax-region-tax-override-edit-TQCB5GSO.js} +41 -21
- package/dist/{user-detail-RD3T5WQT.js → user-detail-4H37KBIP.js} +3 -5
- package/dist/{user-edit-Y5VP6CKB.js → user-edit-42A2VX5E.js} +1 -1
- package/dist/{user-invite-4JFF3NRW.js → user-invite-5EJ3CIQZ.js} +5 -4
- package/dist/{user-list-X6UZ6UZM.js → user-list-EZ56HFI3.js} +5 -6
- package/dist/{user-metadata-XNM2JNNO.js → user-metadata-3GENWLUS.js} +2 -2
- package/package.json +6 -6
- package/dist/chunk-BDGZ4EQO.js +0 -86
- package/dist/settings-AVE3VCCM.js +0 -19
- package/dist/{customer-edit-5EH2AUGN.js → customer-edit-LDKAXHZ6.js} +3 -3
- package/dist/{store-bulk-edit-FQPQQR46.js → store-bulk-edit-XWDZQPFO.js} +1 -1
|
@@ -29,6 +29,7 @@ import {
|
|
|
29
29
|
useStackedModal
|
|
30
30
|
} from "./chunk-FWJLS7XD.js";
|
|
31
31
|
import "./chunk-3QSRE5LS.js";
|
|
32
|
+
import "./chunk-LAVHRER2.js";
|
|
32
33
|
import {
|
|
33
34
|
useRegions
|
|
34
35
|
} from "./chunk-2SCR7R3C.js";
|
|
@@ -43,7 +44,6 @@ import {
|
|
|
43
44
|
useUpdateShippingOptions
|
|
44
45
|
} from "./chunk-SCLV2T6Z.js";
|
|
45
46
|
import "./chunk-H5E3CGD7.js";
|
|
46
|
-
import "./chunk-LAVHRER2.js";
|
|
47
47
|
import "./chunk-Y7QKP6QU.js";
|
|
48
48
|
import "./chunk-INNFZYX2.js";
|
|
49
49
|
import "./chunk-RHKRREUU.js";
|
|
@@ -52,6 +52,7 @@ import "./chunk-DTGEFKK4.js";
|
|
|
52
52
|
import "./chunk-NBMM2TZK.js";
|
|
53
53
|
|
|
54
54
|
// src/pages/locations/location-service-zone-shipping-option-pricing/location-service-zone-shipping-option-pricing.tsx
|
|
55
|
+
import { SectionNoAccess as SectionNoAccess2, isForbidden as isForbidden2, useCan as useCan2 } from "@mercurjs/dashboard-shared";
|
|
55
56
|
import { useTranslation as useTranslation2 } from "react-i18next";
|
|
56
57
|
import { useParams } from "react-router-dom";
|
|
57
58
|
|
|
@@ -61,8 +62,9 @@ import { useMemo, useState } from "react";
|
|
|
61
62
|
import { useForm } from "react-hook-form";
|
|
62
63
|
import * as zod from "zod";
|
|
63
64
|
import { Button, toast } from "@medusajs/ui";
|
|
65
|
+
import { SectionNoAccess, isForbidden, useCan } from "@mercurjs/dashboard-shared";
|
|
64
66
|
import { useTranslation } from "react-i18next";
|
|
65
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
67
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
66
68
|
var EditShippingOptionPricingSchema = zod.object({
|
|
67
69
|
region_prices: zod.record(
|
|
68
70
|
zod.string(),
|
|
@@ -111,15 +113,19 @@ function EditShippingOptionsPricingForm({
|
|
|
111
113
|
() => store?.supported_currencies?.map((c) => c.currency_code) || [],
|
|
112
114
|
[store]
|
|
113
115
|
);
|
|
116
|
+
const canViewRegions = useCan("regions");
|
|
114
117
|
const {
|
|
115
118
|
regions,
|
|
116
119
|
isLoading: isRegionsLoading,
|
|
117
120
|
isError: isRegionsError,
|
|
118
121
|
error: regionsError
|
|
119
|
-
} = useRegions(
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
122
|
+
} = useRegions(
|
|
123
|
+
{
|
|
124
|
+
fields: "id,name,currency_code",
|
|
125
|
+
limit: 999
|
|
126
|
+
},
|
|
127
|
+
{ enabled: canViewRegions }
|
|
128
|
+
);
|
|
123
129
|
const { price_preferences: pricePreferences } = usePricePreferences({});
|
|
124
130
|
const { setCloseOnEscape } = useRouteModal();
|
|
125
131
|
const columns = useShippingOptionPriceColumns({
|
|
@@ -202,6 +208,12 @@ function EditShippingOptionsPricingForm({
|
|
|
202
208
|
if (isStoreError) {
|
|
203
209
|
throw storeError;
|
|
204
210
|
}
|
|
211
|
+
if (!canViewRegions || isForbidden(regionsError)) {
|
|
212
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
213
|
+
/* @__PURE__ */ jsx(RouteFocusModal.Header, {}),
|
|
214
|
+
/* @__PURE__ */ jsx(RouteFocusModal.Body, { children: /* @__PURE__ */ jsx(SectionNoAccess, {}) })
|
|
215
|
+
] });
|
|
216
|
+
}
|
|
205
217
|
if (isRegionsError) {
|
|
206
218
|
throw regionsError;
|
|
207
219
|
}
|
|
@@ -338,7 +350,7 @@ var getDefaultValues = (prices) => {
|
|
|
338
350
|
};
|
|
339
351
|
|
|
340
352
|
// src/pages/locations/location-service-zone-shipping-option-pricing/location-service-zone-shipping-option-pricing.tsx
|
|
341
|
-
import { jsx as jsx2 } from "react/jsx-runtime";
|
|
353
|
+
import { Fragment as Fragment2, jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
342
354
|
function LocationServiceZoneShippingOptionPricing() {
|
|
343
355
|
const { t } = useTranslation2();
|
|
344
356
|
const { so_id, location_id } = useParams();
|
|
@@ -348,17 +360,29 @@ function LocationServiceZoneShippingOptionPricing() {
|
|
|
348
360
|
{ status: 404, headers: { "Content-Type": "application/json" } }
|
|
349
361
|
);
|
|
350
362
|
}
|
|
363
|
+
const canViewShippingOptions = useCan2("shipping_options");
|
|
351
364
|
const {
|
|
352
365
|
shipping_option: shippingOption,
|
|
353
366
|
isError,
|
|
354
367
|
error
|
|
355
|
-
} = useShippingOption(
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
368
|
+
} = useShippingOption(
|
|
369
|
+
so_id,
|
|
370
|
+
{
|
|
371
|
+
fields: "*prices,*prices.price_rules"
|
|
372
|
+
},
|
|
373
|
+
{ enabled: canViewShippingOptions }
|
|
374
|
+
);
|
|
375
|
+
const forbidden = !canViewShippingOptions || isForbidden2(error);
|
|
376
|
+
if (isError && !forbidden) {
|
|
359
377
|
throw error;
|
|
360
378
|
}
|
|
361
|
-
return /* @__PURE__ */
|
|
379
|
+
return /* @__PURE__ */ jsxs2(RouteFocusModal, { prev: `/settings/locations/${location_id}`, "data-testid": "location-shipping-option-pricing-modal", children: [
|
|
380
|
+
forbidden && /* @__PURE__ */ jsxs2(Fragment2, { children: [
|
|
381
|
+
/* @__PURE__ */ jsx2(RouteFocusModal.Header, {}),
|
|
382
|
+
/* @__PURE__ */ jsx2(RouteFocusModal.Body, { children: /* @__PURE__ */ jsx2(SectionNoAccess2, {}) })
|
|
383
|
+
] }),
|
|
384
|
+
!forbidden && shippingOption && /* @__PURE__ */ jsx2(EditShippingOptionsPricingForm, { shippingOption })
|
|
385
|
+
] });
|
|
362
386
|
}
|
|
363
387
|
export {
|
|
364
388
|
LocationServiceZoneShippingOptionPricing as Component
|
|
@@ -21,7 +21,7 @@ import "./chunk-AQHEU7OA.js";
|
|
|
21
21
|
import "./chunk-JW5SGRFC.js";
|
|
22
22
|
import "./chunk-AEBQQ2EG.js";
|
|
23
23
|
import "./chunk-CMVQ5SAG.js";
|
|
24
|
-
import "./chunk-
|
|
24
|
+
import "./chunk-AZV22U4V.js";
|
|
25
25
|
import "./chunk-2SCR7R3C.js";
|
|
26
26
|
import "./chunk-YMMREB3P.js";
|
|
27
27
|
import "./chunk-UNS2F7DK.js";
|
|
@@ -19,10 +19,12 @@ import "./chunk-NBMM2TZK.js";
|
|
|
19
19
|
|
|
20
20
|
// src/pages/inventory/inventory-detail/components/manage-locations/manage-locations-drawer.tsx
|
|
21
21
|
import { Heading } from "@medusajs/ui";
|
|
22
|
+
import { SectionNoAccess, useCan as useCan2 } from "@mercurjs/dashboard-shared";
|
|
22
23
|
import { useTranslation as useTranslation3 } from "react-i18next";
|
|
23
24
|
import { useParams } from "react-router-dom";
|
|
24
25
|
|
|
25
26
|
// src/pages/inventory/inventory-detail/components/manage-locations/components/manage-locations-form.tsx
|
|
27
|
+
import { useCan } from "@mercurjs/dashboard-shared";
|
|
26
28
|
import { Button, Text as Text2, toast as toast2 } from "@medusajs/ui";
|
|
27
29
|
import { useTranslation as useTranslation2 } from "react-i18next";
|
|
28
30
|
import { useMemo as useMemo2, useState as useState2 } from "react";
|
|
@@ -234,7 +236,11 @@ var ManageLocationsForm = ({
|
|
|
234
236
|
const [selectedLocationIds, setSelectedLocationIds] = useState2(
|
|
235
237
|
existingLocationLevels
|
|
236
238
|
);
|
|
237
|
-
const
|
|
239
|
+
const canViewLocations = useCan("stock_locations");
|
|
240
|
+
const { count } = useStockLocations(
|
|
241
|
+
{ limit: 1, fields: "id" },
|
|
242
|
+
{ enabled: canViewLocations }
|
|
243
|
+
);
|
|
238
244
|
const handleLocationSelect = (locationId, selected) => {
|
|
239
245
|
setSelectedLocationIds((prev) => {
|
|
240
246
|
const newSet = new Set(prev);
|
|
@@ -353,7 +359,11 @@ var ManageLocationsDrawer = () => {
|
|
|
353
359
|
} = useInventoryItem(id, {
|
|
354
360
|
fields: "id,sku,title,*location_levels,offers.seller_id"
|
|
355
361
|
});
|
|
356
|
-
const
|
|
362
|
+
const canViewLocations = useCan2("stock_locations");
|
|
363
|
+
const { stock_locations, isLoading: loadingLocations } = useStockLocations(
|
|
364
|
+
void 0,
|
|
365
|
+
{ enabled: canViewLocations }
|
|
366
|
+
);
|
|
357
367
|
const ready = !isLoading && !loadingLocations && inventoryItem && stock_locations;
|
|
358
368
|
if (isError) {
|
|
359
369
|
throw error;
|
|
@@ -361,6 +371,7 @@ var ManageLocationsDrawer = () => {
|
|
|
361
371
|
const sellerId = inventoryItem?.offers?.[0]?.seller_id;
|
|
362
372
|
return /* @__PURE__ */ jsxs4(RouteDrawer, { "data-testid": "inventory-manage-locations-drawer", children: [
|
|
363
373
|
/* @__PURE__ */ jsx5(RouteDrawer.Header, { "data-testid": "inventory-manage-locations-drawer-header", children: /* @__PURE__ */ jsx5(RouteDrawer.Title, { asChild: true, children: /* @__PURE__ */ jsx5(Heading, { "data-testid": "inventory-manage-locations-drawer-title", children: t("inventory.manageLocations") }) }) }),
|
|
374
|
+
!canViewLocations && /* @__PURE__ */ jsx5(SectionNoAccess, {}),
|
|
364
375
|
ready && /* @__PURE__ */ jsx5(
|
|
365
376
|
ManageLocationsForm,
|
|
366
377
|
{
|
package/dist/{marketplace-add-currencies-Z6FUIAU5.js → marketplace-add-currencies-34XKWMI7.js}
RENAMED
|
@@ -13,15 +13,16 @@ import {
|
|
|
13
13
|
useRouteModal
|
|
14
14
|
} from "./chunk-FWJLS7XD.js";
|
|
15
15
|
import "./chunk-3QSRE5LS.js";
|
|
16
|
+
import "./chunk-LAVHRER2.js";
|
|
16
17
|
import "./chunk-THHRRYRS.js";
|
|
17
18
|
import "./chunk-FQERBIVS.js";
|
|
18
19
|
import {
|
|
19
20
|
_DataTable,
|
|
20
21
|
useDataTable
|
|
21
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-SU36MZXC.js";
|
|
22
23
|
import "./chunk-YN3FGNJM.js";
|
|
23
24
|
import "./chunk-ZAOEFQ6K.js";
|
|
24
|
-
import "./chunk-
|
|
25
|
+
import "./chunk-4J74G7N2.js";
|
|
25
26
|
import "./chunk-EIWPJWKF.js";
|
|
26
27
|
import "./chunk-46WEBDVJ.js";
|
|
27
28
|
import {
|
|
@@ -35,7 +36,6 @@ import {
|
|
|
35
36
|
pricePreferencesQueryKeys,
|
|
36
37
|
usePricePreferences
|
|
37
38
|
} from "./chunk-FHZHKIWI.js";
|
|
38
|
-
import "./chunk-LAVHRER2.js";
|
|
39
39
|
import "./chunk-Y7QKP6QU.js";
|
|
40
40
|
import "./chunk-INNFZYX2.js";
|
|
41
41
|
import {
|
|
@@ -45,6 +45,13 @@ import "./chunk-ZA2KFUFR.js";
|
|
|
45
45
|
import "./chunk-DTGEFKK4.js";
|
|
46
46
|
import "./chunk-NBMM2TZK.js";
|
|
47
47
|
|
|
48
|
+
// src/pages/marketplace/marketplace-add-currencies/marketplace-add-currencies.tsx
|
|
49
|
+
import {
|
|
50
|
+
SectionNoAccess as SectionNoAccess2,
|
|
51
|
+
isForbidden as isForbidden2,
|
|
52
|
+
usePermissions
|
|
53
|
+
} from "@mercurjs/dashboard-shared";
|
|
54
|
+
|
|
48
55
|
// src/pages/marketplace/marketplace-add-currencies/components/add-currencies-form/add-currencies-form.tsx
|
|
49
56
|
import { Button, Checkbox, Hint, Switch, toast, Tooltip } from "@medusajs/ui";
|
|
50
57
|
import {
|
|
@@ -54,9 +61,10 @@ import { useCallback, useMemo, useState } from "react";
|
|
|
54
61
|
import { useTranslation } from "react-i18next";
|
|
55
62
|
import * as zod from "zod";
|
|
56
63
|
import { zodResolver } from "@hookform/resolvers/zod";
|
|
64
|
+
import { SectionNoAccess, isForbidden } from "@mercurjs/dashboard-shared";
|
|
57
65
|
import { keepPreviousData } from "@tanstack/react-query";
|
|
58
66
|
import { useForm } from "react-hook-form";
|
|
59
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
67
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
60
68
|
var AddCurrenciesSchema = zod.object({
|
|
61
69
|
currencies: zod.array(zod.string()).min(1),
|
|
62
70
|
pricePreferences: zod.record(zod.boolean())
|
|
@@ -164,6 +172,12 @@ var AddCurrenciesForm = ({
|
|
|
164
172
|
}
|
|
165
173
|
);
|
|
166
174
|
});
|
|
175
|
+
if (isForbidden(error)) {
|
|
176
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
177
|
+
/* @__PURE__ */ jsx(RouteFocusModal.Header, {}),
|
|
178
|
+
/* @__PURE__ */ jsx(RouteFocusModal.Body, { children: /* @__PURE__ */ jsx(SectionNoAccess, {}) })
|
|
179
|
+
] });
|
|
180
|
+
}
|
|
167
181
|
if (isError) {
|
|
168
182
|
throw error;
|
|
169
183
|
}
|
|
@@ -272,8 +286,11 @@ var useColumns = (pricePreferences, setPricePreferences) => {
|
|
|
272
286
|
};
|
|
273
287
|
|
|
274
288
|
// src/pages/marketplace/marketplace-add-currencies/marketplace-add-currencies.tsx
|
|
275
|
-
import { jsx as jsx2 } from "react/jsx-runtime";
|
|
289
|
+
import { Fragment as Fragment2, jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
276
290
|
var MarketplaceAddCurrencies = () => {
|
|
291
|
+
const { can } = usePermissions();
|
|
292
|
+
const canViewCurrencies = can("regions");
|
|
293
|
+
const canViewPreferences = can("price_preferences");
|
|
277
294
|
const { store, isPending, isError, error } = useStore();
|
|
278
295
|
const {
|
|
279
296
|
price_preferences: pricePreferences,
|
|
@@ -286,17 +303,24 @@ var MarketplaceAddCurrencies = () => {
|
|
|
286
303
|
value: store?.supported_currencies?.map((c) => c.currency_code)
|
|
287
304
|
},
|
|
288
305
|
{
|
|
289
|
-
enabled: !!store
|
|
306
|
+
enabled: !!store && canViewPreferences
|
|
290
307
|
}
|
|
291
308
|
);
|
|
292
|
-
const
|
|
309
|
+
const forbidden = !canViewCurrencies || !canViewPreferences || isForbidden2(pricePreferencesError);
|
|
310
|
+
const ready = !forbidden && !!store && !isPending && !!pricePreferences && !isPricePreferencesPending;
|
|
293
311
|
if (isError) {
|
|
294
312
|
throw error;
|
|
295
313
|
}
|
|
296
|
-
if (isPricePreferencesError) {
|
|
314
|
+
if (isPricePreferencesError && !forbidden) {
|
|
297
315
|
throw pricePreferencesError;
|
|
298
316
|
}
|
|
299
|
-
return /* @__PURE__ */
|
|
317
|
+
return /* @__PURE__ */ jsxs2(RouteFocusModal, { children: [
|
|
318
|
+
forbidden && /* @__PURE__ */ jsxs2(Fragment2, { children: [
|
|
319
|
+
/* @__PURE__ */ jsx2(RouteFocusModal.Header, {}),
|
|
320
|
+
/* @__PURE__ */ jsx2(RouteFocusModal.Body, { children: /* @__PURE__ */ jsx2(SectionNoAccess2, {}) })
|
|
321
|
+
] }),
|
|
322
|
+
ready && /* @__PURE__ */ jsx2(AddCurrenciesForm, { store, pricePreferences })
|
|
323
|
+
] });
|
|
300
324
|
};
|
|
301
325
|
export {
|
|
302
326
|
MarketplaceAddCurrencies as Component
|
|
@@ -1,21 +1,22 @@
|
|
|
1
1
|
import {
|
|
2
2
|
MarketplaceDetailPage
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-AW4RL2SA.js";
|
|
4
4
|
import "./chunk-64XMEZ5A.js";
|
|
5
5
|
import "./chunk-JHIMVLB2.js";
|
|
6
6
|
import "./chunk-DB6ANJBO.js";
|
|
7
7
|
import "./chunk-PHOCVOZ5.js";
|
|
8
|
+
import "./chunk-LAVHRER2.js";
|
|
8
9
|
import "./chunk-E74OUNA3.js";
|
|
9
10
|
import "./chunk-H6MYB7GB.js";
|
|
10
11
|
import "./chunk-THHRRYRS.js";
|
|
11
12
|
import "./chunk-FQERBIVS.js";
|
|
12
|
-
import "./chunk-
|
|
13
|
+
import "./chunk-SU36MZXC.js";
|
|
13
14
|
import "./chunk-YN3FGNJM.js";
|
|
14
15
|
import "./chunk-ZAOEFQ6K.js";
|
|
15
|
-
import "./chunk-
|
|
16
|
+
import "./chunk-4J74G7N2.js";
|
|
16
17
|
import "./chunk-EIWPJWKF.js";
|
|
17
18
|
import "./chunk-46WEBDVJ.js";
|
|
18
|
-
import "./chunk-
|
|
19
|
+
import "./chunk-3UOYBH5O.js";
|
|
19
20
|
import "./chunk-W5U6NPSN.js";
|
|
20
21
|
import "./chunk-DSQRFZCO.js";
|
|
21
22
|
import "./chunk-LHE6LM6S.js";
|
|
@@ -27,7 +28,7 @@ import "./chunk-AQHEU7OA.js";
|
|
|
27
28
|
import "./chunk-JW5SGRFC.js";
|
|
28
29
|
import "./chunk-AEBQQ2EG.js";
|
|
29
30
|
import "./chunk-CMVQ5SAG.js";
|
|
30
|
-
import "./chunk-
|
|
31
|
+
import "./chunk-AZV22U4V.js";
|
|
31
32
|
import "./chunk-2SCR7R3C.js";
|
|
32
33
|
import "./chunk-YMMREB3P.js";
|
|
33
34
|
import "./chunk-UNS2F7DK.js";
|
|
@@ -49,7 +50,6 @@ import "./chunk-HRMANL53.js";
|
|
|
49
50
|
import "./chunk-JC2FFAMW.js";
|
|
50
51
|
import "./chunk-OFW63WXL.js";
|
|
51
52
|
import "./chunk-SQ7J4KTS.js";
|
|
52
|
-
import "./chunk-LAVHRER2.js";
|
|
53
53
|
import "./chunk-Y7QKP6QU.js";
|
|
54
54
|
import "./chunk-INNFZYX2.js";
|
|
55
55
|
import "./chunk-Z476HUMI.js";
|
|
@@ -16,6 +16,9 @@ import {
|
|
|
16
16
|
import {
|
|
17
17
|
Form
|
|
18
18
|
} from "./chunk-3QSRE5LS.js";
|
|
19
|
+
import {
|
|
20
|
+
ConditionalTooltip
|
|
21
|
+
} from "./chunk-LAVHRER2.js";
|
|
19
22
|
import {
|
|
20
23
|
useStore,
|
|
21
24
|
useUpdateStore
|
|
@@ -41,6 +44,7 @@ import { Button, Input, Select, toast } from "@medusajs/ui";
|
|
|
41
44
|
import { useForm } from "react-hook-form";
|
|
42
45
|
import { useTranslation } from "react-i18next";
|
|
43
46
|
import { z } from "zod";
|
|
47
|
+
import { usePermissionGate } from "@mercurjs/dashboard-shared";
|
|
44
48
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
45
49
|
var EditStoreSchema = z.object({
|
|
46
50
|
name: z.string().min(1),
|
|
@@ -64,23 +68,29 @@ var EditMarketplaceForm = ({ store }) => {
|
|
|
64
68
|
resolver: zodResolver(EditStoreSchema)
|
|
65
69
|
});
|
|
66
70
|
const { mutateAsync, isPending } = useUpdateStore(store.id);
|
|
71
|
+
const regionsGate = usePermissionGate("regions:view");
|
|
72
|
+
const salesChannelsGate = usePermissionGate("sales_channels:view");
|
|
73
|
+
const locationsGate = usePermissionGate("stock_locations:view");
|
|
67
74
|
const regionsCombobox = useComboboxData({
|
|
68
75
|
queryKey: ["regions", "default_region_id"],
|
|
69
76
|
queryFn: (params) => sdk.admin.regions.query({ ...params, fields: "id,name" }),
|
|
70
77
|
defaultValue: store.default_region_id || void 0,
|
|
71
|
-
getOptions: (data) => data.regions.map((r) => ({ label: r.name, value: r.id }))
|
|
78
|
+
getOptions: (data) => data.regions.map((r) => ({ label: r.name, value: r.id })),
|
|
79
|
+
enabled: regionsGate.allowed
|
|
72
80
|
});
|
|
73
81
|
const salesChannelsCombobox = useComboboxData({
|
|
74
82
|
queryFn: (params) => sdk.admin.salesChannels.query({ ...params, fields: "id,name" }),
|
|
75
83
|
getOptions: (data) => data.sales_channels.map((sc) => ({ label: sc.name, value: sc.id })),
|
|
76
84
|
queryKey: ["sales_channels", "default_sales_channel_id"],
|
|
77
|
-
defaultValue: store.default_sales_channel_id || void 0
|
|
85
|
+
defaultValue: store.default_sales_channel_id || void 0,
|
|
86
|
+
enabled: salesChannelsGate.allowed
|
|
78
87
|
});
|
|
79
88
|
const locationsCombobox = useComboboxData({
|
|
80
89
|
queryFn: (params) => sdk.admin.stockLocations.query({ ...params, fields: "id,name" }),
|
|
81
90
|
getOptions: (data) => data.stock_locations.map((l) => ({ label: l.name, value: l.id })),
|
|
82
91
|
queryKey: ["stock_locations", "default_location_id"],
|
|
83
|
-
defaultValue: store.default_location_id || void 0
|
|
92
|
+
defaultValue: store.default_location_id || void 0,
|
|
93
|
+
enabled: locationsGate.allowed
|
|
84
94
|
});
|
|
85
95
|
const handleSubmit = form.handleSubmit(async (values) => {
|
|
86
96
|
const { default_currency_code, ...rest } = values;
|
|
@@ -157,17 +167,24 @@ var EditMarketplaceForm = ({ store }) => {
|
|
|
157
167
|
render: ({ field }) => {
|
|
158
168
|
return /* @__PURE__ */ jsxs(Form.Item, { "data-testid": "store-edit-form-region-item", children: [
|
|
159
169
|
/* @__PURE__ */ jsx(Form.Label, { "data-testid": "store-edit-form-region-label", children: t("store.defaultRegion") }),
|
|
160
|
-
/* @__PURE__ */ jsx(
|
|
161
|
-
|
|
170
|
+
/* @__PURE__ */ jsx(
|
|
171
|
+
ConditionalTooltip,
|
|
162
172
|
{
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
173
|
+
showTooltip: regionsGate.denied,
|
|
174
|
+
content: regionsGate.tooltip,
|
|
175
|
+
children: /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(Form.Control, { "data-testid": "store-edit-form-region-control", children: /* @__PURE__ */ jsx(
|
|
176
|
+
Combobox,
|
|
177
|
+
{
|
|
178
|
+
...field,
|
|
179
|
+
options: regionsCombobox.options,
|
|
180
|
+
searchValue: regionsCombobox.searchValue,
|
|
181
|
+
onSearchValueChange: regionsCombobox.onSearchValueChange,
|
|
182
|
+
disabled: regionsCombobox.disabled,
|
|
183
|
+
"data-testid": "store-edit-form-region-combobox"
|
|
184
|
+
}
|
|
185
|
+
) }) })
|
|
169
186
|
}
|
|
170
|
-
)
|
|
187
|
+
),
|
|
171
188
|
/* @__PURE__ */ jsx(Form.ErrorMessage, { "data-testid": "store-edit-form-region-error" })
|
|
172
189
|
] });
|
|
173
190
|
}
|
|
@@ -181,17 +198,24 @@ var EditMarketplaceForm = ({ store }) => {
|
|
|
181
198
|
render: ({ field }) => {
|
|
182
199
|
return /* @__PURE__ */ jsxs(Form.Item, { "data-testid": "store-edit-form-sales-channel-item", children: [
|
|
183
200
|
/* @__PURE__ */ jsx(Form.Label, { "data-testid": "store-edit-form-sales-channel-label", children: t("store.defaultSalesChannel") }),
|
|
184
|
-
/* @__PURE__ */ jsx(
|
|
185
|
-
|
|
201
|
+
/* @__PURE__ */ jsx(
|
|
202
|
+
ConditionalTooltip,
|
|
186
203
|
{
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
204
|
+
showTooltip: salesChannelsGate.denied,
|
|
205
|
+
content: salesChannelsGate.tooltip,
|
|
206
|
+
children: /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(Form.Control, { "data-testid": "store-edit-form-sales-channel-control", children: /* @__PURE__ */ jsx(
|
|
207
|
+
Combobox,
|
|
208
|
+
{
|
|
209
|
+
...field,
|
|
210
|
+
options: salesChannelsCombobox.options,
|
|
211
|
+
searchValue: salesChannelsCombobox.searchValue,
|
|
212
|
+
onSearchValueChange: salesChannelsCombobox.onSearchValueChange,
|
|
213
|
+
disabled: salesChannelsCombobox.disabled,
|
|
214
|
+
"data-testid": "store-edit-form-sales-channel-combobox"
|
|
215
|
+
}
|
|
216
|
+
) }) })
|
|
193
217
|
}
|
|
194
|
-
)
|
|
218
|
+
),
|
|
195
219
|
/* @__PURE__ */ jsx(Form.ErrorMessage, { "data-testid": "store-edit-form-sales-channel-error" })
|
|
196
220
|
] });
|
|
197
221
|
}
|
|
@@ -205,17 +229,24 @@ var EditMarketplaceForm = ({ store }) => {
|
|
|
205
229
|
render: ({ field }) => {
|
|
206
230
|
return /* @__PURE__ */ jsxs(Form.Item, { "data-testid": "store-edit-form-location-item", children: [
|
|
207
231
|
/* @__PURE__ */ jsx(Form.Label, { "data-testid": "store-edit-form-location-label", children: t("store.defaultLocation") }),
|
|
208
|
-
/* @__PURE__ */ jsx(
|
|
209
|
-
|
|
232
|
+
/* @__PURE__ */ jsx(
|
|
233
|
+
ConditionalTooltip,
|
|
210
234
|
{
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
235
|
+
showTooltip: locationsGate.denied,
|
|
236
|
+
content: locationsGate.tooltip,
|
|
237
|
+
children: /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(Form.Control, { "data-testid": "store-edit-form-location-control", children: /* @__PURE__ */ jsx(
|
|
238
|
+
Combobox,
|
|
239
|
+
{
|
|
240
|
+
...field,
|
|
241
|
+
options: locationsCombobox.options,
|
|
242
|
+
searchValue: locationsCombobox.searchValue,
|
|
243
|
+
onSearchValueChange: locationsCombobox.onSearchValueChange,
|
|
244
|
+
disabled: locationsCombobox.disabled,
|
|
245
|
+
"data-testid": "store-edit-form-location-combobox"
|
|
246
|
+
}
|
|
247
|
+
) }) })
|
|
217
248
|
}
|
|
218
|
-
)
|
|
249
|
+
),
|
|
219
250
|
/* @__PURE__ */ jsx(Form.ErrorMessage, { "data-testid": "store-edit-form-location-error" })
|
|
220
251
|
] });
|
|
221
252
|
}
|
|
@@ -8,6 +8,7 @@ import {
|
|
|
8
8
|
RouteDrawer
|
|
9
9
|
} from "./chunk-FWJLS7XD.js";
|
|
10
10
|
import "./chunk-3QSRE5LS.js";
|
|
11
|
+
import "./chunk-LAVHRER2.js";
|
|
11
12
|
import "./chunk-W5U6NPSN.js";
|
|
12
13
|
import "./chunk-DSQRFZCO.js";
|
|
13
14
|
import "./chunk-LHE6LM6S.js";
|
|
@@ -19,7 +20,7 @@ import "./chunk-AQHEU7OA.js";
|
|
|
19
20
|
import "./chunk-JW5SGRFC.js";
|
|
20
21
|
import "./chunk-AEBQQ2EG.js";
|
|
21
22
|
import "./chunk-CMVQ5SAG.js";
|
|
22
|
-
import "./chunk-
|
|
23
|
+
import "./chunk-AZV22U4V.js";
|
|
23
24
|
import "./chunk-2SCR7R3C.js";
|
|
24
25
|
import "./chunk-YMMREB3P.js";
|
|
25
26
|
import "./chunk-UNS2F7DK.js";
|
|
@@ -41,7 +42,6 @@ import "./chunk-HRMANL53.js";
|
|
|
41
42
|
import "./chunk-JC2FFAMW.js";
|
|
42
43
|
import "./chunk-OFW63WXL.js";
|
|
43
44
|
import "./chunk-SQ7J4KTS.js";
|
|
44
|
-
import "./chunk-LAVHRER2.js";
|
|
45
45
|
import "./chunk-Y7QKP6QU.js";
|
|
46
46
|
import "./chunk-INNFZYX2.js";
|
|
47
47
|
import "./chunk-Z476HUMI.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
OfferStoreSidebar
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-TVCHVG2A.js";
|
|
4
4
|
import {
|
|
5
5
|
OFFER_PRODUCT_DETAIL_FIELDS
|
|
6
6
|
} from "./chunk-IWBQZK6E.js";
|
|
@@ -16,7 +16,7 @@ import "./chunk-PHOCVOZ5.js";
|
|
|
16
16
|
import "./chunk-IQPN4PZJ.js";
|
|
17
17
|
import {
|
|
18
18
|
ProductMediaSection
|
|
19
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-AUCCE46Q.js";
|
|
20
20
|
import "./chunk-FI474ADU.js";
|
|
21
21
|
import {
|
|
22
22
|
SectionRow
|
|
@@ -35,19 +35,18 @@ import "./chunk-FQERBIVS.js";
|
|
|
35
35
|
import {
|
|
36
36
|
_DataTable,
|
|
37
37
|
useDataTable
|
|
38
|
-
} from "./chunk-
|
|
38
|
+
} from "./chunk-SU36MZXC.js";
|
|
39
39
|
import "./chunk-YN3FGNJM.js";
|
|
40
40
|
import "./chunk-ZAOEFQ6K.js";
|
|
41
|
-
import "./chunk-
|
|
41
|
+
import "./chunk-4J74G7N2.js";
|
|
42
42
|
import "./chunk-EIWPJWKF.js";
|
|
43
43
|
import "./chunk-46WEBDVJ.js";
|
|
44
44
|
import {
|
|
45
45
|
ActionMenu
|
|
46
|
-
} from "./chunk-
|
|
46
|
+
} from "./chunk-3UOYBH5O.js";
|
|
47
47
|
import {
|
|
48
48
|
useSeller
|
|
49
49
|
} from "./chunk-HRMANL53.js";
|
|
50
|
-
import "./chunk-LAVHRER2.js";
|
|
51
50
|
import "./chunk-Y7QKP6QU.js";
|
|
52
51
|
import {
|
|
53
52
|
TwoColumnPageSkeleton
|
|
@@ -63,7 +62,12 @@ import "./chunk-NBMM2TZK.js";
|
|
|
63
62
|
// src/pages/offers/[id]/offer-detail-page.tsx
|
|
64
63
|
import { Children } from "react";
|
|
65
64
|
import { useLoaderData, useParams, useSearchParams } from "react-router-dom";
|
|
66
|
-
import {
|
|
65
|
+
import {
|
|
66
|
+
isForbidden,
|
|
67
|
+
SectionNoAccess,
|
|
68
|
+
useLinkQuery,
|
|
69
|
+
WidgetZone
|
|
70
|
+
} from "@mercurjs/dashboard-shared";
|
|
67
71
|
|
|
68
72
|
// src/pages/offers/[id]/_components/offer-detail-general-section.tsx
|
|
69
73
|
import { Trash } from "@medusajs/icons";
|
|
@@ -160,6 +164,7 @@ var OfferDetailGeneralSection = ({
|
|
|
160
164
|
{
|
|
161
165
|
label: t("actions.delete"),
|
|
162
166
|
onClick: handleDelete,
|
|
167
|
+
permission: "offers:manage",
|
|
163
168
|
icon: /* @__PURE__ */ jsx(Trash, {}),
|
|
164
169
|
disabled: offerIds.length === 0
|
|
165
170
|
}
|
|
@@ -364,6 +369,7 @@ var useColumns = ({
|
|
|
364
369
|
{
|
|
365
370
|
icon: /* @__PURE__ */ jsx2(Trash2, {}),
|
|
366
371
|
label: t("actions.delete"),
|
|
372
|
+
permission: "offers:manage",
|
|
367
373
|
onClick: () => onDelete(row.original.offer.id, skuOf(row.original))
|
|
368
374
|
}
|
|
369
375
|
]
|
|
@@ -572,12 +578,14 @@ var OfferAssociatedProductSection = ({
|
|
|
572
578
|
};
|
|
573
579
|
|
|
574
580
|
// src/pages/offers/[id]/_components/offer-detail-store-section.tsx
|
|
581
|
+
import { useCan } from "@mercurjs/dashboard-shared";
|
|
575
582
|
import { jsx as jsx4 } from "react/jsx-runtime";
|
|
576
583
|
var OfferDetailStoreSection = ({
|
|
577
584
|
sellerId
|
|
578
585
|
}) => {
|
|
586
|
+
const canViewSellers = useCan("sellers");
|
|
579
587
|
const { seller } = useSeller(sellerId ?? "", void 0, {
|
|
580
|
-
enabled: !!sellerId
|
|
588
|
+
enabled: !!sellerId && canViewSellers
|
|
581
589
|
});
|
|
582
590
|
if (!sellerId) {
|
|
583
591
|
return null;
|
|
@@ -599,6 +607,9 @@ var Root = ({ children }) => {
|
|
|
599
607
|
{ initialData }
|
|
600
608
|
);
|
|
601
609
|
if (isError) {
|
|
610
|
+
if (isForbidden(error)) {
|
|
611
|
+
return /* @__PURE__ */ jsx5(SectionNoAccess, {});
|
|
612
|
+
}
|
|
602
613
|
throw error;
|
|
603
614
|
}
|
|
604
615
|
if (isLoading || !product) {
|
package/dist/{offer-variant-detail-page-FVJE5WLV.js → offer-variant-detail-page-HQU4HMZH.js}
RENAMED
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
OfferInventorySection,
|
|
3
3
|
OfferPricingSection,
|
|
4
4
|
OfferStoreSidebar
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-TVCHVG2A.js";
|
|
6
6
|
import {
|
|
7
7
|
OFFER_VARIANT_DETAIL_FIELDS
|
|
8
8
|
} from "./chunk-IWBQZK6E.js";
|
|
@@ -21,16 +21,15 @@ import {
|
|
|
21
21
|
} from "./chunk-E74OUNA3.js";
|
|
22
22
|
import "./chunk-H6MYB7GB.js";
|
|
23
23
|
import "./chunk-FQERBIVS.js";
|
|
24
|
-
import "./chunk-
|
|
24
|
+
import "./chunk-SU36MZXC.js";
|
|
25
25
|
import "./chunk-YN3FGNJM.js";
|
|
26
26
|
import "./chunk-ZAOEFQ6K.js";
|
|
27
27
|
import {
|
|
28
28
|
NoRecords
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-4J74G7N2.js";
|
|
30
30
|
import "./chunk-EIWPJWKF.js";
|
|
31
31
|
import "./chunk-46WEBDVJ.js";
|
|
32
|
-
import "./chunk-
|
|
33
|
-
import "./chunk-LAVHRER2.js";
|
|
32
|
+
import "./chunk-3UOYBH5O.js";
|
|
34
33
|
import "./chunk-Y7QKP6QU.js";
|
|
35
34
|
import {
|
|
36
35
|
TwoColumnPageSkeleton
|