Skip to content

[Bug] Slash-command suggestions are clipped by the composer DockCard #524

@Astro-Han

Description

@Astro-Han

What happened?

Typing / in the Electron/home composer changes the prompt visual state, but the slash-command suggestion menu is no longer visible or interactable. Previously the composer showed command suggestions such as /open and other supported slash commands.

This appears to be a regression from PR #508 (b136aafbe, composer rewrite / slice 10). The slash-command state and command data still exist, but the popover is clipped after the composer moved inside the new joined DockCard shell.

Which area seems affected?

UI or design system

How much does this affect you?

Breaks an important workflow

Steps to reproduce

  1. Open PawWork Electron or the app E2E shell.
  2. Go to a new session/home composer.
  3. Click the prompt input.
  4. Type / or /open.
  5. Observe that the input changes visual state, but the slash-command suggestion menu does not appear above the composer.

What did you expect to happen?

The slash-command suggestion popover should appear above the composer, showing matching commands such as /open, and the suggestions should be visible and clickable/keyboard-selectable.

PawWork version

Current dev after PR #508 / commit b136aafbe.

OS version

macOS / Electron. Reproduced in Chromium E2E against the app shell.

Can you reproduce it again?

Yes, every time

Diagnostics

Observed source path:

  • Slash trigger path still exists: packages/app/src/components/prompt-input/editor-input.ts detects ^/(\S*)$, calls slashOnInput, then sets store.popover = "slash".
  • Slash command data still exists: packages/app/src/components/prompt-input/popover-controllers.ts builds slashCommands from command.options and sync.data.command.
  • Popover render still exists: packages/app/src/components/prompt-input/slash-popover.tsx renders [data-component="prompt-slash-popover"] with absolute -top-2 -translate-y-full.

Likely root cause:

[data-dock="card"] {
  overflow: hidden;
  position: relative;
  z-index: 10;
}

Because PromptPopover is still absolutely positioned upward from inside the prompt input, it is clipped by the parent DockCard. The state opens, but the visible menu is cut off.

Verification run:

bun --cwd packages/app test:e2e e2e/prompt/prompt-slash-open.spec.ts --project=chromium

Result: fails. Playwright resolves [data-slash-id="file.open"], proving the slash item exists in the DOM, but hover() times out because the visible page heading intercepts pointer events. Screenshot shows the /open text in the composer with no visible command menu.

Fix boundary:

  • Do not change the slash command data path.
  • Prefer moving/portaling PromptPopover outside the clipped DockCard or mounting it at the composer-column overlay layer.
  • Avoid simply removing DockCard's overflow: hidden unless the joined-card rounding/segment clipping contract is rechecked, because that overflow may be intentional for the slice 10 card shell.

Related: PR #508, issue #440 slice 10.

Repair options

Preferred repair should preserve the joined-card clipping contract from slice 10. Do not fix this by simply removing DockCard's overflow: hidden unless the rounded-card and segment clipping behavior is revalidated.

Option Scope Trade-off
A. Portal PromptPopover to body or a shell/composer overlay container More robust Requires fixed-position coordinates, z-index, outside-click / Escape behavior, and scroll/resize positioning checks. Best long-term path because it avoids the same clipping class for future composer popovers.
B. Lift PromptPopover out of DockCard and mount it as a composer-column sibling Smaller patch Must rebase the absolute positioning against the new parent. Good fast fix if it keeps current / and @ popovers visible, but may still need a portal cleanup during the later shell/layout slice.
C. Remove DockCard overflow: hidden Avoid Smallest diff, but likely breaks the joined-card rounded-corner / segmented-card visual contract introduced by PR #508.

Suggested default: choose A if implementation time allows; choose B only as a bounded fast fix and call out that 17b shell work may still replace it with a portal/overlay primitive.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P1High priorityappApplication behavior and product flowsbugSomething isn't workinguiDesign system and user interface

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions