@springmicro/cart 0.6.1 → 0.6.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/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@springmicro/cart",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "0.6.
|
|
4
|
+
"version": "0.6.2",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"types": "dist/index.d.ts",
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"@nanostores/persistent": "^0.10.1",
|
|
25
25
|
"@nanostores/query": "^0.3.3",
|
|
26
26
|
"@nanostores/react": "^0.7.2",
|
|
27
|
-
"@springmicro/utils": "0.6.
|
|
27
|
+
"@springmicro/utils": "0.6.2",
|
|
28
28
|
"dotenv": "^16.4.5",
|
|
29
29
|
"nanostores": "^0.10.3",
|
|
30
30
|
"react": "^18.2.0",
|
|
@@ -49,5 +49,5 @@
|
|
|
49
49
|
"vite-plugin-css-injected-by-js": "^3.5.1",
|
|
50
50
|
"yup": "^1.4.0"
|
|
51
51
|
},
|
|
52
|
-
"gitHead": "
|
|
52
|
+
"gitHead": "f0aee01ae9b45595f59d70a5fdf9cae8933edb24"
|
|
53
53
|
}
|
|
Binary file
|
|
@@ -77,6 +77,7 @@ async function getTax(apiBaseUrl, taxProvider, items, v, products, dev) {
|
|
|
77
77
|
const taxable_items = items.filter(
|
|
78
78
|
(i) => i.unit_amount > 0 && products[i.product_id].type !== "DONATION"
|
|
79
79
|
);
|
|
80
|
+
dev && console.log("Taxable items", taxable_items);
|
|
80
81
|
if (taxable_items.length === 0) return { tax_amount: 0 };
|
|
81
82
|
|
|
82
83
|
const res = await fetch(
|
|
@@ -122,7 +123,7 @@ export default function ReviewAndCalculateTaxes({
|
|
|
122
123
|
defaultValues = {},
|
|
123
124
|
dev,
|
|
124
125
|
}) {
|
|
125
|
-
console.log({ products, prices });
|
|
126
|
+
dev && console.log({ products, prices });
|
|
126
127
|
const [formDisabled, setFormDisabled] = useState(true);
|
|
127
128
|
const [formError, setFormError] = useState(undefined);
|
|
128
129
|
const theme = useTheme();
|
|
@@ -420,7 +421,7 @@ function CheckoutActionFields({ formik, products, prices }) {
|
|
|
420
421
|
// Overwrites the checkout field to use the last one provided. This allows prices to overwrite product checkout fields if necessary.
|
|
421
422
|
].reduce((old, field) => ({ ...old, [field.name]: field }), {});
|
|
422
423
|
|
|
423
|
-
console.log("Checkout fields", checkoutFields);
|
|
424
|
+
// console.log("Checkout fields", checkoutFields);
|
|
424
425
|
const handleInputFocus = (e) => {
|
|
425
426
|
const focusedEl = (e.target as HTMLElement).getAttribute("name");
|
|
426
427
|
if (focusedEl) {
|