From 50c4f558db47c1cc6e2f8612d003b7c5bd5e2cda Mon Sep 17 00:00:00 2001 From: Jakub Neander Date: Thu, 22 Jul 2021 17:29:24 +0200 Subject: [PATCH 01/10] specify the minimal required Saleor version (#418) --- framework/saleor/README.md | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/framework/saleor/README.md b/framework/saleor/README.md index 1684ff6bc..590fb0275 100644 --- a/framework/saleor/README.md +++ b/framework/saleor/README.md @@ -1,19 +1,15 @@ ## Saleor Provider -**Demo:** TBD +**Demo:** https://saleor.vercel.store/ -Before getting starter, a [Saleor](https://saleor.io/) account and store is required before using the provider. +You need a [Saleor](https://saleor.io/) instance, either in the cloud or self-hosted. -Next, copy the `.env.template` file in this directory to `.env.local` in the main directory (which will be ignored by Git): +This provider requires Saleor **3.x** or higher. + +Copy the `.env.template` file in this directory to `.env.local` in the main directory (which will be ignored by Git): ```bash cp framework/saleor/.env.template .env.local ``` Then, set the environment variables in `.env.local` to match the ones from your store. - -## Contribute - -Our commitment to Open Source can be found [here](https://vercel.com/oss). - -If you find an issue with the provider or want a new feature, feel free to open a PR or [create a new issue](https://github.com/vercel/commerce/issues). From 177914186e610512058380c855eeff1daac5f717 Mon Sep 17 00:00:00 2001 From: MitchStarkTekton <61703668+MitchStarkTekton@users.noreply.github.com> Date: Wed, 28 Jul 2021 20:30:55 -0400 Subject: [PATCH 02/10] convert category to number before checking for int (#422) --- framework/bigcommerce/product/use-search.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/framework/bigcommerce/product/use-search.tsx b/framework/bigcommerce/product/use-search.tsx index bea01753b..cd6c34612 100644 --- a/framework/bigcommerce/product/use-search.tsx +++ b/framework/bigcommerce/product/use-search.tsx @@ -22,7 +22,7 @@ export const handler: SWRHook = { const url = new URL(options.url!, 'http://a') if (search) url.searchParams.set('search', search) - if (Number.isInteger(categoryId)) + if (Number.isInteger(Number(categoryId))) url.searchParams.set('categoryId', String(categoryId)) if (Number.isInteger(brandId)) url.searchParams.set('brandId', String(brandId)) From 4b164d20a3122004b762c3fc1221f294f629a7c0 Mon Sep 17 00:00:00 2001 From: Jakub Neander Date: Thu, 29 Jul 2021 02:31:35 +0200 Subject: [PATCH 03/10] provide more details for Saleor in its README (#419) --- framework/saleor/README.md | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/framework/saleor/README.md b/framework/saleor/README.md index 590fb0275..00af272b0 100644 --- a/framework/saleor/README.md +++ b/framework/saleor/README.md @@ -12,4 +12,11 @@ Copy the `.env.template` file in this directory to `.env.local` in the main dire cp framework/saleor/.env.template .env.local ``` -Then, set the environment variables in `.env.local` to match the ones from your store. +Then, set the environment following variables in your `.env.local`. Both, `NEXT_PUBLIC_SALEOR_API_URL` and `COMMERCE_IMAGE_HOST` must point to your own Saleor instance. + +``` +COMMERCE_PROVIDER=saleor +NEXT_PUBLIC_SALEOR_API_URL=https://vercel.saleor.cloud/graphql/ +NEXT_PUBLIC_SALEOR_CHANNEL=default-channel +COMMERCE_IMAGE_HOST=vercel.saleor.cloud +``` From ff715c4ccbf62e5d439de4acf85ebabe52708310 Mon Sep 17 00:00:00 2001 From: Michael Bromley Date: Thu, 29 Jul 2021 02:32:42 +0200 Subject: [PATCH 04/10] Add note in Vendure readme on correct server config for sessions (#417) --- framework/vendure/README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/framework/vendure/README.md b/framework/vendure/README.md index c1bcd7b5b..7f1dccb3f 100644 --- a/framework/vendure/README.md +++ b/framework/vendure/README.md @@ -13,6 +13,8 @@ UI hooks and data fetching methods built from the ground up for e-commerce appli ``` 3. With the Vendure server running, start this project using `yarn dev` or `npm run dev`. +**Note:** The Vendure server needs to be configured to use the "cookie" tokenMethod rather than "bearer" to work with this provider. For more information see the [Managing Sessions docs](https://www.vendure.io/docs/storefront/managing-sessions/). + ## Known Limitations 1. Vendure does not ship with built-in wishlist functionality. From b40f6329087a60ada5a154583a9b2a361a373c93 Mon Sep 17 00:00:00 2001 From: Vinicius Zucatti Date: Thu, 29 Jul 2021 19:43:04 -0300 Subject: [PATCH 05/10] Fix unexpected uppercase (#414) --- assets/base.css | 1 - 1 file changed, 1 deletion(-) diff --git a/assets/base.css b/assets/base.css index 00081f459..05a234a73 100644 --- a/assets/base.css +++ b/assets/base.css @@ -77,7 +77,6 @@ html { height: 100%; box-sizing: border-box; touch-action: manipulation; - font-feature-settings: 'case' 1, 'rlig' 1, 'calt' 0; text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; From 5abae15ead720f7c19766ad6fd1a58f528ba6820 Mon Sep 17 00:00:00 2001 From: Heba Elmasry <38689569+hebaayman77177@users.noreply.github.com> Date: Fri, 30 Jul 2021 00:48:43 +0200 Subject: [PATCH 06/10] add vendure config in .env.template (#397) * edited the local template and the readme files to add vendure configrations * Update README.md Co-authored-by: heba Co-authored-by: Luis Alvarez D --- .env.template | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.env.template b/.env.template index 23627e5fb..1f0fe0536 100644 --- a/.env.template +++ b/.env.template @@ -20,3 +20,6 @@ NEXT_PUBLIC_SWELL_PUBLIC_KEY= NEXT_PUBLIC_SALEOR_API_URL= NEXT_PUBLIC_SALEOR_CHANNEL= + +NEXT_PUBLIC_VENDURE_SHOP_API_URL= +NEXT_PUBLIC_VENDURE_LOCAL_URL= From fe6c0d8ed54eeb048ae8de482d228fd2db9d0317 Mon Sep 17 00:00:00 2001 From: pfcodes Date: Thu, 29 Jul 2021 16:10:39 -0700 Subject: [PATCH 07/10] Update README.md (#375) grammer fix --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 8204b3445..d53c5ed86 100644 --- a/README.md +++ b/README.md @@ -151,5 +151,5 @@ Next, you're free to customize the starter. More updates coming soon. Stay tuned After Email confirmation, Checkout should be manually enabled through BigCommerce platform. Look for "Review & test your store" section through BigCommerce's dashboard.

-BigCommerce team has been notified and they plan to add more detailed about this subject. +BigCommerce team has been notified and they plan to add more details about this subject. From 07dbeb4194757cfcd3157fc43dfb7d53c44e3aa6 Mon Sep 17 00:00:00 2001 From: Gandharv Date: Fri, 30 Jul 2021 10:17:45 +0530 Subject: [PATCH 08/10] fix login button staying disabled (#267) When an error occurs the login button stays disabled, --- components/auth/LoginView.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/components/auth/LoginView.tsx b/components/auth/LoginView.tsx index 35ff98f66..5e513deb9 100644 --- a/components/auth/LoginView.tsx +++ b/components/auth/LoginView.tsx @@ -38,6 +38,7 @@ const LoginView: FC = () => { } catch ({ errors }) { setMessage(errors[0].message) setLoading(false) + setDisabled(false) } } From 34d0a0b97828345505887eed3c648b406a50fb0c Mon Sep 17 00:00:00 2001 From: thegoodcode Date: Fri, 30 Jul 2021 05:50:55 +0100 Subject: [PATCH 09/10] Fix login error messages (#283) --- framework/bigcommerce/auth/use-login.tsx | 2 +- framework/shopify/auth/use-login.tsx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/framework/bigcommerce/auth/use-login.tsx b/framework/bigcommerce/auth/use-login.tsx index 3ebacc9b7..d366b5260 100644 --- a/framework/bigcommerce/auth/use-login.tsx +++ b/framework/bigcommerce/auth/use-login.tsx @@ -16,7 +16,7 @@ export const handler: MutationHook = { if (!(email && password)) { throw new CommerceError({ message: - 'A first name, last name, email and password are required to login', + 'An email and password are required to login', }) } diff --git a/framework/shopify/auth/use-login.tsx b/framework/shopify/auth/use-login.tsx index d4369b7c2..e1de89c99 100644 --- a/framework/shopify/auth/use-login.tsx +++ b/framework/shopify/auth/use-login.tsx @@ -22,7 +22,7 @@ export const handler: MutationHook = { if (!(email && password)) { throw new CommerceError({ message: - 'A first name, last name, email and password are required to login', + 'An email and password are required to login', }) } From 44ce537b57c7a46386167f790a42b041499386ae Mon Sep 17 00:00:00 2001 From: Gandharv Date: Fri, 30 Jul 2021 10:27:02 +0530 Subject: [PATCH 10/10] remove spread operator from component (#263) * remove spread operator from component * Remove props destructuring Co-authored-by: Luis Alvarez --- components/product/ProductCard/ProductCard.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/components/product/ProductCard/ProductCard.tsx b/components/product/ProductCard/ProductCard.tsx index 39c19db00..95f2f3f07 100644 --- a/components/product/ProductCard/ProductCard.tsx +++ b/components/product/ProductCard/ProductCard.tsx @@ -7,6 +7,7 @@ import Image, { ImageProps } from 'next/image' import WishlistButton from '@components/wishlist/WishlistButton' import usePrice from '@framework/product/use-price' import ProductTag from '../ProductTag' + interface Props { className?: string product: Product @@ -23,7 +24,6 @@ const ProductCard: FC = ({ className, noNameTag = false, variant = 'default', - ...props }) => { const { price } = usePrice({ amount: product.price.value, @@ -38,7 +38,7 @@ const ProductCard: FC = ({ ) return ( - + {variant === 'slim' && ( <>