Wire the shipped ColorSimplificationPreview component into the Settings modal — currently inlines a "render here (separate issue)" TODO block #133

Closed
opened 2026-10-03 03:58:27 +00:00 by Mark · 1 comment
Owner

Finding

src/components/workspace/ColorSimplificationPreview.tsx is a complete, working dialog component for the full-size color simplification preview. It has no importers. The Settings modal inlines a placeholder block with a "render here (separate issue)" TODO comment instead.

The Settings modal's ColorSimplificationSection shows a thumbnail. Clicking the thumbnail is supposed to open the full-size preview. The current inline implementation just shows a stub div saying "Full color simplification preview UI will render here (separate issue)." The shipped ColorSimplificationPreview component IS the implementation; it just needs to be wired in.

Where

  • Shipped component: src/components/workspace/ColorSimplificationPreview.tsx (full file, 40 lines, with prop types open, onClose, imageSrc, colorSensitivity)
  • Inlined placeholder: src/components/workspace/ColorSimplificationSection.tsx:79-80 ("Full color simplification preview UI will render here (separate issue).")
  • Wiring point: src/components/workspace/SettingsModal.tsx (passes fullPreviewOpen to ColorSimplificationSection)

Suggested fix shape

Replace the inlined placeholder div in ColorSimplificationSection.tsx with a render of <ColorSimplificationPreview>. The component already has the right prop shape; ColorSimplificationSection already has open / onClose / imageSrc / colorSensitivity available to forward. The wiring is mechanical.

After the fix:

  • User opens Settings → Color Simplification Preview section → thumbnail visible
  • User clicks thumbnail → full-size preview opens
  • The full preview is the same <ColorPreview> component rendered at a larger size, with the same imageSrc and colorSensitivity

This was the explicit promise of issue #124 ("Settings modal: add Color simplification preview section") when it closed. The section shipped. The full preview path did not.

Severity

Medium. The user reaches the entry point, the click does the right thing (opens a modal), but the modal contents are a TODO comment instead of the actual feature. The "render here (separate issue)" message is a production TODO.

Discovered by

Gap analysis (2026-10-02) of unreached components.

  • #124 (closed) — Settings modal Color Simplification Preview section. The section itself is fine; the full-preview path is the gap.
  • #121 (closed) — added the live client-side quantization. The output of that quantization should be visible in the full preview.
## Finding `src/components/workspace/ColorSimplificationPreview.tsx` is a complete, working dialog component for the full-size color simplification preview. **It has no importers.** The Settings modal inlines a placeholder block with a "render here (separate issue)" TODO comment instead. The Settings modal's `ColorSimplificationSection` shows a thumbnail. Clicking the thumbnail is supposed to open the full-size preview. The current inline implementation just shows a stub div saying "Full color simplification preview UI will render here (separate issue)." The shipped `ColorSimplificationPreview` component IS the implementation; it just needs to be wired in. ## Where - Shipped component: `src/components/workspace/ColorSimplificationPreview.tsx` (full file, 40 lines, with prop types `open`, `onClose`, `imageSrc`, `colorSensitivity`) - Inlined placeholder: `src/components/workspace/ColorSimplificationSection.tsx:79-80` ("Full color simplification preview UI will render here (separate issue).") - Wiring point: `src/components/workspace/SettingsModal.tsx` (passes `fullPreviewOpen` to `ColorSimplificationSection`) ## Suggested fix shape Replace the inlined placeholder div in `ColorSimplificationSection.tsx` with a render of `<ColorSimplificationPreview>`. The component already has the right prop shape; `ColorSimplificationSection` already has `open` / `onClose` / `imageSrc` / `colorSensitivity` available to forward. The wiring is mechanical. After the fix: - User opens Settings → Color Simplification Preview section → thumbnail visible - User clicks thumbnail → full-size preview opens - The full preview is the same `<ColorPreview>` component rendered at a larger size, with the same `imageSrc` and `colorSensitivity` This was the explicit promise of issue #124 ("Settings modal: add Color simplification preview section") when it closed. The section shipped. The full preview path did not. ## Severity Medium. The user reaches the entry point, the click does the right thing (opens a modal), but the modal contents are a TODO comment instead of the actual feature. The "render here (separate issue)" message is a production TODO. ## Discovered by Gap analysis (2026-10-02) of unreached components. ## Related - #124 (closed) — Settings modal Color Simplification Preview section. The section itself is fine; the full-preview path is the gap. - #121 (closed) — added the live client-side quantization. The output of that quantization should be visible in the full preview.
Author
Owner

Wired ColorSimplificationPreview into ColorSimplificationSection — the inline "render here (separate issue)" TODO block is replaced by the shipped dialog component.

  • ColorSimplificationSection now imports ColorSimplificationPreview and renders it inside the fullPreviewOpen slot, forwarding imageSrc / colorSensitivity and a new onCloseFullPreview prop.
  • SettingsModal wires onCloseFullPreview={() => setShowFullColorPreview(false)} so the dialog Close button + click-outside both clear the modal state.
  • The color-simplification-full-preview testid (locked in by #124) is preserved on the wrapping div; the shipped dialog adds its own color-simplification-preview testid inside.
  • 8/8 ColorSimplificationSection tests pass; two new regression tests guard the wiring (shipped dialog reachable when fullPreviewOpen=true, Close button fires onCloseFullPreview).

Fix commit: 0c41453 on main.

Wired ColorSimplificationPreview into ColorSimplificationSection — the inline "render here (separate issue)" TODO block is replaced by the shipped dialog component. - ColorSimplificationSection now imports ColorSimplificationPreview and renders it inside the fullPreviewOpen slot, forwarding imageSrc / colorSensitivity and a new onCloseFullPreview prop. - SettingsModal wires onCloseFullPreview={() => setShowFullColorPreview(false)} so the dialog Close button + click-outside both clear the modal state. - The color-simplification-full-preview testid (locked in by #124) is preserved on the wrapping div; the shipped dialog adds its own color-simplification-preview testid inside. - 8/8 ColorSimplificationSection tests pass; two new regression tests guard the wiring (shipped dialog reachable when fullPreviewOpen=true, Close button fires onCloseFullPreview). Fix commit: 0c41453 on main.
Mark closed this issue 2026-10-03 04:36:44 +00:00
Sign in to join this conversation.
No description provided.