Restore identity photo previews in Flutter Web #71

Merged
tech merged 4 commits from kyc-69 into main 2026-10-23 10:51:08 +00:00
Owner

Accepted ID/selfie photos could show “This image is damaged” because Photo's read-only byte view reached Flutter Web's decoder. A synthetic valid image reproduced _UnmodifiableUint8ListView is not a subtype of NativeUint8List in CanvasKit's typed-array conversion.

The preview now creates a compatible byte copy while preserving the immutable model, decode limit and cache eviction. Actual preview failures have accurate EN/RU recovery copy and an isolated live-region announcement. Six regressions await actual decoding and cover JPEG/PNG, replacement/removal, cache cleanup, review re-entry and narrow/large-text recovery. Existing KYC measurement is reused without photo data or raw exception telemetry.

The complete contribution was reviewed; no further defects were found. Latest main (ec4115d) is integrated. Final validation: changed Dart format check and app analyzer pass; all six Chrome regressions and all 240 tests in make test-frontend pass on the integrated code. The earlier standalone release web build and Wasm dry run also passed. Safari/native assistive-technology checks and preview-only telemetry limitations are documented in docs/ux/photo-preview.md.

Fixes #69. Primary module: kyc; frontend only. User authorized merging and rebuilding the frontend from clean, pulled main.

Accepted ID/selfie photos could show “This image is damaged” because Photo's read-only byte view reached Flutter Web's decoder. A synthetic valid image reproduced `_UnmodifiableUint8ListView is not a subtype of NativeUint8List` in CanvasKit's typed-array conversion. The preview now creates a compatible byte copy while preserving the immutable model, decode limit and cache eviction. Actual preview failures have accurate EN/RU recovery copy and an isolated live-region announcement. Six regressions await actual decoding and cover JPEG/PNG, replacement/removal, cache cleanup, review re-entry and narrow/large-text recovery. Existing KYC measurement is reused without photo data or raw exception telemetry. The complete contribution was reviewed; no further defects were found. Latest main (ec4115d) is integrated. Final validation: changed Dart format check and app analyzer pass; all six Chrome regressions and all 240 tests in `make test-frontend` pass on the integrated code. The earlier standalone release web build and Wasm dry run also passed. Safari/native assistive-technology checks and preview-only telemetry limitations are documented in `docs/ux/photo-preview.md`. Fixes #69. Primary module: kyc; frontend only. User authorized merging and rebuilding the frontend from clean, pulled main.
tech added the frontend label 2026-10-23 10:33:42 +00:00
tech self-assigned this 2026-10-23 10:33:42 +00:00
tech added 1 commit 2026-10-23 10:33:42 +00:00
tech added 1 commit 2026-10-23 10:33:53 +00:00
tech added 2 commits 2026-10-23 10:50:44 +00:00
tech merged commit de449d53bf into main 2026-10-23 10:51:08 +00:00
Sign in to join this conversation.
No Reviewers
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: tech/sxchnge#71