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

Mat-select and ctrl+c changes selected item #14274

Closed
PepijnDhollander opened this issue Nov 26, 2018 · 1 comment · Fixed by #14301
Closed

Mat-select and ctrl+c changes selected item #14274

PepijnDhollander opened this issue Nov 26, 2018 · 1 comment · Fixed by #14301
Assignees
Labels
P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent

Comments

@PepijnDhollander
Copy link

Bug, feature request, or proposal:

I want to copy the selected value by selecting (highlighting) it and pressing ctrl+C
but the list jumps to the first item that begins with C

What is the expected behavior?

the selected text is copied to clipboard
and the selected item is unchanged

What is the current behavior?

the selected text is copied to the clipboard
and the selected item is changed

What are the steps to reproduce?

Similar to Ctrl+C but with Ctrl+P
in the default stackblitz of mat-select basic:
https://stackblitz.com/angular/nlmxjolypgj?file=app%2Fselect-overview-example.ts

select item "Tacos" , highlight it and hold the mouse button until outside the mat-select component
(otherwise the dropdown opens)
now press Ctrl+P which should print the screen with "Tacos" selected
But the screen is printed with "Pizza" selected

The "highlighting" is not the cause because clicking the preview and focussing on the first mat-select by using "tab" and then pressing Ctrl+P has the same result ("Pizza" is selected)

What is the use-case or motivation for changing an existing behavior?

the client wants to copy the selected value to another location

Which versions of Angular, Material, OS, TypeScript, browsers are affected?

Material 7.1

Is there anything else we should know?

please ask

@crisbeto crisbeto self-assigned this Nov 26, 2018
@crisbeto crisbeto added P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent has pr labels Nov 27, 2018
crisbeto added a commit to crisbeto/material2 that referenced this issue Nov 27, 2018
Recently we switched to skip handling keyboard events with modifiers, unless the consumer opted into them explicitly. The changes weren't applied when in typeahead mode.

Fixes angular#14274.
crisbeto added a commit to crisbeto/material2 that referenced this issue Nov 27, 2018
Recently we switched to skip handling keyboard events with modifiers, unless the consumer opted into them explicitly. The changes weren't applied when in typeahead mode.

Fixes angular#14274.
jelbourn pushed a commit that referenced this issue Nov 28, 2018
Recently we switched to skip handling keyboard events with modifiers, unless the consumer opted into them explicitly. The changes weren't applied when in typeahead mode.

Fixes #14274.
jelbourn pushed a commit that referenced this issue Nov 28, 2018
…14301)

Recently we switched to skip handling keyboard events with modifiers, unless the consumer opted into them explicitly. The changes weren't applied when in typeahead mode.

Fixes #14274.
jelbourn pushed a commit that referenced this issue Dec 3, 2018
…14301)

Recently we switched to skip handling keyboard events with modifiers, unless the consumer opted into them explicitly. The changes weren't applied when in typeahead mode.

Fixes #14274.
josephperrott pushed a commit to josephperrott/components that referenced this issue Jan 14, 2019
…ngular#14301)

Recently we switched to skip handling keyboard events with modifiers, unless the consumer opted into them explicitly. The changes weren't applied when in typeahead mode.

Fixes angular#14274.
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 10, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
P3 An issue that is relevant to core functions, but does not impede progress. Important, but not urgent
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants