@mercurjs/admin 2.0.0-canary.39 → 2.0.0-canary.41
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-ZUXBF5G3.js → add-campaign-promotions-7TPECJOT.js} +4 -4
- package/dist/{api-key-management-detail-SKJNAZ5L.js → api-key-management-detail-2EFDWJSF.js} +7 -7
- package/dist/{api-key-management-list-2D4WKI6Y.js → api-key-management-list-UZLHSM2R.js} +6 -5
- package/dist/{api-key-management-sales-channels-C7EWPHC2.js → api-key-management-sales-channels-ER5ZINL7.js} +6 -7
- package/dist/{campaign-create-B7XM2FZM.js → campaign-create-AFR3V7P4.js} +3 -3
- package/dist/{campaign-detail-7U4CQHU5.js → campaign-detail-UUNEZUY7.js} +9 -8
- package/dist/{campaign-list-SC7FLTRM.js → campaign-list-2AAGWYEG.js} +6 -5
- package/dist/category-create-LY45Z7YB.js +23 -0
- package/dist/{category-detail-HGHR3R2R.js → category-detail-AGTIMI6P.js} +7 -6
- package/dist/{category-list-QBBFGHQM.js → category-list-ROM7UTA4.js} +6 -5
- package/dist/{chunk-ENMRRG4N.js → chunk-2AWQ4FPA.js} +6 -6
- package/dist/{chunk-VBAAYYCS.js → chunk-2HPZJCAF.js} +6 -6
- package/dist/{chunk-SFG7JTBH.js → chunk-2LAANNMF.js} +111 -48
- package/dist/{chunk-KYUXTS2L.js → chunk-2UN7CNBG.js} +7 -7
- package/dist/chunk-3LTXCGNM.js +204 -0
- package/dist/{chunk-EDQBUWY7.js → chunk-3NIWL75F.js} +6 -6
- package/dist/{product-create-variant-CJPECBV4.js → chunk-4UTK7DZN.js} +63 -69
- package/dist/{chunk-5VEYNZSW.js → chunk-5322X23U.js} +9 -4
- package/dist/{chunk-U3SFHLUA.js → chunk-53IISBJZ.js} +1 -0
- package/dist/{chunk-DGCPYCHU.js → chunk-54RTJBYO.js} +63 -8
- package/dist/{chunk-E2AAYIHS.js → chunk-5EFOVNK2.js} +3 -3
- package/dist/{chunk-NQPAEBSZ.js → chunk-6E3T6CGY.js} +15 -7
- package/dist/{chunk-V2DXJ75C.js → chunk-6OA7JZ5E.js} +1 -1
- package/dist/chunk-72IQIAGX.js +245 -0
- package/dist/{chunk-3IYIS5UZ.js → chunk-7DOPC5GY.js} +4 -4
- package/dist/{chunk-Q6XCCONH.js → chunk-AI6RJGRQ.js} +9 -9
- package/dist/{price-list-create-OK7YYLAB.js → chunk-AJZQBGE4.js} +193 -428
- package/dist/{chunk-XDVS4B7W.js → chunk-BAV6Y7RC.js} +8 -7
- package/dist/{chunk-4WYBW3HK.js → chunk-BCAT7P6B.js} +3 -3
- package/dist/{chunk-LYT3RI4O.js → chunk-BHYDGWZ6.js} +18 -9
- package/dist/{chunk-DK3U2SRA.js → chunk-BIEYPCHL.js} +5 -5
- package/dist/{product-create-NVBKO426.js → chunk-BLG726FI.js} +36 -68
- package/dist/chunk-BVRI7YAR.js +100 -0
- package/dist/{chunk-2IGCU3KP.js → chunk-DOMRLXOI.js} +2 -2
- package/dist/{chunk-K6FXWZ2M.js → chunk-F55UXYYA.js} +10 -0
- package/dist/{chunk-AOVEX4EM.js → chunk-FNXSMFGL.js} +5 -5
- package/dist/{chunk-IXGP2EEN.js → chunk-FYAYHOCN.js} +2 -3
- package/dist/{chunk-QBOXELB5.js → chunk-GJHAVFXL.js} +4 -4
- package/dist/{price-list-prices-add-7PGUONDK.js → chunk-GOVOSXUU.js} +90 -290
- package/dist/{chunk-66IHH2HG.js → chunk-H6W6Q6YE.js} +3 -3
- package/dist/{seller-details-KROISMQC.js → chunk-HVLQFQGD.js} +74 -146
- package/dist/{chunk-QD6KYDYH.js → chunk-I6R4I7EF.js} +6 -6
- package/dist/{chunk-RIMR3ULR.js → chunk-ISYWL6RZ.js} +64 -33
- package/dist/{chunk-HHNJNKCB.js → chunk-KMUEJ3IE.js} +59 -20
- package/dist/{chunk-GJTIHFXG.js → chunk-KOILMFJX.js} +29 -31
- package/dist/{chunk-3SAH3NUS.js → chunk-LIXRNUG5.js} +1 -1
- package/dist/chunk-LOJD5572.js +433 -0
- package/dist/{chunk-T25UE7SS.js → chunk-MD56QRKC.js} +6 -6
- package/dist/{chunk-S4QUEQQK.js → chunk-MSFNMGFD.js} +48 -48
- package/dist/{chunk-YH4VQBAA.js → chunk-MX52GGQO.js} +81 -52
- package/dist/{chunk-O6O22BN4.js → chunk-N7BCAAJC.js} +113 -48
- package/dist/{chunk-JA2XIIIZ.js → chunk-NXKCVD5F.js} +6 -5
- package/dist/{chunk-G4QMLQF2.js → chunk-NZN7PFPB.js} +2 -4
- package/dist/{chunk-KUDLPUWR.js → chunk-OFWYMU6K.js} +8 -8
- package/dist/chunk-OOAY7PAK.js +1155 -0
- package/dist/chunk-PAQH5QQH.js +685 -0
- package/dist/{chunk-3H74EI2D.js → chunk-POCHIWE2.js} +100 -40
- package/dist/chunk-PXBCTPQO.js +248 -0
- package/dist/chunk-QSZ2FIM2.js +223 -0
- package/dist/{chunk-23663A2W.js → chunk-R5VKVG6S.js} +1 -1
- package/dist/{chunk-DP5U3GQU.js → chunk-RXUUBJSZ.js} +1 -1
- package/dist/{chunk-FYB5MS4F.js → chunk-S2GARTQU.js} +6 -6
- package/dist/{chunk-7TLEUIAL.js → chunk-SO6PXIPV.js} +21 -16
- package/dist/{category-create-UWBJGIED.js → chunk-ST74PSEZ.js} +78 -149
- package/dist/{chunk-33FUPXJL.js → chunk-T3OYE2MH.js} +4 -4
- package/dist/{chunk-JRWB7VWP.js → chunk-U4RMXPGI.js} +8 -8
- package/dist/{chunk-YGSM5PVN.js → chunk-UI2BJVP5.js} +1 -1
- package/dist/{chunk-FXU7SL6M.js → chunk-UOIUQC3P.js} +25 -15
- package/dist/{chunk-ZU2RNSCP.js → chunk-UONTDHRH.js} +4 -2
- package/dist/{chunk-J7SR4GW5.js → chunk-V3SHSLK4.js} +4 -4
- package/dist/{chunk-TE5VQBCL.js → chunk-V42ZR4XW.js} +8 -9
- package/dist/chunk-V5J73NPW.js +117 -0
- package/dist/{chunk-QP6XXG6A.js → chunk-VOFAM7HJ.js} +74 -42
- package/dist/{chunk-CR4E2DCR.js → chunk-VT3RBTYK.js} +3 -3
- package/dist/{chunk-AOVJTW7M.js → chunk-VWQYMOBM.js} +9 -9
- package/dist/{chunk-6L2LSIPR.js → chunk-VXAQZ2ZZ.js} +4 -4
- package/dist/{chunk-OSHCUDYY.js → chunk-X3KBQBGW.js} +6 -6
- package/dist/{chunk-WZADCDDE.js → chunk-X56THFPA.js} +2 -1
- package/dist/{chunk-HZKW7HRU.js → chunk-X7NWBH7T.js} +64 -35
- package/dist/{chunk-OFRQZHVQ.js → chunk-XE5ZMNUN.js} +6 -6
- package/dist/{chunk-4GVHNYZR.js → chunk-XHVYNMTA.js} +2 -2
- package/dist/{chunk-U2UCL2VG.js → chunk-XIZLPYEE.js} +3 -111
- package/dist/{chunk-KXPCEVFB.js → chunk-XOKRMMVP.js} +6 -6
- package/dist/{chunk-XVKRTPVM.js → chunk-Y5N26ZC3.js} +41 -15
- package/dist/{chunk-A6Z2Q7D5.js → chunk-Z2MDPTF2.js} +4 -2
- package/dist/{chunk-TKGZBTOS.js → chunk-ZFSZTRZ6.js} +54 -32
- package/dist/{chunk-RV6NZTNP.js → chunk-ZZEAWVFX.js} +27 -27
- package/dist/{collection-detail-YJ3FV2C6.js → collection-detail-SRR3HSIV.js} +7 -6
- package/dist/{collection-list-WDQOBHQN.js → collection-list-MKISW5S4.js} +6 -5
- package/dist/{commission-rate-detail-UQDIIMIK.js → commission-rate-detail-GLB733F3.js} +5 -4
- package/dist/{commission-rate-list-WTDZLKUR.js → commission-rate-list-5V3FQROA.js} +6 -5
- package/dist/{customer-detail-N7CS4IJU.js → customer-detail-SBQF232S.js} +4 -3
- package/dist/customer-group-add-customers-LCNDTLXR.js +1 -1
- package/dist/{customer-group-detail-UCTY4FF7.js → customer-group-detail-QQSNRM2K.js} +6 -5
- package/dist/{customer-group-list-XOQ64CVR.js → customer-group-list-IO7SVK3F.js} +15 -6
- package/dist/{customer-list-BUUO6OF7.js → customer-list-TXBAME4V.js} +4 -3
- package/dist/customers-add-customer-group-BKEV24N2.js +1 -1
- package/dist/index.d.ts +225 -16
- package/dist/index.js +581 -387
- package/dist/inventory-create-Q4JIXZTT.js +56 -0
- package/dist/{inventory-detail-BJT5WEV5.js → inventory-detail-3D37JWQT.js} +7 -6
- package/dist/{inventory-list-3LWBPWVK.js → inventory-list-WH42ADNB.js} +6 -5
- package/dist/{inventory-stock-G3GP4FZX.js → inventory-stock-DTKOGYT7.js} +6 -6
- package/dist/{location-detail-N7J6PEAP.js → location-detail-2SSHXSKL.js} +5 -4
- package/dist/location-fulfillment-providers-BHCY2MYC.js +1 -1
- package/dist/{location-list-UG6B47NP.js → location-list-LPISOSQI.js} +5 -4
- package/dist/{location-sales-channels-3IGHCJEN.js → location-sales-channels-PPH53OHD.js} +6 -7
- package/dist/location-service-zone-shipping-option-create-GSXLVEGO.js +57 -0
- package/dist/{location-service-zone-shipping-option-pricing-7VMPXDWX.js → location-service-zone-shipping-option-pricing-4CTGXBP3.js} +6 -6
- package/dist/marketplace-add-currencies-CIGOPBO6.js +1 -1
- package/dist/{marketplace-detail-7KJMXXAJ.js → marketplace-detail-3CBLIYVK.js} +6 -5
- package/dist/{order-detail-C25NQSZN.js → order-detail-AJV2PE7J.js} +7 -6
- package/dist/{order-edit-billing-address-NVRMPZEU.js → order-edit-billing-address-QQUPIC2H.js} +6 -6
- package/dist/{order-list-7NH7LROU.js → order-list-VPQOG5WE.js} +6 -5
- package/dist/pages/index.d.ts +2608 -82
- package/dist/pages/index.js +238 -156
- package/dist/{payout-detail-MDD5SRK5.js → payout-detail-PMR26YQI.js} +5 -4
- package/dist/{payout-list-XY2A5KYS.js → payout-list-DMG7MQM7.js} +6 -4
- package/dist/price-list-configuration-XK3IZLLX.js +1 -1
- package/dist/price-list-create-QS6CVEWS.js +76 -0
- package/dist/{price-list-detail-IGFSM77P.js → price-list-detail-IO5ZURVW.js} +7 -6
- package/dist/{price-list-list-TBXQ5DOS.js → price-list-list-B3FKB46L.js} +6 -5
- package/dist/price-list-prices-add-NSAQWBT6.js +71 -0
- package/dist/{price-list-prices-edit-QVGBT6AI.js → price-list-prices-edit-UOAIOS5X.js} +6 -6
- package/dist/product-create-UVKMOKRF.js +68 -0
- package/dist/product-create-variant-TCXDJ425.js +53 -0
- package/dist/{product-detail-ZC37BGPC.js → product-detail-273ME23P.js} +4 -4
- package/dist/{product-list-635ZXM2D.js → product-list-2ZHLFSBI.js} +5 -4
- package/dist/{product-media-ZMDAVPGI.js → product-media-YMFP6Q6A.js} +3 -3
- package/dist/{product-prices-WMRIC7WM.js → product-prices-X6JO3Y5A.js} +5 -5
- package/dist/{product-sales-channels-LSN5DVWZ.js → product-sales-channels-2PVBPK6W.js} +2 -3
- package/dist/{product-stock-HF42WRSC.js → product-stock-ARRFHDSU.js} +6 -6
- package/dist/{product-tag-detail-OJLYO3Q5.js → product-tag-detail-545AVFGA.js} +7 -6
- package/dist/{product-tag-list-XFHGJBRF.js → product-tag-list-2Y2Q7K3A.js} +7 -6
- package/dist/{product-type-detail-J4UA4AEM.js → product-type-detail-PBP572AM.js} +7 -6
- package/dist/{product-type-list-H5EQHCXS.js → product-type-list-XWNUKETZ.js} +6 -5
- package/dist/{product-variant-detail-5WKYURFA.js → product-variant-detail-RJUQWBYH.js} +4 -3
- package/dist/{profile-detail-EYNXOHGZ.js → profile-detail-H22ZBNOB.js} +5 -4
- package/dist/{promotion-add-campaign-B5SF72KC.js → promotion-add-campaign-5LCKEU6H.js} +3 -3
- package/dist/promotion-create-KXBEHXPK.js +54 -0
- package/dist/{promotion-detail-MVFOMS4E.js → promotion-detail-NZZ2HII7.js} +7 -6
- package/dist/{promotion-list-IN4VWEQN.js → promotion-list-KARWNOAQ.js} +9 -8
- package/dist/{refund-reason-list-DJZZC7KK.js → refund-reason-list-GTZQBZ7R.js} +3 -2
- package/dist/{region-detail-OFZHX57G.js → region-detail-3OPMLS4V.js} +5 -4
- package/dist/{region-list-L4FKHVJJ.js → region-list-542EMW5C.js} +6 -5
- package/dist/{reservation-detail-LZYEM5NW.js → reservation-detail-IPGIBQW4.js} +5 -4
- package/dist/{reservation-list-OGPDB7WG.js → reservation-list-CEFKMB2G.js} +6 -5
- package/dist/{reset-password-Q7Y4FWRE.js → reset-password-R5ULRWEM.js} +1 -1
- package/dist/{return-reason-list-6ICMSVKF.js → return-reason-list-S7LU655M.js} +5 -4
- package/dist/{sales-channel-detail-RRJG7U7R.js → sales-channel-detail-QCJ6OC3H.js} +7 -6
- package/dist/{sales-channel-list-LUZ4ZXCY.js → sales-channel-list-KYNBWXUD.js} +7 -7
- package/dist/seller-details-A7TYGP67.js +104 -0
- package/dist/{seller-list-664H4SI5.js → seller-list-5KPNNC2B.js} +7 -6
- package/dist/{shipping-option-type-detail-2RY3NHRO.js → shipping-option-type-detail-OBYOZZWS.js} +5 -4
- package/dist/{shipping-option-type-list-IOSOE33S.js → shipping-option-type-list-UGVMQ3DC.js} +6 -5
- package/dist/{shipping-profile-detail-RIIAX7VE.js → shipping-profile-detail-RYOFRMLH.js} +5 -4
- package/dist/{shipping-profiles-list-AL4EJSJY.js → shipping-profiles-list-XJGQ7AVX.js} +5 -4
- package/dist/{tax-region-create-UOTLTCOP.js → tax-region-create-AR2LNF2G.js} +6 -6
- package/dist/{tax-region-detail-CA2W5W6A.js → tax-region-detail-PIGY5JQ7.js} +7 -6
- package/dist/{tax-region-list-JTZ7KZCX.js → tax-region-list-AMGZWUAI.js} +6 -5
- package/dist/{tax-region-province-detail-ZHLX4FF4.js → tax-region-province-detail-D3R4FJT4.js} +6 -5
- package/dist/types-DUhfb5tH.d.ts +30 -0
- package/dist/{user-detail-YNPBC5MN.js → user-detail-H66ZAR7W.js} +5 -4
- package/dist/{user-list-LNTZNT3D.js → user-list-HIUXLIJV.js} +5 -4
- package/package.json +3 -3
- package/dist/chunk-62ZRA6BZ.js +0 -216
- package/dist/chunk-6PNMR6XP.js +0 -192
- package/dist/chunk-7COSFMM7.js +0 -163
- package/dist/chunk-A2KURGQO.js +0 -151
- package/dist/chunk-BHID7W3U.js +0 -78
- package/dist/chunk-UKLRBS4W.js +0 -61
- package/dist/inventory-create-QLEIHESO.js +0 -620
- package/dist/location-service-zone-shipping-option-create-GYPW6SSN.js +0 -811
- package/dist/promotion-create-D77SANLX.js +0 -1262
- package/dist/{adjust-inventory-HZCWL6SC.js → adjust-inventory-WL7D7TQR.js} +3 -3
- package/dist/{campaign-budget-edit-AIXCDGG3.js → campaign-budget-edit-722ECPRI.js} +3 -3
- package/dist/{category-products-XLCG2JR7.js → category-products-H3VFYGOU.js} +2 -2
- package/dist/{chunk-DEKJJ7NG.js → chunk-OFCUTNGV.js} +3 -3
- package/dist/{chunk-KUWNYCGL.js → chunk-U3OWJE7V.js} +0 -0
- package/dist/{collection-add-products-IQ7M63BA.js → collection-add-products-BQ2FZKR4.js} +1 -1
- package/dist/{commission-rate-create-VC72GTV4.js → commission-rate-create-GFQNADQS.js} +9 -9
- package/dist/{commission-rate-edit-AXJKJNFY.js → commission-rate-edit-A2BFZUEI.js} +9 -9
- package/dist/{location-service-zone-shipping-option-edit-E3GN4ZF5.js → location-service-zone-shipping-option-edit-KPECMUYB.js} +3 -3
- package/dist/{order-create-claim-7WW6MXTT.js → order-create-claim-IWTV2HKL.js} +6 -6
- package/dist/{order-create-edit-KAH6ZPLX.js → order-create-edit-H2MHZFIW.js} +5 -5
- package/dist/{order-create-exchange-ELLWF3IY.js → order-create-exchange-PPMRSGLD.js} +6 -6
- package/dist/{order-create-refund-5QZBOSCA.js → order-create-refund-LZOHRL7T.js} +3 -3
- package/dist/{order-create-return-L6DEDPJK.js → order-create-return-WY6R4QMN.js} +6 -6
- package/dist/{order-edit-shipping-address-BPU7OL2N.js → order-edit-shipping-address-XQCSN4YO.js} +3 -3
- package/dist/{order-receive-return-FW5QZJBM.js → order-receive-return-GKMHYD4G.js} +1 -1
- package/dist/{product-edit-LQJDUUVX.js → product-edit-QGRKGJ3H.js} +1 -1
- package/dist/{product-variant-edit-66ZUIIMP.js → product-variant-edit-IQLBIHDE.js} +1 -1
- package/dist/{product-variant-manage-inventory-items-CV2CC2PV.js → product-variant-manage-inventory-items-C77QHYRT.js} +3 -3
- package/dist/{promotion-edit-details-YKS24GBD.js → promotion-edit-details-BFXPUEE6.js} +4 -4
- package/dist/{region-create-UMJK3VGL.js → region-create-ZPY6V77Q.js} +3 -3
- package/dist/{region-edit-ODVSNJHM.js → region-edit-Q2CBVPR2.js} +3 -3
- package/dist/{sales-channel-add-products-EOWFSO35.js → sales-channel-add-products-PIY4PUIW.js} +2 -2
- package/dist/{tax-region-province-create-RFYCUDER.js → tax-region-province-create-7BMYABJ6.js} +3 -3
- package/dist/{tax-region-tax-override-create-WIWUNXW6.js → tax-region-tax-override-create-EBDKSAXG.js} +6 -6
- package/dist/{tax-region-tax-override-edit-SWROFQTP.js → tax-region-tax-override-edit-55ODL7KC.js} +6 -6
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
SingleColumnPage
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-XIZLPYEE.js";
|
|
4
4
|
import {
|
|
5
5
|
SingleColumnPageSkeleton
|
|
6
6
|
} from "./chunk-INNFZYX2.js";
|
|
@@ -74,12 +74,12 @@ var Root = ({ children }) => {
|
|
|
74
74
|
if (isError) {
|
|
75
75
|
throw error;
|
|
76
76
|
}
|
|
77
|
-
return /* @__PURE__ */ jsx2(SingleColumnPage, { "data-testid": "profile-detail-page", children:
|
|
77
|
+
return Children.count(children) > 0 ? /* @__PURE__ */ jsx2(SingleColumnPage, { "data-testid": "profile-detail-page", children }) : /* @__PURE__ */ jsx2(SingleColumnPage, { "data-testid": "profile-detail-page", children: /* @__PURE__ */ jsx2(ProfileGeneralSection, { user }) });
|
|
78
78
|
};
|
|
79
|
-
var
|
|
79
|
+
var ProfileDetailPage = Object.assign(Root, {
|
|
80
80
|
GeneralSection: ProfileGeneralSection
|
|
81
81
|
});
|
|
82
82
|
|
|
83
83
|
export {
|
|
84
|
-
|
|
84
|
+
ProfileDetailPage
|
|
85
85
|
};
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
import {
|
|
7
7
|
TaxRegionTable,
|
|
8
8
|
useTaxRegionTable
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-UONTDHRH.js";
|
|
10
10
|
import {
|
|
11
11
|
TaxRegionCard
|
|
12
12
|
} from "./chunk-D2XBJTUO.js";
|
|
@@ -18,7 +18,7 @@ import {
|
|
|
18
18
|
} from "./chunk-VW56KWO2.js";
|
|
19
19
|
import {
|
|
20
20
|
SingleColumnPage
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-XIZLPYEE.js";
|
|
22
22
|
import {
|
|
23
23
|
SingleColumnPageSkeleton
|
|
24
24
|
} from "./chunk-INNFZYX2.js";
|
|
@@ -37,9 +37,8 @@ import {
|
|
|
37
37
|
} from "./chunk-JLATVDLM.js";
|
|
38
38
|
|
|
39
39
|
// src/pages/tax-regions/tax-region-detail/tax-region-detail.tsx
|
|
40
|
-
import { Children } from "react";
|
|
40
|
+
import { useState as useState2, Children } from "react";
|
|
41
41
|
import { useLoaderData, useParams } from "react-router-dom";
|
|
42
|
-
import { useState as useState2 } from "react";
|
|
43
42
|
|
|
44
43
|
// src/pages/tax-regions/tax-region-detail/components/tax-region-detail-section/tax-region-detail-section.tsx
|
|
45
44
|
import { Badge, Container, Tooltip } from "@medusajs/ui";
|
|
@@ -248,7 +247,7 @@ function TaxRegionProviderSection({
|
|
|
248
247
|
}
|
|
249
248
|
|
|
250
249
|
// src/pages/tax-regions/tax-region-detail/tax-region-detail.tsx
|
|
251
|
-
import {
|
|
250
|
+
import { jsx as jsx6, jsxs as jsxs4 } from "react/jsx-runtime";
|
|
252
251
|
var Root = ({ children }) => {
|
|
253
252
|
const { id } = useParams();
|
|
254
253
|
const [showSublevelRegions, setShowSublevelRegions] = useState2(false);
|
|
@@ -265,7 +264,7 @@ var Root = ({ children }) => {
|
|
|
265
264
|
if (isError) {
|
|
266
265
|
throw error;
|
|
267
266
|
}
|
|
268
|
-
return /* @__PURE__ */ jsx6(
|
|
267
|
+
return Children.count(children) > 0 ? /* @__PURE__ */ jsx6(SingleColumnPage, { data: taxRegion, showJSON: true, showMetadata: true, children }) : /* @__PURE__ */ jsxs4(SingleColumnPage, { data: taxRegion, showJSON: true, showMetadata: true, children: [
|
|
269
268
|
/* @__PURE__ */ jsx6(
|
|
270
269
|
TaxRegionSublevelAlert,
|
|
271
270
|
{
|
|
@@ -284,9 +283,9 @@ var Root = ({ children }) => {
|
|
|
284
283
|
),
|
|
285
284
|
/* @__PURE__ */ jsx6(TaxRegionOverrideSection, { taxRegion }),
|
|
286
285
|
/* @__PURE__ */ jsx6(TaxRegionProviderSection, { taxRegion })
|
|
287
|
-
] })
|
|
286
|
+
] });
|
|
288
287
|
};
|
|
289
|
-
var
|
|
288
|
+
var TaxRegionDetailPage = Object.assign(Root, {
|
|
290
289
|
SublevelAlert: TaxRegionSublevelAlert,
|
|
291
290
|
DetailSection: TaxRegionDetailSection,
|
|
292
291
|
ProvinceSection: TaxRegionProvinceSection,
|
|
@@ -295,5 +294,5 @@ var TaxRegionDetail = Object.assign(Root, {
|
|
|
295
294
|
});
|
|
296
295
|
|
|
297
296
|
export {
|
|
298
|
-
|
|
297
|
+
TaxRegionDetailPage
|
|
299
298
|
};
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
import {
|
|
2
|
+
JsonViewSection,
|
|
3
|
+
MetadataSection
|
|
4
|
+
} from "./chunk-XIZLPYEE.js";
|
|
5
|
+
|
|
6
|
+
// src/components/layout/pages/two-column-page/two-column-page.tsx
|
|
7
|
+
import { clx } from "@medusajs/ui";
|
|
8
|
+
import { Children } from "react";
|
|
9
|
+
import { Outlet } from "react-router-dom";
|
|
10
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
11
|
+
var Root = ({
|
|
12
|
+
children,
|
|
13
|
+
/**
|
|
14
|
+
* Widgets to be rendered in the main content area and sidebar.
|
|
15
|
+
*/
|
|
16
|
+
/**
|
|
17
|
+
* Data to be passed to widgets, JSON view, and Metadata view.
|
|
18
|
+
*/
|
|
19
|
+
data,
|
|
20
|
+
/**
|
|
21
|
+
* Whether to show JSON view of the data. Defaults to false.
|
|
22
|
+
*/
|
|
23
|
+
showJSON = false,
|
|
24
|
+
/**
|
|
25
|
+
* Whether to show metadata view of the data. Defaults to false.
|
|
26
|
+
*/
|
|
27
|
+
showMetadata = false,
|
|
28
|
+
/**
|
|
29
|
+
* Whether to render an outlet for children routes. Defaults to true.
|
|
30
|
+
*/
|
|
31
|
+
hasOutlet = true
|
|
32
|
+
}) => {
|
|
33
|
+
if (showJSON && !data) {
|
|
34
|
+
if (process.env.NODE_ENV === "development") {
|
|
35
|
+
console.warn(
|
|
36
|
+
"`showJSON` is true but no data is provided. To display JSON, provide data prop."
|
|
37
|
+
);
|
|
38
|
+
}
|
|
39
|
+
showJSON = false;
|
|
40
|
+
}
|
|
41
|
+
if (showMetadata && !data) {
|
|
42
|
+
if (process.env.NODE_ENV === "development") {
|
|
43
|
+
console.warn(
|
|
44
|
+
"`showMetadata` is true but no data is provided. To display metadata, provide data prop."
|
|
45
|
+
);
|
|
46
|
+
}
|
|
47
|
+
showMetadata = false;
|
|
48
|
+
}
|
|
49
|
+
const childrenArray = Children.toArray(children);
|
|
50
|
+
if (childrenArray.length !== 2) {
|
|
51
|
+
throw new Error("TwoColumnPage expects exactly two children");
|
|
52
|
+
}
|
|
53
|
+
const [main, sidebar] = childrenArray;
|
|
54
|
+
const showExtraData = showJSON || showMetadata;
|
|
55
|
+
return /* @__PURE__ */ jsxs("div", { className: "flex w-full flex-col gap-y-3", children: [
|
|
56
|
+
/* @__PURE__ */ jsxs("div", { className: "flex w-full flex-col items-start gap-x-4 gap-y-3 xl:grid xl:grid-cols-[minmax(0,_1fr)_440px]", children: [
|
|
57
|
+
/* @__PURE__ */ jsxs("div", { className: "flex w-full min-w-0 flex-col gap-y-3", children: [
|
|
58
|
+
main,
|
|
59
|
+
showExtraData && /* @__PURE__ */ jsxs(
|
|
60
|
+
"div",
|
|
61
|
+
{
|
|
62
|
+
className: "hidden flex-col gap-y-3 xl:flex",
|
|
63
|
+
"data-testid": "product-extra-data-desktop",
|
|
64
|
+
children: [
|
|
65
|
+
showMetadata && /* @__PURE__ */ jsx(MetadataSection, { data }),
|
|
66
|
+
showJSON && /* @__PURE__ */ jsx(JsonViewSection, { data })
|
|
67
|
+
]
|
|
68
|
+
}
|
|
69
|
+
)
|
|
70
|
+
] }),
|
|
71
|
+
/* @__PURE__ */ jsxs("div", { className: "flex w-full flex-col gap-y-3 xl:mt-0", children: [
|
|
72
|
+
sidebar,
|
|
73
|
+
showExtraData && /* @__PURE__ */ jsxs(
|
|
74
|
+
"div",
|
|
75
|
+
{
|
|
76
|
+
className: "flex flex-col gap-y-3 xl:hidden",
|
|
77
|
+
"data-testid": "product-extra-data-mobile",
|
|
78
|
+
children: [
|
|
79
|
+
showMetadata && /* @__PURE__ */ jsx(MetadataSection, { data }),
|
|
80
|
+
showJSON && /* @__PURE__ */ jsx(JsonViewSection, { data })
|
|
81
|
+
]
|
|
82
|
+
}
|
|
83
|
+
)
|
|
84
|
+
] })
|
|
85
|
+
] }),
|
|
86
|
+
hasOutlet && /* @__PURE__ */ jsx(Outlet, {})
|
|
87
|
+
] });
|
|
88
|
+
};
|
|
89
|
+
var Main = ({
|
|
90
|
+
children,
|
|
91
|
+
className,
|
|
92
|
+
...props
|
|
93
|
+
}) => {
|
|
94
|
+
return /* @__PURE__ */ jsx("div", { className: clx("flex w-full flex-col gap-y-3", className), ...props, children });
|
|
95
|
+
};
|
|
96
|
+
var Sidebar = ({
|
|
97
|
+
children,
|
|
98
|
+
className,
|
|
99
|
+
...props
|
|
100
|
+
}) => {
|
|
101
|
+
return /* @__PURE__ */ jsx(
|
|
102
|
+
"div",
|
|
103
|
+
{
|
|
104
|
+
className: clx(
|
|
105
|
+
"flex w-full max-w-[100%] flex-col gap-y-3 xl:mt-0 xl:max-w-[440px]",
|
|
106
|
+
className
|
|
107
|
+
),
|
|
108
|
+
...props,
|
|
109
|
+
children
|
|
110
|
+
}
|
|
111
|
+
);
|
|
112
|
+
};
|
|
113
|
+
var TwoColumnPage = Object.assign(Root, { Main, Sidebar });
|
|
114
|
+
|
|
115
|
+
export {
|
|
116
|
+
TwoColumnPage
|
|
117
|
+
};
|
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
} from "./chunk-ULJ3OMWU.js";
|
|
9
9
|
import {
|
|
10
10
|
SingleColumnPage
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-XIZLPYEE.js";
|
|
12
12
|
import {
|
|
13
13
|
ActionMenu
|
|
14
14
|
} from "./chunk-BDGZ4EQO.js";
|
|
@@ -18,17 +18,17 @@ import {
|
|
|
18
18
|
} from "./chunk-A4X5VP3G.js";
|
|
19
19
|
|
|
20
20
|
// src/pages/commission-rates/commission-rate-list/commission-rate-list.tsx
|
|
21
|
-
import { Children } from "react";
|
|
21
|
+
import { Children as Children3 } from "react";
|
|
22
|
+
|
|
23
|
+
// src/pages/commission-rates/commission-rate-list/components/commission-rate-list-view/commission-rate-list-view.tsx
|
|
24
|
+
import { Children as Children2 } from "react";
|
|
25
|
+
import { Container } from "@medusajs/ui";
|
|
22
26
|
|
|
23
|
-
// src/pages/commission-rates/commission-rate-list/components/commission-rate-list-
|
|
27
|
+
// src/pages/commission-rates/commission-rate-list/components/commission-rate-list-view/commission-rate-list-data-table.tsx
|
|
24
28
|
import { PencilSquare, Trash } from "@medusajs/icons";
|
|
25
29
|
import {
|
|
26
30
|
Badge,
|
|
27
|
-
Button,
|
|
28
|
-
Container,
|
|
29
|
-
Heading,
|
|
30
31
|
StatusBadge,
|
|
31
|
-
Text,
|
|
32
32
|
toast,
|
|
33
33
|
usePrompt
|
|
34
34
|
} from "@medusajs/ui";
|
|
@@ -36,10 +36,9 @@ import { keepPreviousData } from "@tanstack/react-query";
|
|
|
36
36
|
import { createColumnHelper } from "@tanstack/react-table";
|
|
37
37
|
import { useMemo } from "react";
|
|
38
38
|
import { useTranslation } from "react-i18next";
|
|
39
|
-
import {
|
|
40
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
39
|
+
import { jsx } from "react/jsx-runtime";
|
|
41
40
|
var PAGE_SIZE = 20;
|
|
42
|
-
var
|
|
41
|
+
var CommissionRateListDataTable = () => {
|
|
43
42
|
const { t } = useTranslation();
|
|
44
43
|
const { commission_rates, count, isPending: isLoading, isError, error } = useCommissionRates(
|
|
45
44
|
{
|
|
@@ -63,33 +62,24 @@ var CommissionRateListTable = () => {
|
|
|
63
62
|
if (isError) {
|
|
64
63
|
throw error;
|
|
65
64
|
}
|
|
66
|
-
return /* @__PURE__ */
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
search: true,
|
|
85
|
-
orderBy: [
|
|
86
|
-
{ key: "name", label: "Name" },
|
|
87
|
-
{ key: "created_at", label: t("fields.createdAt") },
|
|
88
|
-
{ key: "updated_at", label: t("fields.updatedAt") }
|
|
89
|
-
]
|
|
90
|
-
}
|
|
91
|
-
)
|
|
92
|
-
] });
|
|
65
|
+
return /* @__PURE__ */ jsx(
|
|
66
|
+
_DataTable,
|
|
67
|
+
{
|
|
68
|
+
table,
|
|
69
|
+
columns,
|
|
70
|
+
count: count ?? 0,
|
|
71
|
+
pageSize: PAGE_SIZE,
|
|
72
|
+
isLoading,
|
|
73
|
+
navigateTo: (row) => `${row.original.id}`,
|
|
74
|
+
pagination: true,
|
|
75
|
+
search: true,
|
|
76
|
+
orderBy: [
|
|
77
|
+
{ key: "name", label: "Name" },
|
|
78
|
+
{ key: "created_at", label: t("fields.createdAt") },
|
|
79
|
+
{ key: "updated_at", label: t("fields.updatedAt") }
|
|
80
|
+
]
|
|
81
|
+
}
|
|
82
|
+
);
|
|
93
83
|
};
|
|
94
84
|
var CommissionRateActions = ({
|
|
95
85
|
commissionRate
|
|
@@ -173,15 +163,57 @@ var useColumns = () => {
|
|
|
173
163
|
);
|
|
174
164
|
};
|
|
175
165
|
|
|
166
|
+
// src/pages/commission-rates/commission-rate-list/components/commission-rate-list-view/commission-rate-list-header.tsx
|
|
167
|
+
import { Children } from "react";
|
|
168
|
+
import { Button, Heading, Text } from "@medusajs/ui";
|
|
169
|
+
import { useTranslation as useTranslation2 } from "react-i18next";
|
|
170
|
+
import { Link } from "react-router-dom";
|
|
171
|
+
import { Fragment, jsx as jsx2, jsxs } from "react/jsx-runtime";
|
|
172
|
+
var CommissionRateListTitle = () => {
|
|
173
|
+
return /* @__PURE__ */ jsxs("div", { children: [
|
|
174
|
+
/* @__PURE__ */ jsx2(Heading, { children: "Commission Rates" }),
|
|
175
|
+
/* @__PURE__ */ jsx2(Text, { className: "text-ui-fg-subtle", size: "small", children: "Manage commission rates and rules for your marketplace." })
|
|
176
|
+
] });
|
|
177
|
+
};
|
|
178
|
+
var CommissionRateListActions = ({
|
|
179
|
+
children
|
|
180
|
+
}) => {
|
|
181
|
+
const { t } = useTranslation2();
|
|
182
|
+
return /* @__PURE__ */ jsx2("div", { className: "flex items-center justify-center gap-x-2", children: Children.count(children) > 0 ? children : /* @__PURE__ */ jsx2(Link, { to: "/settings/commission-rates/create", children: /* @__PURE__ */ jsx2(Button, { size: "small", variant: "secondary", children: t("actions.create") }) }) });
|
|
183
|
+
};
|
|
184
|
+
var CommissionRateListHeader = ({
|
|
185
|
+
children
|
|
186
|
+
}) => {
|
|
187
|
+
return /* @__PURE__ */ jsx2("div", { className: "flex items-center justify-between px-6 py-4", children: Children.count(children) > 0 ? children : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
188
|
+
/* @__PURE__ */ jsx2(CommissionRateListTitle, {}),
|
|
189
|
+
/* @__PURE__ */ jsx2(CommissionRateListActions, {})
|
|
190
|
+
] }) });
|
|
191
|
+
};
|
|
192
|
+
|
|
193
|
+
// src/pages/commission-rates/commission-rate-list/components/commission-rate-list-view/commission-rate-list-view.tsx
|
|
194
|
+
import { Fragment as Fragment2, jsx as jsx3, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
195
|
+
var CommissionRateListView = ({
|
|
196
|
+
children
|
|
197
|
+
}) => {
|
|
198
|
+
return /* @__PURE__ */ jsx3(Container, { className: "divide-y p-0", children: Children2.count(children) > 0 ? children : /* @__PURE__ */ jsxs2(Fragment2, { children: [
|
|
199
|
+
/* @__PURE__ */ jsx3(CommissionRateListHeader, {}),
|
|
200
|
+
/* @__PURE__ */ jsx3(CommissionRateListDataTable, {})
|
|
201
|
+
] }) });
|
|
202
|
+
};
|
|
203
|
+
|
|
176
204
|
// src/pages/commission-rates/commission-rate-list/commission-rate-list.tsx
|
|
177
|
-
import { jsx as
|
|
205
|
+
import { jsx as jsx4 } from "react/jsx-runtime";
|
|
178
206
|
var Root = ({ children }) => {
|
|
179
|
-
return /* @__PURE__ */
|
|
207
|
+
return /* @__PURE__ */ jsx4(SingleColumnPage, { children: Children3.count(children) > 0 ? children : /* @__PURE__ */ jsx4(CommissionRateListView, {}) });
|
|
180
208
|
};
|
|
181
|
-
var
|
|
182
|
-
Table:
|
|
209
|
+
var CommissionRateListPage = Object.assign(Root, {
|
|
210
|
+
Table: CommissionRateListView,
|
|
211
|
+
Header: CommissionRateListHeader,
|
|
212
|
+
HeaderTitle: CommissionRateListTitle,
|
|
213
|
+
HeaderActions: CommissionRateListActions,
|
|
214
|
+
DataTable: CommissionRateListDataTable
|
|
183
215
|
});
|
|
184
216
|
|
|
185
217
|
export {
|
|
186
|
-
|
|
218
|
+
CommissionRateListPage
|
|
187
219
|
};
|
|
@@ -17,7 +17,7 @@ import {
|
|
|
17
17
|
} from "./chunk-ULJ3OMWU.js";
|
|
18
18
|
import {
|
|
19
19
|
SingleColumnPage
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-XIZLPYEE.js";
|
|
21
21
|
import {
|
|
22
22
|
ActionMenu
|
|
23
23
|
} from "./chunk-BDGZ4EQO.js";
|
|
@@ -236,7 +236,7 @@ import { jsx as jsx6 } from "react/jsx-runtime";
|
|
|
236
236
|
var Root = ({ children }) => {
|
|
237
237
|
return /* @__PURE__ */ jsx6(SingleColumnPage, { children: Children3.count(children) > 0 ? children : /* @__PURE__ */ jsx6(PriceListListTable, {}) });
|
|
238
238
|
};
|
|
239
|
-
var
|
|
239
|
+
var PriceListListPage = Object.assign(Root, {
|
|
240
240
|
Table: PriceListListTable,
|
|
241
241
|
Header: PriceListListHeader,
|
|
242
242
|
HeaderTitle: PriceListListTitle,
|
|
@@ -245,5 +245,5 @@ var PriceListList = Object.assign(Root, {
|
|
|
245
245
|
});
|
|
246
246
|
|
|
247
247
|
export {
|
|
248
|
-
|
|
248
|
+
PriceListListPage
|
|
249
249
|
};
|
|
@@ -14,16 +14,16 @@ import {
|
|
|
14
14
|
import {
|
|
15
15
|
PlaceholderCell
|
|
16
16
|
} from "./chunk-PHOCVOZ5.js";
|
|
17
|
-
import {
|
|
18
|
-
_DataTable,
|
|
19
|
-
useDataTable
|
|
20
|
-
} from "./chunk-ULJ3OMWU.js";
|
|
21
17
|
import {
|
|
22
18
|
TwoColumnPage
|
|
23
|
-
} from "./chunk-
|
|
19
|
+
} from "./chunk-V5J73NPW.js";
|
|
24
20
|
import {
|
|
25
21
|
Thumbnail
|
|
26
22
|
} from "./chunk-WIYFXWRI.js";
|
|
23
|
+
import {
|
|
24
|
+
_DataTable,
|
|
25
|
+
useDataTable
|
|
26
|
+
} from "./chunk-ULJ3OMWU.js";
|
|
27
27
|
import {
|
|
28
28
|
TwoColumnPageSkeleton
|
|
29
29
|
} from "./chunk-INNFZYX2.js";
|
|
@@ -672,7 +672,7 @@ var Root = ({ children }) => {
|
|
|
672
672
|
if (isError) {
|
|
673
673
|
throw error;
|
|
674
674
|
}
|
|
675
|
-
return /* @__PURE__ */ jsx11(
|
|
675
|
+
return Children.count(children) > 0 ? /* @__PURE__ */ jsx11(TwoColumnPage, { data: inventory_item, showJSON: true, showMetadata: true, "data-testid": "inventory-detail-page", children }) : /* @__PURE__ */ jsxs5(TwoColumnPage, { data: inventory_item, showJSON: true, showMetadata: true, "data-testid": "inventory-detail-page", children: [
|
|
676
676
|
/* @__PURE__ */ jsxs5(TwoColumnPage.Main, { "data-testid": "inventory-detail-main", children: [
|
|
677
677
|
/* @__PURE__ */ jsx11(InventoryItemGeneralSection, { inventoryItem: inventory_item }),
|
|
678
678
|
/* @__PURE__ */ jsx11(
|
|
@@ -692,9 +692,9 @@ var Root = ({ children }) => {
|
|
|
692
692
|
),
|
|
693
693
|
/* @__PURE__ */ jsx11(InventoryItemAttributeSection, { inventoryItem: inventory_item })
|
|
694
694
|
] })
|
|
695
|
-
] })
|
|
695
|
+
] });
|
|
696
696
|
};
|
|
697
|
-
var
|
|
697
|
+
var InventoryDetailPage = Object.assign(Root, {
|
|
698
698
|
Main: TwoColumnPage.Main,
|
|
699
699
|
Sidebar: TwoColumnPage.Sidebar,
|
|
700
700
|
MainGeneralSection: InventoryItemGeneralSection,
|
|
@@ -706,5 +706,5 @@ var InventoryDetail = Object.assign(Root, {
|
|
|
706
706
|
|
|
707
707
|
export {
|
|
708
708
|
INVENTORY_DETAIL_FIELDS,
|
|
709
|
-
|
|
709
|
+
InventoryDetailPage
|
|
710
710
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
require_dist
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-F55UXYYA.js";
|
|
4
4
|
import {
|
|
5
5
|
DateCell
|
|
6
6
|
} from "./chunk-25LYVP3C.js";
|
|
@@ -13,7 +13,7 @@ import {
|
|
|
13
13
|
} from "./chunk-ULJ3OMWU.js";
|
|
14
14
|
import {
|
|
15
15
|
SingleColumnPage
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-XIZLPYEE.js";
|
|
17
17
|
import {
|
|
18
18
|
ActionMenu
|
|
19
19
|
} from "./chunk-BDGZ4EQO.js";
|
|
@@ -210,7 +210,7 @@ import { jsx as jsx6 } from "react/jsx-runtime";
|
|
|
210
210
|
var Root = ({ children }) => {
|
|
211
211
|
return /* @__PURE__ */ jsx6(SingleColumnPage, { children: Children3.count(children) > 0 ? children : /* @__PURE__ */ jsx6(SellerListTable, {}) });
|
|
212
212
|
};
|
|
213
|
-
var
|
|
213
|
+
var SellerListPage = Object.assign(Root, {
|
|
214
214
|
Table: SellerListTable,
|
|
215
215
|
Header: SellerListHeader,
|
|
216
216
|
HeaderTitle: SellerListTitle,
|
|
@@ -219,5 +219,5 @@ var SellersList = Object.assign(Root, {
|
|
|
219
219
|
});
|
|
220
220
|
|
|
221
221
|
export {
|
|
222
|
-
|
|
222
|
+
SellerListPage
|
|
223
223
|
};
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
} from "./chunk-3XPXUIK3.js";
|
|
7
7
|
import {
|
|
8
8
|
TwoColumnPage
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-V5J73NPW.js";
|
|
10
10
|
import {
|
|
11
11
|
TwoColumnPageSkeleton
|
|
12
12
|
} from "./chunk-INNFZYX2.js";
|
|
@@ -112,7 +112,7 @@ var ReservationGeneralSection = ({
|
|
|
112
112
|
};
|
|
113
113
|
|
|
114
114
|
// src/pages/reservations/reservation-detail/reservation-detail.tsx
|
|
115
|
-
import {
|
|
115
|
+
import { jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
|
|
116
116
|
var Root = ({ children }) => {
|
|
117
117
|
const { id } = useParams();
|
|
118
118
|
const initialData = useLoaderData();
|
|
@@ -142,12 +142,12 @@ var Root = ({ children }) => {
|
|
|
142
142
|
if (isError) {
|
|
143
143
|
throw error;
|
|
144
144
|
}
|
|
145
|
-
return /* @__PURE__ */ jsx2(
|
|
145
|
+
return Children.count(children) > 0 ? /* @__PURE__ */ jsx2(TwoColumnPage, { data: reservation, showJSON: true, showMetadata: true, "data-testid": "reservation-detail-page", children }) : /* @__PURE__ */ jsxs2(TwoColumnPage, { data: reservation, showJSON: true, showMetadata: true, "data-testid": "reservation-detail-page", children: [
|
|
146
146
|
/* @__PURE__ */ jsx2(TwoColumnPage.Main, { children: /* @__PURE__ */ jsx2(ReservationGeneralSection, { reservation }) }),
|
|
147
147
|
/* @__PURE__ */ jsx2(TwoColumnPage.Sidebar, { children: inventory_item && /* @__PURE__ */ jsx2(InventoryItemGeneralSection, { inventoryItem: inventory_item }) })
|
|
148
|
-
] })
|
|
148
|
+
] });
|
|
149
149
|
};
|
|
150
|
-
var
|
|
150
|
+
var ReservationDetailPage = Object.assign(Root, {
|
|
151
151
|
Main: TwoColumnPage.Main,
|
|
152
152
|
Sidebar: TwoColumnPage.Sidebar,
|
|
153
153
|
MainGeneralSection: ReservationGeneralSection,
|
|
@@ -155,5 +155,5 @@ var ReservationDetail = Object.assign(Root, {
|
|
|
155
155
|
});
|
|
156
156
|
|
|
157
157
|
export {
|
|
158
|
-
|
|
158
|
+
ReservationDetailPage
|
|
159
159
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
CreateCampaignFormFields
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-OFCUTNGV.js";
|
|
4
4
|
import {
|
|
5
5
|
useComboboxData
|
|
6
6
|
} from "./chunk-AEFDAU3Y.js";
|
|
@@ -216,6 +216,7 @@ var AddCampaignPromotionFields = ({
|
|
|
216
216
|
"data-testid": "promotion-add-campaign-form-campaign-id-combobox"
|
|
217
217
|
}
|
|
218
218
|
) }),
|
|
219
|
+
!promotionCurrencyCode && /* @__PURE__ */ jsx2(Form.Hint, { "data-testid": "promotion-add-campaign-form-campaign-id-hint", children: t("promotions.form.campaign.existing.currencyHint") }),
|
|
219
220
|
/* @__PURE__ */ jsx2(Form.ErrorMessage, { "data-testid": "promotion-add-campaign-form-campaign-id-error" })
|
|
220
221
|
] });
|
|
221
222
|
}
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
} from "./chunk-ULJ3OMWU.js";
|
|
8
8
|
import {
|
|
9
9
|
SingleColumnPage
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-XIZLPYEE.js";
|
|
11
11
|
import {
|
|
12
12
|
ActionMenu
|
|
13
13
|
} from "./chunk-BDGZ4EQO.js";
|
|
@@ -20,19 +20,43 @@ import {
|
|
|
20
20
|
} from "./chunk-5PB7KCTF.js";
|
|
21
21
|
|
|
22
22
|
// src/pages/campaigns/campaign-list/campaign-list.tsx
|
|
23
|
-
import { Children } from "react";
|
|
23
|
+
import { Children as Children2 } from "react";
|
|
24
24
|
|
|
25
25
|
// src/pages/campaigns/campaign-list/components/campaign-list-table.tsx
|
|
26
26
|
import { PencilSquare, Trash } from "@medusajs/icons";
|
|
27
27
|
import { Button, Container, Heading, toast, usePrompt } from "@medusajs/ui";
|
|
28
28
|
import { keepPreviousData } from "@tanstack/react-query";
|
|
29
29
|
import { createColumnHelper } from "@tanstack/react-table";
|
|
30
|
-
import { useMemo } from "react";
|
|
30
|
+
import { Children, useMemo } from "react";
|
|
31
31
|
import { useTranslation } from "react-i18next";
|
|
32
32
|
import { Link } from "react-router-dom";
|
|
33
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
33
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
34
34
|
var PAGE_SIZE = 20;
|
|
35
|
-
var
|
|
35
|
+
var CampaignListTitle = () => {
|
|
36
|
+
const { t } = useTranslation();
|
|
37
|
+
return /* @__PURE__ */ jsx(Heading, { level: "h2", "data-testid": "campaign-list-table-heading", children: t("campaigns.domain") });
|
|
38
|
+
};
|
|
39
|
+
var CampaignListCreateButton = () => {
|
|
40
|
+
const { t } = useTranslation();
|
|
41
|
+
return /* @__PURE__ */ jsx(Link, { to: "/campaigns/create", children: /* @__PURE__ */ jsx(Button, { size: "small", variant: "secondary", "data-testid": "campaign-list-table-create-button", children: t("actions.create") }) });
|
|
42
|
+
};
|
|
43
|
+
var CampaignListActions = ({ children }) => {
|
|
44
|
+
return /* @__PURE__ */ jsx("div", { className: "flex items-center gap-x-2", children: Children.count(children) > 0 ? children : /* @__PURE__ */ jsx(CampaignListCreateButton, {}) });
|
|
45
|
+
};
|
|
46
|
+
var CampaignListHeader = ({ children }) => {
|
|
47
|
+
return /* @__PURE__ */ jsx(
|
|
48
|
+
"div",
|
|
49
|
+
{
|
|
50
|
+
className: "flex items-center justify-between px-6 py-4",
|
|
51
|
+
"data-testid": "campaign-list-table-header",
|
|
52
|
+
children: Children.count(children) > 0 ? children : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
53
|
+
/* @__PURE__ */ jsx(CampaignListTitle, {}),
|
|
54
|
+
/* @__PURE__ */ jsx(CampaignListActions, {})
|
|
55
|
+
] })
|
|
56
|
+
}
|
|
57
|
+
);
|
|
58
|
+
};
|
|
59
|
+
var CampaignListDataTable = () => {
|
|
36
60
|
const { t } = useTranslation();
|
|
37
61
|
const { raw, searchParams } = useCampaignTableQuery({ pageSize: PAGE_SIZE });
|
|
38
62
|
const {
|
|
@@ -56,32 +80,32 @@ var CampaignListTable = () => {
|
|
|
56
80
|
if (isError) {
|
|
57
81
|
throw error;
|
|
58
82
|
}
|
|
59
|
-
return /* @__PURE__ */
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
)
|
|
84
|
-
] });
|
|
83
|
+
return /* @__PURE__ */ jsx(
|
|
84
|
+
_DataTable,
|
|
85
|
+
{
|
|
86
|
+
table,
|
|
87
|
+
columns,
|
|
88
|
+
count,
|
|
89
|
+
pageSize: PAGE_SIZE,
|
|
90
|
+
pagination: true,
|
|
91
|
+
search: true,
|
|
92
|
+
navigateTo: (row) => row.id,
|
|
93
|
+
isLoading,
|
|
94
|
+
queryObject: raw,
|
|
95
|
+
orderBy: [
|
|
96
|
+
{ key: "name", label: t("fields.name") },
|
|
97
|
+
{ key: "created_at", label: t("fields.createdAt") },
|
|
98
|
+
{ key: "updated_at", label: t("fields.updatedAt") }
|
|
99
|
+
],
|
|
100
|
+
"data-testid": "campaign-list-table"
|
|
101
|
+
}
|
|
102
|
+
);
|
|
103
|
+
};
|
|
104
|
+
var CampaignListTable = ({ children }) => {
|
|
105
|
+
return /* @__PURE__ */ jsx(Container, { className: "divide-y p-0", "data-testid": "campaign-list-table-container", children: Children.count(children) > 0 ? children : /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
106
|
+
/* @__PURE__ */ jsx(CampaignListHeader, {}),
|
|
107
|
+
/* @__PURE__ */ jsx(CampaignListDataTable, {})
|
|
108
|
+
] }) });
|
|
85
109
|
};
|
|
86
110
|
var CampaignActions = ({ campaign }) => {
|
|
87
111
|
const { t } = useTranslation();
|
|
@@ -159,12 +183,17 @@ var useColumns = () => {
|
|
|
159
183
|
// src/pages/campaigns/campaign-list/campaign-list.tsx
|
|
160
184
|
import { jsx as jsx2 } from "react/jsx-runtime";
|
|
161
185
|
var Root = ({ children }) => {
|
|
162
|
-
return /* @__PURE__ */ jsx2(SingleColumnPage, { hasOutlet: true, children:
|
|
186
|
+
return /* @__PURE__ */ jsx2(SingleColumnPage, { hasOutlet: true, children: Children2.count(children) > 0 ? children : /* @__PURE__ */ jsx2(CampaignListTable, {}) });
|
|
163
187
|
};
|
|
164
|
-
var
|
|
165
|
-
Table: CampaignListTable
|
|
188
|
+
var CampaignListPage = Object.assign(Root, {
|
|
189
|
+
Table: CampaignListTable,
|
|
190
|
+
Header: CampaignListHeader,
|
|
191
|
+
HeaderTitle: CampaignListTitle,
|
|
192
|
+
HeaderActions: CampaignListActions,
|
|
193
|
+
HeaderCreateButton: CampaignListCreateButton,
|
|
194
|
+
DataTable: CampaignListDataTable
|
|
166
195
|
});
|
|
167
196
|
|
|
168
197
|
export {
|
|
169
|
-
|
|
198
|
+
CampaignListPage
|
|
170
199
|
};
|