Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug(mat-selection-list): command + A does not work as a select all. #24781

Closed
1 task
Brutusn opened this issue Apr 15, 2022 · 0 comments · Fixed by #30183 · May be fixed by #24788
Closed
1 task

bug(mat-selection-list): command + A does not work as a select all. #24781

Brutusn opened this issue Apr 15, 2022 · 0 comments · Fixed by #30183 · May be fixed by #24788
Labels
area: material/list P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent

Comments

@Brutusn
Copy link

Brutusn commented Apr 15, 2022

Is this a regression?

  • Yes, this behavior used to work in the previous version

The previous version in which this bug was not present was

No response

Description

Inside the mat-selection-list you have the option to use ctrl + A. It will select all items in the list. For MacOs it won't work, it uses the 'metaKey'.

I looked into the code and I think it needs to be added here, just don't know how to do it.

hasModifierKey(event, 'ctrlKey') &&

Reproduction

Steps to reproduce:

  1. Use mac os
  2. Checkout: https://stackblitz.com/run?file=src/app/list-selection-example.ts (basic example)
  3. Press command + A

Expected Behavior

I expect all items to be selected.

Actual Behavior

All text is selected but not the items itself.

Environment

  • Angular: 13.x.x
  • CDK/Material: 13.3.3
  • Browser(s): all.
  • Operating System (e.g. Windows, macOS, Ubuntu): macOS
@Brutusn Brutusn added the needs triage This issue needs to be triaged by the team label Apr 15, 2022
volvachev pushed a commit to volvachev/components that referenced this issue Apr 15, 2022
Fixes a bug in Angular Material `list` when using MacOs `command`+`a` does not work for 'select all functionality'.

Fixes angular#24781
volvachev added a commit to volvachev/components that referenced this issue Apr 15, 2022
Fixes a bug in Angular Material `list` when using MacOs `command`+`a` does not work for 'select all functionality'.

Fixes angular#24781
volvachev added a commit to volvachev/components that referenced this issue Apr 16, 2022
Fixes a bug in Angular Material `list` when using MacOs `command`+`a` does not work for 'select all functionality'.

Fixes angular#24781
volvachev added a commit to volvachev/components that referenced this issue Apr 16, 2022
Fixes a bug in Angular Material `list` when using MacOs `command`+`a` does not work for 'select all functionality'.

Fixes angular#24781
@crisbeto crisbeto added P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent has pr area: material/list and removed needs triage This issue needs to be triaged by the team labels Apr 22, 2022
@mmalerba mmalerba removed the has pr label Dec 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: material/list P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent
Projects
None yet
3 participants