Components
Saved content
Let an authenticated reader save an item to a named list while keeping authentication and persistence explicit.
On this page
Purpose and placement
Let an authenticated reader save an item to a named list while keeping authentication and persistence explicit.
Anatomy
| Part | Behavior |
|---|---|
| Trigger | Save action with expanded-state context. |
| List choices | Existing lists and new-list entry. |
| Authentication | Login-required path for visitors. |
| Feedback | Request errors and saved state. |
Configuration and contract
| Input or decision | Implementation |
|---|---|
| Identity | Use the source supported content identity rather than a title as the persistent key. |
| Persistence | Lists and membership are API-backed; client selection is not sufficient evidence of saved data. |
States and feedback
- Unauthenticated reader, authenticated lists, create-list flow and error recovery.
- Capture APIs report the visitor state; no private account or saved collection is captured.
Usage rules
- Keep the item context visible when requesting login.
- Avoid optimistic confirmation without a successful persistence contract.
Accessibility and verification
Source uses aria-expanded for the trigger. Verify dialog focus, keyboard list selection and error announcements before extending this flow.
Source references
| File | Responsibility |
|---|---|
| components/save-this-control.tsx | Audited Townwell implementation; use this file when extending this interface. |
| components/save-this-button.tsx | Audited Townwell implementation; use this file when extending this interface. |
| components/account/account-login-modal.tsx | Audited Townwell implementation; use this file when extending this interface. |
Related topics
Source audit: 2026-10-07 · Revision ce8bc72b96da · Documentation v0.1