mirror of
https://github.com/angular/angular.git
synced 2026-09-14 13:54:52 +08:00
a67a8b2fc7
On MacOS, pressing the alt key and another key turns into symbols, and doesn't match the intended behavior. For example, `keydown.alt.s` reports instead as `keydown.alt.ß`. We rely on the `key` field and not the `code` field, which properly reports the code for S in this case. This change adds support to allow users to specify they want to look at the `code` field instead of the `key` field within their event string. Example: `keydown.code.alt.leftshift` would only match the LeftShift and not the right shift based on code values. It would also allow the user to specify `keydown.code.alt.keys` to match S instead of ß when alt / option is pressed on MacOS and would also work on Windows. Fixes #45992 PR Close #46030
Angular
The sources for this package are in the main Angular repo. Please file issues and pull requests against that repo.
Usage information and reference details can be found in Angular documentation.
License: MIT