show selected option value in variant selector label for a11y
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
parent
0fe48baaa8
commit
e226e64c0b
18
PROGRESS.md
18
PROGRESS.md
@ -21,7 +21,7 @@
|
|||||||
- Transactional emails (order confirmation, shipping notification)
|
- Transactional emails (order confirmation, shipping notification)
|
||||||
- Demo content polished and ready for production
|
- Demo content polished and ready for production
|
||||||
|
|
||||||
**Tier 1 MVP complete.** CI pipeline done. Hosting & deployment done (including observability). PageSpeed CI done (99-100 mobile, 97+ desktop). Usability fixes 16/18 done (remaining 2 are now tracked as features below). Shipping costs at checkout done.
|
**Tier 1 MVP complete.** CI pipeline done. Hosting & deployment done (including observability). PageSpeed CI done (99-100 mobile, 97+ desktop). Usability fixes done. Shipping costs at checkout done. Per-colour product images with gallery filtering done (both providers). Printful integration complete (sync, orders, shipping, webhooks, mockup enrichment, catalog colours).
|
||||||
|
|
||||||
## Task list
|
## Task list
|
||||||
|
|
||||||
@ -48,8 +48,7 @@ Plans: [admin-redesign.md](docs/plans/admin-redesign.md) | [setup-wizard.md](doc
|
|||||||
| ~~15~~ | ~~Setup wizard + admin tests~~ | 13 | 1.5h | done |
|
| ~~15~~ | ~~Setup wizard + admin tests~~ | 13 | 1.5h | done |
|
||||||
| ~~5~~ | ~~Search (functional search with results)~~ | — | 3-4h | done |
|
| ~~5~~ | ~~Search (functional search with results)~~ | — | 3-4h | done |
|
||||||
| ~~17~~ | ~~Wire shop LiveViews to DB queries (replace PreviewData indirection)~~ | — | 2-3h | done |
|
| ~~17~~ | ~~Wire shop LiveViews to DB queries (replace PreviewData indirection)~~ | — | 2-3h | done |
|
||||||
| | **Next up** | | | |
|
| ~~16~~ | ~~Per-colour images + gallery filtering~~ | — | 3h | done |
|
||||||
| 16 | Variant refinement with live data | — | 2-3h | |
|
|
||||||
| ~~18~~ | ~~Shipping costs at checkout~~ | 17 | 4h | done |
|
| ~~18~~ | ~~Shipping costs at checkout~~ | 17 | 4h | done |
|
||||||
| | **Printful integration** | | | |
|
| | **Printful integration** | | | |
|
||||||
| ~~24~~ | ~~Printful HTTP client~~ | — | 1.5h | done |
|
| ~~24~~ | ~~Printful HTTP client~~ | — | 1.5h | done |
|
||||||
@ -58,6 +57,7 @@ Plans: [admin-redesign.md](docs/plans/admin-redesign.md) | [setup-wizard.md](doc
|
|||||||
| ~~27~~ | ~~Printful shipping rates~~ | 25 | 1.5h | done |
|
| ~~27~~ | ~~Printful shipping rates~~ | 25 | 1.5h | done |
|
||||||
| ~~28~~ | ~~Printful mockup generation worker~~ | 25 | — | done (existing pipeline) |
|
| ~~28~~ | ~~Printful mockup generation worker~~ | 25 | — | done (existing pipeline) |
|
||||||
| ~~29~~ | ~~Printful webhooks~~ | 25 | 1.5h | done |
|
| ~~29~~ | ~~Printful webhooks~~ | 25 | 1.5h | done |
|
||||||
|
| | **Next up** | | | |
|
||||||
| 30 | Admin UI tweaks for Printful | 25 | 1h | |
|
| 30 | Admin UI tweaks for Printful | 25 | 1h | |
|
||||||
| 31 | Printful tests + integration testing | 24-30 | 4.5h | |
|
| 31 | Printful tests + integration testing | 24-30 | 4.5h | |
|
||||||
| | **CSS migration (after admin stable)** | | | |
|
| | **CSS migration (after admin stable)** | | | |
|
||||||
@ -67,7 +67,7 @@ Plans: [admin-redesign.md](docs/plans/admin-redesign.md) | [setup-wizard.md](doc
|
|||||||
| 22 | Remove DaisyUI | 21 | 1h | |
|
| 22 | Remove DaisyUI | 21 | 1h | |
|
||||||
| 23 | CSS migration tests + visual QA | 22 | 1h | |
|
| 23 | CSS migration tests + visual QA | 22 | 1h | |
|
||||||
|
|
||||||
**Total remaining: ~39-45 hours across ~18 sessions**
|
**Total remaining: ~13-15 hours across ~7-8 sessions** (admin Printful tweaks, Printful tests, CSS migration)
|
||||||
|
|
||||||
## Usability fixes (16/18 done)
|
## Usability fixes (16/18 done)
|
||||||
|
|
||||||
@ -161,6 +161,13 @@ See: [docs/plans/image-optimization.md](docs/plans/image-optimization.md) for im
|
|||||||
- Filters to only published variants (not full catalog)
|
- Filters to only published variants (not full catalog)
|
||||||
- Price updates on variant change
|
- Price updates on variant change
|
||||||
- Startup recovery for stale sync status
|
- Startup recovery for stale sync status
|
||||||
|
- [x] Per-colour product images (0fe48ba)
|
||||||
|
- `color` column on product_images, tagged during sync (both providers)
|
||||||
|
- PDP gallery filters by selected colour (hero gets all, others front+back)
|
||||||
|
- Printify options filtered to enabled variants only (not full blueprint)
|
||||||
|
- Hero/default colour ordered first in swatch list
|
||||||
|
- MockupEnricher generates per-colour mockups for Printful
|
||||||
|
- Printful catalog API fetched for hex colour codes
|
||||||
|
|
||||||
#### Future Enhancements (post-MVP)
|
#### Future Enhancements (post-MVP)
|
||||||
- [ ] Print provider insights — fetch provider name/location via `get_print_providers/1` during sync, store in `provider_data`. Show "Ships from UK/US" on product pages. Admin dashboard showing which providers are used, their locations, and shipping cost analysis to help optimise product selection for domestic fulfilment and combined postage savings
|
- [ ] Print provider insights — fetch provider name/location via `get_print_providers/1` during sync, store in `provider_data`. Show "Ships from UK/US" on product pages. Admin dashboard showing which providers are used, their locations, and shipping cost analysis to help optimise product selection for domestic fulfilment and combined postage savings
|
||||||
@ -350,6 +357,9 @@ See: [docs/plans/page-builder.md](docs/plans/page-builder.md) for design
|
|||||||
|
|
||||||
| Feature | Commit | Notes |
|
| Feature | Commit | Notes |
|
||||||
|---------|--------|-------|
|
|---------|--------|-------|
|
||||||
|
| Per-colour images + gallery filtering | 0fe48ba | colour column on product_images, per-colour mockup enrichment, PDP gallery filtering, Printify option filtering, hero colour ordering, 821 tests |
|
||||||
|
| Printful catalog colours | 4e19d4c | Fetch hex codes from catalog product API during sync, cached per catalog_product_id |
|
||||||
|
| Printful integration | 3c788bf..24d61f7 | HTTP client, provider (sync + orders), shipping rates, webhooks, mockup enrichment, admin UI |
|
||||||
| Shipping costs at checkout | — | Rates, exchange rates, country detection, Stripe shipping options, 780 tests |
|
| Shipping costs at checkout | — | Rates, exchange rates, country detection, Stripe shipping options, 780 tests |
|
||||||
| Search + admin polish | 44933ac | Search race condition fix, image 304s, LIKE fallback, admin header icon, 757 tests |
|
| Search + admin polish | 44933ac | Search race condition fix, image 304s, LIKE fallback, admin header icon, 757 tests |
|
||||||
| DB wiring + search UX | 57c3ba0 | Shop LiveViews use DB queries, search keyboard nav, ARIA, 755 tests |
|
| DB wiring + search UX | 57c3ba0 | Shop LiveViews use DB queries, search keyboard nav, ARIA, 755 tests |
|
||||||
|
|||||||
@ -1490,9 +1490,12 @@ defmodule SimpleshopThemeWeb.ShopComponents.Product do
|
|||||||
def variant_selector(assigns) do
|
def variant_selector(assigns) do
|
||||||
~H"""
|
~H"""
|
||||||
<div class="mb-6">
|
<div class="mb-6">
|
||||||
<label class="block font-semibold mb-2" style="color: var(--t-text-primary);">
|
<div class="block font-semibold mb-2" style="color: var(--t-text-primary);">
|
||||||
{@option_type.name}
|
{@option_type.name}<span
|
||||||
</label>
|
:if={@selected}
|
||||||
|
style="color: var(--t-text-secondary); font-weight: normal;"
|
||||||
|
>: {@selected}</span>
|
||||||
|
</div>
|
||||||
<div class="flex flex-wrap gap-2">
|
<div class="flex flex-wrap gap-2">
|
||||||
<%= if @option_type.type == :color do %>
|
<%= if @option_type.type == :color do %>
|
||||||
<.color_swatch
|
<.color_swatch
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user