feat(pwa): rebuild /profile against DS primitives + view/edit toggle (#142) #169
No reviewers
Labels
No labels
area:auth
area:ci
area:db
area:infra
area:native
area:pwa
area:service
epic
feature
foundation
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
james/carol!169
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "142-profile-ds-rebuild"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #142.
Summary
/profilenow opens read-only. A page-levelEdit(secondary, pencil-led) reveals form controls; the header flips to ghostCancel+ primaryDone. Done submits the basics form if dirty (re-using the existing PUT) and exits; Cancel reverts the form to the cached profile and exits.Field+Input+Textarea.viewHintcopy. Edit mode shows the avatar +Upload(secondary) +Remove(ghost) + the format/size hint. Upload is still one-shot — the upload itself is the commit, no buffer-on-Done.Badge(kind) · value · label. Edit mode adds a pencil + trashIconButtonpair per row; the pencil expands that row into an inline form (Select + value + label + Save/Cancel). A dashed add-row at the bottom of the list lets the user POST a new contact. Per-row mutations stay eager — Done is not a bulk-commit for contacts.profile.module.csscarries the layout, mono-eyebrow read rows, picture frame, and contact-row patterns.forwardRef+useImperativeHandlebridge connects the page-level Done/Cancel to the BasicsSection's TanStack Form, keeping the form's complex typing internal to the component while letting the page drivesubmitIfDirty()/reset()imperatively.picture.uploadButton+picture.viewHintkeys inmessages/en.json; existing keys re-used.Server flows untouched:
/api/profilePUT,/api/profile/contactsPOST/PATCH/DELETE,/api/profile/picturePOST/DELETE all see identical request shapes. Correctness-over-optimistic discipline from #21 is preserved — every mutation still invalidates["profile"]and waits.Test plan
npm run lint/npx tsc --noEmit/npm testall clean (440 passed).style="color:transparent"from the sidebar<img>(Next.js Image default; not from this page).🤖 Generated with Claude Code
Trivy (container image)
Threshold:
high· Total findings: 121 · At/above threshold: 16.27.0, 7.28.0, 8.5.0📊 Test coverage
Patch coverage: no testable lines changed.
Overall (
app/,lib/,db/, excluding UI per ADR-0019):Soft thresholds per ADR-0019. Coverage is informational and does not block merge.