Skip to content

Add multi-shop Universal Checkout sample carts - #841

Draft
tiagocandido wants to merge 1 commit into
uc-web-eventsfrom
uc-sample-shops
Draft

tiagocandido wants to merge 1 commit into
uc-web-eventsfrom
uc-sample-shops

Conversation

@tiagocandido

@tiagocandido tiagocandido commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

What changes are you making?

Add a separate Universal Checkout sample page with editable storefront domains, product loading, per-shop quantities and independent cart previews. Keep the existing single-checkout page available through shared navigation.

The state/controller/view split handles stale catalog responses, failed-shop retry, unavailable variants, cart invalidation and page restoration. Layouts keep all shop catalogs and controls reachable at wide and narrow widths. This layer builds the cart UI; session creation and checkout presentation are added above it in the stack.

How to test

From the repository root, with dependencies installed:

pnpm --dir platforms/web lint
pnpm --dir platforms/web test
pnpm --dir platforms/web build
pnpm --dir platforms/web verify
pnpm --dir platforms/web sample:build

Start the sample with pnpm --dir platforms/web sample and open /universal.html. Add two eligible storefront domains, select different products and quantities, remove/re-add a shop, retry a failed catalog and resize the page. The full stack passes 440 Web tests and sample lint/typecheck/build; focused tests cover domain parsing, asynchronous catalogs, quantities, availability and the rendered cart controls.

tophat results

On the public-base revision, two shops loaded from ignored environment configuration. Both catalogs loaded and independent product selections populated their carts. Removing a shop invalidated the prepared URL; reloading restored the configured shops with empty carts.

@github-actions github-actions Bot added the #gsd:50662 Rebase Checkout Kit on UCP label Sep 28, 2026
@tiagocandido
tiagocandido added this pull request to stack #845 September 28, 2026 15:20
@tiagocandido
tiagocandido marked this pull request as ready for review September 28, 2026 15:23
@tiagocandido
tiagocandido requested a review from a team as a code owner September 28, 2026 15:23
@github-actions

github-actions Bot commented Sep 28, 2026 •

Copy link
Copy Markdown

Web — Coverage Report

Lines Statements Branches Functions
Coverage: 89%
87.96% (753/856) 82.72% (479/579) 92.18% (177/192)

@github-actions

github-actions Bot commented Sep 28, 2026 •

Copy link
Copy Markdown

Package Size

Platform Artifact Base Head Delta
Web npm tarball 126.3 KiB 126.3 KiB 0 B
Web file breakdown
File Base Head Delta
dist/telemetry-BhYuVVw_.js.map 215.7 KiB 215.7 KiB 0 B
dist/custom-elements.json 90.8 KiB 90.8 KiB 0 B
dist/universal.js.map 63.9 KiB 63.9 KiB 0 B
dist/index.d.ts 47.7 KiB 47.7 KiB 0 B
dist/universal.d.ts 44.7 KiB 44.7 KiB 0 B
dist/index.js.map 34.8 KiB 34.8 KiB 0 B
dist/telemetry-BhYuVVw_.js 34.4 KiB 34.4 KiB 0 B
README.md 20.1 KiB 20.1 KiB 0 B
dist/universal.js 18.9 KiB 18.9 KiB 0 B
dist/index.js 8.3 KiB 8.3 KiB 0 B
package.json 3.1 KiB 3.1 KiB 0 B
LICENSE 1.1 KiB 1.1 KiB 0 B

Measured from the PR base SHA and PR head SHA. The file breakdown shows uncompressed sizes within each package artifact, so individual files do not sum to the compressed artifact total. This comment reports package artifact sizes only; it is not a final app binary-size report.

@tiagocandido
tiagocandido marked this pull request as draft September 29, 2026 10:01

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

#gsd:50662 Rebase Checkout Kit on UCP

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant