Components
Media library
Manage reusable visual assets with searchable metadata and recognizable image previews.
On this page
Purpose and placement
Manage reusable visual assets with searchable metadata and recognizable image previews.
Anatomy
| Part | Behavior |
|---|---|
| Filter controls | Query, subject and usage context. |
| Asset card/row | Image preview, descriptive identity and metadata. |
| Record actions | Edit or use the existing asset. |
Configuration and contract
| Input or decision | Implementation |
|---|---|
| Media record | cdnUrl, fileName, dimensions, size, alt/credit and classification. |
| Source route | /admin/media uses media records from the application data boundary. |
| Capture records | Existing source photos with synthetic metadata; not a live inventory export. |
States and feedback
- Populated library light/dark and desktop/phone.
- Full-page records capture.
- Empty filter and broken delivery should have explicit feedback.
Usage rules
- Use accurate image ratio; object-fit cropping is acceptable, arbitrary stretching is not.
- Retain photographer and usage information.
- Query/filter UI appearance does not prove filtering when isolated fixture reads ignore conditions.
Accessibility and verification
Check image alternatives, descriptive record links and filter labels. Ensure metadata remains available without hovering.
Source references
| File | Responsibility |
|---|---|
| app/admin/(shell)/media/page.tsx | Audited Townwell implementation; use this file when extending this interface. |
| lib/media-library.ts | Audited Townwell implementation; use this file when extending this interface. |
Examples from the app
Actual Boise Today and Townwell UI with synthetic editorial, business, review, media metadata and analytics. Existing Boise imagery; no live data changes. Captured at 2× resolution or higher. Select an image to inspect it full size.
Related topics
Source audit: 2026-10-07 · Revision ce8bc72b96da · Documentation v0.1