Skip to content

feat(storefront): design both sides of the garment - #44

Merged
Lingz450 merged 1 commit into
mainfrom
feat/studio-two-sided-design
Jul 18, 2026
Merged

feat(storefront): design both sides of the garment#44
Lingz450 merged 1 commit into
mainfrom
feat/studio-two-sided-design

Conversation

@Lingz450

Copy link
Copy Markdown
Collaborator

Completes the two-sided design flow. Builds on the merged cart-both-sides work (#39).

What

The Design Studio can now print both the front and back of one piece (the same artwork, placed independently per side), and the cart draws each case:

You design Cart shows
Front only front · art, back · blank
Back only front · blank, back · art
Both sides front · art, back · art + "Both sides"

Studio

  • StudioConfig models the active side (placement/scale/transform) plus a stashed otherSide; switchView turns the garment over, keeping each side's print. collectSides yields the printed sides.
  • Placement chips are filtered to the side being viewed; the view toggle shows a dot per printed side; a "leave this side blank" clears the active side when the other stays printed; the summary lists every printed side.
  • Add-to-bag carries per-side geometry in designSides.
  • Share URL round-trips both sides (o-prefixed params); an old single-side link viewing the back migrates its print to the other side (no silent loss).

Cart

  • Each line renders front + back, each side from its own designSides entry (falls back to the single-side fields for product / older lines).
  • Line identity + saved-design signature fold in every printed side, so one-sided and two-sided compositions never merge.

Verification

Driven in-browser end-to-end: default front print → turned to back (chips switched to back-only, "blank" prompt) → printed back (both view dots lit, summary "front · Small · back · Medium") → add to bag. The stored line carried designSides: { front: {left-chest, small}, back: {back, medium} }, and the cart drew two art images (front + back) with a "Both sides" tag. Front-only and back-only lines still render one side each.

Gate green: format, lint, typecheck, 290 storefront tests (two-sided model, switchView/collectSides, two-sided URL round-trip, cart identity), build.

Note

Rebased onto current main (which gained #42/#43 from parallel work); no overlap with those files.

🤖 Generated with Claude Code

The Design Studio can now print BOTH the front and back of one piece (the
same artwork, placed independently per side), and the cart shows each case.

Studio:
- StudioConfig models the active side (placement/scale/transform) plus a
  stashed otherSide; `switchView` turns the garment over, keeping each
  side's print. `collectSides` yields the printed sides.
- Placement chips are filtered to the side being viewed; the view toggle
  shows a dot per printed side; a "leave this side blank" clears the active
  side when the other stays printed; the summary lists every printed side.
- add-to-bag carries per-side geometry in `designSides`.
- Share URL round-trips both sides (o-prefixed params); an old single-side
  link viewing the back migrates its print to the other side.

Cart:
- Each line already drew front + back; now each side renders from its own
  designSides entry. Front-only → front·art/back·blank; back-only →
  front·blank/back·art; both → front·art/back·art with a "Both sides" tag.
- Line identity + saved-design signature fold in every printed side, so
  distinct one/two-sided compositions never merge.

Verified in-browser end-to-end: designed front, turned to back, printed it,
added to bag — the line stored both sides and the cart drew art on both.
Gate green: format, lint, typecheck, 290 storefront tests, build.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@vercel

vercel Bot commented Jul 18, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
tai-storefront Ready Ready Preview, Comment Jul 18, 2026 8:24pm
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
tai-admin Skipped Skipped Jul 18, 2026 8:24pm

@Lingz450
Lingz450 merged commit 2c4d6a7 into main Jul 18, 2026
4 checks passed
@Lingz450
Lingz450 deleted the feat/studio-two-sided-design branch July 18, 2026 20:41
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