Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

W-17483735 - Prepare cart page ability to add item based on query string for shopp… #2205

Open
wants to merge 4 commits into
base: develop
Choose a base branch
from

Conversation

alexvuong
Copy link
Collaborator

@alexvuong alexvuong commented Jan 15, 2025

Description

As part of integrate shopper agent into pwa-kit, pwa-kit will need to be aware of when the agent is sending a link for shopper to add an item to cart. The link will look like this
https://pwa-kit.mobify-storefront.com/global/en-GB/cart?items=productId1,productId2

In this PR, I refactored the cart page to add these productIds from query string into the cart page.

How Agent works

The scenario is when a shopper asks the agent to add an item into cart. The agent can't add an item directly to cart, but it will generate a link and tell shopper to click that link to add the item to cart. When shoppers click on the link from the agent, it will navigate to pwa-kit cart page, and add those items from search query into cart.

image

Types of Changes

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Documentation update
  • Breaking change (could cause existing functionality to not work as expected)
  • Other changes (non-breaking changes that does not fit any of the above)

Breaking changes include:

  • Removing a public function or component or prop
  • Adding a required argument to a function
  • Changing the data type of a function parameter or return value
  • Adding a new peer dependency to package.json

Changes

  • (change1)

How to Test-Drive This PR

Checklists

General

  • Changes are covered by test cases
  • CHANGELOG.md updated with a short description of changes (not required for documentation updates)

Accessibility Compliance

You must check off all items in one of the follow two lists:

  • There are no changes to UI

or...

Localization

  • Changes include a UI text update in the Retail React App (which requires translation)

@alexvuong alexvuong requested a review from a team as a code owner January 15, 2025 04:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant