@medusajs/draft-order 2.11.4-preview-20251129090132 → 2.11.4-preview-20251129120139
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/.medusa/server/src/admin/index.js +75 -75
- package/.medusa/server/src/admin/index.mjs +75 -75
- package/package.json +16 -16
|
@@ -9572,74 +9572,6 @@ const ID = () => {
|
|
|
9572
9572
|
/* @__PURE__ */ jsxRuntime.jsx(reactRouterDom.Outlet, {})
|
|
9573
9573
|
] });
|
|
9574
9574
|
};
|
|
9575
|
-
const Email = () => {
|
|
9576
|
-
const { id } = reactRouterDom.useParams();
|
|
9577
|
-
const { order, isPending, isError, error } = useOrder(id, {
|
|
9578
|
-
fields: "+email"
|
|
9579
|
-
});
|
|
9580
|
-
if (isError) {
|
|
9581
|
-
throw error;
|
|
9582
|
-
}
|
|
9583
|
-
const isReady = !isPending && !!order;
|
|
9584
|
-
return /* @__PURE__ */ jsxRuntime.jsxs(RouteDrawer, { children: [
|
|
9585
|
-
/* @__PURE__ */ jsxRuntime.jsxs(RouteDrawer.Header, { children: [
|
|
9586
|
-
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Title, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(ui.Heading, { children: "Edit Email" }) }),
|
|
9587
|
-
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Description, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "sr-only", children: "Edit the email for the draft order" }) })
|
|
9588
|
-
] }),
|
|
9589
|
-
isReady && /* @__PURE__ */ jsxRuntime.jsx(EmailForm, { order })
|
|
9590
|
-
] });
|
|
9591
|
-
};
|
|
9592
|
-
const EmailForm = ({ order }) => {
|
|
9593
|
-
const form = reactHookForm.useForm({
|
|
9594
|
-
defaultValues: {
|
|
9595
|
-
email: order.email ?? ""
|
|
9596
|
-
},
|
|
9597
|
-
resolver: zod.zodResolver(schema$5)
|
|
9598
|
-
});
|
|
9599
|
-
const { mutateAsync, isPending } = useUpdateDraftOrder(order.id);
|
|
9600
|
-
const { handleSuccess } = useRouteModal();
|
|
9601
|
-
const onSubmit = form.handleSubmit(async (data) => {
|
|
9602
|
-
await mutateAsync(
|
|
9603
|
-
{ email: data.email },
|
|
9604
|
-
{
|
|
9605
|
-
onSuccess: () => {
|
|
9606
|
-
handleSuccess();
|
|
9607
|
-
},
|
|
9608
|
-
onError: (error) => {
|
|
9609
|
-
ui.toast.error(error.message);
|
|
9610
|
-
}
|
|
9611
|
-
}
|
|
9612
|
-
);
|
|
9613
|
-
});
|
|
9614
|
-
return /* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Form, { form, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
9615
|
-
KeyboundForm,
|
|
9616
|
-
{
|
|
9617
|
-
className: "flex flex-1 flex-col overflow-hidden",
|
|
9618
|
-
onSubmit,
|
|
9619
|
-
children: [
|
|
9620
|
-
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Body, { className: "flex flex-col gap-y-6 overflow-y-auto", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
9621
|
-
Form$2.Field,
|
|
9622
|
-
{
|
|
9623
|
-
control: form.control,
|
|
9624
|
-
name: "email",
|
|
9625
|
-
render: ({ field }) => /* @__PURE__ */ jsxRuntime.jsxs(Form$2.Item, { children: [
|
|
9626
|
-
/* @__PURE__ */ jsxRuntime.jsx(Form$2.Label, { children: "Email" }),
|
|
9627
|
-
/* @__PURE__ */ jsxRuntime.jsx(Form$2.Control, { children: /* @__PURE__ */ jsxRuntime.jsx(ui.Input, { ...field }) }),
|
|
9628
|
-
/* @__PURE__ */ jsxRuntime.jsx(Form$2.ErrorMessage, {})
|
|
9629
|
-
] })
|
|
9630
|
-
}
|
|
9631
|
-
) }),
|
|
9632
|
-
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Footer, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-end gap-2", children: [
|
|
9633
|
-
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Close, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(ui.Button, { size: "small", variant: "secondary", children: "Cancel" }) }),
|
|
9634
|
-
/* @__PURE__ */ jsxRuntime.jsx(ui.Button, { size: "small", type: "submit", isLoading: isPending, children: "Save" })
|
|
9635
|
-
] }) })
|
|
9636
|
-
]
|
|
9637
|
-
}
|
|
9638
|
-
) });
|
|
9639
|
-
};
|
|
9640
|
-
const schema$5 = objectType({
|
|
9641
|
-
email: stringType().email()
|
|
9642
|
-
});
|
|
9643
9575
|
const BillingAddress = () => {
|
|
9644
9576
|
const { id } = reactRouterDom.useParams();
|
|
9645
9577
|
const { order, isPending, isError, error } = useOrder(id, {
|
|
@@ -9672,7 +9604,7 @@ const BillingAddressForm = ({ order }) => {
|
|
|
9672
9604
|
postal_code: ((_i = order.billing_address) == null ? void 0 : _i.postal_code) ?? "",
|
|
9673
9605
|
phone: ((_j = order.billing_address) == null ? void 0 : _j.phone) ?? ""
|
|
9674
9606
|
},
|
|
9675
|
-
resolver: zod.zodResolver(schema$
|
|
9607
|
+
resolver: zod.zodResolver(schema$5)
|
|
9676
9608
|
});
|
|
9677
9609
|
const { mutateAsync, isPending } = useUpdateDraftOrder(order.id);
|
|
9678
9610
|
const { handleSuccess } = useRouteModal();
|
|
@@ -9829,7 +9761,7 @@ const BillingAddressForm = ({ order }) => {
|
|
|
9829
9761
|
}
|
|
9830
9762
|
) });
|
|
9831
9763
|
};
|
|
9832
|
-
const schema$
|
|
9764
|
+
const schema$5 = addressSchema;
|
|
9833
9765
|
const CustomItems = () => {
|
|
9834
9766
|
return /* @__PURE__ */ jsxRuntime.jsxs(RouteDrawer, { children: [
|
|
9835
9767
|
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Header, { children: /* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Title, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(ui.Heading, { children: "Edit Custom Items" }) }) }),
|
|
@@ -9838,7 +9770,7 @@ const CustomItems = () => {
|
|
|
9838
9770
|
};
|
|
9839
9771
|
const CustomItemsForm = () => {
|
|
9840
9772
|
const form = reactHookForm.useForm({
|
|
9841
|
-
resolver: zod.zodResolver(schema$
|
|
9773
|
+
resolver: zod.zodResolver(schema$4)
|
|
9842
9774
|
});
|
|
9843
9775
|
return /* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Form, { form, children: /* @__PURE__ */ jsxRuntime.jsxs(KeyboundForm, { className: "flex flex-1 flex-col", children: [
|
|
9844
9776
|
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Body, {}),
|
|
@@ -9848,6 +9780,74 @@ const CustomItemsForm = () => {
|
|
|
9848
9780
|
] }) })
|
|
9849
9781
|
] }) });
|
|
9850
9782
|
};
|
|
9783
|
+
const schema$4 = objectType({
|
|
9784
|
+
email: stringType().email()
|
|
9785
|
+
});
|
|
9786
|
+
const Email = () => {
|
|
9787
|
+
const { id } = reactRouterDom.useParams();
|
|
9788
|
+
const { order, isPending, isError, error } = useOrder(id, {
|
|
9789
|
+
fields: "+email"
|
|
9790
|
+
});
|
|
9791
|
+
if (isError) {
|
|
9792
|
+
throw error;
|
|
9793
|
+
}
|
|
9794
|
+
const isReady = !isPending && !!order;
|
|
9795
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(RouteDrawer, { children: [
|
|
9796
|
+
/* @__PURE__ */ jsxRuntime.jsxs(RouteDrawer.Header, { children: [
|
|
9797
|
+
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Title, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(ui.Heading, { children: "Edit Email" }) }),
|
|
9798
|
+
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Description, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx("span", { className: "sr-only", children: "Edit the email for the draft order" }) })
|
|
9799
|
+
] }),
|
|
9800
|
+
isReady && /* @__PURE__ */ jsxRuntime.jsx(EmailForm, { order })
|
|
9801
|
+
] });
|
|
9802
|
+
};
|
|
9803
|
+
const EmailForm = ({ order }) => {
|
|
9804
|
+
const form = reactHookForm.useForm({
|
|
9805
|
+
defaultValues: {
|
|
9806
|
+
email: order.email ?? ""
|
|
9807
|
+
},
|
|
9808
|
+
resolver: zod.zodResolver(schema$3)
|
|
9809
|
+
});
|
|
9810
|
+
const { mutateAsync, isPending } = useUpdateDraftOrder(order.id);
|
|
9811
|
+
const { handleSuccess } = useRouteModal();
|
|
9812
|
+
const onSubmit = form.handleSubmit(async (data) => {
|
|
9813
|
+
await mutateAsync(
|
|
9814
|
+
{ email: data.email },
|
|
9815
|
+
{
|
|
9816
|
+
onSuccess: () => {
|
|
9817
|
+
handleSuccess();
|
|
9818
|
+
},
|
|
9819
|
+
onError: (error) => {
|
|
9820
|
+
ui.toast.error(error.message);
|
|
9821
|
+
}
|
|
9822
|
+
}
|
|
9823
|
+
);
|
|
9824
|
+
});
|
|
9825
|
+
return /* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Form, { form, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
9826
|
+
KeyboundForm,
|
|
9827
|
+
{
|
|
9828
|
+
className: "flex flex-1 flex-col overflow-hidden",
|
|
9829
|
+
onSubmit,
|
|
9830
|
+
children: [
|
|
9831
|
+
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Body, { className: "flex flex-col gap-y-6 overflow-y-auto", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
9832
|
+
Form$2.Field,
|
|
9833
|
+
{
|
|
9834
|
+
control: form.control,
|
|
9835
|
+
name: "email",
|
|
9836
|
+
render: ({ field }) => /* @__PURE__ */ jsxRuntime.jsxs(Form$2.Item, { children: [
|
|
9837
|
+
/* @__PURE__ */ jsxRuntime.jsx(Form$2.Label, { children: "Email" }),
|
|
9838
|
+
/* @__PURE__ */ jsxRuntime.jsx(Form$2.Control, { children: /* @__PURE__ */ jsxRuntime.jsx(ui.Input, { ...field }) }),
|
|
9839
|
+
/* @__PURE__ */ jsxRuntime.jsx(Form$2.ErrorMessage, {})
|
|
9840
|
+
] })
|
|
9841
|
+
}
|
|
9842
|
+
) }),
|
|
9843
|
+
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Footer, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-end gap-2", children: [
|
|
9844
|
+
/* @__PURE__ */ jsxRuntime.jsx(RouteDrawer.Close, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx(ui.Button, { size: "small", variant: "secondary", children: "Cancel" }) }),
|
|
9845
|
+
/* @__PURE__ */ jsxRuntime.jsx(ui.Button, { size: "small", type: "submit", isLoading: isPending, children: "Save" })
|
|
9846
|
+
] }) })
|
|
9847
|
+
]
|
|
9848
|
+
}
|
|
9849
|
+
) });
|
|
9850
|
+
};
|
|
9851
9851
|
const schema$3 = objectType({
|
|
9852
9852
|
email: stringType().email()
|
|
9853
9853
|
});
|
|
@@ -13064,10 +13064,6 @@ const routeModule = {
|
|
|
13064
13064
|
handle,
|
|
13065
13065
|
loader,
|
|
13066
13066
|
children: [
|
|
13067
|
-
{
|
|
13068
|
-
Component: Email,
|
|
13069
|
-
path: "/draft-orders/:id/email"
|
|
13070
|
-
},
|
|
13071
13067
|
{
|
|
13072
13068
|
Component: BillingAddress,
|
|
13073
13069
|
path: "/draft-orders/:id/billing-address"
|
|
@@ -13076,6 +13072,10 @@ const routeModule = {
|
|
|
13076
13072
|
Component: CustomItems,
|
|
13077
13073
|
path: "/draft-orders/:id/custom-items"
|
|
13078
13074
|
},
|
|
13075
|
+
{
|
|
13076
|
+
Component: Email,
|
|
13077
|
+
path: "/draft-orders/:id/email"
|
|
13078
|
+
},
|
|
13079
13079
|
{
|
|
13080
13080
|
Component: Items,
|
|
13081
13081
|
path: "/draft-orders/:id/items"
|
|
@@ -9565,74 +9565,6 @@ const ID = () => {
|
|
|
9565
9565
|
/* @__PURE__ */ jsx(Outlet, {})
|
|
9566
9566
|
] });
|
|
9567
9567
|
};
|
|
9568
|
-
const Email = () => {
|
|
9569
|
-
const { id } = useParams();
|
|
9570
|
-
const { order, isPending, isError, error } = useOrder(id, {
|
|
9571
|
-
fields: "+email"
|
|
9572
|
-
});
|
|
9573
|
-
if (isError) {
|
|
9574
|
-
throw error;
|
|
9575
|
-
}
|
|
9576
|
-
const isReady = !isPending && !!order;
|
|
9577
|
-
return /* @__PURE__ */ jsxs(RouteDrawer, { children: [
|
|
9578
|
-
/* @__PURE__ */ jsxs(RouteDrawer.Header, { children: [
|
|
9579
|
-
/* @__PURE__ */ jsx(RouteDrawer.Title, { asChild: true, children: /* @__PURE__ */ jsx(Heading, { children: "Edit Email" }) }),
|
|
9580
|
-
/* @__PURE__ */ jsx(RouteDrawer.Description, { asChild: true, children: /* @__PURE__ */ jsx("span", { className: "sr-only", children: "Edit the email for the draft order" }) })
|
|
9581
|
-
] }),
|
|
9582
|
-
isReady && /* @__PURE__ */ jsx(EmailForm, { order })
|
|
9583
|
-
] });
|
|
9584
|
-
};
|
|
9585
|
-
const EmailForm = ({ order }) => {
|
|
9586
|
-
const form = useForm({
|
|
9587
|
-
defaultValues: {
|
|
9588
|
-
email: order.email ?? ""
|
|
9589
|
-
},
|
|
9590
|
-
resolver: zodResolver(schema$5)
|
|
9591
|
-
});
|
|
9592
|
-
const { mutateAsync, isPending } = useUpdateDraftOrder(order.id);
|
|
9593
|
-
const { handleSuccess } = useRouteModal();
|
|
9594
|
-
const onSubmit = form.handleSubmit(async (data) => {
|
|
9595
|
-
await mutateAsync(
|
|
9596
|
-
{ email: data.email },
|
|
9597
|
-
{
|
|
9598
|
-
onSuccess: () => {
|
|
9599
|
-
handleSuccess();
|
|
9600
|
-
},
|
|
9601
|
-
onError: (error) => {
|
|
9602
|
-
toast.error(error.message);
|
|
9603
|
-
}
|
|
9604
|
-
}
|
|
9605
|
-
);
|
|
9606
|
-
});
|
|
9607
|
-
return /* @__PURE__ */ jsx(RouteDrawer.Form, { form, children: /* @__PURE__ */ jsxs(
|
|
9608
|
-
KeyboundForm,
|
|
9609
|
-
{
|
|
9610
|
-
className: "flex flex-1 flex-col overflow-hidden",
|
|
9611
|
-
onSubmit,
|
|
9612
|
-
children: [
|
|
9613
|
-
/* @__PURE__ */ jsx(RouteDrawer.Body, { className: "flex flex-col gap-y-6 overflow-y-auto", children: /* @__PURE__ */ jsx(
|
|
9614
|
-
Form$2.Field,
|
|
9615
|
-
{
|
|
9616
|
-
control: form.control,
|
|
9617
|
-
name: "email",
|
|
9618
|
-
render: ({ field }) => /* @__PURE__ */ jsxs(Form$2.Item, { children: [
|
|
9619
|
-
/* @__PURE__ */ jsx(Form$2.Label, { children: "Email" }),
|
|
9620
|
-
/* @__PURE__ */ jsx(Form$2.Control, { children: /* @__PURE__ */ jsx(Input, { ...field }) }),
|
|
9621
|
-
/* @__PURE__ */ jsx(Form$2.ErrorMessage, {})
|
|
9622
|
-
] })
|
|
9623
|
-
}
|
|
9624
|
-
) }),
|
|
9625
|
-
/* @__PURE__ */ jsx(RouteDrawer.Footer, { children: /* @__PURE__ */ jsxs("div", { className: "flex justify-end gap-2", children: [
|
|
9626
|
-
/* @__PURE__ */ jsx(RouteDrawer.Close, { asChild: true, children: /* @__PURE__ */ jsx(Button, { size: "small", variant: "secondary", children: "Cancel" }) }),
|
|
9627
|
-
/* @__PURE__ */ jsx(Button, { size: "small", type: "submit", isLoading: isPending, children: "Save" })
|
|
9628
|
-
] }) })
|
|
9629
|
-
]
|
|
9630
|
-
}
|
|
9631
|
-
) });
|
|
9632
|
-
};
|
|
9633
|
-
const schema$5 = objectType({
|
|
9634
|
-
email: stringType().email()
|
|
9635
|
-
});
|
|
9636
9568
|
const BillingAddress = () => {
|
|
9637
9569
|
const { id } = useParams();
|
|
9638
9570
|
const { order, isPending, isError, error } = useOrder(id, {
|
|
@@ -9665,7 +9597,7 @@ const BillingAddressForm = ({ order }) => {
|
|
|
9665
9597
|
postal_code: ((_i = order.billing_address) == null ? void 0 : _i.postal_code) ?? "",
|
|
9666
9598
|
phone: ((_j = order.billing_address) == null ? void 0 : _j.phone) ?? ""
|
|
9667
9599
|
},
|
|
9668
|
-
resolver: zodResolver(schema$
|
|
9600
|
+
resolver: zodResolver(schema$5)
|
|
9669
9601
|
});
|
|
9670
9602
|
const { mutateAsync, isPending } = useUpdateDraftOrder(order.id);
|
|
9671
9603
|
const { handleSuccess } = useRouteModal();
|
|
@@ -9822,7 +9754,7 @@ const BillingAddressForm = ({ order }) => {
|
|
|
9822
9754
|
}
|
|
9823
9755
|
) });
|
|
9824
9756
|
};
|
|
9825
|
-
const schema$
|
|
9757
|
+
const schema$5 = addressSchema;
|
|
9826
9758
|
const CustomItems = () => {
|
|
9827
9759
|
return /* @__PURE__ */ jsxs(RouteDrawer, { children: [
|
|
9828
9760
|
/* @__PURE__ */ jsx(RouteDrawer.Header, { children: /* @__PURE__ */ jsx(RouteDrawer.Title, { asChild: true, children: /* @__PURE__ */ jsx(Heading, { children: "Edit Custom Items" }) }) }),
|
|
@@ -9831,7 +9763,7 @@ const CustomItems = () => {
|
|
|
9831
9763
|
};
|
|
9832
9764
|
const CustomItemsForm = () => {
|
|
9833
9765
|
const form = useForm({
|
|
9834
|
-
resolver: zodResolver(schema$
|
|
9766
|
+
resolver: zodResolver(schema$4)
|
|
9835
9767
|
});
|
|
9836
9768
|
return /* @__PURE__ */ jsx(RouteDrawer.Form, { form, children: /* @__PURE__ */ jsxs(KeyboundForm, { className: "flex flex-1 flex-col", children: [
|
|
9837
9769
|
/* @__PURE__ */ jsx(RouteDrawer.Body, {}),
|
|
@@ -9841,6 +9773,74 @@ const CustomItemsForm = () => {
|
|
|
9841
9773
|
] }) })
|
|
9842
9774
|
] }) });
|
|
9843
9775
|
};
|
|
9776
|
+
const schema$4 = objectType({
|
|
9777
|
+
email: stringType().email()
|
|
9778
|
+
});
|
|
9779
|
+
const Email = () => {
|
|
9780
|
+
const { id } = useParams();
|
|
9781
|
+
const { order, isPending, isError, error } = useOrder(id, {
|
|
9782
|
+
fields: "+email"
|
|
9783
|
+
});
|
|
9784
|
+
if (isError) {
|
|
9785
|
+
throw error;
|
|
9786
|
+
}
|
|
9787
|
+
const isReady = !isPending && !!order;
|
|
9788
|
+
return /* @__PURE__ */ jsxs(RouteDrawer, { children: [
|
|
9789
|
+
/* @__PURE__ */ jsxs(RouteDrawer.Header, { children: [
|
|
9790
|
+
/* @__PURE__ */ jsx(RouteDrawer.Title, { asChild: true, children: /* @__PURE__ */ jsx(Heading, { children: "Edit Email" }) }),
|
|
9791
|
+
/* @__PURE__ */ jsx(RouteDrawer.Description, { asChild: true, children: /* @__PURE__ */ jsx("span", { className: "sr-only", children: "Edit the email for the draft order" }) })
|
|
9792
|
+
] }),
|
|
9793
|
+
isReady && /* @__PURE__ */ jsx(EmailForm, { order })
|
|
9794
|
+
] });
|
|
9795
|
+
};
|
|
9796
|
+
const EmailForm = ({ order }) => {
|
|
9797
|
+
const form = useForm({
|
|
9798
|
+
defaultValues: {
|
|
9799
|
+
email: order.email ?? ""
|
|
9800
|
+
},
|
|
9801
|
+
resolver: zodResolver(schema$3)
|
|
9802
|
+
});
|
|
9803
|
+
const { mutateAsync, isPending } = useUpdateDraftOrder(order.id);
|
|
9804
|
+
const { handleSuccess } = useRouteModal();
|
|
9805
|
+
const onSubmit = form.handleSubmit(async (data) => {
|
|
9806
|
+
await mutateAsync(
|
|
9807
|
+
{ email: data.email },
|
|
9808
|
+
{
|
|
9809
|
+
onSuccess: () => {
|
|
9810
|
+
handleSuccess();
|
|
9811
|
+
},
|
|
9812
|
+
onError: (error) => {
|
|
9813
|
+
toast.error(error.message);
|
|
9814
|
+
}
|
|
9815
|
+
}
|
|
9816
|
+
);
|
|
9817
|
+
});
|
|
9818
|
+
return /* @__PURE__ */ jsx(RouteDrawer.Form, { form, children: /* @__PURE__ */ jsxs(
|
|
9819
|
+
KeyboundForm,
|
|
9820
|
+
{
|
|
9821
|
+
className: "flex flex-1 flex-col overflow-hidden",
|
|
9822
|
+
onSubmit,
|
|
9823
|
+
children: [
|
|
9824
|
+
/* @__PURE__ */ jsx(RouteDrawer.Body, { className: "flex flex-col gap-y-6 overflow-y-auto", children: /* @__PURE__ */ jsx(
|
|
9825
|
+
Form$2.Field,
|
|
9826
|
+
{
|
|
9827
|
+
control: form.control,
|
|
9828
|
+
name: "email",
|
|
9829
|
+
render: ({ field }) => /* @__PURE__ */ jsxs(Form$2.Item, { children: [
|
|
9830
|
+
/* @__PURE__ */ jsx(Form$2.Label, { children: "Email" }),
|
|
9831
|
+
/* @__PURE__ */ jsx(Form$2.Control, { children: /* @__PURE__ */ jsx(Input, { ...field }) }),
|
|
9832
|
+
/* @__PURE__ */ jsx(Form$2.ErrorMessage, {})
|
|
9833
|
+
] })
|
|
9834
|
+
}
|
|
9835
|
+
) }),
|
|
9836
|
+
/* @__PURE__ */ jsx(RouteDrawer.Footer, { children: /* @__PURE__ */ jsxs("div", { className: "flex justify-end gap-2", children: [
|
|
9837
|
+
/* @__PURE__ */ jsx(RouteDrawer.Close, { asChild: true, children: /* @__PURE__ */ jsx(Button, { size: "small", variant: "secondary", children: "Cancel" }) }),
|
|
9838
|
+
/* @__PURE__ */ jsx(Button, { size: "small", type: "submit", isLoading: isPending, children: "Save" })
|
|
9839
|
+
] }) })
|
|
9840
|
+
]
|
|
9841
|
+
}
|
|
9842
|
+
) });
|
|
9843
|
+
};
|
|
9844
9844
|
const schema$3 = objectType({
|
|
9845
9845
|
email: stringType().email()
|
|
9846
9846
|
});
|
|
@@ -13057,10 +13057,6 @@ const routeModule = {
|
|
|
13057
13057
|
handle,
|
|
13058
13058
|
loader,
|
|
13059
13059
|
children: [
|
|
13060
|
-
{
|
|
13061
|
-
Component: Email,
|
|
13062
|
-
path: "/draft-orders/:id/email"
|
|
13063
|
-
},
|
|
13064
13060
|
{
|
|
13065
13061
|
Component: BillingAddress,
|
|
13066
13062
|
path: "/draft-orders/:id/billing-address"
|
|
@@ -13069,6 +13065,10 @@ const routeModule = {
|
|
|
13069
13065
|
Component: CustomItems,
|
|
13070
13066
|
path: "/draft-orders/:id/custom-items"
|
|
13071
13067
|
},
|
|
13068
|
+
{
|
|
13069
|
+
Component: Email,
|
|
13070
|
+
path: "/draft-orders/:id/email"
|
|
13071
|
+
},
|
|
13072
13072
|
{
|
|
13073
13073
|
Component: Items,
|
|
13074
13074
|
path: "/draft-orders/:id/items"
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@medusajs/draft-order",
|
|
3
|
-
"version": "2.11.4-preview-
|
|
3
|
+
"version": "2.11.4-preview-20251129120139",
|
|
4
4
|
"description": "A starter for Medusa plugins.",
|
|
5
5
|
"author": "Medusa (https://medusajs.com)",
|
|
6
6
|
"license": "MIT",
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
"@ariakit/react": "^0.4.15",
|
|
38
38
|
"@babel/runtime": "^7.26.10",
|
|
39
39
|
"@hookform/resolvers": "3.4.2",
|
|
40
|
-
"@medusajs/js-sdk": "2.11.4-preview-
|
|
40
|
+
"@medusajs/js-sdk": "2.11.4-preview-20251129120139",
|
|
41
41
|
"@tanstack/react-query": "5.64.2",
|
|
42
42
|
"@uiw/react-json-view": "^2.0.0-alpha.17",
|
|
43
43
|
"date-fns": "^3.6.0",
|
|
@@ -48,22 +48,22 @@
|
|
|
48
48
|
"react-hook-form": "7.49.1"
|
|
49
49
|
},
|
|
50
50
|
"devDependencies": {
|
|
51
|
-
"@medusajs/admin-sdk": "2.11.4-preview-
|
|
52
|
-
"@medusajs/cli": "2.11.4-preview-
|
|
53
|
-
"@medusajs/framework": "2.11.4-preview-
|
|
54
|
-
"@medusajs/icons": "2.11.4-preview-
|
|
55
|
-
"@medusajs/test-utils": "2.11.4-preview-
|
|
56
|
-
"@medusajs/types": "2.11.4-preview-
|
|
57
|
-
"@medusajs/ui": "4.0.28-preview-
|
|
58
|
-
"@medusajs/ui-preset": "2.11.4-preview-
|
|
51
|
+
"@medusajs/admin-sdk": "2.11.4-preview-20251129120139",
|
|
52
|
+
"@medusajs/cli": "2.11.4-preview-20251129120139",
|
|
53
|
+
"@medusajs/framework": "2.11.4-preview-20251129120139",
|
|
54
|
+
"@medusajs/icons": "2.11.4-preview-20251129120139",
|
|
55
|
+
"@medusajs/test-utils": "2.11.4-preview-20251129120139",
|
|
56
|
+
"@medusajs/types": "2.11.4-preview-20251129120139",
|
|
57
|
+
"@medusajs/ui": "4.0.28-preview-20251129120139",
|
|
58
|
+
"@medusajs/ui-preset": "2.11.4-preview-20251129120139"
|
|
59
59
|
},
|
|
60
60
|
"peerDependencies": {
|
|
61
|
-
"@medusajs/admin-sdk": "2.11.4-preview-
|
|
62
|
-
"@medusajs/cli": "2.11.4-preview-
|
|
63
|
-
"@medusajs/framework": "2.11.4-preview-
|
|
64
|
-
"@medusajs/icons": "2.11.4-preview-
|
|
65
|
-
"@medusajs/test-utils": "2.11.4-preview-
|
|
66
|
-
"@medusajs/ui": "4.0.28-preview-
|
|
61
|
+
"@medusajs/admin-sdk": "2.11.4-preview-20251129120139",
|
|
62
|
+
"@medusajs/cli": "2.11.4-preview-20251129120139",
|
|
63
|
+
"@medusajs/framework": "2.11.4-preview-20251129120139",
|
|
64
|
+
"@medusajs/icons": "2.11.4-preview-20251129120139",
|
|
65
|
+
"@medusajs/test-utils": "2.11.4-preview-20251129120139",
|
|
66
|
+
"@medusajs/ui": "4.0.28-preview-20251129120139",
|
|
67
67
|
"react": "^18.3.1",
|
|
68
68
|
"react-dom": "^18.3.1",
|
|
69
69
|
"react-router-dom": "6.20.1"
|