angular/packages/platform-browser/test/dom/events
Jessica Janiuk a67a8b2fc7 refactor(platform-browser): Updates keyboard event library to support code field (#46030)
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
2022-07-18 15:28:58 +00:00
..
event_manager_spec.ts test: avoid test fixture affecting zone in all web tests (#46511) 2022-06-27 15:46:41 -07:00
hammer_gestures_spec.ts build: update to jasmine 4.0 (#45558) 2022-04-11 16:25:28 +00:00
key_events_spec.ts refactor(platform-browser): Updates keyboard event library to support code field (#46030) 2022-07-18 15:28:58 +00:00
zone_event_unpatched_init.js test: avoid test fixture affecting zone in all web tests (#46511) 2022-06-27 15:46:41 -07:00