@atomic-solutions/woocommerce-react 0.2.4 → 0.2.6
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/hooks/index.cjs +2 -1
- package/dist/hooks/index.cjs.map +1 -1
- package/dist/hooks/index.d.cts +2 -2
- package/dist/hooks/index.d.ts +2 -2
- package/dist/hooks/index.js +2 -1
- package/dist/hooks/index.js.map +1 -1
- package/dist/{index-curVj6LB.d.ts → index-BWIYt7TO.d.ts} +2088 -2088
- package/dist/{index-Cq857W8p.d.cts → index-CaNfLsEj.d.cts} +2088 -2088
- package/dist/index.cjs +10 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +3 -3
- package/dist/index.d.ts +3 -3
- package/dist/index.js +10 -4
- package/dist/index.js.map +1 -1
- package/dist/provider/index.d.cts +2 -2
- package/dist/provider/index.d.ts +2 -2
- package/dist/{types-8KIvr2ze.d.cts → types-_8YqnkO-.d.cts} +15 -14
- package/dist/{types-8KIvr2ze.d.ts → types-_8YqnkO-.d.ts} +15 -14
- package/package.json +2 -2
package/dist/hooks/index.cjs
CHANGED
|
@@ -426,10 +426,11 @@ var useProcessCheckout = () => {
|
|
|
426
426
|
mutationKey: queryKeys.checkout.mutations.process(),
|
|
427
427
|
mutationFn: (input) => client.checkout.process(input),
|
|
428
428
|
onSuccess: (checkout) => {
|
|
429
|
+
const cart = queryClient.getQueryData(queryKeys.cart.details()) ?? null;
|
|
429
430
|
queryClient.invalidateQueries({ queryKey: queryKeys.cart.all });
|
|
430
431
|
queryClient.invalidateQueries({ queryKey: queryKeys.checkout.all });
|
|
431
432
|
if (emitEvent) {
|
|
432
|
-
emitEvent(createSuccessEvent("checkout:processed", { checkout }));
|
|
433
|
+
emitEvent(createSuccessEvent("checkout:processed", { checkout, cart }));
|
|
433
434
|
}
|
|
434
435
|
},
|
|
435
436
|
onError: (error) => {
|