@mercurjs/vendor 2.2.0-rc.0 → 2.2.0-rc.2
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/{[id]-4HO4S2PX.js → [id]-3GF4DR5K.js} +704 -670
- package/dist/{[id]-4LIIFGET.js → [id]-3HIZGJWE.js} +140 -51
- package/dist/{[id]-XP5KEMNX.js → [id]-AXGVRF7M.js} +99 -62
- package/dist/{[id]-N7JEZFXQ.js → [id]-C7IFTDTJ.js} +4 -3
- package/dist/{[id]-DT5YJVKG.js → [id]-DKF4YEXN.js} +32 -31
- package/dist/{[id]-DCGPICT3.js → [id]-IFWREJVP.js} +37 -36
- package/dist/{[id]-IEBZ6V3W.js → [id]-LJABCC3D.js} +43 -42
- package/dist/{[id]-3LNKC5OJ.js → [id]-MIASQVLP.js} +93 -52
- package/dist/{[id]-U6FKX5UQ.js → [id]-NGB5OLRW.js} +68 -54
- package/dist/{[id]-XB45DY2D.js → [id]-ONBG5DZJ.js} +121 -43
- package/dist/{[id]-CUBGVODE.js → [id]-OV5VX7KD.js} +102 -61
- package/dist/{[id]-5P5LTATX.js → [id]-QWI3RWE6.js} +31 -13
- package/dist/{[id]-AQUUZFRX.js → [id]-RFC2YGFT.js} +142 -44
- package/dist/{[id]-5EECCIRP.js → [id]-VKEADKFV.js} +74 -49
- package/dist/{[location_id]-I4HHUHWY.js → [location_id]-ZG5GZKHC.js} +11 -10
- package/dist/{[province_id]-OYX4MOCF.js → [province_id]-KEDQTW6S.js} +31 -30
- package/dist/{add-RPRJWCYU.js → add-FDIWOFVE.js} +31 -30
- package/dist/{add-3T4GBFMM.js → add-ZIP3VEAV.js} +37 -37
- package/dist/{add-customer-groups-FB5T6PQN.js → add-customer-groups-EJIRM264.js} +25 -25
- package/dist/{add-products-F243SWGD.js → add-products-MW2JYTSJ.js} +30 -30
- package/dist/{add-promotions-TJDK7HLW.js → add-promotions-3BALABRA.js} +7 -7
- package/dist/{add-to-campaign-Q6OAJMUJ.js → add-to-campaign-B7RFNWPF.js} +5 -5
- package/dist/{address-XVBSNMFU.js → address-CP2MSWLA.js} +41 -29
- package/dist/{adjust-inventory-IZLRMQXV.js → adjust-inventory-CQPDV5X7.js} +3 -3
- package/dist/{allocate-items-Q3VALDYT.js → allocate-items-5HHGU3XW.js} +4 -4
- package/dist/{areas-IYGBRCRH.js → areas-XQE3AYPZ.js} +7 -7
- package/dist/{attributes-LGEM2JJW.js → attributes-HU6I723C.js} +2 -2
- package/dist/breadcrumb-3M7RKX5V.js +47 -0
- package/dist/{breadcrumb-WG6TIF4C.js → breadcrumb-4O2P6XRS.js} +5 -3
- package/dist/{breadcrumb-K4HBKZUE.js → breadcrumb-4Z7NR2BO.js} +3 -3
- package/dist/{breadcrumb-BC6XN2SE.js → breadcrumb-4ZZFD3UH.js} +3 -3
- package/dist/{breadcrumb-MOA2DBOE.js → breadcrumb-6VWM2EJF.js} +2 -2
- package/dist/{breadcrumb-YOY6Z36F.js → breadcrumb-75QGQDKN.js} +2 -2
- package/dist/{breadcrumb-FEYGZFJU.js → breadcrumb-C7X6FV2H.js} +3 -3
- package/dist/breadcrumb-EAYZVNKS.js +33 -0
- package/dist/{breadcrumb-H45Z2WNG.js → breadcrumb-FF7H3XPP.js} +4 -4
- package/dist/{breadcrumb-KZPOPXGG.js → breadcrumb-GLBWFHKW.js} +2 -2
- package/dist/{breadcrumb-XEZCMI55.js → breadcrumb-HK53R6S2.js} +2 -2
- package/dist/{breadcrumb-BFNJWOJ4.js → breadcrumb-KV6K64PW.js} +2 -2
- package/dist/{breadcrumb-LEFHXFLT.js → breadcrumb-KZ5TSCXK.js} +3 -3
- package/dist/breadcrumb-TPITDYD7.js +46 -0
- package/dist/{breadcrumb-XGXKCDYS.js → breadcrumb-UVODV3YP.js} +4 -4
- package/dist/{breadcrumb-L262VPBO.js → breadcrumb-WIB5IGST.js} +2 -2
- package/dist/{breadcrumb-BXD3SRM7.js → breadcrumb-X5TTCKIB.js} +2 -2
- package/dist/{campaigns-DZKRNCA4.js → campaigns-JKFMRYZE.js} +6 -6
- package/dist/{categories-JZJA2IBQ.js → categories-2PGWWGP6.js} +7 -7
- package/dist/{chunk-CRYZK4NU.js → chunk-2GVPLCQR.js} +2 -2
- package/dist/{chunk-MJP5V3JN.js → chunk-3IZSQI6K.js} +2 -2
- package/dist/chunk-432S4FGR.js +0 -0
- package/dist/{chunk-HDEOZN2Q.js → chunk-4OQLPIUZ.js} +27 -27
- package/dist/{chunk-JJP6AKMV.js → chunk-4U2BLH45.js} +1 -1
- package/dist/{chunk-WFHGJGCW.js → chunk-4ZWIWI2H.js} +27 -12
- package/dist/{chunk-DSTHXHJ5.js → chunk-52KJSIHS.js} +1358 -1392
- package/dist/{chunk-GSH6ZGI6.js → chunk-54SCBOWD.js} +35 -12
- package/dist/{chunk-MAW6ZT3D.js → chunk-55TS752B.js} +1 -1
- package/dist/{chunk-3ALBZK4M.js → chunk-57ZJ6HTU.js} +18 -4
- package/dist/{chunk-EPRYM3FA.js → chunk-5DKUSZQ7.js} +2 -2
- package/dist/{chunk-L57USMYC.js → chunk-5YZ3G5EZ.js} +1 -1
- package/dist/{chunk-3SH24DGG.js → chunk-656G74I2.js} +2 -2
- package/dist/{chunk-ZLYGEART.js → chunk-65HHU6D3.js} +1 -1
- package/dist/{chunk-ZTOYVPGA.js → chunk-6PSJJHI4.js} +1 -1
- package/dist/{chunk-FCZJAYMM.js → chunk-6RHJFSE3.js} +1 -1
- package/dist/{chunk-W3UHAQCV.js → chunk-7TQNE3E2.js} +1 -1
- package/dist/{chunk-FDKFUIYV.js → chunk-AAKR2CB4.js} +1 -1
- package/dist/{chunk-KTJLJTFO.js → chunk-ASN3XS2R.js} +95 -68
- package/dist/{chunk-UNE4VD5U.js → chunk-B25W27XK.js} +21 -10
- package/dist/{chunk-H6LZ77GX.js → chunk-BEPAXQMU.js} +4 -1
- package/dist/{chunk-PUAWN7SS.js → chunk-BHEU34FL.js} +1 -1
- package/dist/{chunk-634XVU3D.js → chunk-CVXKASWV.js} +2 -2
- package/dist/{chunk-S7NGDLZ3.js → chunk-D6RN3ONJ.js} +3 -3
- package/dist/{chunk-VD27SL7H.js → chunk-DHARUTMI.js} +7 -6
- package/dist/{chunk-6FDPVW7Y.js → chunk-DIAWPVYS.js} +2 -2
- package/dist/{chunk-MT6WOKIW.js → chunk-DREOA2LP.js} +3 -3
- package/dist/{chunk-RILHLBKW.js → chunk-DRKRLQZZ.js} +2 -2
- package/dist/{chunk-IEVN722X.js → chunk-DSY5PNK6.js} +1 -1
- package/dist/{chunk-LXZXXOJ3.js → chunk-DTGEFKK4.js} +14 -1
- package/dist/{chunk-JDNXS37G.js → chunk-E5VLRRZR.js} +2 -2
- package/dist/{chunk-GZ4KTAWS.js → chunk-EPSDO2MJ.js} +1 -1
- package/dist/{chunk-KZQFIPY2.js → chunk-ESXMD6CR.js} +12 -4
- package/dist/{chunk-D76WZZSB.js → chunk-F4ORNDFU.js} +8 -7
- package/dist/{chunk-VE6GRIIN.js → chunk-FV76G2D7.js} +2 -2
- package/dist/{chunk-WBCWER26.js → chunk-G64YUZSL.js} +1 -1
- package/dist/{chunk-Y4PM3IDZ.js → chunk-GGXGKMYK.js} +1 -1
- package/dist/{chunk-7MARNXFG.js → chunk-GHDLST2P.js} +1 -1
- package/dist/{chunk-2NPD4S55.js → chunk-H3PVTKOP.js} +2 -2
- package/dist/{chunk-E6W57UP3.js → chunk-HRUO43BZ.js} +2 -2
- package/dist/{chunk-OYUJYPDF.js → chunk-II3CLUXA.js} +3 -2
- package/dist/{chunk-CUAGC54B.js → chunk-IP6TSKUQ.js} +23 -9
- package/dist/{chunk-KIURBTC4.js → chunk-J2XUEO2E.js} +1 -1
- package/dist/{chunk-QIF4QE7T.js → chunk-K5324KIX.js} +1 -1
- package/dist/{chunk-5BYYDBLS.js → chunk-KGHHGMDU.js} +4 -4
- package/dist/{chunk-QWW6RHZC.js → chunk-KUH5ZX7G.js} +5 -4
- package/dist/{chunk-NTJ3BMOE.js → chunk-L2NJPDUD.js} +1 -1
- package/dist/{chunk-JK4M3ZKY.js → chunk-LFX6R456.js} +5 -5
- package/dist/{chunk-MAVQ636Y.js → chunk-MDFKI2FL.js} +1 -1
- package/dist/{chunk-WFE6CT6M.js → chunk-MDGTQT5D.js} +1 -1
- package/dist/{chunk-ZLHCZ5F2.js → chunk-MR6REQKT.js} +5 -5
- package/dist/{chunk-LWFBBTJ3.js → chunk-N7YRIXJA.js} +22 -11
- package/dist/{chunk-ZQCCVCHB.js → chunk-O72AIZUN.js} +1 -1
- package/dist/{chunk-RPU4UOQK.js → chunk-OATVHDPZ.js} +1 -1
- package/dist/{chunk-JY2XON7H.js → chunk-OCS24TF4.js} +7 -6
- package/dist/{chunk-3TST3EWQ.js → chunk-OQTL7PXK.js} +2 -2
- package/dist/{chunk-V5K6HISS.js → chunk-ORI73OPX.js} +2 -2
- package/dist/{chunk-2KA4TGBQ.js → chunk-OZ2UHCWA.js} +20 -9
- package/dist/{chunk-JTHDMXZV.js → chunk-P27MQBMZ.js} +2 -2
- package/dist/{chunk-4IRQSBA7.js → chunk-P76QYIFF.js} +1 -1
- package/dist/{chunk-5PAUN3PM.js → chunk-P7UBW2EI.js} +3 -3
- package/dist/{chunk-5RMLLTR7.js → chunk-PEXMLTJX.js} +2 -2
- package/dist/chunk-QEFPTNPC.js +81 -0
- package/dist/{chunk-BQHVM46E.js → chunk-RLRWDHME.js} +1 -1
- package/dist/{chunk-7BFQKYCJ.js → chunk-RPMYKDNA.js} +2 -2
- package/dist/{chunk-UX5UYDCY.js → chunk-RSOV55K7.js} +2 -2
- package/dist/{chunk-RTMMO6IU.js → chunk-RZHVUQ7G.js} +25 -13
- package/dist/{chunk-3I6ZAMGN.js → chunk-SFQOECF7.js} +1 -1
- package/dist/{chunk-LQSLDDPT.js → chunk-T35QBLG7.js} +1 -1
- package/dist/{chunk-7EXKHL5L.js → chunk-TDL742KZ.js} +1 -1
- package/dist/{chunk-6Q3J6ZMM.js → chunk-UDPMSL6L.js} +41 -19
- package/dist/{chunk-EDV4MTTT.js → chunk-VQTQILLY.js} +65 -37
- package/dist/{chunk-TPGIMZLI.js → chunk-VR7P4DAZ.js} +1 -1
- package/dist/{chunk-5BQO3YQP.js → chunk-VUWAOX7H.js} +2 -2
- package/dist/{chunk-JR7AABT5.js → chunk-VWPNMEOE.js} +2 -2
- package/dist/{chunk-MVEHWM7K.js → chunk-W34KDYZA.js} +15 -4
- package/dist/{chunk-EAAZV3B7.js → chunk-WJ4KVDFV.js} +24 -12
- package/dist/{chunk-MUGQQY6P.js → chunk-WN2NWWVO.js} +49 -11
- package/dist/chunk-WQTWBXKO.js +23 -0
- package/dist/{chunk-3BXCPHN6.js → chunk-XCHKUSUU.js} +1 -0
- package/dist/{chunk-KG2NUK4J.js → chunk-XEQU2OQP.js} +46 -15
- package/dist/{chunk-AOLE7MBM.js → chunk-XG76XXM2.js} +1 -1
- package/dist/{chunk-O7BGGWW6.js → chunk-XKEYHWBS.js} +5 -5
- package/dist/{chunk-DQ7LZZJX.js → chunk-XQO243HC.js} +24 -13
- package/dist/{chunk-TJKZ5QCJ.js → chunk-XUJUJD2E.js} +3 -3
- package/dist/{chunk-27WLUOI2.js → chunk-Y6S7K3YB.js} +1 -1
- package/dist/{chunk-G6YNCIVF.js → chunk-YAUGB4LD.js} +2 -2
- package/dist/{chunk-WCXFUBEF.js → chunk-YVI3LZ3X.js} +9 -9
- package/dist/{chunk-MNHP6YRC.js → chunk-YVYYOBAE.js} +3 -3
- package/dist/{chunk-3C2T27YW.js → chunk-YXWZT3PX.js} +1 -1
- package/dist/{chunk-QWJTJSIT.js → chunk-ZC2ME3UB.js} +1 -1
- package/dist/{collections-XIHCTMSJ.js → collections-BLDMQOVB.js} +31 -31
- package/dist/{configuration-3GCBMM27.js → configuration-UMRBE5RQ.js} +2 -2
- package/dist/{configuration-FWZTMYXY.js → configuration-YVYVOLSP.js} +4 -4
- package/dist/{create-BV3QDTK2.js → create-3SBSLZQO.js} +3 -3
- package/dist/{create-NF2LPVXA.js → create-3TN2CT6M.js} +2 -2
- package/dist/{create-VL7LDTVE.js → create-3WBHG32J.js} +12 -12
- package/dist/{create-2RGNAVVY.js → create-3ZQFAKYR.js} +27 -27
- package/dist/{create-PJVLJ7T6.js → create-4ZRQVXT5.js} +31 -31
- package/dist/{create-GO7APBBU.js → create-7Z63KA2P.js} +25 -25
- package/dist/{create-N534JQPH.js → create-B4VIR7YP.js} +7 -7
- package/dist/{create-U64NEOEL.js → create-EKDZW233.js} +2 -2
- package/dist/{create-X5SOAPD3.js → create-EMU23LKH.js} +2 -2
- package/dist/{create-RPBHXU32.js → create-FYKFT7TQ.js} +23 -23
- package/dist/{create-32MXB6FD.js → create-NNBIDU4Q.js} +23 -23
- package/dist/{create-FHIFVCSG.js → create-PO2JF7F5.js} +37 -37
- package/dist/{create-NEK6JCKR.js → create-PO3JC6QK.js} +13 -13
- package/dist/{create-YKYLCEAK.js → create-QZVZF3MJ.js} +5 -5
- package/dist/{create-K26SM34L.js → create-T3KSWODJ.js} +2 -2
- package/dist/{create-HEZYB7RF.js → create-TDQISX3H.js} +59 -25
- package/dist/{create-3AMFYYI6.js → create-XORPYXNT.js} +25 -25
- package/dist/{create-AMNH3WXL.js → create-XU35U2HL.js} +36 -32
- package/dist/{create-XLYGW5PN.js → create-ZLYEPOAQ.js} +24 -24
- package/dist/{customer-group-add-customers-2C53NFBJ.js → customer-group-add-customers-UTBBZ6T4.js} +5 -5
- package/dist/{customer-group-create-75QQEQZF.js → customer-group-create-L3H5REVP.js} +2 -2
- package/dist/{customer-group-detail-AOQYYAOG.js → customer-group-detail-WSBXE23J.js} +19 -15
- package/dist/{customer-group-edit-N77RCW6I.js → customer-group-edit-D6FJH5TK.js} +49 -28
- package/dist/{customer-groups-GNFV7VMT.js → customer-groups-TWCYFU3U.js} +37 -16
- package/dist/{customers-HNINO6YL.js → customers-6HDZKARD.js} +7 -7
- package/dist/{edit-UNN3QTEJ.js → edit-2RN3OT27.js} +24 -8
- package/dist/{edit-WEUFBORT.js → edit-5XPDTCB5.js} +25 -25
- package/dist/{edit-TD7QFM4Z.js → edit-CNXA4GKJ.js} +15 -17
- package/dist/{edit-BSD6667Q.js → edit-DCMMX4GW.js} +28 -29
- package/dist/{edit-NHQJLCAK.js → edit-DKUERO2V.js} +2 -2
- package/dist/{edit-I2RJUPWV.js → edit-FF2ZWS6U.js} +3 -3
- package/dist/{edit-3DUCWSLA.js → edit-ISFEI7YX.js} +79 -46
- package/dist/{edit-O65JD54W.js → edit-IVBVZ5NL.js} +6 -6
- package/dist/{edit-IJ6DCBUU.js → edit-K2IP2H25.js} +29 -12
- package/dist/{edit-ZOLSAIKF.js → edit-MUQ37ETA.js} +2 -2
- package/dist/{edit-JB7KVBOL.js → edit-NTTJKLUI.js} +4 -4
- package/dist/{edit-4PWAJ7A3.js → edit-OOY2XGLZ.js} +24 -24
- package/dist/{edit-7SBPHN6P.js → edit-P6YZBA32.js} +24 -8
- package/dist/{edit-3V34KJS2.js → edit-Q7KDO37A.js} +2 -2
- package/dist/{edit-ZGAOUZYP.js → edit-QII5YJ2R.js} +25 -25
- package/dist/{edit-WN2Q3TOX.js → edit-RRA6J5FW.js} +3 -3
- package/dist/{edit-SIKOSSHF.js → edit-Y4XONJJU.js} +23 -23
- package/dist/{edit-ZORE6RUD.js → edit-YDMBLXGU.js} +56 -37
- package/dist/{edit-7CLOJ3UZ.js → edit-YPIJHIGC.js} +37 -37
- package/dist/{edit-budget-D22WMVYR.js → edit-budget-PYPHUJPW.js} +2 -2
- package/dist/{edit-inventory-item-QMYWEBZ3.js → edit-inventory-item-5VBH365V.js} +23 -8
- package/dist/{edit-inventory-item-attributes-HLG6JR6S.js → edit-inventory-item-attributes-RMKG2IRO.js} +2 -2
- package/dist/{edit-price-F7ZWM3FN.js → edit-price-PDS4XN2J.js} +5 -5
- package/dist/{edit-stock-ITAZNHPU.js → edit-stock-UI6HXHJJ.js} +4 -4
- package/dist/extension-targets.d.ts +248 -0
- package/dist/extension-targets.js +1 -0
- package/dist/{fulfillment-U2GRQ6DD.js → fulfillment-6GC3NRFT.js} +33 -24
- package/dist/{fulfillment-providers-CMU2JB5X.js → fulfillment-providers-IND53UPG.js} +28 -28
- package/dist/index.css +24 -12
- package/dist/index.d.ts +2 -0
- package/dist/index.js +257 -230
- package/dist/{inventory-FKEXULLT.js → inventory-BDST2XIX.js} +7 -7
- package/dist/{inventory-4JKLAZ2Q.js → inventory-LSG2IEWD.js} +4 -4
- package/dist/{invite-3R2CEWLN.js → invite-CNJQ27AY.js} +30 -43
- package/dist/{invite-MNAX6EUC.js → invite-DD2G6UUM.js} +27 -27
- package/dist/{loader-MAAMUP2Z.js → loader-BLRQLIJT.js} +13 -11
- package/dist/{loader-HTPUNIOS.js → loader-MJTR2S7V.js} +14 -12
- package/dist/{locations-2VWSMWHL.js → locations-HHP2DZ4N.js} +3 -3
- package/dist/login-FK6ATIQV.js +41 -0
- package/dist/{manage-locations-RWGDXXJQ.js → manage-locations-V2AJVZXA.js} +3 -3
- package/dist/{media-P6WSFHY4.js → media-2Z2UIOQU.js} +27 -27
- package/dist/{media-YB4G5CMV.js → media-T26YU24S.js} +25 -25
- package/dist/{metadata-J447GEBP.js → metadata-3CER2AEK.js} +23 -23
- package/dist/{metadata-6OYHLPLA.js → metadata-BGYWXGMG.js} +23 -23
- package/dist/{metadata-VTQ2CGZX.js → metadata-MSAODJ2T.js} +23 -23
- package/dist/{metadata-5Q6FLVX4.js → metadata-WB37SSTG.js} +23 -23
- package/dist/{metadata-ADXGD4Y6.js → metadata-XS3VAC3N.js} +23 -23
- package/dist/{offer-create-page-ACPKTNHA.js → offer-create-page-QAHHXLLJ.js} +31 -29
- package/dist/{offer-detail-page-S4R4N5GL.js → offer-detail-page-ZLGP4ELR.js} +81 -28
- package/dist/{offer-variant-detail-page-XUMDXZUD.js → offer-variant-detail-page-2A7TRGYS.js} +28 -22
- package/dist/offers-ZBAZOZ7Q.js +54 -0
- package/dist/{onboarding-TUGXFOA6.js → onboarding-XCCZ2TMN.js} +70 -75
- package/dist/orders-VFSDZYOV.js +63 -0
- package/dist/{organization-YIOAVFHN.js → organization-YB45TRUN.js} +25 -25
- package/dist/{organize-OWT5QSJR.js → organize-HQLROEUF.js} +4 -4
- package/dist/{organize-BTA7NJD2.js → organize-T62CDRZC.js} +4 -4
- package/dist/pages/index.d.ts +17 -2
- package/dist/pages/index.js +69 -69
- package/dist/{payment-details-K2XFATEL.js → payment-details-O4EWCOYQ.js} +42 -30
- package/dist/{payouts-K5IDTJV3.js → payouts-7O5W2X5J.js} +8 -8
- package/dist/{price-lists-DNPIPDAW.js → price-lists-5CSCTVWN.js} +9 -9
- package/dist/{pricing-5VUPPNKS.js → pricing-CF3FJP6A.js} +5 -5
- package/dist/{pricing-J5FIDZIY.js → pricing-NHI4NSLA.js} +25 -25
- package/dist/{product-tags-SJYIGXEV.js → product-tags-2TLA7BVO.js} +38 -38
- package/dist/{product-types-4PTJW5DE.js → product-types-LZAMCLGS.js} +7 -7
- package/dist/{product-variant-detail-FO6J3RFA.js → product-variant-detail-UNG6LWDP.js} +27 -26
- package/dist/{product-variant-edit-55TAIBZO.js → product-variant-edit-K5U3JZFW.js} +25 -25
- package/dist/{products-XM57LXJK.js → products-27ASSSVK.js} +43 -42
- package/dist/{products-EQMANSO6.js → products-WJJBC3NI.js} +30 -30
- package/dist/{professional-details-WWZPTXSX.js → professional-details-ZCRAWCXZ.js} +41 -29
- package/dist/{profile-5IADQ727.js → profile-T2QLFLI7.js} +77 -38
- package/dist/{promotions-BYW6TZ5B.js → promotions-E4Z6APSX.js} +9 -9
- package/dist/{receive-MTXKKPKZ.js → receive-QCVCAR3R.js} +6 -6
- package/dist/{refund-3IXGYA7W.js → refund-GAOWE636.js} +74 -50
- package/dist/{register-U5PQZATC.js → register-IKY5DDUR.js} +28 -27
- package/dist/{reset-password-SKUJJLSV.js → reset-password-RMKCQLBX.js} +3 -3
- package/dist/{return-reasons-QDPSIJG3.js → return-reasons-RH6IEU2M.js} +20 -17
- package/dist/{sales-channels-GBSTCWVP.js → sales-channels-C5M2ZA5L.js} +6 -5
- package/dist/{sales-channels-N4NE3FXP.js → sales-channels-ZHYGTRWU.js} +7 -6
- package/dist/{settings-ZUBBFS67.js → settings-5IUDEPUN.js} +42 -42
- package/dist/{shipment-TKSCPC3M.js → shipment-UP2OGESO.js} +23 -23
- package/dist/{shipping-DODEUYOQ.js → shipping-ACK5UOA5.js} +4 -4
- package/dist/{shipping-profile-O4JMJLN7.js → shipping-profile-3US7LC5E.js} +2 -2
- package/dist/shipping-profiles-34432J3C.js +46 -0
- package/dist/{stock-GYK2GHJN.js → stock-VMND7PJY.js} +23 -23
- package/dist/{store-XWOALZ5Q.js → store-BCNSSIO6.js} +130 -60
- package/dist/{store-closure-46B3XZ2I.js → store-closure-QGR3F45Y.js} +23 -23
- package/dist/{store-select-E77E3ZY7.js → store-select-55ZOJGGV.js} +47 -27
- package/dist/{tax-regions-S2LFRTMP.js → tax-regions-RTPVM4IC.js} +11 -8
- package/dist/{team-N2C5JPSU.js → team-DAUWBJAI.js} +32 -31
- package/package.json +21 -16
- package/dist/breadcrumb-ILEAQRW7.js +0 -33
- package/dist/breadcrumb-NZYOCEEM.js +0 -47
- package/dist/breadcrumb-VY5DNTTJ.js +0 -46
- package/dist/chunk-HXGLPDZW.js +0 -34
- package/dist/chunk-KVKO6N4G.js +0 -13
- package/dist/login-YUWOWICV.js +0 -39
- package/dist/offers-OTZJBW43.js +0 -54
- package/dist/orders-PJSJNGZS.js +0 -63
- package/dist/shipping-profiles-4TJ4IH6U.js +0 -46
- /package/dist/{chunk-HFRHHT36.js → chunk-NWU7EGGF.js} +0 -0
|
@@ -7,23 +7,23 @@ import {
|
|
|
7
7
|
CategoryHeader,
|
|
8
8
|
ProductStatusCell,
|
|
9
9
|
ProductStatusHeader
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-G64YUZSL.js";
|
|
11
11
|
import {
|
|
12
12
|
ProductCell
|
|
13
13
|
} from "./chunk-FWPGOIFA.js";
|
|
14
14
|
import {
|
|
15
15
|
useProductTableFilters
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-LFX6R456.js";
|
|
17
17
|
import {
|
|
18
18
|
PlaceholderCell
|
|
19
19
|
} from "./chunk-PHOCVOZ5.js";
|
|
20
|
-
import {
|
|
21
|
-
_DataTable,
|
|
22
|
-
useDataTable
|
|
23
|
-
} from "./chunk-W3UHAQCV.js";
|
|
24
20
|
import {
|
|
25
21
|
SingleColumnPage
|
|
26
22
|
} from "./chunk-YV6MK4PZ.js";
|
|
23
|
+
import {
|
|
24
|
+
_DataTable,
|
|
25
|
+
useDataTable
|
|
26
|
+
} from "./chunk-7TQNE3E2.js";
|
|
27
27
|
import {
|
|
28
28
|
useQueryParams
|
|
29
29
|
} from "./chunk-THHRRYRS.js";
|
|
@@ -32,13 +32,14 @@ import {
|
|
|
32
32
|
} from "./chunk-BDGZ4EQO.js";
|
|
33
33
|
import {
|
|
34
34
|
useBulkDeleteOffers
|
|
35
|
-
} from "./chunk-
|
|
35
|
+
} from "./chunk-5DKUSZQ7.js";
|
|
36
36
|
import {
|
|
37
37
|
useProducts
|
|
38
|
-
} from "./chunk-
|
|
38
|
+
} from "./chunk-YAUGB4LD.js";
|
|
39
39
|
|
|
40
40
|
// src/pages/offers/offer-list-page.tsx
|
|
41
41
|
import { Children as Children2 } from "react";
|
|
42
|
+
import { WidgetZone } from "@mercurjs/dashboard-shared";
|
|
42
43
|
|
|
43
44
|
// src/pages/offers/_components/offer-list-table.tsx
|
|
44
45
|
import { Container } from "@medusajs/ui";
|
|
@@ -47,7 +48,9 @@ import { Outlet } from "react-router-dom";
|
|
|
47
48
|
|
|
48
49
|
// src/pages/offers/_components/offer-list-data-table.tsx
|
|
49
50
|
import { keepPreviousData } from "@tanstack/react-query";
|
|
51
|
+
import { useMemo as useMemo2 } from "react";
|
|
50
52
|
import { useTranslation as useTranslation3 } from "react-i18next";
|
|
53
|
+
import { useExtendableTable } from "@mercurjs/dashboard-shared";
|
|
51
54
|
|
|
52
55
|
// src/pages/offers/_components/use-offer-table-columns.tsx
|
|
53
56
|
import { Text } from "@medusajs/ui";
|
|
@@ -200,6 +203,7 @@ var useOfferTableColumns = () => {
|
|
|
200
203
|
var useOfferTableFilters = () => useProductTableFilters();
|
|
201
204
|
|
|
202
205
|
// src/pages/offers/_components/use-offer-table-query.tsx
|
|
206
|
+
import { useLinkQuery } from "@mercurjs/dashboard-shared";
|
|
203
207
|
var useOfferTableQuery = ({
|
|
204
208
|
pageSize = 10,
|
|
205
209
|
prefix
|
|
@@ -232,6 +236,7 @@ var useOfferTableQuery = ({
|
|
|
232
236
|
order,
|
|
233
237
|
q
|
|
234
238
|
} = raw;
|
|
239
|
+
const { fields } = useLinkQuery("offer", OFFER_PRODUCT_LIST_FIELDS);
|
|
235
240
|
const searchParams = {
|
|
236
241
|
limit: pageSize,
|
|
237
242
|
offset: offset ? Number(offset) : 0,
|
|
@@ -245,7 +250,7 @@ var useOfferTableQuery = ({
|
|
|
245
250
|
created_at: created_at ? JSON.parse(created_at) : void 0,
|
|
246
251
|
updated_at: updated_at ? JSON.parse(updated_at) : void 0,
|
|
247
252
|
has_offer: "true",
|
|
248
|
-
fields
|
|
253
|
+
fields
|
|
249
254
|
};
|
|
250
255
|
return {
|
|
251
256
|
searchParams,
|
|
@@ -265,8 +270,12 @@ var OfferListDataTable = () => {
|
|
|
265
270
|
{ placeholderData: keepPreviousData }
|
|
266
271
|
);
|
|
267
272
|
const rows = products ?? [];
|
|
268
|
-
const
|
|
269
|
-
const columns =
|
|
273
|
+
const baseFilters = useOfferTableFilters();
|
|
274
|
+
const { columns, filters: extFilters } = useColumns();
|
|
275
|
+
const filters = useMemo2(
|
|
276
|
+
() => [...baseFilters, ...extFilters],
|
|
277
|
+
[baseFilters, extFilters]
|
|
278
|
+
);
|
|
270
279
|
const { table } = useDataTable({
|
|
271
280
|
data: rows,
|
|
272
281
|
columns,
|
|
@@ -308,6 +317,20 @@ var OfferListDataTable = () => {
|
|
|
308
317
|
}
|
|
309
318
|
);
|
|
310
319
|
};
|
|
320
|
+
var useColumns = () => {
|
|
321
|
+
const base = useOfferTableColumns();
|
|
322
|
+
const actionsColumn = base[base.length - 1];
|
|
323
|
+
const baseColumns = base.slice(0, -1);
|
|
324
|
+
const { columns: extended, filters } = useExtendableTable({
|
|
325
|
+
model: "offer",
|
|
326
|
+
columns: baseColumns
|
|
327
|
+
});
|
|
328
|
+
const columns = useMemo2(
|
|
329
|
+
() => [...extended, actionsColumn],
|
|
330
|
+
[extended, actionsColumn]
|
|
331
|
+
);
|
|
332
|
+
return { columns, filters };
|
|
333
|
+
};
|
|
311
334
|
|
|
312
335
|
// src/pages/offers/_components/offer-list-header.tsx
|
|
313
336
|
import { Button, Heading } from "@medusajs/ui";
|
|
@@ -339,7 +362,7 @@ var OfferListTable = ({ children }) => /* @__PURE__ */ jsxs2(Container, { classN
|
|
|
339
362
|
|
|
340
363
|
// src/pages/offers/offer-list-page.tsx
|
|
341
364
|
import { jsx as jsx6 } from "react/jsx-runtime";
|
|
342
|
-
var Root = ({ children }) => /* @__PURE__ */ jsx6(SingleColumnPage, { children: Children2.count(children) > 0 ? children : /* @__PURE__ */ jsx6(OfferListTable, {}) });
|
|
365
|
+
var Root = ({ children }) => /* @__PURE__ */ jsx6(SingleColumnPage, { children: /* @__PURE__ */ jsx6(WidgetZone, { id: "offers.list", children: Children2.count(children) > 0 ? children : /* @__PURE__ */ jsx6(OfferListTable, {}) }) });
|
|
343
366
|
var OfferListPage = Object.assign(Root, {
|
|
344
367
|
Table: OfferListTable,
|
|
345
368
|
Header: OfferListHeader,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
AuthLayout
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-QEFPTNPC.js";
|
|
4
4
|
import {
|
|
5
5
|
AvatarBox
|
|
6
6
|
} from "./chunk-CP5IL4P6.js";
|
|
@@ -10,11 +10,21 @@ import {
|
|
|
10
10
|
import {
|
|
11
11
|
Form
|
|
12
12
|
} from "./chunk-3QSRE5LS.js";
|
|
13
|
+
import {
|
|
14
|
+
require_dist
|
|
15
|
+
} from "./chunk-52KJSIHS.js";
|
|
16
|
+
import {
|
|
17
|
+
useFeatureFlags
|
|
18
|
+
} from "./chunk-RLRWDHME.js";
|
|
13
19
|
import {
|
|
14
20
|
useSignInWithEmailPass
|
|
15
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-K5324KIX.js";
|
|
22
|
+
import {
|
|
23
|
+
__toESM
|
|
24
|
+
} from "./chunk-NBMM2TZK.js";
|
|
16
25
|
|
|
17
26
|
// src/pages/login/login.tsx
|
|
27
|
+
var import_types = __toESM(require_dist(), 1);
|
|
18
28
|
import { Children } from "react";
|
|
19
29
|
import { zodResolver } from "@hookform/resolvers/zod";
|
|
20
30
|
import i18n from "i18next";
|
|
@@ -23,6 +33,7 @@ import { useForm } from "react-hook-form";
|
|
|
23
33
|
import { Trans, useTranslation } from "react-i18next";
|
|
24
34
|
import { Link, useNavigate, useSearchParams } from "react-router-dom";
|
|
25
35
|
import * as z from "zod";
|
|
36
|
+
import { WidgetZone } from "@mercurjs/dashboard-shared";
|
|
26
37
|
import config from "virtual:mercur/config";
|
|
27
38
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
28
39
|
var LoginSchema = z.object({
|
|
@@ -30,7 +41,7 @@ var LoginSchema = z.object({
|
|
|
30
41
|
password: z.string().min(1, { message: i18n.t("login.validation.passwordRequired") })
|
|
31
42
|
});
|
|
32
43
|
var LoginLogo = () => {
|
|
33
|
-
return /* @__PURE__ */ jsx(AvatarBox, {});
|
|
44
|
+
return /* @__PURE__ */ jsx(WidgetZone, { id: "login.logo", children: /* @__PURE__ */ jsx(AvatarBox, {}) });
|
|
34
45
|
};
|
|
35
46
|
var LoginHeader = () => {
|
|
36
47
|
const { t } = useTranslation();
|
|
@@ -137,6 +148,7 @@ var LoginForm = () => {
|
|
|
137
148
|
] }) });
|
|
138
149
|
};
|
|
139
150
|
var LoginFooter = () => {
|
|
151
|
+
const { feature_flags } = useFeatureFlags();
|
|
140
152
|
return /* @__PURE__ */ jsxs("div", { className: "mt-auto flex flex-col gap-y-2", children: [
|
|
141
153
|
/* @__PURE__ */ jsx("span", { className: "text-ui-fg-muted txt-small", children: /* @__PURE__ */ jsx(
|
|
142
154
|
Trans,
|
|
@@ -154,7 +166,7 @@ var LoginFooter = () => {
|
|
|
154
166
|
]
|
|
155
167
|
}
|
|
156
168
|
) }),
|
|
157
|
-
|
|
169
|
+
feature_flags?.[import_types.MercurFeatureFlags.SELLER_REGISTRATION] && /* @__PURE__ */ jsx("span", { className: "text-ui-fg-muted txt-small", children: /* @__PURE__ */ jsx(
|
|
158
170
|
Trans,
|
|
159
171
|
{
|
|
160
172
|
i18nKey: "login.notSellerYet",
|
|
@@ -175,10 +187,12 @@ var LoginFooter = () => {
|
|
|
175
187
|
var Root = ({ children }) => {
|
|
176
188
|
return /* @__PURE__ */ jsx(AuthLayout, { children: Children.count(children) > 0 ? children : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
177
189
|
/* @__PURE__ */ jsx(LoginLogo, {}),
|
|
190
|
+
/* @__PURE__ */ jsx(WidgetZone, { id: "login.before" }),
|
|
178
191
|
/* @__PURE__ */ jsxs("div", { className: "mt-6", children: [
|
|
179
192
|
/* @__PURE__ */ jsx(LoginHeader, {}),
|
|
180
193
|
/* @__PURE__ */ jsx(LoginForm, {})
|
|
181
194
|
] }),
|
|
195
|
+
/* @__PURE__ */ jsx(WidgetZone, { id: "login.after" }),
|
|
182
196
|
/* @__PURE__ */ jsx(LoginFooter, {})
|
|
183
197
|
] }) });
|
|
184
198
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
productsQueryKeys
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-YAUGB4LD.js";
|
|
4
4
|
import {
|
|
5
5
|
queryClient
|
|
6
6
|
} from "./chunk-RHKRREUU.js";
|
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
} from "./chunk-ZA2KFUFR.js";
|
|
10
10
|
import {
|
|
11
11
|
sdk
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-DTGEFKK4.js";
|
|
13
13
|
|
|
14
14
|
// src/hooks/api/offers.tsx
|
|
15
15
|
import {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
productsQueryKeys
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-YAUGB4LD.js";
|
|
4
4
|
import {
|
|
5
5
|
queryClient
|
|
6
6
|
} from "./chunk-RHKRREUU.js";
|
|
@@ -9,7 +9,7 @@ import {
|
|
|
9
9
|
} from "./chunk-ZA2KFUFR.js";
|
|
10
10
|
import {
|
|
11
11
|
sdk
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-DTGEFKK4.js";
|
|
13
13
|
|
|
14
14
|
// src/hooks/api/categories.tsx
|
|
15
15
|
import {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
useStockLocation
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-O72AIZUN.js";
|
|
4
4
|
|
|
5
5
|
// src/pages/settings/locations/[location_id]/constants.ts
|
|
6
6
|
var LOCATION_DETAILS_FIELD = "name,*sales_channels,*address,fulfillment_sets.type,fulfillment_sets.name,*fulfillment_sets.service_zones.geo_zones,*fulfillment_sets.service_zones,*fulfillment_sets.service_zones.shipping_options,*fulfillment_sets.service_zones.shipping_options.rules,*fulfillment_sets.service_zones.shipping_options.shipping_profile,*fulfillment_providers";
|
|
@@ -13,29 +13,26 @@ import {
|
|
|
13
13
|
} from "./chunk-YVCBMOJG.js";
|
|
14
14
|
import {
|
|
15
15
|
SingleCategoryCombobox
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-P76QYIFF.js";
|
|
17
17
|
import {
|
|
18
18
|
useComboboxData
|
|
19
19
|
} from "./chunk-OVPAOBZB.js";
|
|
20
20
|
import {
|
|
21
21
|
UploadMediaFormItem
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-OATVHDPZ.js";
|
|
23
23
|
import {
|
|
24
24
|
PRODUCT_CREATE_FORM_DEFAULTS,
|
|
25
25
|
ProductCreateSchema,
|
|
26
26
|
generateVariantsFromAttributes,
|
|
27
27
|
normalizeProductFormValues
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-E5VLRRZR.js";
|
|
29
29
|
import {
|
|
30
30
|
ChipInput
|
|
31
31
|
} from "./chunk-KDE4HKH2.js";
|
|
32
32
|
import {
|
|
33
33
|
useAttributeTableFilters,
|
|
34
34
|
useAttributeTableQuery
|
|
35
|
-
} from "./chunk-
|
|
36
|
-
import {
|
|
37
|
-
DataTable
|
|
38
|
-
} from "./chunk-IV57G2CB.js";
|
|
35
|
+
} from "./chunk-4OQLPIUZ.js";
|
|
39
36
|
import {
|
|
40
37
|
Combobox
|
|
41
38
|
} from "./chunk-VBRTC2VU.js";
|
|
@@ -52,22 +49,26 @@ import {
|
|
|
52
49
|
import {
|
|
53
50
|
Form
|
|
54
51
|
} from "./chunk-3QSRE5LS.js";
|
|
52
|
+
import {
|
|
53
|
+
_DataTable,
|
|
54
|
+
useDataTable
|
|
55
|
+
} from "./chunk-7TQNE3E2.js";
|
|
55
56
|
import {
|
|
56
57
|
require_dist
|
|
57
|
-
} from "./chunk-
|
|
58
|
+
} from "./chunk-52KJSIHS.js";
|
|
58
59
|
import {
|
|
59
60
|
ActionMenu
|
|
60
61
|
} from "./chunk-BDGZ4EQO.js";
|
|
61
62
|
import {
|
|
62
63
|
useFeatureFlags
|
|
63
|
-
} from "./chunk-
|
|
64
|
+
} from "./chunk-RLRWDHME.js";
|
|
64
65
|
import {
|
|
65
66
|
useCreateProduct,
|
|
66
67
|
useProductAttributes
|
|
67
|
-
} from "./chunk-
|
|
68
|
+
} from "./chunk-YAUGB4LD.js";
|
|
68
69
|
import {
|
|
69
70
|
sdk
|
|
70
|
-
} from "./chunk-
|
|
71
|
+
} from "./chunk-DTGEFKK4.js";
|
|
71
72
|
import {
|
|
72
73
|
__toESM
|
|
73
74
|
} from "./chunk-NBMM2TZK.js";
|
|
@@ -108,14 +109,13 @@ import {
|
|
|
108
109
|
import { useTranslation as useTranslation2 } from "react-i18next";
|
|
109
110
|
|
|
110
111
|
// src/pages/products/create/components/product-create-attributes-form/product-create-add-attributes-modal.tsx
|
|
112
|
+
import { Badge, Button, Checkbox } from "@medusajs/ui";
|
|
113
|
+
import { keepPreviousData } from "@tanstack/react-query";
|
|
111
114
|
import {
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
createDataTableColumnHelper
|
|
115
|
-
} from "@medusajs/ui";
|
|
115
|
+
createColumnHelper
|
|
116
|
+
} from "@tanstack/react-table";
|
|
116
117
|
import { useEffect, useMemo, useState } from "react";
|
|
117
118
|
import { useTranslation } from "react-i18next";
|
|
118
|
-
import { keepPreviousData } from "@tanstack/react-query";
|
|
119
119
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
120
120
|
var ADD_ATTRIBUTES_MODAL_ID = "add-attributes";
|
|
121
121
|
var PAGE_SIZE = 20;
|
|
@@ -132,12 +132,10 @@ var ProductCreateAddAttributesModal = () => {
|
|
|
132
132
|
const { t } = useTranslation();
|
|
133
133
|
const { getValues, setValue } = form;
|
|
134
134
|
const { setIsOpen, getIsOpen } = useStackedModal();
|
|
135
|
-
const [rowSelection, setRowSelection] = useState(
|
|
136
|
-
|
|
137
|
-
);
|
|
138
|
-
const [state, setState] = useState([]);
|
|
135
|
+
const [rowSelection, setRowSelection] = useState({});
|
|
136
|
+
const [selected, setSelected] = useState([]);
|
|
139
137
|
const categoryId = form.watch("category_id");
|
|
140
|
-
const { searchParams } = useAttributeTableQuery({
|
|
138
|
+
const { searchParams, raw } = useAttributeTableQuery({
|
|
141
139
|
pageSize: PAGE_SIZE,
|
|
142
140
|
prefix: ADD_ATTRIBUTES_MODAL_ID
|
|
143
141
|
});
|
|
@@ -156,14 +154,14 @@ var ProductCreateAddAttributesModal = () => {
|
|
|
156
154
|
const attributes = getValues("attributes") ?? [];
|
|
157
155
|
const existing = attributes.filter((a) => a.attribute_id);
|
|
158
156
|
const selection = {};
|
|
159
|
-
const
|
|
157
|
+
const entries = [];
|
|
160
158
|
for (const a of existing) {
|
|
161
159
|
if (a.attribute_id) {
|
|
162
160
|
selection[a.attribute_id] = true;
|
|
163
161
|
const apiAttr = product_attributes?.find(
|
|
164
162
|
(pa) => pa.id === a.attribute_id
|
|
165
163
|
);
|
|
166
|
-
|
|
164
|
+
entries.push({
|
|
167
165
|
id: a.attribute_id,
|
|
168
166
|
name: a.title,
|
|
169
167
|
values: Array.isArray(a.values) ? a.values : a.values ? [a.values] : [],
|
|
@@ -180,7 +178,7 @@ var ProductCreateAddAttributesModal = () => {
|
|
|
180
178
|
for (const attr of product_attributes) {
|
|
181
179
|
if (attr.is_required && !selection[attr.id]) {
|
|
182
180
|
selection[attr.id] = true;
|
|
183
|
-
|
|
181
|
+
entries.push({
|
|
184
182
|
id: attr.id,
|
|
185
183
|
name: attr.name,
|
|
186
184
|
values: [],
|
|
@@ -192,9 +190,10 @@ var ProductCreateAddAttributesModal = () => {
|
|
|
192
190
|
}
|
|
193
191
|
}
|
|
194
192
|
setRowSelection(selection);
|
|
195
|
-
|
|
193
|
+
setSelected(entries);
|
|
196
194
|
}, [open, getValues, product_attributes]);
|
|
197
|
-
const
|
|
195
|
+
const updater = (fn) => {
|
|
196
|
+
const next = typeof fn === "function" ? fn(rowSelection) : fn;
|
|
198
197
|
if (product_attributes) {
|
|
199
198
|
for (const attr of product_attributes) {
|
|
200
199
|
if (attr.is_required) {
|
|
@@ -202,24 +201,20 @@ var ProductCreateAddAttributesModal = () => {
|
|
|
202
201
|
}
|
|
203
202
|
}
|
|
204
203
|
}
|
|
205
|
-
const
|
|
206
|
-
|
|
207
|
-
ids.filter((id) => next[id] && !rowSelection[id])
|
|
204
|
+
const addedIds = new Set(
|
|
205
|
+
Object.keys(next).filter((id) => next[id] && !rowSelection[id])
|
|
208
206
|
);
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
setState((prev) => {
|
|
221
|
-
const filteredPrev = prev.filter((a) => next[a.id]);
|
|
222
|
-
return Array.from(/* @__PURE__ */ new Set([...filteredPrev, ...addedAttributes]));
|
|
207
|
+
const addedAttributes = addedIds.size > 0 ? product_attributes?.filter((attr) => addedIds.has(attr.id)).map((attr) => ({
|
|
208
|
+
id: attr.id,
|
|
209
|
+
name: attr.name,
|
|
210
|
+
values: [],
|
|
211
|
+
is_variant_axis: attr.is_variant_axis,
|
|
212
|
+
type: attr.type,
|
|
213
|
+
available_values: attr.values?.map((v) => ({ id: v.id, name: v.name })) ?? []
|
|
214
|
+
})) ?? [] : [];
|
|
215
|
+
setSelected((prev) => {
|
|
216
|
+
const kept = prev.filter((a) => next[a.id]);
|
|
217
|
+
return Array.from(/* @__PURE__ */ new Set([...kept, ...addedAttributes]));
|
|
223
218
|
});
|
|
224
219
|
setRowSelection(next);
|
|
225
220
|
};
|
|
@@ -229,7 +224,7 @@ var ProductCreateAddAttributesModal = () => {
|
|
|
229
224
|
const requiredIds = new Set(
|
|
230
225
|
product_attributes?.filter((a) => a.is_required).map((a) => a.id) ?? []
|
|
231
226
|
);
|
|
232
|
-
const selectedAttributes =
|
|
227
|
+
const selectedAttributes = selected.map((a) => ({
|
|
233
228
|
attribute_id: a.id,
|
|
234
229
|
title: a.name,
|
|
235
230
|
values: a.values,
|
|
@@ -247,28 +242,45 @@ var ProductCreateAddAttributesModal = () => {
|
|
|
247
242
|
};
|
|
248
243
|
const filters = useAttributeTableFilters();
|
|
249
244
|
const columns = useColumns();
|
|
245
|
+
const { table } = useDataTable({
|
|
246
|
+
data: product_attributes ?? [],
|
|
247
|
+
columns,
|
|
248
|
+
count,
|
|
249
|
+
getRowId: (row) => row.id,
|
|
250
|
+
pageSize: PAGE_SIZE,
|
|
251
|
+
enablePagination: true,
|
|
252
|
+
enableRowSelection: (row) => !row.original.is_required,
|
|
253
|
+
rowSelection: { state: rowSelection, updater },
|
|
254
|
+
prefix: ADD_ATTRIBUTES_MODAL_ID
|
|
255
|
+
});
|
|
250
256
|
if (isError) {
|
|
251
257
|
throw error;
|
|
252
258
|
}
|
|
253
259
|
return /* @__PURE__ */ jsxs(StackedFocusModal.Content, { className: "flex flex-col overflow-hidden", children: [
|
|
254
260
|
/* @__PURE__ */ jsx(StackedFocusModal.Header, {}),
|
|
255
|
-
/* @__PURE__ */ jsx(StackedFocusModal.Body, { className: "flex-
|
|
256
|
-
|
|
261
|
+
/* @__PURE__ */ jsx(StackedFocusModal.Body, { className: "flex size-full flex-col overflow-hidden", children: /* @__PURE__ */ jsx(
|
|
262
|
+
_DataTable,
|
|
257
263
|
{
|
|
258
|
-
|
|
264
|
+
table,
|
|
259
265
|
columns,
|
|
260
|
-
|
|
261
|
-
rowCount: count,
|
|
266
|
+
count,
|
|
262
267
|
pageSize: PAGE_SIZE,
|
|
263
|
-
getRowId: (row) => row.id,
|
|
264
|
-
rowSelection: {
|
|
265
|
-
state: rowSelection,
|
|
266
|
-
onRowSelectionChange,
|
|
267
|
-
enableRowSelection: (row) => !row.original.is_required
|
|
268
|
-
},
|
|
269
268
|
isLoading,
|
|
269
|
+
filters,
|
|
270
|
+
orderBy: [
|
|
271
|
+
{ key: "name", label: t("attributes.fields.name") },
|
|
272
|
+
{ key: "created_at", label: t("fields.createdAt") },
|
|
273
|
+
{ key: "updated_at", label: t("fields.updatedAt") }
|
|
274
|
+
],
|
|
275
|
+
queryObject: raw,
|
|
276
|
+
prefix: ADD_ATTRIBUTES_MODAL_ID,
|
|
270
277
|
layout: "fill",
|
|
271
|
-
|
|
278
|
+
pagination: true,
|
|
279
|
+
search: true,
|
|
280
|
+
noRecords: {
|
|
281
|
+
title: t("products.create.attributes.noAttributesTitle"),
|
|
282
|
+
message: t("products.create.attributes.noAttributesDescription")
|
|
283
|
+
}
|
|
272
284
|
}
|
|
273
285
|
) }),
|
|
274
286
|
/* @__PURE__ */ jsx(StackedFocusModal.Footer, { children: /* @__PURE__ */ jsxs("div", { className: "flex items-center justify-end gap-x-2", children: [
|
|
@@ -277,28 +289,43 @@ var ProductCreateAddAttributesModal = () => {
|
|
|
277
289
|
] }) })
|
|
278
290
|
] });
|
|
279
291
|
};
|
|
280
|
-
var columnHelper =
|
|
292
|
+
var columnHelper = createColumnHelper();
|
|
281
293
|
var useColumns = () => {
|
|
282
294
|
const { t } = useTranslation();
|
|
283
295
|
return useMemo(
|
|
284
296
|
() => [
|
|
285
|
-
columnHelper.
|
|
297
|
+
columnHelper.display({
|
|
298
|
+
id: "select",
|
|
299
|
+
header: ({ table }) => /* @__PURE__ */ jsx(
|
|
300
|
+
Checkbox,
|
|
301
|
+
{
|
|
302
|
+
checked: table.getIsSomePageRowsSelected() ? "indeterminate" : table.getIsAllPageRowsSelected(),
|
|
303
|
+
onCheckedChange: (value) => table.toggleAllPageRowsSelected(!!value)
|
|
304
|
+
}
|
|
305
|
+
),
|
|
306
|
+
cell: ({ row }) => /* @__PURE__ */ jsx(
|
|
307
|
+
Checkbox,
|
|
308
|
+
{
|
|
309
|
+
checked: row.getIsSelected(),
|
|
310
|
+
disabled: !row.getCanSelect(),
|
|
311
|
+
onCheckedChange: (value) => row.toggleSelected(!!value),
|
|
312
|
+
onClick: (e) => e.stopPropagation()
|
|
313
|
+
}
|
|
314
|
+
)
|
|
315
|
+
}),
|
|
286
316
|
columnHelper.accessor("name", {
|
|
287
|
-
header: t("attributes.fields.
|
|
288
|
-
enableSorting: false
|
|
317
|
+
header: t("attributes.fields.productAttribute")
|
|
289
318
|
}),
|
|
290
319
|
columnHelper.accessor("handle", {
|
|
291
320
|
header: t("attributes.fields.handle"),
|
|
292
321
|
cell: (info) => {
|
|
293
322
|
const handle = info.getValue();
|
|
294
323
|
return handle ? `/${handle}` : "-";
|
|
295
|
-
}
|
|
296
|
-
enableSorting: false
|
|
324
|
+
}
|
|
297
325
|
}),
|
|
298
326
|
columnHelper.accessor("is_required", {
|
|
299
327
|
header: t("attributes.fields.required"),
|
|
300
|
-
cell: (info) => info.getValue() ? t("filters.radio.yes") : t("filters.radio.no")
|
|
301
|
-
enableSorting: false
|
|
328
|
+
cell: (info) => info.getValue() ? t("filters.radio.yes") : t("filters.radio.no")
|
|
302
329
|
}),
|
|
303
330
|
columnHelper.accessor("type", {
|
|
304
331
|
header: t("attributes.fields.type"),
|
|
@@ -306,13 +333,11 @@ var useColumns = () => {
|
|
|
306
333
|
const type = info.getValue();
|
|
307
334
|
const labelKey = ATTRIBUTE_TYPE_LABELS[type];
|
|
308
335
|
return labelKey ? t(labelKey) : type;
|
|
309
|
-
}
|
|
310
|
-
enableSorting: false
|
|
336
|
+
}
|
|
311
337
|
}),
|
|
312
338
|
columnHelper.accessor("is_variant_axis", {
|
|
313
339
|
header: t("attributes.fields.variantAxis"),
|
|
314
|
-
cell: (info) => info.getValue() ? t("filters.radio.yes") : t("filters.radio.no")
|
|
315
|
-
enableSorting: false
|
|
340
|
+
cell: (info) => info.getValue() ? t("filters.radio.yes") : t("filters.radio.no")
|
|
316
341
|
}),
|
|
317
342
|
columnHelper.display({
|
|
318
343
|
id: "values",
|
|
@@ -1748,6 +1773,8 @@ var ProductCreateForm = ({
|
|
|
1748
1773
|
return /* @__PURE__ */ jsx9(
|
|
1749
1774
|
TabbedForm,
|
|
1750
1775
|
{
|
|
1776
|
+
model: "product",
|
|
1777
|
+
zone: "create",
|
|
1751
1778
|
form,
|
|
1752
1779
|
onSubmit: handleSubmit,
|
|
1753
1780
|
isLoading: isPending,
|