Skip to content

DataForm: Focus loss when collapsing in Card view #73242

@mirka

Description

@mirka

Description

When toggling the expand/collapse button in Card view, keyboard focus is lost. The focus needs to stay on the button.

Step-by-step reproduction instructions

  1. Toggle the collapse button by keyboard.
  2. Focus is lost.

Screenshots, screen recording, code snippet

CleanShot.2025-11-13.at.23-44-05.mp4

Environment info

No response

Please confirm that you have searched existing issues in the repo.

  • Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

  • Yes

Please confirm which theme type you used for testing.

  • Block
  • Classic
  • Hybrid (e.g. classic with theme.json)
  • Not sure

Metadata

Metadata

Assignees

Labels

Good First IssueAn issue that's suitable for someone looking to contribute for the first time[Feature] DataViewsWork surrounding upgrading and evolving views in the site editor and beyond[Focus] Accessibility (a11y)Changes that impact accessibility and need corresponding review (e.g. markup changes).[Status] In ProgressTracking issues with work in progress[Type] BugAn existing feature does not function as intended

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions