Skip to content

fix(select): an NcSelect dropdown inside a modal is clickable - #561

Merged
rubenvdlinde merged 1 commit into
developmentfrom
fix/the-support-note-is-settled-for-every-seeded-account
Sep 6, 2026
Merged

fix(select): an NcSelect dropdown inside a modal is clickable#561
rubenvdlinde merged 1 commit into
developmentfrom
fix/the-support-note-is-settled-for-every-seeded-account

Conversation

@rubenvdlinde

Copy link
Copy Markdown
Contributor

All eleven remaining failures, one defect

Two specs, one cause — and a second, smaller one behind it.

NcSelect defaults appendToBody to true, so vue-select moves the open menu to <body> and positions it with inline styles. Its z-index reads var(--vs-dropdown-z-index), which nc-vue declares on body as 9999.

NcModal does not use a fixed z-index at all. It assigns one at runtime, counting up as modals open — measured 10005 for the first and 10010 for the second on one page. Every one of those is above 9999, so the modal always wins and the menu is drawn underneath it.

Why it survived three rounds of fixes

The failure never names the select. elementFromPoint() at the option's own centre returns whatever modal content happens to sit over it, so Playwright reported:

<p class="dashboard-config__hint"> ... subtree intercepts pointer events

and a reader goes looking at the hint. The interceptor named in the log is innocent.

⚠️ This is not the same bug as .dashboard-config__field--select in DashboardConfigModal.vue, and that rule cannot help. It raises the field so a menu rendered inside the modal clears the fields below it. This menu is not inside the modal at all.

Two obvious fixes both lose — measured, not assumed

attempt why it fails
.vs__dropdown-menu { z-index: 10100 } overridden by nc-vue's own same-specificity rule in _plugin-vue_export-helper-*.chunk.css, which loads after this file. The rule shipped in the bundle and the computed value stayed 9999.
:root { --vs-dropdown-z-index: 10100 } loses to nc-vue's declaration on body, which is more specific for everything inside it.

Setting the variable on the menu beats an inherited value whatever the source order, so this needs no !important.

The support note was settled for one user of two

global-setup.ts records it through the logged-in admin's own preference, and the marker is per user — so the suite settled it for exactly one of the people it logs in as.

With the z-index fixed, "recipient sees the shared dashboard in their switcher" was the last failure standing, and the call log named cn-support-dialog intercepting a toggle it also called visible, enabled and stable.

seed.sh now settles it for every seeded account, with occ — the only thing there that can write another user's preference, since the app's own endpoint writes the caller's. That mirrors the firstrunwizard block already above it, which documents this same shape for this same test.

Verified against a real instance, not reasoned about

spec before after
conditional-visibility-editor 7 failing on CI 13 passed of 13
dashboard-sharing 4 failing on CI 4 passed of 4

Upstream

The z-index collision belongs in nextcloud-vue, where the modal counter and the dropdown constant should be related rather than coincidental. This keeps the app usable meanwhile.

🤖 Generated with Claude Code

All eleven of launchpad's remaining e2e failures, across two specs, were one
defect wearing a misleading name — and a second, smaller one behind it.

NcSelect defaults `appendToBody` to true, so vue-select moves the open menu to
`<body>` and positions it with inline styles. Its z-index reads
`var(--vs-dropdown-z-index)`, which nc-vue declares on `body` as 9999. NcModal
does not use a fixed z-index at all: it assigns one at RUNTIME, counting up as
modals open — measured 10005 for the first and 10010 for the second on one
page. Every one of those is above 9999, so the modal always wins and the menu
is drawn underneath it.

The failure never names the select. `elementFromPoint()` at the option's own
centre returns whatever modal content happens to sit over it, so Playwright
reported `<p class="dashboard-config__hint"> intercepts pointer events` and a
reader goes looking at the hint. That is why this survived three rounds of
fixes: the interceptor named in the log is innocent.

⚠️ NOT THE SAME BUG as `.dashboard-config__field--select` in
DashboardConfigModal.vue, and that rule cannot help. It raises the FIELD so a
menu rendered INSIDE the modal clears the fields below it. This menu is not
inside the modal at all.

⚠️ TWO OBVIOUS FIXES BOTH LOSE, MEASURED RATHER THAN ASSUMED. A plain
`.vs__dropdown-menu { z-index }` is overridden by nc-vue's own
same-specificity rule in `_plugin-vue_export-helper-*.chunk.css`, which loads
after this file: the rule shipped in the bundle and the computed value stayed
9999. Redeclaring the variable on `:root` loses to nc-vue's declaration on
`body`, which is more specific for everything inside it. Setting the variable
on the MENU beats an inherited value whatever the source order, so this needs
no `!important`.

THE SUPPORT NOTE WAS SETTLED FOR ONE USER OF THE TWO. `global-setup.ts` records
it through the logged-in admin's own preference and the marker is per user, so
the suite settled it for exactly one of the people it logs in as. With the
z-index fixed, "recipient sees the shared dashboard in their switcher" was the
last failure standing, and the call log named `cn-support-dialog` intercepting a
toggle it also called visible, enabled and stable. seed.sh now settles it for
every seeded account, with occ, because occ is the only thing there that can
write another user's preference — the app's own endpoint writes the caller's.
That mirrors the firstrunwizard block already above it, which documents this
same shape for the same test.

Verified against a real instance, not reasoned about: conditional-visibility-
editor 13 passed of 13, dashboard-sharing 4 passed of 4. Both were 0 of their
CI-failing subsets before.

The z-index collision belongs upstream in nextcloud-vue, where the modal
counter and the dropdown constant should be related rather than coincidental.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@github-actions

github-actions Bot commented Sep 6, 2026

Copy link
Copy Markdown
Contributor

Quality Report — ConductionNL/launchpad @ ed3efb3

Check PHP Vue Security License Tests
lint
phpcs
phpmd
psalm
phpstan
phpmetrics
eslint
stylelint
build
check-manifest
format
check-schema-l10n
composer ✅ 104/104
npm ✅ 527/527
app:check-code ⏭️
info.xml
REUSE
PHPUnit
Newman
Playwright ⏭️ deferred — runs on the promotion into beta/main, not on a pull request into development
Hydra gates

Quality workflow — 2026-09-06 06:32 UTC

Download the full PDF report from the workflow artifacts.

@rubenvdlinde
rubenvdlinde merged commit 69ac83a into development Sep 6, 2026
43 checks passed
rubenvdlinde added a commit that referenced this pull request Sep 6, 2026
…d alone (#562)

Correcting my own description in #561. It said nc-vue declares
`--vs-dropdown-z-index` on `body` as 9999. That is true of nc-vue's chunk
stylesheet, and it is ALSO true of this app's own `css/launchpad.css`, which
re-declares it there deliberately under ConductionNL/nextcloud-vue#864 because
nc-vue 9.10 moved the declaration onto the select root where an appended menu
cannot inherit it. Leaving that out made the new rule look like it replaced the
old one.

It does not. They fix different halves and removing either brings a different
failure back:

  css/launchpad.css        restores INHERITANCE, so the menu receives a value.
  src/styles/workspace.css raises the VALUE above NcModal, which assigns itself
                           a runtime z-index counting up as modals open —
                           measured 10005 for the first and 10010 for the
                           second. Every one beats 9999, so the #864 workaround
                           alone still leaves the menu under any modal.

That matters because #864 is open and ends with "delete both once upstream
fixes the scoping". Whoever closes it will read this file, and now finds a line
saying the 10100 rule must stay until nc-vue relates the two numbers rather than
choosing them independently. Both comments now point at each other.

Comment-only. No rule changes.

Co-authored-by: Conduction Release Bot <release-bot@conduction.nl>
Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
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.

1 participant