Skip to content

feat(ui): redesign phase 6a — Export, Settings and Shortcuts dialogs, keyboard shortcuts - #31

Merged
provos merged 2 commits into
mainfrom
feat/redesign-dialogs
Sep 26, 2026
Merged

provos merged 2 commits into
mainfrom
feat/redesign-dialogs

Conversation

@provos

@provos provos commented Sep 26, 2026

Copy link
Copy Markdown
Owner

Phase 6 (first half) of the Claude Design handoff (docs/redesign/HANDOFF.md §3, §6, §8).

  • ExportDialog: opened by the Export step, the header's Export… button or Ctrl+E.
    • The 3D scene pane has:
      • camera distance, max distance and focal length, mirrored from the Preview panel and sharing its camera draft;
      • displacement and depth of field;
      • a ground summary with an Edit button that jumps to the Ground step;
      • Upscale textures;
      • Create scene / Download glTF, and "Scene ready · View in 3D" once a scene exists.
    • The Animation pane has frames (with a duration hint) and Render animation.
  • SettingsDialog: opened by the gear or Ctrl+,.
    • Sections, with a jump nav: Inpainting (model, server + Test connection, ComfyUI workflow, API key + Test), Depth (model), Masks (padding, blur), Slicing (number of slices), Project (Load / Save state), Appearance (Dark / Light).
    • Loading a state file closes the dialog. "Model settings" in the Inpaint panel and the empty state's "load a saved project" link open the matching section.
  • ShortcutsDialog (?) and the §6 shortcuts, handled on the app root:
    • They are ignored in text fields, except Ctrl+Enter, which still generates from the prompt fields.
    • Enter on a focused button activates the button.
    • Delete stays scoped to the focused layer list, so a stray key press can't delete a slice.
  • The dialogs are native modal <dialog>s that stay mounted, so their controls always exist. All existing test ids are kept, and the mirrored controls use new ids.
  • e2e driver: openTab('Export' | 'Configuration') opens the dialogs, the driver closes any dialog (Esc) before touching the workspace, and sliders/buttons inside the Export dialog open it on the right pane. The scenarios are unchanged.
  • Cleanup:
    • Removed the unused help tooltips.
    • Renamed the composite canvas layer's test id: it duplicated the Composite view tab's view-composite.

Still to come in 6b: toasts, job cards and job cancel (backend), the model-download detail line, the narrower Inspector, and removing the legacy CSS aliases.

Tests: vitest 373 passing, svelte-check clean, e2e 46/46 locally.

🤖 Generated with Claude Code

… keyboard shortcuts

- Export dialog (Export step, header Export, Ctrl+E): 3D scene pane with
  camera mirrored from Preview, displacement, depth of field, ground
  summary with Edit, upscale, Create scene / Download glTF, View in 3D;
  Animation pane with frames and Render.
- Settings dialog (gear, Ctrl+,): Inpainting, Depth, Masks, Slicing,
  Project and Appearance sections with a jump nav; loading a state file
  closes it.
- Shortcuts dialog (?) and the HANDOFF section 6 shortcuts, handled on the
  app root and ignored in text fields (Ctrl+Enter still generates from
  the prompts). Delete stays scoped to the layer list.
- Dialogs are native modal <dialog>s that stay mounted, so their values
  are always readable; existing test ids are kept.
- e2e driver: Export/Configuration map to the dialogs; it closes dialogs
  before touching the workspace.
- Drop the unused help tooltips; the composite canvas layer's test id no
  longer collides with the Composite view tab.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI lite review requested due to automatic review settings September 26, 2026 15:54

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

The dialog-driven UI/state refactor is consistently applied across components, tests, and the e2e driver, with only a minor shortcuts-label wording nit noted.

Review effort: Lite
Findings: 1 Low severity

Open (1)
What changed in this PR

Implements phase 6a of the redesign by moving Export/Settings/Shortcuts into native modal <dialog> components, centralizing keyboard shortcut handling at the app shell root, and updating UI state + tests/e2e driver to match the new interaction model.

Changes:

  • Replaces the former Inspector “Export” / “Configuration” panels with always-mounted modal dialogs (ExportDialog, SettingsDialog, ShortcutsDialog) driven by uiStore.dialog.
  • Adds an app-root keyboard shortcut handler (lib/shortcuts.ts) and wires Inpaint-specific actions via registerInpaintActions.
  • Updates unit tests and the Playwright Svelte UiDriver to open/close dialogs and keep scenarios frontend-neutral.
File Description
frontend/​src/​lib/​state/​ui.svelte.ts Refactors UI state to add dialog + settings section state; removes Export/Configuration from MainTab.
frontend/​src/​lib/​state/​ui.svelte.test.ts Updates and extends store tests for dialog behavior and Export step semantics.
frontend/​src/​lib/​shortcuts.ts Adds centralized keyboard shortcut handling and a shortcuts list for the dialog.
frontend/​src/​lib/​shortcuts.test.ts Adds comprehensive shortcut behavior tests (modifiers, text-field exclusions, dialog gating).
frontend/​src/​lib/​helpTexts.ts Removes unused legacy contextual help text constants.
frontend/​src/​lib/​components/​upload/​InputImagePanel.svelte Updates composite layer test id and routes empty-state “load project” to Settings dialog section.
frontend/​src/​lib/​components/​shell/​Shell.test.ts Adjusts shell tests for dialogs (Export/Settings) instead of Inspector tabs.
frontend/​src/​lib/​components/​shell/​Inspector.svelte Removes Export/Configuration panels from the Inspector; keeps only step panels.
frontend/​src/​lib/​components/​shell/​AppShell.svelte Mounts dialogs at the root and attaches keydown handling to the app container.
frontend/​src/​lib/​components/​shell/​AppHeader.svelte Switches Settings/Export header actions to open dialogs (with shortcut hints).
frontend/​src/​lib/​components/​shared/​HelpTooltip.test.ts Removes tests for the deleted HelpTooltip component.
frontend/​src/​lib/​components/​shared/​HelpTooltip.svelte Removes the (now-unused) HelpTooltip component implementation.
frontend/​src/​lib/​components/​shared/​Dialog.test.ts Adds tests for the shared native <dialog> wrapper behavior (open/close/backdrop/etc).
frontend/​src/​lib/​components/​shared/​Dialog.svelte Introduces a reusable native <dialog> wrapper tied to uiStore.dialog.
frontend/​src/​lib/​components/​inpainting/​InpaintPanel.svelte Registers inpaint shortcut actions and routes “Model settings” to the Settings dialog.
frontend/​src/​lib/​components/​export/​ExportTab.svelte Removes the old Export Inspector panel component.
frontend/​src/​lib/​components/​dialogs/​ShortcutsDialog.test.ts Adds tests validating dialog open behavior and shortcut list rendering.
frontend/​src/​lib/​components/​dialogs/​ShortcutsDialog.svelte Adds the shortcuts dialog UI, rendering SHORTCUTS.
frontend/​src/​lib/​components/​dialogs/​SettingsDialog.test.ts Adds tests for Settings dialog behavior, section nav, probes, persistence, and restore-close behavior.
frontend/​src/​lib/​components/​dialogs/​SettingsDialog.svelte Implements the Settings dialog UI + section nav and wiring to workflow actions.
frontend/​src/​lib/​components/​dialogs/​ExportDialog.test.ts Updates/expands export tests for dialog layout (tabs), camera draft mirroring, and “View in 3D”.
frontend/​src/​lib/​components/​dialogs/​ExportDialog.svelte Implements the Export dialog (3D scene + animation panes) and workflow hooks.
frontend/​src/​lib/​components/​config/​ConfigurationTab.test.ts Removes tests for the deleted ConfigurationTab panel.
frontend/​src/​lib/​components/​config/​ConfigurationTab.svelte Removes the old Configuration Inspector panel component.
e2e/​drivers/​svelte.ts Updates the UiDriver to open Export/Settings as dialogs and close dialogs before workspace interactions.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread frontend/src/lib/shortcuts.ts Outdated
{ keys: 'Ctrl+Enter', action: 'Generate candidates' },
{ keys: '1 2 3', action: 'Pick candidate' },
{ keys: 'A', action: 'Apply picked candidate' },
{ keys: 'I M L C', action: 'View: Input, depth Map, sLice, Composite' },
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@provos
provos merged commit 1781a37 into main Sep 26, 2026
1 check passed
@provos
provos deleted the feat/redesign-dialogs branch September 26, 2026 16:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants