67 lines
2.8 KiB
Markdown
67 lines
2.8 KiB
Markdown
---
|
|
status: diagnosed
|
|
phase: 29-image-presentation
|
|
source: [29-01-SUMMARY.md, 29-02-SUMMARY.md, 29-03-SUMMARY.md, 29-04-SUMMARY.md]
|
|
started: 2026-04-12T19:10:00Z
|
|
updated: 2026-04-13T12:15:00Z
|
|
---
|
|
|
|
## Current Test
|
|
|
|
[testing complete]
|
|
|
|
## Tests
|
|
|
|
### 1. Images use fit-within instead of crop
|
|
expected: Browse any page with item/catalog cards. Images should fit inside the frame without cropping — full image visible, no parts cut off.
|
|
result: pass
|
|
|
|
### 2. Dominant color background fill
|
|
expected: Where an image doesn't fill the entire frame, the empty space is filled with a color extracted from the image (not white or gray).
|
|
result: pass
|
|
|
|
### 3. Crop editor on item detail
|
|
expected: Open an item that has an image. In edit mode, you should see a crop icon button next to the trash icon, positioned as an overlay on the image. Clicking it opens a crop editor with zoom slider.
|
|
result: pass
|
|
reported: "Initially reported as issue but confirmed working on re-test — false claim"
|
|
|
|
### 4. Crop editor on image upload
|
|
expected: Upload a new image to an item. After the upload completes, a crop editor should appear automatically. After cropping, the preview should reflect the crop immediately.
|
|
result: issue
|
|
reported: "crop editor opens on upload correctly, but after cropping the cropped image isn't shown in the edit state always — after clicking save it is shown correctly"
|
|
severity: minor
|
|
|
|
### 5. Crop settings persist
|
|
expected: Adjust the crop on an item image, save it. Navigate away and come back — image displays with saved crop settings.
|
|
result: pass
|
|
|
|
### 6. Consistency across surfaces
|
|
expected: All image surfaces use the same fit-within + dominant color treatment.
|
|
result: pass
|
|
|
|
## Summary
|
|
|
|
total: 6
|
|
passed: 5
|
|
issues: 1
|
|
pending: 0
|
|
skipped: 0
|
|
blocked: 0
|
|
|
|
## Gaps
|
|
|
|
- truth: "Cropped image preview should update in edit state immediately after cropping"
|
|
status: failed
|
|
reason: "User reported: cropped image not shown in edit state after cropping, but renders correctly after save"
|
|
severity: minor
|
|
test: 4
|
|
root_cause: "ImageUpload component does not store or forward crop values to its GearImage preview after crop editor closes. onCropChange sends to server but no local state is updated. GearImage in ImageUpload receives zero crop props. Only after form save + query refetch do crop values appear."
|
|
artifacts:
|
|
- path: "src/client/components/ImageUpload.tsx"
|
|
issue: "GearImage preview (line 110-114) rendered without cropZoom/cropX/cropY props; no local crop state exists"
|
|
- path: "src/client/routes/items/$itemId.tsx"
|
|
issue: "onCropChange (line 288-293) fires server mutation but updates no local/form state"
|
|
missing:
|
|
- Add local crop state in ImageUpload that gets set from crop editor result and passed as props to GearImage
|
|
debug_session: ".planning/debug/crop-preview-edit-state.md"
|