Skip to content

[WC-3628]: fix combobox menu hidden behind the next tree node - #2535

Open
r0b1n wants to merge 1 commit into
mainfrom
r0b1n/combobox-popup-in-tree-node
Open

r0b1n wants to merge 1 commit into
mainfrom
r0b1n/combobox-popup-in-tree-node

Conversation

@r0b1n

@r0b1n r0b1n commented Nov 17, 2026

Copy link
Copy Markdown
Collaborator

Pull request type

Bug fix (non-breaking change which fixes an issue)


Description

In Tree Node v2, a combo box placed in a node could open its menu underneath the next node, so part of the option list was hidden. Identically configured combo boxes behaved differently: a menu that stayed inside its own node, or had no node after it, looked fine, while a menu that reached into the next node was covered.

Cause: .widget-tree-node-v2-body had will-change: grid-template-rows, opacity. will-change: opacity makes every node body its own stacking context, even when nothing animates, so the menu's z-index only competed inside its own node, and later nodes were painted over it.

Fix:

  • Remove will-change. It gave no real benefit: grid-template-rows can't be composited, and the opacity hint only kept one extra layer per expandable node. The transition still drives the animation.
  • Add .widget-tree-node-v2-body:has([data-overlay-content]) { position: relative; z-index: 1 }. While the opacity transition runs (~200ms) the body is a stacking context again; this lifts the body containing an open popup above its siblings, at every nesting level. It's the same approach as the data grid header cells (.th:has([data-overlay-content]) in _datagrid.scss).

What should be covered while testing?

  • A Tree Node with a parent association (v2) and combo boxes in the node content: open the combo box of a node followed by other nodes, including nested child nodes. The menu should show above the following nodes.
  • Expanding and collapsing nodes still animates as before.

will-change: opacity made every node body its own stacking context, so an
open combobox menu was painted under the following node. Drop will-change
and lift the body that contains an open popup ([data-overlay-content]),
which also covers the short window while the opacity transition runs.
@r0b1n
r0b1n requested a review from a team as a code owner November 17, 2026 09:06
@github-actions

Copy link
Copy Markdown
Contributor

AI Code Review

✅ Approved — no issues found


What was reviewed

File Change
packages/pluggableWidgets/tree-node-web/src/components/v2/ui/TreeNodeV2.scss Removed will-change from the v2 node body. Added :has([data-overlay-content]) to raise a body that contains an open popup.
packages/pluggableWidgets/tree-node-web/CHANGELOG.md Added a user-facing "Fixed" entry under Unreleased.

Skipped (out of scope): dist/, pnpm-lock.yaml

CI: pending: Run code quality check, Plan E2E matrix, sigridci · unrelated failures: security/snyk (external scanner)


Positives

  • The :has([data-overlay-content]) approach matches the existing data grid header cell fix in _datagrid.scss. Combobox sets data-overlay-content only while the menu is open, so the selector matches.
  • The changelog entry describes behavior for app developers and follows the repo voice.
  • The PR description explains the root cause: will-change: opacity creates a stacking context for every node body.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants