ckeditor5 icon indicating copy to clipboard operation
ckeditor5 copied to clipboard

Unify focus and list items rendering in dropdown menus

Open Mati365 opened this issue 1 year ago • 1 comments

Suggested merge commit message (convention)

Internal (ui): Unify dropdown menus focus behavior with menu bar and other menus. Internal (ui): Use ListItemButtonView instead of ButtonView class as base for dropdown menu buttons. Internal (ui): Add support for hasIconSpace attribute of ListItemButtonView and allocate space for check marks if there is at least one toggleable menu item in menu.


Additional information

  1. I marked this commit as internal because dropdown menu is not released yet.
  2. Focus behavior has been changed in order to make it unified with menu bar. After this change, hovering menu items moves focus from search input to menu items, and any keyboard interaction with the menu makes it show the focus border.
  3. Why is it based on ck/16311 branch? 3.1. We don't have manual tests for dropdown menu, and the only way to test that is AI. 3.2. The presence of search input is important to show how "hover focus" behaves with that kind of dropdown.

Part of PRs:

  1. https://github.com/ckeditor/ckeditor5/pull/16314
  2. https://github.com/ckeditor/ckeditor5/pull/16631

Screens

⚠️ Look at the focus placement.

Before:

obraz

After:

obraz

https://github.com/ckeditor/ckeditor5/assets/3949262/4570632f-56ed-474e-a861-dc20d9e7e170

Mati365 avatar Jul 01 '24 07:07 Mati365

@scofalik This one can be merged directly to core dropdown function. I rebased it on search branch just for tests. There should be no conflicts.

Mati365 avatar Jul 03 '24 09:07 Mati365

There has been no activity on this PR for the past year. We've marked it as stale and will close it in 30 days. We understand it may still be relevant, so if you're interested in the contribution, leave a comment or reaction under this PR.

CKEditorBot avatar Jul 03 '25 23:07 CKEditorBot

We've closed your PR due to inactivity. While time has passed, the core of your contribution might still be relevant. If you're able, consider reopening a similar PR.

CKEditorBot avatar Aug 03 '25 23:08 CKEditorBot