refactor(cards): extract Card3D component (Brief 1) #77

Merged
varutasu merged 1 commit from refactor/cards-page-split-brief-1 into main 2026-06-03 09:57:49 -04:00
varutasu commented 2026-06-02 22:58:06 -04:00 (Migrated from github.com)

Summary

  • Extract Card3D and internal CardBack from pages/cards.js into components/Card3D.js (~530 lines)
  • pages/cards.js drops from ~1,505 → ~974 lines; behavior unchanged (AuthenticatedCards still renders CardItem)
  • Fix latent scope bug: Card3D now accepts useManaSvg prop instead of referencing parent manaSymbolSettings

Test plan

  • npm run lint
  • npm run test:run (80/80)
  • Smoke on /cards (authenticated grid unchanged — still uses CardItem)

Follow-ups

  • Brief 2: extract PublicCardsView
  • Brief 3: extract AuthenticatedCards / hook+view split

Made with Cursor

## Summary - Extract `Card3D` and internal `CardBack` from `pages/cards.js` into `components/Card3D.js` (~530 lines) - `pages/cards.js` drops from ~1,505 → ~974 lines; behavior unchanged (`AuthenticatedCards` still renders `CardItem`) - Fix latent scope bug: `Card3D` now accepts `useManaSvg` prop instead of referencing parent `manaSymbolSettings` ## Test plan - [x] `npm run lint` - [x] `npm run test:run` (80/80) - [ ] Smoke on `/cards` (authenticated grid unchanged — still uses `CardItem`) ## Follow-ups - Brief 2: extract `PublicCardsView` - Brief 3: extract `AuthenticatedCards` / hook+view split Made with [Cursor](https://cursor.com)
vercel[bot] commented 2026-06-02 22:58:09 -04:00 (Migrated from github.com)

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

Project Deployment Actions Updated (UTC)
tcg-vault Ready Ready Preview, Comment Jun 3, 2026 2:58am

Request Review

[vc]: #ZBI1k+clRDx7qAV8kNKSFtnyCBLAAUa+LgBwhUWc9nc=:eyJpc01vbm9yZXBvIjp0cnVlLCJ0eXBlIjoiZ2l0aHViIiwicHJvamVjdHMiOlt7Im5hbWUiOiJ0Y2ctdmF1bHQiLCJwcm9qZWN0SWQiOiJwcmpfRjZXOEVvRkd3Y0g3aWVGcnRvRlNlOXdVVkFhNSIsImxpdmVGZWVkYmFjayI6eyJyZXNvbHZlZCI6MCwidW5yZXNvbHZlZCI6MCwidG90YWwiOjAsImxpbmsiOiJ0Y2ctdmF1bHQtZ2l0LXJlZmFjdG9yLWNhcmRzLTQ5NTBiYS1yYW5kYWxsLXN0aWxsd2VsbHMtcHJvamVjdHMudmVyY2VsLmFwcCJ9LCJpbnNwZWN0b3JVcmwiOiJodHRwczovL3ZlcmNlbC5jb20vcmFuZGFsbC1zdGlsbHdlbGxzLXByb2plY3RzL3RjZy12YXVsdC8zbTdnQW1NanU5RkRQV3NRMTVuTG1zWDd0TUpCIiwicHJldmlld1VybCI6InRjZy12YXVsdC1naXQtcmVmYWN0b3ItY2FyZHMtNDk1MGJhLXJhbmRhbGwtc3RpbGx3ZWxscy1wcm9qZWN0cy52ZXJjZWwuYXBwIiwibmV4dENvbW1pdFN0YXR1cyI6IkRFUExPWUVEIn1dLCJyZXF1ZXN0UmV2aWV3VXJsIjoiaHR0cHM6Ly92ZXJjZWwuY29tL3ZlcmNlbC1hZ2VudC9yZXF1ZXN0LXJldmlldz9vd25lcj12YXJ1dGFzdSZyZXBvPXRjZy12YXVsdCZwcj03NyJ9 The latest updates on your projects. Learn more about [Vercel for GitHub](https://vercel.link/github-learn-more). | Project | Deployment | Actions | Updated (UTC) | | :--- | :----- | :------ | :------ | | [tcg-vault](https://vercel.com/randall-stillwells-projects/tcg-vault) | ![Ready](https://vercel.com/static/status/ready.svg) [Ready](https://vercel.com/randall-stillwells-projects/tcg-vault/3m7gAmMju9FDPWsQ15nLmsX7tMJB) | [Preview](https://tcg-vault-git-refactor-cards-4950ba-randall-stillwells-projects.vercel.app), [Comment](https://vercel.live/open-feedback/tcg-vault-git-refactor-cards-4950ba-randall-stillwells-projects.vercel.app?via=pr-comment-feedback-link) | Jun 3, 2026 2:58am | <a href="https://vercel.com/vercel-agent/request-review?owner=varutasu&repo=tcg-vault&pr=77" rel="noreferrer"><picture><source media="(prefers-color-scheme: dark)" srcset="https://agents-vade-review.vercel.sh/request-review-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://agents-vade-review.vercel.sh/request-review-light.svg"><img src="https://agents-vade-review.vercel.sh/request-review-light.svg" alt="Request Review"></picture></a>
github-actions[bot] commented 2026-06-02 22:58:16 -04:00 (Migrated from github.com)

Pipeline Health

Build + CI gates

Gate Status
Vercel build (Preview) pass
CI: Lint pass
CI: Schema map fresh skipped
Preview smoke pass
Visual diff pass

Build runs on Vercel; this CI runs lint and schema-map drift only (no duplicate build).

Role reports

Role Status
Reviewer report pending
A11y audit pending
Design system audit pending

See individual comments above for details. This rollup updates automatically.

<!-- pipeline-rollup --> ## Pipeline Health ### Build + CI gates | Gate | Status | | --- | --- | | Vercel build (Preview) | ✅ pass | | CI: Lint | ✅ pass | | CI: Schema map fresh | ❌ skipped | | Preview smoke | ✅ pass | | Visual diff | ✅ pass | _Build runs on Vercel; this CI runs lint and schema-map drift only (no duplicate build)._ ### Role reports | Role | Status | | --- | --- | | Reviewer report | ⏳ pending | | A11y audit | ⏳ pending | | Design system audit | ⏳ pending | See individual comments above for details. This rollup updates automatically.
github-actions[bot] commented 2026-06-02 22:59:19 -04:00 (Migrated from github.com)

Visual Diff

Screenshots and diffs uploaded as artifacts: view run

If intentional changes: update snapshots locally with npx playwright test --project=visual --update-snapshots and commit.

## Visual Diff Screenshots and diffs uploaded as artifacts: [view run](https://github.com/varutasu/tcg-vault/actions/runs/26860960453) If intentional changes: update snapshots locally with `npx playwright test --project=visual --update-snapshots` and commit.
Sign in to join this conversation.
No description provided.