Skip to content

[stable34] build(deps): bump @nextcloud/dialogs from 7.4.1 to 7.5.0 in /build/frontend-legacy - #64077

Open
dependabot[bot] wants to merge 3 commits into
stable34from
dependabot/npm_and_yarn/build/frontend-legacy/stable34/nextcloud/dialogs-7.5.0
Open

[stable34] build(deps): bump @nextcloud/dialogs from 7.4.1 to 7.5.0 in /build/frontend-legacy#64077
dependabot[bot] wants to merge 3 commits into
stable34from
dependabot/npm_and_yarn/build/frontend-legacy/stable34/nextcloud/dialogs-7.5.0

Conversation

@dependabot

@dependabot dependabot Bot commented on behalf of github Sep 5, 2026

Copy link
Copy Markdown
Contributor

Bumps @nextcloud/dialogs from 7.4.1 to 7.5.0.

Release notes

Sourced from @​nextcloud/dialogs's releases.

v7.5.0

v7.5.0

Notes

This version include some reworked - and accessible - toast notifications. Those new toast messages will be displayed on the bottom start of the page, this is by design and not a bug.

Added

Fixed

Changelog

Sourced from @​nextcloud/dialogs's changelog.

v7.5.0

Notes

This version include some reworked - and accessible - toast notifications. Those new toast messages will be displayed on the bottom start of the page, this is by design and not a bug.

Added

Fixed

Commits
  • dec5ccf Merge pull request #2579 from nextcloud-libraries/chore/prepare-rel
  • 395a38f chore: add note about toasts
  • 6d2dd27 chore: prepare v7.5.0
  • 4030af4 Merge pull request #2575 from nextcloud-libraries/dependabot/npm_and_yarn/mai...
  • a07e474 chore(deps-dev): bump the vitest group with 2 updates
  • 40d0492 Merge pull request #2565 from nextcloud-libraries/automated/noid/main-fix-npm...
  • 20df0f0 Merge pull request #2539 from nextcloud-libraries/feat/timeout-configuration
  • f4e2981 chore: adjust to comply with ESLint
  • c8e9080 feat: toast timeout configuration
  • 19882e5 Merge pull request #2574 from nextcloud-libraries/translations_441be4f7621043...
  • Additional commits viewable in compare view

Dependabot compatibility score

You can trigger a rebase of this PR by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

@dependabot
dependabot Bot requested review from a team as code owners September 5, 2026 02:39
@dependabot dependabot Bot added the 3. to review Waiting for reviews label Sep 5, 2026
@dependabot
dependabot Bot requested review from kristian-zendato, sorbaugh and susnux and removed request for a team September 5, 2026 02:39
@github-actions github-actions Bot changed the title build(deps): bump @nextcloud/dialogs from 7.4.1 to 7.5.0 in /build/frontend-legacy [stable34] build(deps): bump @nextcloud/dialogs from 7.4.1 to 7.5.0 in /build/frontend-legacy Sep 5, 2026
@AndyScherzinger AndyScherzinger added this to the Nextcloud 34.0.4 milestone Sep 5, 2026
@AndyScherzinger

Copy link
Copy Markdown
Member

/compile

dependabot Bot and others added 2 commits September 11, 2026 14:55
Bumps [@nextcloud/dialogs](https://github.com/nextcloud-libraries/nextcloud-dialogs) from 7.4.1 to 7.5.0.
- [Release notes](https://github.com/nextcloud-libraries/nextcloud-dialogs/releases)
- [Changelog](https://github.com/nextcloud-libraries/nextcloud-dialogs/blob/main/CHANGELOG.md)
- [Commits](nextcloud-libraries/nextcloud-dialogs@v7.4.1...v7.5.0)

---
updated-dependencies:
- dependency-name: "@nextcloud/dialogs"
  dependency-version: 7.5.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
@AndyScherzinger
AndyScherzinger force-pushed the dependabot/npm_and_yarn/build/frontend-legacy/stable34/nextcloud/dialogs-7.5.0 branch from 0e06062 to c3450ef Compare September 11, 2026 12:55
@AndyScherzinger

Copy link
Copy Markdown
Member

Analysis: TypeError: Cannot read properties of undefined (reading 'nodeType') after @nextcloud/dialogs 7.4.1 → 7.5.0

Root cause

@nextcloud/dialogs 7.5.0, lib/toast.ts:

296:  data = new DOMParser().parseFromString(data, 'text/html').body.innerText
...
311:  const text = getAnnouncementText(data, opts.isHTML)
270:  return getVisibleText(data)           // ← data is undefined
244:  if (node.nodeType === Node.TEXT_NODE) // ← throws

jsdom has never implemented HTMLElement.innerText — it is not even on the prototype. Verified against jsdom 30 (and 29.1.1 is what this repo locks):

jsdom version: 30.0.1
innerText   : undefined
textContent : "hi there"
in prototype: false

So at line 296 data becomes undefined. getAnnouncementText(undefined, false) fails the typeof data === 'string' guard, falls through to getVisibleText(undefined), and dereferences .nodeType. The exact error was reproduced in isolation with the 7.5.0 code path.

Why the bump surfaced it (and why it is still non-breaking)

7.4.1 had the same innerText defect — line 122: element.innerHTML = data; data = element.innerText. Under jsdom the toast message was already undefined there; it was just handed to Toastify as text and rendered harmlessly. 7.5.0 added the new persistent aria-live announcement path (getAnnouncementText / getVisibleText), which now dereferences that value.

The bump did not introduce the defect — it converted a pre-existing silent one into a throw. The semver-minor classification is accurate for browser use.

Not an issue outside tests

In real browsers innerText exists. The DOMParser document has no browsing context, so nothing in it is "being rendered", and per the HTML spec innerText then returns the same value as textContent. The strip works correctly in every browser. No user-facing regression — jsdom-only.

Why this particular spec fails

Two latent issues in our own code line up:

  1. apps/files/src/composables/useHotKeys.ts:36useHotKey(key, () => executeAction(action), …). The returned promise is never awaited or caught, so anything escaping executeAction becomes an unhandled rejection (hence processTicksAndRejections in the trace).
  2. useHotKeys.spec.ts does vi.mock('../actions/deleteAction.ts', { spy: true }), which keeps the real exec. In the 'registeres actions' test the call stack contains keydown, so exec enters askConfirmation(...) and throws under jsdom. executeAction catches it, logs, and calls showError at apps/files/src/utils/actionUtils.ts:75 — inside the catch. showError itself then throws, escapes the catch, and there is no handler anywhere up the chain.

Recommended fixes

Upstream (the real fix)nextcloud-libraries/nextcloud-dialogs: use textContent instead of innerText at toast.ts:296, and/or guard getVisibleText against a nullish node. 7.5.0 is currently the latest published version, so no released fix exists yet.

In this repo, to unblock the bump — add an innerText polyfill to build/frontend-legacy/__tests__/mock-window.js:

Object.defineProperty(HTMLElement.prototype, 'innerText', {
      get() { return this.textContent },
      set(value) { this.textContent = value },
      configurable: true,
})

This also fixes the latent 7.4.1 breakage where toasts silently announced undefined in tests.

Worth doing regardless — attach a .catch() in useHotKeys.ts:36 so a failing action can never produce an unhandled rejection.

Related

build/frontend also runs on jsdom and pulls dialogs from the root package.json (still ^7.4.1). The equivalent dependabot PR there will hit the identical failure, so the polyfill likely belongs in both test setups.

Note: if this is headed for the PR thread or an upstream issue, our AGENTS.md requires review comments and issue reports to be in your own words — worth rewording rather than pasting verbatim.

jsdom does not implement HTMLElement.innerText, so @nextcloud/dialogs'
showMessage() receives undefined when it strips markup by round-tripping
through it. Since 7.5.0 the live region announcement dereferences that
value and throws "Cannot read properties of undefined (reading
'nodeType')".

Assisted-by: ClaudeCode:claude-opus-5
Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants