@mercurjs/admin 2.3.6-canary.0 → 2.3.6-canary.10
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-PBGDZSCD.js → add-campaign-promotions-EIQFBRHD.js} +13 -8
- package/dist/{adjust-inventory-BBAU3NMM.js → adjust-inventory-H46YCNLT.js} +8 -3
- package/dist/{api-key-management-detail-ZGGQBQAM.js → api-key-management-detail-Z4KSJHUC.js} +6 -8
- package/dist/{api-key-management-list-T2WHT6MT.js → api-key-management-list-QZIRPINF.js} +5 -5
- package/dist/{api-key-management-sales-channels-FS3KXQQ6.js → api-key-management-sales-channels-RGZ3QITG.js} +9 -7
- package/dist/{attribute-create-C435ZHB2.js → attribute-create-7I5GNYFM.js} +6 -5
- package/dist/{attribute-detail-SPYDB3I5.js → attribute-detail-GP4PEFJ7.js} +17 -11
- package/dist/{attribute-edit-AAEAOP5B.js → attribute-edit-YNKCBXLU.js} +2 -2
- package/dist/{attribute-edit-possible-value-BJSQCTNO.js → attribute-edit-possible-value-XY7W42FB.js} +2 -2
- package/dist/{attribute-list-SCFBKH4L.js → attribute-list-ZC3CG5LS.js} +7 -7
- package/dist/{campaign-detail-BHRCOKL3.js → campaign-detail-OZWTK26Z.js} +11 -11
- package/dist/{campaign-list-GIMU2QVW.js → campaign-list-XCO4FJDZ.js} +5 -5
- package/dist/{categories-metadata-MJAYSCTW.js → categories-metadata-QYH5U77W.js} +3 -3
- package/dist/{category-detail-GVEDFNM7.js → category-detail-V2QUSUF3.js} +11 -12
- package/dist/{category-list-J7XYQDJU.js → category-list-XDOYTQ4X.js} +6 -6
- package/dist/{category-products-VVF5NXCE.js → category-products-DL4KV6NX.js} +16 -9
- package/dist/{chunk-NIDM2VQO.js → chunk-23CSVCQK.js} +28 -17
- package/dist/{chunk-DUFGVZ6H.js → chunk-25TWJMWE.js} +2 -2
- package/dist/{chunk-VTXMQTXK.js → chunk-26REB3B6.js} +4 -3
- package/dist/{chunk-ZH6TIKKW.js → chunk-2MOTQNEG.js} +1 -0
- package/dist/{chunk-M6X7KIBW.js → chunk-2XBNM6TM.js} +4 -4
- package/dist/{chunk-BQZ5P3IA.js → chunk-36KEGXUQ.js} +112 -75
- package/dist/{chunk-475XGX3J.js → chunk-3BKRMIWA.js} +24 -13
- package/dist/{chunk-NCDKLTDP.js → chunk-3H3BJSIK.js} +34 -12
- package/dist/chunk-3PPYNV2Q.js +268 -0
- package/dist/chunk-3UOYBH5O.js +8 -0
- package/dist/{chunk-GFHUI2QK.js → chunk-473QGQSA.js} +9 -6
- package/dist/{chunk-3XS5ADKJ.js → chunk-4AOVNA5G.js} +31 -20
- package/dist/{chunk-IKAUNMRC.js → chunk-4J74G7N2.js} +15 -3
- package/dist/{chunk-WIDHYDJQ.js → chunk-4JQDYQSX.js} +20 -10
- package/dist/{chunk-RW3NEG36.js → chunk-4W77EUYY.js} +9 -7
- package/dist/{chunk-6UYV7B42.js → chunk-4Y7SBHXE.js} +10 -8
- package/dist/{chunk-VVIJHBKM.js → chunk-5MXEKSK4.js} +1 -1
- package/dist/{chunk-AGO4ROOR.js → chunk-5OIFUF7R.js} +1 -1
- package/dist/{chunk-S4WDCOQD.js → chunk-5QW3GY37.js} +27 -14
- package/dist/{chunk-5TIADRZ7.js → chunk-63JSBXD5.js} +8 -6
- package/dist/{chunk-5ENOJFDI.js → chunk-7CGMFCSU.js} +1 -1
- package/dist/{chunk-7QZFRDTU.js → chunk-7GCMYYFL.js} +7 -4
- package/dist/{chunk-OWWE5Y6T.js → chunk-7URQCA3H.js} +8 -6
- package/dist/{chunk-R2ODJ3D3.js → chunk-A3LCORSK.js} +11 -7
- package/dist/{chunk-IZ77JV46.js → chunk-AUCCE46Q.js} +6 -3
- package/dist/{chunk-PFQO7UQG.js → chunk-AW4RL2SA.js} +60 -33
- package/dist/{chunk-2NOIR4BR.js → chunk-AZV22U4V.js} +20 -2
- package/dist/chunk-BORT2CVW.js +2927 -0
- package/dist/{chunk-VYSTJIAD.js → chunk-CX5XB56X.js} +4 -3
- package/dist/{chunk-VWPX7GLC.js → chunk-DBGBLXBS.js} +1 -1
- package/dist/{chunk-J4SYK3RT.js → chunk-DGRHDZQO.js} +15 -5
- package/dist/{chunk-6AQYZWOC.js → chunk-DL5J4DV2.js} +2 -2
- package/dist/{chunk-7UHN2CW7.js → chunk-DM52HEOD.js} +1 -1
- package/dist/{chunk-EJGGX3ON.js → chunk-DMLXILXG.js} +12 -10
- package/dist/{chunk-VBHKRUON.js → chunk-DUKOOIQD.js} +6 -5
- package/dist/{chunk-BLU2WLIJ.js → chunk-DWPBJEEM.js} +21 -8
- package/dist/{chunk-6P7HBAUM.js → chunk-E4CMR4T2.js} +21 -13
- package/dist/{chunk-QEBISX7V.js → chunk-EBAFVGM3.js} +1 -1
- package/dist/{chunk-J34YB5R4.js → chunk-EHLCUND7.js} +12 -10
- package/dist/{chunk-DBCNRZZE.js → chunk-EIPTLSNT.js} +3 -1
- package/dist/{chunk-KWFSBUD6.js → chunk-ESRIX7ZH.js} +1485 -1411
- package/dist/{chunk-YM5X7CQL.js → chunk-FCAJQFYT.js} +32 -12
- package/dist/{chunk-437KXVGO.js → chunk-G63BL5AB.js} +8 -5
- package/dist/{chunk-BZPOERWW.js → chunk-GIV6KSQX.js} +18 -9
- package/dist/{chunk-G2KWNZV6.js → chunk-GMJLK3IK.js} +2 -2
- package/dist/{chunk-P2KYQNXQ.js → chunk-GQYB3OOC.js} +108 -65
- package/dist/{chunk-4FAYO6UJ.js → chunk-GZUXEIEB.js} +3 -3
- package/dist/{chunk-7ASAC2FM.js → chunk-H4TJZB26.js} +26 -18
- package/dist/{chunk-5SNW2DCY.js → chunk-HXDCSVQP.js} +42 -18
- package/dist/{chunk-NQEXDESI.js → chunk-IBTEL5KA.js} +32 -14
- package/dist/{chunk-Q732RWRD.js → chunk-IQRFJO4N.js} +7 -5
- package/dist/{chunk-LBFX6AVE.js → chunk-JFRYC6GK.js} +17 -10
- package/dist/{chunk-7YBZ2PEZ.js → chunk-JQ7GOJK6.js} +135 -58
- package/dist/{chunk-FOWWGEP7.js → chunk-JS2DAWKO.js} +9 -6
- package/dist/{chunk-IHCKU5FR.js → chunk-K6OBX6ZR.js} +8 -7
- package/dist/{chunk-RSDTHO3I.js → chunk-KB3BTLIB.js} +6 -4
- package/dist/{chunk-VIHLAFDA.js → chunk-KYOZ4CCY.js} +61 -29
- package/dist/{chunk-D6WRJZPH.js → chunk-LCUAIH7P.js} +7 -5
- package/dist/{chunk-F5EZQMOA.js → chunk-M7VHCFCW.js} +10 -8
- package/dist/{chunk-EVCAR6GP.js → chunk-MAEUKXZ4.js} +8 -5
- package/dist/{chunk-HFCJJJKP.js → chunk-MKKOAF2W.js} +26 -12
- package/dist/{chunk-MQFPD5J4.js → chunk-MNKJHZZT.js} +10 -6
- package/dist/{chunk-YUL4ES52.js → chunk-MSJ2QS4Y.js} +6 -4
- package/dist/{chunk-VE5FQQTG.js → chunk-MTP3MDAA.js} +10 -7
- package/dist/{chunk-24JEBPKI.js → chunk-NJ2NRKAJ.js} +57 -14
- package/dist/{chunk-XMIDY45X.js → chunk-NRRSESP2.js} +32 -13
- package/dist/{chunk-B7QLJF77.js → chunk-NUE5ZL5N.js} +11 -5
- package/dist/{chunk-B6KT5U7W.js → chunk-NZIDSNBJ.js} +10 -8
- package/dist/{chunk-PAG3PYAQ.js → chunk-O5W5DCKH.js} +1 -1
- package/dist/{chunk-CFQX7HAW.js → chunk-OCDZIJBM.js} +11 -5
- package/dist/{chunk-KTO2WJ75.js → chunk-OGTWBHJC.js} +2 -2
- package/dist/{chunk-3KRUGI6C.js → chunk-ONTZADVX.js} +1 -1
- package/dist/{chunk-W62DN2I2.js → chunk-OWSAXYGH.js} +1 -1
- package/dist/{chunk-ESNSDIEC.js → chunk-PDPCFFFH.js} +1 -1
- package/dist/{chunk-Q6M2TNLO.js → chunk-PGOJH3NS.js} +61 -329
- package/dist/{chunk-LXW3L56Z.js → chunk-Q2XWHI6K.js} +6 -3
- package/dist/{chunk-ENKVW7JW.js → chunk-QKW6ZECR.js} +29 -14
- package/dist/{chunk-JBT2FR4K.js → chunk-QPDL77XZ.js} +21 -10
- package/dist/{chunk-D7E6HL5O.js → chunk-QPXGSVW4.js} +10 -8
- package/dist/{chunk-M336ZIRO.js → chunk-QQ2UM2KH.js} +9 -7
- package/dist/{chunk-YWZQKODL.js → chunk-R55XYG6Y.js} +28 -15
- package/dist/{chunk-AOLP2YDZ.js → chunk-RAD3UMQ3.js} +7 -5
- package/dist/{chunk-HFM6N7R3.js → chunk-RLF7ADLP.js} +21 -13
- package/dist/{chunk-A2UTT4YX.js → chunk-SLXOKSG4.js} +58 -28
- package/dist/{chunk-ZOU25JF6.js → chunk-SU36MZXC.js} +11 -3
- package/dist/{chunk-F644YFJZ.js → chunk-SZSAJHN7.js} +7 -6
- package/dist/{chunk-GR7S7WTT.js → chunk-TPWSE5HE.js} +16 -11
- package/dist/{chunk-7ECQXPOG.js → chunk-TVCHVG2A.js} +3 -3
- package/dist/{chunk-HJACC6KV.js → chunk-UKQ6FES4.js} +6 -3
- package/dist/{chunk-JL3NKSLJ.js → chunk-USO2SWZV.js} +9 -4
- package/dist/chunk-USY2322P.js +17 -0
- package/dist/{chunk-6ASLWQB3.js → chunk-V3UQOU5W.js} +4 -2
- package/dist/{chunk-XXYVUV5F.js → chunk-VD2CKAYG.js} +21 -10
- package/dist/{chunk-C4XKPQ6T.js → chunk-VLNTJXXO.js} +16 -3
- package/dist/{chunk-D3RDR3D3.js → chunk-W3LCOK3O.js} +153 -124
- package/dist/{chunk-MXM5ZD4Y.js → chunk-W5U6NPSN.js} +10 -25
- package/dist/{chunk-MM5RRCPX.js → chunk-WVHNOE7Y.js} +1 -1
- package/dist/{chunk-RFENVF7Y.js → chunk-XUOGIKEE.js} +3 -3
- package/dist/{chunk-R22UAHRF.js → chunk-YDESULL7.js} +3 -1
- package/dist/{chunk-7I7G5ZJE.js → chunk-YIXWAK3A.js} +12 -7
- package/dist/{chunk-ZFPASY4R.js → chunk-Z2FX5GG4.js} +24 -12
- package/dist/{chunk-JQEAWWRP.js → chunk-ZPJOSHV7.js} +23 -12
- package/dist/{chunk-U2RBSUMY.js → chunk-ZU76OTV3.js} +2 -2
- package/dist/{collection-add-products-HCY2YT3W.js → collection-add-products-FWEVXBYC.js} +16 -9
- package/dist/{collection-detail-QAEPOJZX.js → collection-detail-U4AW4QJ3.js} +11 -12
- package/dist/{collection-list-AWLZYMWL.js → collection-list-PFXGNWL7.js} +15 -15
- package/dist/{collection-metadata-XM2EBCWF.js → collection-metadata-IKYBHHEU.js} +3 -3
- package/dist/{commission-rule-create-CDLLQIY4.js → commission-rule-create-QDNXXBTV.js} +64 -30
- package/dist/{commission-rule-detail-LFEZ5U6V.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-MUKIEJWZ.js → commissions-list-AQUW636T.js} +6 -6
- package/dist/{customer-detail-XO7RBVUC.js → customer-detail-TBGKTNQQ.js} +9 -9
- package/dist/{customer-group-add-customers-XYWJSXKS.js → customer-group-add-customers-RWJOA2NJ.js} +3 -3
- package/dist/{customer-group-detail-4G53UKOS.js → customer-group-detail-47IPD337.js} +7 -8
- package/dist/{customer-group-list-5VA7HGD5.js → customer-group-list-Q2AYIVO4.js} +7 -8
- package/dist/{customer-group-metadata-FUJFFWCO.js → customer-group-metadata-T3WFBL7U.js} +3 -3
- package/dist/{customer-list-NEPELR3R.js → customer-list-JOPTF4QB.js} +5 -6
- package/dist/{customer-metadata-GWZC456X.js → customer-metadata-YSMWL4L3.js} +3 -3
- package/dist/{customers-add-customer-group-MYC76YGW.js → customers-add-customer-group-AVRYBS6Q.js} +14 -7
- package/dist/{edit-inventory-item-ZSV4WF6G.js → edit-inventory-item-7M7Q6HL4.js} +2 -2
- package/dist/{edit-inventory-item-attributes-NWSAQMKX.js → edit-inventory-item-attributes-E7J2WFPF.js} +2 -2
- package/dist/{edit-reservation-W3THLKKK.js → edit-reservation-S3QTQRPY.js} +11 -3
- package/dist/{edit-rules-RJC3AYJN.js → edit-rules-NRF7U4AT.js} +2 -2
- package/dist/extension-targets.d.ts +27 -0
- package/dist/home-E7IVATD3.js +64 -0
- package/dist/index.css +271 -9
- package/dist/index.d.ts +10 -30
- package/dist/index.js +635 -3925
- package/dist/{inventory-detail-7HB5QEL4.js → inventory-detail-U6TRGZRY.js} +8 -8
- package/dist/{inventory-list-FN7FCI4W.js → inventory-list-JWA7U2LB.js} +4 -5
- package/dist/{inventory-metadata-FGHOW3YG.js → inventory-metadata-KO622YEI.js} +3 -3
- package/dist/{inventory-stock-PZ2ENOGF.js → inventory-stock-WWXYVFK2.js} +21 -11
- package/dist/{location-detail-B2BWLVAD.js → location-detail-27FBZML7.js} +5 -7
- package/dist/{location-fulfillment-providers-XIYMIEFN.js → location-fulfillment-providers-WT72L5JS.js} +21 -13
- package/dist/{location-list-VIAP63HV.js → location-list-RMHT36AO.js} +5 -7
- package/dist/{location-sales-channels-TNP3C7UW.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-6O2JXV6I.js → location-service-zone-shipping-option-create-WJOLO6A3.js} +4 -4
- 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-TZHRVYA5.js → login-ISNIWXU2.js} +3 -3
- package/dist/{manage-locations-ZFIRHMNH.js → manage-locations-5FKFNJQN.js} +158 -36
- package/dist/{marketplace-add-currencies-Z6FUIAU5.js → marketplace-add-currencies-34XKWMI7.js} +33 -9
- package/dist/{marketplace-detail-4IP5HIEW.js → marketplace-detail-A76FTENH.js} +7 -7
- package/dist/{marketplace-edit-G7YNGABC.js → marketplace-edit-KXKUECZQ.js} +61 -30
- package/dist/{marketplace-metadata-EGDXYKCE.js → marketplace-metadata-364KJG43.js} +3 -3
- package/dist/{offer-detail-page-WWEUCEFC.js → offer-detail-page-BDDDZSPL.js} +36 -13
- package/dist/{offer-variant-detail-page-FVJE5WLV.js → offer-variant-detail-page-HQU4HMZH.js} +4 -5
- package/dist/{offers-VG334CFD.js → offers-2JDCFVN4.js} +10 -11
- package/dist/{order-create-claim-4CIL76V5.js → order-create-claim-4ERPSGPD.js} +105 -61
- package/dist/{order-create-edit-BFE4N7RN.js → order-create-edit-BGLNMKKI.js} +17 -10
- package/dist/{order-create-exchange-CC7CQECO.js → order-create-exchange-TOPPZZGS.js} +107 -63
- package/dist/{order-create-refund-FJLL4CUD.js → order-create-refund-M3K5MZDM.js} +39 -24
- package/dist/{order-create-return-USO7AS7R.js → order-create-return-64GZ2LCL.js} +109 -70
- package/dist/{order-detail-3ODC5NOT.js → order-detail-DIUKR6ZJ.js} +9 -9
- package/dist/{order-edit-billing-address-SBVWRA25.js → order-edit-billing-address-ZAR5DETE.js} +3 -3
- package/dist/{order-edit-email-BREEW246.js → order-edit-email-V45SEUCO.js} +2 -2
- package/dist/{order-edit-shipping-address-XUG74AFY.js → order-edit-shipping-address-45Z6TNHL.js} +2 -2
- package/dist/{order-list-I6JZT6JK.js → order-list-KZHROLY3.js} +7 -7
- package/dist/{order-metadata-VIG5MGYV.js → order-metadata-7245QRUQ.js} +3 -3
- package/dist/{order-request-transfer-RYVK4WYW.js → order-request-transfer-JYPDXCY2.js} +28 -14
- package/dist/pages/index.d.ts +2 -2
- package/dist/pages/index.js +99 -98
- package/dist/{payout-list-WZ6QMJJY.js → payout-list-KILGQ4XP.js} +3 -3
- package/dist/{price-list-create-JFXLTNOJ.js → price-list-create-H3KJPUF4.js} +12 -12
- package/dist/{price-list-customer-availability-WU2OGO37.js → price-list-customer-availability-CQY55U4O.js} +31 -14
- package/dist/{price-list-detail-5YTX66KF.js → price-list-detail-I44VTKE6.js} +10 -11
- package/dist/{price-list-list-5CNSLAUF.js → price-list-list-TD5JIO7L.js} +5 -5
- package/dist/{price-list-prices-add-HVTEQOWQ.js → price-list-prices-add-XEJKCRTM.js} +11 -11
- package/dist/{price-list-prices-edit-OVHIDATP.js → price-list-prices-edit-WELHT4O4.js} +19 -10
- package/dist/{product-add-existing-attributes-2UFTXE2N.js → product-add-existing-attributes-5B6HD2M3.js} +10 -8
- package/dist/{product-create-SHIGHLQN.js → product-create-DTITIXGY.js} +12 -11
- package/dist/{product-create-attribute-QYRCPUFC.js → product-create-attribute-7TV3OHW7.js} +1 -1
- package/dist/{product-create-variant-MZLHG5JF.js → product-create-variant-S3UJRMMJ.js} +3 -3
- package/dist/{product-detail-UGSTCK7J.js → product-detail-2MYEE5AM.js} +9 -10
- package/dist/{product-edit-2CMVTDWT.js → product-edit-TAVV5CWR.js} +8 -3
- package/dist/{product-edit-attribute-W3AS47FM.js → product-edit-attribute-URHTZ2EQ.js} +9 -3
- package/dist/{product-list-XDJB3HX7.js → product-list-QYZXPM4I.js} +11 -12
- package/dist/{product-media-CO3F57JT.js → product-media-MFDAEXNQ.js} +3 -3
- package/dist/{product-metadata-5CRGB7TR.js → product-metadata-SC5BXN66.js} +3 -3
- package/dist/{product-organization-TNS7GBKN.js → product-organization-GCIGER6X.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-QORH6X2D.js → product-tag-create-PX7Q2AXU.js} +2 -2
- package/dist/{product-tag-detail-CDSYBTAM.js → product-tag-detail-4CGCZVSL.js} +18 -18
- package/dist/{product-tag-edit-JWYVCPCC.js → product-tag-edit-PXSZMCCT.js} +2 -2
- package/dist/{product-tag-list-RKLCU3UE.js → product-tag-list-2S6PHBIB.js} +18 -18
- package/dist/{product-tag-metadata-BCUPIIJ5.js → product-tag-metadata-2SO7ICOZ.js} +3 -3
- package/dist/{product-type-detail-IY7TWXUQ.js → product-type-detail-M4QLNFSG.js} +11 -12
- package/dist/{product-type-list-N3E5HQFW.js → product-type-list-JXU3446J.js} +5 -5
- package/dist/{product-type-metadata-DKBBQB6R.js → product-type-metadata-7D3J3NSO.js} +3 -3
- package/dist/{product-variant-detail-XHMS2UT5.js → product-variant-detail-VQ55W7PD.js} +4 -6
- package/dist/{product-variant-edit-4DPXTYPT.js → product-variant-edit-XEC7BR5G.js} +4 -4
- package/dist/{product-variant-metadata-ETVJBXSW.js → product-variant-metadata-KFLIOCU2.js} +3 -3
- package/dist/{profile-detail-KFLXUGQ5.js → profile-detail-SQZ6JFAN.js} +3 -5
- package/dist/{profile-edit-4FDALFG5.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-7ZUJ4W2J.js → promotion-create-6TMK6PEP.js} +5 -4
- package/dist/{promotion-detail-SWO4PZDC.js → promotion-detail-YRWEIXY7.js} +7 -9
- package/dist/{promotion-list-S4B6SVD6.js → promotion-list-NFVGSR23.js} +9 -9
- package/dist/{refund-reason-create-P5FUFEGK.js → refund-reason-create-HZOBFOPB.js} +2 -2
- package/dist/{refund-reason-edit-AKOTWXCE.js → refund-reason-edit-KS6NMC22.js} +2 -2
- package/dist/{refund-reason-list-ABRFC3OQ.js → refund-reason-list-RL7WOHKC.js} +11 -12
- 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-IBLHFR57.js → region-detail-S5OT2PGL.js} +4 -5
- package/dist/{region-edit-NUMG2V5L.js → region-edit-IXCS3MRH.js} +32 -14
- package/dist/{region-list-JTR3SEWI.js → region-list-2MWAGD2D.js} +4 -5
- package/dist/{region-metadata-Q6HEMCHD.js → region-metadata-ADPG7OLJ.js} +3 -3
- package/dist/{reservation-create-H3T3AHTK.js → reservation-create-YEICXID2.js} +67 -44
- package/dist/{reservation-detail-5GYGVM3M.js → reservation-detail-EBIDXEVF.js} +4 -6
- package/dist/{reservation-list-VRRSKQ4W.js → reservation-list-5QNXC2WU.js} +4 -5
- package/dist/{reservation-metadata-P4G3JEDW.js → reservation-metadata-TWJE777O.js} +3 -3
- package/dist/{reset-password-VJY5CXJU.js → reset-password-FIZYJ2R4.js} +1 -1
- package/dist/{return-reason-list-6MQKG72S.js → return-reason-list-VDX6CFJL.js} +10 -10
- package/dist/{review-detail-K555FECH.js → review-detail-NPB3OKCE.js} +2 -4
- package/dist/{review-list-E56WE7VS.js → review-list-NXBVRP5T.js} +4 -5
- package/dist/{sales-channel-add-products-MPJ7UCEJ.js → sales-channel-add-products-MBSSIGYE.js} +19 -10
- package/dist/{sales-channel-detail-F37LBP6R.js → sales-channel-detail-R2BCF7TA.js} +11 -12
- package/dist/{sales-channel-list-XAWN5OKC.js → sales-channel-list-246V7NV3.js} +5 -7
- package/dist/{sales-channel-metadata-NBWFH4QX.js → sales-channel-metadata-PMLMQIKU.js} +3 -3
- package/dist/settings-UG4P6CCP.js +63 -0
- package/dist/{shipping-option-type-create-M23CI42D.js → shipping-option-type-create-NOFP2DOM.js} +2 -2
- package/dist/{shipping-option-type-detail-QIJZQ5WW.js → shipping-option-type-detail-47AZVCFP.js} +5 -7
- package/dist/{shipping-option-type-edit-WXTEQM32.js → shipping-option-type-edit-42JILKHX.js} +2 -2
- package/dist/{shipping-option-type-list-PRXZQSPR.js → shipping-option-type-list-TTAA63ZN.js} +8 -8
- package/dist/{shipping-profile-detail-KPRFJE4V.js → shipping-profile-detail-RGB67K3C.js} +2 -4
- package/dist/{shipping-profile-metadata-S7Z3IC6I.js → shipping-profile-metadata-GXMY5E57.js} +3 -3
- package/dist/{shipping-profiles-list-LK5ZXRJG.js → shipping-profiles-list-DD3G2THE.js} +4 -5
- package/dist/{store-bulk-edit-NBWZMDP7.js → store-bulk-edit-RRNJZEOU.js} +2 -2
- package/dist/{store-create-J4SL6SY3.js → store-create-UQ333C5F.js} +37 -15
- package/dist/{store-details-ITYKAZSI.js → store-details-D7RUCH5Y.js} +13 -14
- package/dist/{store-edit-NZMI7PNS.js → store-edit-RCNV5XI4.js} +3 -3
- package/dist/{store-list-RXPN3VVO.js → store-list-BMPOSAAE.js} +13 -14
- package/dist/{store-member-invite-IEUG54XA.js → store-member-invite-ALW6E3XA.js} +15 -6
- package/dist/{tax-region-create-PIDKQEWT.js → tax-region-create-3B6FWGWS.js} +3 -3
- package/dist/{tax-region-detail-7RNNZ4UE.js → tax-region-detail-PU4Q42KO.js} +8 -9
- package/dist/{tax-region-edit-I27QZZPB.js → tax-region-edit-P4L2CUFV.js} +2 -2
- package/dist/{tax-region-list-BXLYIYQT.js → tax-region-list-PUNXDH34.js} +5 -6
- package/dist/{tax-region-metadata-6YIZSRLO.js → tax-region-metadata-EDZ7YGYR.js} +3 -3
- package/dist/{tax-region-province-detail-AHS5SRP5.js → tax-region-province-detail-3ZQOCKZ2.js} +7 -8
- package/dist/{tax-region-tax-override-create-Z6S43XQ6.js → tax-region-tax-override-create-J5ZUAELL.js} +15 -15
- package/dist/{tax-region-tax-override-edit-4EOURL2M.js → tax-region-tax-override-edit-HDVKIL5P.js} +46 -26
- package/dist/{user-detail-5LOE6QGK.js → user-detail-4H37KBIP.js} +3 -5
- package/dist/{user-edit-O2M5II52.js → user-edit-42A2VX5E.js} +1 -1
- package/dist/{user-invite-SZIUG2WK.js → user-invite-5EJ3CIQZ.js} +35 -134
- package/dist/{user-list-6YRC6HYX.js → user-list-EZ56HFI3.js} +5 -6
- package/dist/{user-metadata-2PEU2IJE.js → user-metadata-3GENWLUS.js} +3 -3
- package/package.json +14 -14
- package/dist/chunk-4F6SHS7A.js +0 -83
- package/dist/chunk-BDGZ4EQO.js +0 -86
- package/dist/chunk-WMA3WTCM.js +0 -117
- package/dist/home-I3OILW5Z.js +0 -16
- package/dist/settings-AVE3VCCM.js +0 -19
- package/dist/{customer-edit-5EH2AUGN.js → customer-edit-LDKAXHZ6.js} +3 -3
- package/dist/{invite-6WUERQLW.js → invite-IZ2YTVPF.js} +1 -1
|
@@ -10,10 +10,13 @@ import {
|
|
|
10
10
|
decorateVariantsWithDefaultValues,
|
|
11
11
|
generateVariantsFromAttributes,
|
|
12
12
|
normalizeProductFormValues
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-GMJLK3IK.js";
|
|
14
14
|
import {
|
|
15
15
|
HandleInput
|
|
16
16
|
} from "./chunk-HJ56YXBU.js";
|
|
17
|
+
import {
|
|
18
|
+
uploadRichTextImage
|
|
19
|
+
} from "./chunk-USY2322P.js";
|
|
17
20
|
import {
|
|
18
21
|
useAttributeTableFilters
|
|
19
22
|
} from "./chunk-RT6L7JXU.js";
|
|
@@ -22,7 +25,7 @@ import {
|
|
|
22
25
|
} from "./chunk-4YWKKCTT.js";
|
|
23
26
|
import {
|
|
24
27
|
SingleCategoryCombobox
|
|
25
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-W3LCOK3O.js";
|
|
26
29
|
import {
|
|
27
30
|
useComboboxData
|
|
28
31
|
} from "./chunk-5KGMGL4N.js";
|
|
@@ -53,22 +56,25 @@ import {
|
|
|
53
56
|
import {
|
|
54
57
|
Form
|
|
55
58
|
} from "./chunk-3QSRE5LS.js";
|
|
59
|
+
import {
|
|
60
|
+
ConditionalTooltip
|
|
61
|
+
} from "./chunk-LAVHRER2.js";
|
|
56
62
|
import {
|
|
57
63
|
require_dist
|
|
58
|
-
} from "./chunk-
|
|
64
|
+
} from "./chunk-ESRIX7ZH.js";
|
|
59
65
|
import {
|
|
60
66
|
_DataTable,
|
|
61
67
|
useDataTable
|
|
62
|
-
} from "./chunk-
|
|
68
|
+
} from "./chunk-SU36MZXC.js";
|
|
69
|
+
import {
|
|
70
|
+
ActionMenu
|
|
71
|
+
} from "./chunk-3UOYBH5O.js";
|
|
63
72
|
import {
|
|
64
73
|
useRegions
|
|
65
74
|
} from "./chunk-2SCR7R3C.js";
|
|
66
75
|
import {
|
|
67
76
|
useStore
|
|
68
77
|
} from "./chunk-3JN6NCCN.js";
|
|
69
|
-
import {
|
|
70
|
-
ActionMenu
|
|
71
|
-
} from "./chunk-BDGZ4EQO.js";
|
|
72
78
|
import {
|
|
73
79
|
useSalesChannel
|
|
74
80
|
} from "./chunk-JC2FFAMW.js";
|
|
@@ -88,15 +94,18 @@ import {
|
|
|
88
94
|
// src/pages/products/product-create/product-create.tsx
|
|
89
95
|
import { Children as Children2 } from "react";
|
|
90
96
|
import { useTranslation as useTranslation10 } from "react-i18next";
|
|
97
|
+
import { useCan as useCan4 } from "@mercurjs/dashboard-shared";
|
|
91
98
|
|
|
92
99
|
// src/pages/products/product-create/components/product-create-form/product-create-form.tsx
|
|
93
100
|
import { Button as Button3, toast } from "@medusajs/ui";
|
|
94
101
|
import { useEffect as useEffect3, useMemo as useMemo4, Children } from "react";
|
|
95
102
|
import { useForm, useWatch as useWatch4 } from "react-hook-form";
|
|
96
103
|
import { useTranslation as useTranslation9 } from "react-i18next";
|
|
104
|
+
import { isForbidden as isForbidden2, useCan as useCan3 } from "@mercurjs/dashboard-shared";
|
|
97
105
|
|
|
98
106
|
// src/pages/products/product-create/components/product-create-attributes-form/product-create-attributes-form.tsx
|
|
99
107
|
var import_types = __toESM(require_dist(), 1);
|
|
108
|
+
import { useCan as useCan2 } from "@mercurjs/dashboard-shared";
|
|
100
109
|
import { XMarkMini } from "@medusajs/icons";
|
|
101
110
|
import {
|
|
102
111
|
Button as Button2,
|
|
@@ -120,6 +129,11 @@ import { useTranslation as useTranslation2 } from "react-i18next";
|
|
|
120
129
|
|
|
121
130
|
// src/pages/products/product-create/components/product-create-attributes-form/product-create-add-attributes-modal.tsx
|
|
122
131
|
import { Badge, Button, Checkbox } from "@medusajs/ui";
|
|
132
|
+
import {
|
|
133
|
+
isForbidden,
|
|
134
|
+
SectionNoAccess,
|
|
135
|
+
useCan
|
|
136
|
+
} from "@mercurjs/dashboard-shared";
|
|
123
137
|
import { keepPreviousData } from "@tanstack/react-query";
|
|
124
138
|
import {
|
|
125
139
|
createColumnHelper
|
|
@@ -153,8 +167,10 @@ var ProductCreateAddAttributesModal = () => {
|
|
|
153
167
|
() => ({ ...searchParams, category_id: categoryId || void 0 }),
|
|
154
168
|
[searchParams, categoryId]
|
|
155
169
|
);
|
|
170
|
+
const canViewAttributes = useCan("product_attributes");
|
|
156
171
|
const { product_attributes, count, isLoading, isError, error } = useProductAttributes(attributesQuery, {
|
|
157
|
-
placeholderData: keepPreviousData
|
|
172
|
+
placeholderData: keepPreviousData,
|
|
173
|
+
enabled: canViewAttributes
|
|
158
174
|
});
|
|
159
175
|
const open = getIsOpen(ADD_ATTRIBUTES_MODAL_ID);
|
|
160
176
|
useEffect(() => {
|
|
@@ -260,9 +276,16 @@ var ProductCreateAddAttributesModal = () => {
|
|
|
260
276
|
rowSelection: { state: rowSelection, updater },
|
|
261
277
|
prefix: ADD_ATTRIBUTES_MODAL_ID
|
|
262
278
|
});
|
|
263
|
-
|
|
279
|
+
const noAccess = !canViewAttributes || isError && isForbidden(error);
|
|
280
|
+
if (isError && !noAccess) {
|
|
264
281
|
throw error;
|
|
265
282
|
}
|
|
283
|
+
if (noAccess) {
|
|
284
|
+
return /* @__PURE__ */ jsxs(StackedFocusModal.Content, { className: "flex flex-col overflow-hidden", children: [
|
|
285
|
+
/* @__PURE__ */ jsx(StackedFocusModal.Header, {}),
|
|
286
|
+
/* @__PURE__ */ jsx(StackedFocusModal.Body, { children: /* @__PURE__ */ jsx(SectionNoAccess, {}) })
|
|
287
|
+
] });
|
|
288
|
+
}
|
|
266
289
|
return /* @__PURE__ */ jsxs(StackedFocusModal.Content, { className: "flex flex-col overflow-hidden", children: [
|
|
267
290
|
/* @__PURE__ */ jsx(StackedFocusModal.Header, {}),
|
|
268
291
|
/* @__PURE__ */ jsx(StackedFocusModal.Body, { className: "flex size-full flex-col overflow-hidden", children: /* @__PURE__ */ jsx(
|
|
@@ -767,12 +790,13 @@ var RequiredAttributes = () => {
|
|
|
767
790
|
const { t } = useTranslation2();
|
|
768
791
|
const form = useTabbedForm();
|
|
769
792
|
const categoryId = form.watch("category_id");
|
|
793
|
+
const canViewAttributes = useCan2("product_attributes");
|
|
770
794
|
const { product_attributes } = useProductAttributes(
|
|
771
795
|
{
|
|
772
796
|
category_id: categoryId,
|
|
773
797
|
is_required: true
|
|
774
798
|
},
|
|
775
|
-
{ enabled: !!categoryId }
|
|
799
|
+
{ enabled: !!categoryId && canViewAttributes }
|
|
776
800
|
);
|
|
777
801
|
const attributes = form.watch("attributes") || [];
|
|
778
802
|
useEffect2(() => {
|
|
@@ -939,7 +963,8 @@ import { Heading as Heading3 } from "@medusajs/ui";
|
|
|
939
963
|
import { useTranslation as useTranslation6 } from "react-i18next";
|
|
940
964
|
|
|
941
965
|
// src/pages/products/product-create/components/product-create-details-form/components/product-create-details-general-section/product-create-general-section.tsx
|
|
942
|
-
import { Input as Input2
|
|
966
|
+
import { Input as Input2 } from "@medusajs/ui";
|
|
967
|
+
import { RichTextEditor } from "@mercurjs/dashboard-shared";
|
|
943
968
|
import { useTranslation as useTranslation3 } from "react-i18next";
|
|
944
969
|
import { jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
945
970
|
var ProductCreateGeneralSection = () => {
|
|
@@ -1004,7 +1029,15 @@ var ProductCreateGeneralSection = () => {
|
|
|
1004
1029
|
render: ({ field }) => {
|
|
1005
1030
|
return /* @__PURE__ */ jsxs3(Form.Item, { "data-testid": "product-create-general-section-description-item", children: [
|
|
1006
1031
|
/* @__PURE__ */ jsx3(Form.Label, { optional: true, "data-testid": "product-create-general-section-description-label", children: t("products.fields.description.label") }),
|
|
1007
|
-
/* @__PURE__ */ jsx3(Form.Control, { "data-testid": "product-create-general-section-description-control", children: /* @__PURE__ */ jsx3(
|
|
1032
|
+
/* @__PURE__ */ jsx3(Form.Control, { "data-testid": "product-create-general-section-description-control", children: /* @__PURE__ */ jsx3(
|
|
1033
|
+
RichTextEditor,
|
|
1034
|
+
{
|
|
1035
|
+
...field,
|
|
1036
|
+
placeholder: t("products.fields.description.placeholder"),
|
|
1037
|
+
onUpload: uploadRichTextImage,
|
|
1038
|
+
"data-testid": "product-create-general-section-description-input"
|
|
1039
|
+
}
|
|
1040
|
+
) })
|
|
1008
1041
|
] });
|
|
1009
1042
|
}
|
|
1010
1043
|
}
|
|
@@ -1536,6 +1569,7 @@ var Header = () => {
|
|
|
1536
1569
|
};
|
|
1537
1570
|
|
|
1538
1571
|
// src/pages/products/product-create/components/product-create-organize-form/components/product-create-organize-section/product-create-details-organize-section.tsx
|
|
1572
|
+
import { usePermissionGate } from "@mercurjs/dashboard-shared";
|
|
1539
1573
|
import { Heading as Heading4 } from "@medusajs/ui";
|
|
1540
1574
|
import { useWatch as useWatch2 } from "react-hook-form";
|
|
1541
1575
|
import { useTranslation as useTranslation7 } from "react-i18next";
|
|
@@ -1543,13 +1577,18 @@ import { jsx as jsx7, jsxs as jsxs7 } from "react/jsx-runtime";
|
|
|
1543
1577
|
var ProductCreateOrganizationSection = () => {
|
|
1544
1578
|
const form = useTabbedForm();
|
|
1545
1579
|
const { t } = useTranslation7();
|
|
1580
|
+
const collectionsGate = usePermissionGate("product_collections:view");
|
|
1581
|
+
const typesGate = usePermissionGate("product_types:view");
|
|
1582
|
+
const tagsGate = usePermissionGate("product_tags:view");
|
|
1583
|
+
const sellersGate = usePermissionGate("sellers:view");
|
|
1546
1584
|
const collections = useComboboxData({
|
|
1547
1585
|
queryKey: ["product_collections"],
|
|
1548
1586
|
queryFn: (params) => sdk.admin.collections.query(params),
|
|
1549
1587
|
getOptions: (data) => data.collections.map((collection) => ({
|
|
1550
1588
|
label: collection.title,
|
|
1551
1589
|
value: collection.id
|
|
1552
|
-
}))
|
|
1590
|
+
})),
|
|
1591
|
+
enabled: collectionsGate.allowed
|
|
1553
1592
|
});
|
|
1554
1593
|
const types = useComboboxData({
|
|
1555
1594
|
queryKey: ["product_types"],
|
|
@@ -1557,7 +1596,8 @@ var ProductCreateOrganizationSection = () => {
|
|
|
1557
1596
|
getOptions: (data) => data.product_types.map((type) => ({
|
|
1558
1597
|
label: type.value,
|
|
1559
1598
|
value: type.id
|
|
1560
|
-
}))
|
|
1599
|
+
})),
|
|
1600
|
+
enabled: typesGate.allowed
|
|
1561
1601
|
});
|
|
1562
1602
|
const tags = useComboboxData({
|
|
1563
1603
|
queryKey: ["product_tags"],
|
|
@@ -1565,7 +1605,8 @@ var ProductCreateOrganizationSection = () => {
|
|
|
1565
1605
|
getOptions: (data) => data.product_tags.map((tag) => ({
|
|
1566
1606
|
label: tag.value,
|
|
1567
1607
|
value: tag.id
|
|
1568
|
-
}))
|
|
1608
|
+
})),
|
|
1609
|
+
enabled: tagsGate.allowed
|
|
1569
1610
|
});
|
|
1570
1611
|
const sellers = useComboboxData({
|
|
1571
1612
|
queryKey: ["sellers"],
|
|
@@ -1573,7 +1614,8 @@ var ProductCreateOrganizationSection = () => {
|
|
|
1573
1614
|
getOptions: (data) => data.sellers.map((seller) => ({
|
|
1574
1615
|
label: seller.name,
|
|
1575
1616
|
value: seller.id
|
|
1576
|
-
}))
|
|
1617
|
+
})),
|
|
1618
|
+
enabled: sellersGate.allowed
|
|
1577
1619
|
});
|
|
1578
1620
|
const isGloballyAvailable = useWatch2({
|
|
1579
1621
|
control: form.control,
|
|
@@ -1610,17 +1652,25 @@ var ProductCreateOrganizationSection = () => {
|
|
|
1610
1652
|
render: ({ field }) => {
|
|
1611
1653
|
return /* @__PURE__ */ jsxs7(Form.Item, { "data-testid": "product-create-organize-section-collection-item", children: [
|
|
1612
1654
|
/* @__PURE__ */ jsx7(Form.Label, { optional: true, "data-testid": "product-create-organize-section-collection-label", children: t("products.fields.collection.label") }),
|
|
1613
|
-
/* @__PURE__ */ jsx7(
|
|
1614
|
-
|
|
1655
|
+
/* @__PURE__ */ jsx7(
|
|
1656
|
+
ConditionalTooltip,
|
|
1615
1657
|
{
|
|
1616
|
-
|
|
1617
|
-
|
|
1618
|
-
|
|
1619
|
-
|
|
1620
|
-
|
|
1621
|
-
|
|
1658
|
+
showTooltip: collectionsGate.denied,
|
|
1659
|
+
content: collectionsGate.tooltip,
|
|
1660
|
+
children: /* @__PURE__ */ jsx7("div", { children: /* @__PURE__ */ jsx7(Form.Control, { "data-testid": "product-create-organize-section-collection-control", children: /* @__PURE__ */ jsx7(
|
|
1661
|
+
Combobox,
|
|
1662
|
+
{
|
|
1663
|
+
...field,
|
|
1664
|
+
disabled: collectionsGate.denied,
|
|
1665
|
+
options: collections.options,
|
|
1666
|
+
searchValue: collections.searchValue,
|
|
1667
|
+
onSearchValueChange: collections.onSearchValueChange,
|
|
1668
|
+
fetchNextPage: collections.fetchNextPage,
|
|
1669
|
+
"data-testid": "product-create-organize-section-collection-input"
|
|
1670
|
+
}
|
|
1671
|
+
) }) })
|
|
1622
1672
|
}
|
|
1623
|
-
)
|
|
1673
|
+
),
|
|
1624
1674
|
/* @__PURE__ */ jsx7(Form.ErrorMessage, {})
|
|
1625
1675
|
] });
|
|
1626
1676
|
}
|
|
@@ -1636,17 +1686,25 @@ var ProductCreateOrganizationSection = () => {
|
|
|
1636
1686
|
render: ({ field }) => {
|
|
1637
1687
|
return /* @__PURE__ */ jsxs7(Form.Item, { "data-testid": "product-create-organize-section-type-item", children: [
|
|
1638
1688
|
/* @__PURE__ */ jsx7(Form.Label, { optional: true, "data-testid": "product-create-organize-section-type-label", children: t("products.fields.type.label") }),
|
|
1639
|
-
/* @__PURE__ */ jsx7(
|
|
1640
|
-
|
|
1689
|
+
/* @__PURE__ */ jsx7(
|
|
1690
|
+
ConditionalTooltip,
|
|
1641
1691
|
{
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
|
|
1646
|
-
|
|
1647
|
-
|
|
1692
|
+
showTooltip: typesGate.denied,
|
|
1693
|
+
content: typesGate.tooltip,
|
|
1694
|
+
children: /* @__PURE__ */ jsx7("div", { children: /* @__PURE__ */ jsx7(Form.Control, { "data-testid": "product-create-organize-section-type-control", children: /* @__PURE__ */ jsx7(
|
|
1695
|
+
Combobox,
|
|
1696
|
+
{
|
|
1697
|
+
...field,
|
|
1698
|
+
disabled: typesGate.denied,
|
|
1699
|
+
options: types.options,
|
|
1700
|
+
searchValue: types.searchValue,
|
|
1701
|
+
onSearchValueChange: types.onSearchValueChange,
|
|
1702
|
+
fetchNextPage: types.fetchNextPage,
|
|
1703
|
+
"data-testid": "product-create-organize-section-type-input"
|
|
1704
|
+
}
|
|
1705
|
+
) }) })
|
|
1648
1706
|
}
|
|
1649
|
-
)
|
|
1707
|
+
),
|
|
1650
1708
|
/* @__PURE__ */ jsx7(Form.ErrorMessage, {})
|
|
1651
1709
|
] });
|
|
1652
1710
|
}
|
|
@@ -1660,17 +1718,25 @@ var ProductCreateOrganizationSection = () => {
|
|
|
1660
1718
|
render: ({ field }) => {
|
|
1661
1719
|
return /* @__PURE__ */ jsxs7(Form.Item, { "data-testid": "product-create-organize-section-tags-item", children: [
|
|
1662
1720
|
/* @__PURE__ */ jsx7(Form.Label, { optional: true, "data-testid": "product-create-organize-section-tags-label", children: t("products.fields.tags.label") }),
|
|
1663
|
-
/* @__PURE__ */ jsx7(
|
|
1664
|
-
|
|
1721
|
+
/* @__PURE__ */ jsx7(
|
|
1722
|
+
ConditionalTooltip,
|
|
1665
1723
|
{
|
|
1666
|
-
|
|
1667
|
-
|
|
1668
|
-
|
|
1669
|
-
|
|
1670
|
-
|
|
1671
|
-
|
|
1724
|
+
showTooltip: tagsGate.denied,
|
|
1725
|
+
content: tagsGate.tooltip,
|
|
1726
|
+
children: /* @__PURE__ */ jsx7("div", { children: /* @__PURE__ */ jsx7(Form.Control, { "data-testid": "product-create-organize-section-tags-control", children: /* @__PURE__ */ jsx7(
|
|
1727
|
+
Combobox,
|
|
1728
|
+
{
|
|
1729
|
+
...field,
|
|
1730
|
+
disabled: tagsGate.denied,
|
|
1731
|
+
options: tags.options,
|
|
1732
|
+
searchValue: tags.searchValue,
|
|
1733
|
+
onSearchValueChange: tags.onSearchValueChange,
|
|
1734
|
+
fetchNextPage: tags.fetchNextPage,
|
|
1735
|
+
"data-testid": "product-create-organize-section-tags-input"
|
|
1736
|
+
}
|
|
1737
|
+
) }) })
|
|
1672
1738
|
}
|
|
1673
|
-
)
|
|
1739
|
+
),
|
|
1674
1740
|
/* @__PURE__ */ jsx7(Form.ErrorMessage, {})
|
|
1675
1741
|
] });
|
|
1676
1742
|
}
|
|
@@ -1709,18 +1775,26 @@ var ProductCreateOrganizationSection = () => {
|
|
|
1709
1775
|
render: ({ field }) => {
|
|
1710
1776
|
return /* @__PURE__ */ jsxs7(Form.Item, { "data-testid": "product-create-organize-section-stores-item", children: [
|
|
1711
1777
|
/* @__PURE__ */ jsx7(Form.Label, { "data-testid": "product-create-organize-section-stores-label", children: t("products.fields.stores.label") }),
|
|
1712
|
-
/* @__PURE__ */ jsx7(
|
|
1713
|
-
|
|
1778
|
+
/* @__PURE__ */ jsx7(
|
|
1779
|
+
ConditionalTooltip,
|
|
1714
1780
|
{
|
|
1715
|
-
|
|
1716
|
-
|
|
1717
|
-
|
|
1718
|
-
|
|
1719
|
-
|
|
1720
|
-
|
|
1721
|
-
|
|
1781
|
+
showTooltip: sellersGate.denied,
|
|
1782
|
+
content: sellersGate.tooltip,
|
|
1783
|
+
children: /* @__PURE__ */ jsx7("div", { children: /* @__PURE__ */ jsx7(Form.Control, { "data-testid": "product-create-organize-section-stores-control", children: /* @__PURE__ */ jsx7(
|
|
1784
|
+
Combobox,
|
|
1785
|
+
{
|
|
1786
|
+
...field,
|
|
1787
|
+
value: field.value ?? [],
|
|
1788
|
+
disabled: sellersGate.denied,
|
|
1789
|
+
options: sellers.options,
|
|
1790
|
+
searchValue: sellers.searchValue,
|
|
1791
|
+
onSearchValueChange: sellers.onSearchValueChange,
|
|
1792
|
+
fetchNextPage: sellers.fetchNextPage,
|
|
1793
|
+
"data-testid": "product-create-organize-section-stores-input"
|
|
1794
|
+
}
|
|
1795
|
+
) }) })
|
|
1722
1796
|
}
|
|
1723
|
-
)
|
|
1797
|
+
),
|
|
1724
1798
|
/* @__PURE__ */ jsx7(Form.ErrorMessage, {})
|
|
1725
1799
|
] });
|
|
1726
1800
|
}
|
|
@@ -1924,13 +1998,15 @@ var ProductCreateForm = ({
|
|
|
1924
1998
|
resolver: zodResolver(schema ?? ProductCreateSchema)
|
|
1925
1999
|
});
|
|
1926
2000
|
const { mutateAsync, isPending } = useCreateProduct();
|
|
2001
|
+
const canViewRegions = useCan3("regions");
|
|
1927
2002
|
const {
|
|
1928
2003
|
regions,
|
|
1929
|
-
isPending:
|
|
2004
|
+
isPending: isRegionsQueryPending,
|
|
1930
2005
|
isError: isRegionsError,
|
|
1931
2006
|
error: regionsError
|
|
1932
|
-
} = useRegions({ limit: 9999 });
|
|
1933
|
-
|
|
2007
|
+
} = useRegions({ limit: 9999 }, { enabled: canViewRegions });
|
|
2008
|
+
const isRegionsPending = canViewRegions && isRegionsQueryPending;
|
|
2009
|
+
if (isRegionsError && !isForbidden2(regionsError)) {
|
|
1934
2010
|
throw regionsError;
|
|
1935
2011
|
}
|
|
1936
2012
|
const regionsCurrencyMap = useMemo4(() => {
|
|
@@ -2099,6 +2175,7 @@ var ProductCreateForm = ({
|
|
|
2099
2175
|
import { jsx as jsx11, jsxs as jsxs9 } from "react/jsx-runtime";
|
|
2100
2176
|
var Root5 = ({ children }) => {
|
|
2101
2177
|
const { t } = useTranslation10();
|
|
2178
|
+
const canViewSalesChannels = useCan4("sales_channels");
|
|
2102
2179
|
const {
|
|
2103
2180
|
store,
|
|
2104
2181
|
isPending: isStorePending,
|
|
@@ -2113,9 +2190,9 @@ var Root5 = ({ children }) => {
|
|
|
2113
2190
|
isError: isSalesChannelError,
|
|
2114
2191
|
error: salesChannelError
|
|
2115
2192
|
} = useSalesChannel(store?.default_sales_channel_id, {
|
|
2116
|
-
enabled: !!store?.default_sales_channel_id
|
|
2193
|
+
enabled: !!store?.default_sales_channel_id && canViewSalesChannels
|
|
2117
2194
|
});
|
|
2118
|
-
const ready = !!store && !isStorePending && !!sales_channel && !isSalesChannelPending;
|
|
2195
|
+
const ready = !!store && !isStorePending && (!canViewSalesChannels || !!sales_channel && !isSalesChannelPending);
|
|
2119
2196
|
if (isStoreError) {
|
|
2120
2197
|
throw storeError;
|
|
2121
2198
|
}
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
} from "./chunk-NFZEX33S.js";
|
|
7
7
|
import {
|
|
8
8
|
DataTable
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-VLNTJXXO.js";
|
|
10
10
|
import {
|
|
11
11
|
SingleColumnPage
|
|
12
12
|
} from "./chunk-H6MYB7GB.js";
|
|
@@ -37,6 +37,7 @@ import { keepPreviousData } from "@tanstack/react-query";
|
|
|
37
37
|
import { useCallback, useMemo } from "react";
|
|
38
38
|
import { useTranslation } from "react-i18next";
|
|
39
39
|
import { useNavigate } from "react-router-dom";
|
|
40
|
+
import { usePermissions } from "@mercurjs/dashboard-shared";
|
|
40
41
|
import { jsx } from "react/jsx-runtime";
|
|
41
42
|
var PAGE_SIZE = 20;
|
|
42
43
|
var SalesChannelListDataTable = () => {
|
|
@@ -80,6 +81,7 @@ var SalesChannelListDataTable = () => {
|
|
|
80
81
|
var columnHelper = createDataTableColumnHelper();
|
|
81
82
|
var useColumns = () => {
|
|
82
83
|
const { t } = useTranslation();
|
|
84
|
+
const { can } = usePermissions();
|
|
83
85
|
const prompt = usePrompt();
|
|
84
86
|
const navigate = useNavigate();
|
|
85
87
|
const base = useSalesChannelTableColumns();
|
|
@@ -117,7 +119,7 @@ var useColumns = () => {
|
|
|
117
119
|
actions: (ctx) => {
|
|
118
120
|
const disabledTooltip = ctx.row.original.is_default ? t("salesChannels.tooltip.cannotDeleteDefault") : void 0;
|
|
119
121
|
return [
|
|
120
|
-
[
|
|
122
|
+
!can("sales_channels", "edit") ? [] : [
|
|
121
123
|
{
|
|
122
124
|
icon: /* @__PURE__ */ jsx(PencilSquare, {}),
|
|
123
125
|
label: t("actions.edit"),
|
|
@@ -126,7 +128,7 @@ var useColumns = () => {
|
|
|
126
128
|
)
|
|
127
129
|
}
|
|
128
130
|
],
|
|
129
|
-
[
|
|
131
|
+
!can("sales_channels", "manage") ? [] : [
|
|
130
132
|
{
|
|
131
133
|
icon: /* @__PURE__ */ jsx(Trash, {}),
|
|
132
134
|
label: t("actions.delete"),
|
|
@@ -135,11 +137,11 @@ var useColumns = () => {
|
|
|
135
137
|
disabledTooltip
|
|
136
138
|
}
|
|
137
139
|
]
|
|
138
|
-
];
|
|
140
|
+
].filter((group) => group.length > 0);
|
|
139
141
|
}
|
|
140
142
|
})
|
|
141
143
|
],
|
|
142
|
-
[base, handleDelete, navigate, t]
|
|
144
|
+
[base, handleDelete, navigate, t, can]
|
|
143
145
|
);
|
|
144
146
|
};
|
|
145
147
|
|
|
@@ -148,6 +150,7 @@ import { Children } from "react";
|
|
|
148
150
|
import { Button, Heading, Text } from "@medusajs/ui";
|
|
149
151
|
import { useTranslation as useTranslation2 } from "react-i18next";
|
|
150
152
|
import { Link } from "react-router-dom";
|
|
153
|
+
import { PermissionAction } from "@mercurjs/dashboard-shared";
|
|
151
154
|
import { Fragment, jsx as jsx2, jsxs } from "react/jsx-runtime";
|
|
152
155
|
var SalesChannelListTitle = () => {
|
|
153
156
|
const { t } = useTranslation2();
|
|
@@ -160,7 +163,7 @@ var SalesChannelListActions = ({
|
|
|
160
163
|
children
|
|
161
164
|
}) => {
|
|
162
165
|
const { t } = useTranslation2();
|
|
163
|
-
return /* @__PURE__ */ jsx2("div", { className: "flex items-center justify-center gap-x-2", children: Children.count(children) > 0 ? children : /* @__PURE__ */ jsx2(Button, { size: "small", variant: "secondary", asChild: true, children: /* @__PURE__ */ jsx2(Link, { to: "/settings/sales-channels/create", children: t("actions.create") }) }) });
|
|
166
|
+
return /* @__PURE__ */ jsx2("div", { className: "flex items-center justify-center gap-x-2", children: Children.count(children) > 0 ? children : /* @__PURE__ */ jsx2(PermissionAction, { permission: "sales_channels:edit", children: /* @__PURE__ */ jsx2(Button, { size: "small", variant: "secondary", asChild: true, children: /* @__PURE__ */ jsx2(Link, { to: "/settings/sales-channels/create", children: t("actions.create") }) }) }) });
|
|
164
167
|
};
|
|
165
168
|
var SalesChannelListHeader = ({
|
|
166
169
|
children
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk-6G456XO4.js";
|
|
4
4
|
import {
|
|
5
5
|
useCustomerTableFilters
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-YDESULL7.js";
|
|
7
7
|
import {
|
|
8
8
|
useCustomerTableQuery
|
|
9
9
|
} from "./chunk-GRH7C3QN.js";
|
|
@@ -13,13 +13,13 @@ import {
|
|
|
13
13
|
import {
|
|
14
14
|
_DataTable,
|
|
15
15
|
useDataTable
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-SU36MZXC.js";
|
|
17
|
+
import {
|
|
18
|
+
ActionMenu
|
|
19
|
+
} from "./chunk-3UOYBH5O.js";
|
|
17
20
|
import {
|
|
18
21
|
useCustomers
|
|
19
22
|
} from "./chunk-XWOFQSGH.js";
|
|
20
|
-
import {
|
|
21
|
-
ActionMenu
|
|
22
|
-
} from "./chunk-BDGZ4EQO.js";
|
|
23
23
|
|
|
24
24
|
// src/pages/customers/customer-list/customer-list.tsx
|
|
25
25
|
import { Children as Children2 } from "react";
|
|
@@ -43,7 +43,7 @@ var CustomerListTitle = () => {
|
|
|
43
43
|
};
|
|
44
44
|
var CustomerListCreateButton = () => {
|
|
45
45
|
const { t } = useTranslation();
|
|
46
|
-
return /* @__PURE__ */ jsx(PermissionGuard, {
|
|
46
|
+
return /* @__PURE__ */ jsx(PermissionGuard, { permission: "customers:edit", children: /* @__PURE__ */ jsx(Link, { to: "/customers/create", "data-testid": "customer-list-create-link", children: /* @__PURE__ */ jsx(Button, { size: "small", variant: "secondary", "data-testid": "customer-list-create-button", children: t("actions.create") }) }) });
|
|
47
47
|
};
|
|
48
48
|
var CustomerListActions = ({ children }) => {
|
|
49
49
|
return /* @__PURE__ */ jsx("div", { className: "flex items-center gap-x-2", children: Children.count(children) > 0 ? children : /* @__PURE__ */ jsx(CustomerListCreateButton, {}) });
|
|
@@ -138,7 +138,8 @@ var CustomerActions = ({
|
|
|
138
138
|
{
|
|
139
139
|
icon: /* @__PURE__ */ jsx(PencilSquare, {}),
|
|
140
140
|
label: t("actions.edit"),
|
|
141
|
-
to: `/customers/${customer.id}/edit
|
|
141
|
+
to: `/customers/${customer.id}/edit`,
|
|
142
|
+
permission: "customers:edit"
|
|
142
143
|
}
|
|
143
144
|
]
|
|
144
145
|
}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
2
|
SingleColumnPage
|
|
3
3
|
} from "./chunk-H6MYB7GB.js";
|
|
4
|
+
import {
|
|
5
|
+
ActionMenu
|
|
6
|
+
} from "./chunk-3UOYBH5O.js";
|
|
4
7
|
import {
|
|
5
8
|
useDeleteUser,
|
|
6
9
|
useUser
|
|
7
|
-
} from "./chunk-
|
|
8
|
-
import {
|
|
9
|
-
ActionMenu
|
|
10
|
-
} from "./chunk-BDGZ4EQO.js";
|
|
10
|
+
} from "./chunk-AZV22U4V.js";
|
|
11
11
|
import {
|
|
12
12
|
SingleColumnPageSkeleton
|
|
13
13
|
} from "./chunk-INNFZYX2.js";
|
|
@@ -63,6 +63,7 @@ var UserGeneralSection = ({ user }) => {
|
|
|
63
63
|
{
|
|
64
64
|
actions: [
|
|
65
65
|
{
|
|
66
|
+
permission: "users:edit",
|
|
66
67
|
label: t("actions.edit"),
|
|
67
68
|
to: "edit",
|
|
68
69
|
icon: /* @__PURE__ */ jsx(PencilSquare, {})
|
|
@@ -72,6 +73,7 @@ var UserGeneralSection = ({ user }) => {
|
|
|
72
73
|
{
|
|
73
74
|
actions: [
|
|
74
75
|
{
|
|
76
|
+
permission: "users:manage",
|
|
75
77
|
label: t("actions.delete"),
|
|
76
78
|
onClick: handleDeleteUser,
|
|
77
79
|
icon: /* @__PURE__ */ jsx(Trash, {})
|