Commit Graph
24 Commits
Author SHA1 Message Date
Timo K.andClaude Fable 5.1 bc58aed0d7 Keep keyboard shortcuts within Element Call's root
The call's shortcuts were listened for on the window and allowed
whenever focus was inside the standalone app's `#root` — which, for a
component embedded in a host, is the host's own root, or nothing. So m,
v and space fired while the user typed in the host's composer, and two
Element Calls on one page both answered every key.

Listen on the element Element Call treats as its root instead (the body
standalone, so nothing changes there), and judge whether a key press is
spoken for by what has focus — a dialog or a text field — rather than by
where it sits in the DOM, since the modals are now portalled to that
same root.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-08 13:52:34 +02:00
Timo K 58f430eb32 review 2026-05-04 18:25:04 +02:00
Timo K b5c1b36850 more logging 2026-04-28 13:53:08 +02:00
Timo K 6b1b316ce4 fix tests 2026-04-27 18:22:06 +02:00
Timo K 89281c6d70 Refactor leveraging the fact, things blocking shortcuts are using react
portals.
2026-04-27 14:21:02 +02:00
Timo K 2b46925e77 Call window.controls.onBackButtonPressed if esc is pressed without any
focus.
2026-04-22 11:51:33 +02:00
Robin e08f16f889 All my Friday work. Demoable! 2025-09-19 17:50:43 +02:00
Hugh Nimmo-Smith 0f5dc33918 Fix copyright header to say dual license not just AGPL (#3013)
This probably should have been part of https://github.com/element-hq/element-call/pull/2984
2025-02-18 17:59:58 +00:00
Hugh Nimmo-Smith 0087e37f30 Enable @typescript-eslint/consistent-type-imports lint rule (#2886)
* Enable @typescript-eslint/consistent-type-imports lint rule

This is to help ensure that we get proper vite/rollup lazy loading by not `import`ing more than we need to.

Revert "Enable @typescript-eslint/consistent-type-imports lint rule"

This reverts commit ba385fa00b7e410cc508fd5fb9fe972233ae114f.

Enable @typescript-eslint/consistent-type-imports lint rule

This is to help ensure that we get proper vite/rollup lazy loading by not `import`ing more than we need to.

.

* Format
2024-12-11 09:27:55 +00:00
Robin 51e4a3b14b Don't trigger keyboard shortcuts if modifiers are held
None of these keyboard shortcuts expect modifier keys, so they should in fact expect the absence of modifiers.
2024-11-22 13:17:05 -05:00
Will Hunt b3ceb5300c Add keyboard shortcuts for raised hand / reactions (#2784)
* Add support for reactions / raised-hands via keyboard shortcuts.

* Add tests

* Fixup shortcuts

* update snapshotr

* fix type

* keyshortcuts

* remove mistakenly commited file

* fix label logic

* Add renderer for call joined / left

* Use caption

* lint

* remove unexpected file

* remove other unexpected change

* Remove other other unexpected change.
2024-11-19 16:57:57 +00:00
fkwp 9add3e52c4 Update file headers copyright and change licence to AGPL-3.0-only 2024-09-06 10:22:13 +02:00
Robin 380f49fccc Improve accessibility of keyboard shortcuts
Ensure that they don't interfere with say, using spacebar to press a button, and also ensure that they won't do surprising things like scroll the page at the same time.
2024-07-24 18:42:21 -04:00
Robin 614bc82402 Format code 2023-10-11 10:42:04 -04:00
Robin a7624806b2 Upgrade eslint-plugin-matrix-org to 1.2.1
This upgrade came with a number of new lints that needed to be fixed across the code base. Primarily: explicit return types on functions, and explicit visibility modifiers on class members.
2023-09-22 18:07:06 -04:00
David Baker 4459eaeb9d Fix audio mute on window blur
https://github.com/vector-im/element-call/pull/1015/files missed a
change of spacebarHeld to a ref.
2023-04-21 10:18:43 +01:00
Robin Townsend 4114622d44 Remove the keyboard shortcut setting 2023-04-19 16:15:38 -04:00
Robin Townsend 6f13989819 Fix lint errors 2023-04-19 15:55:55 -04:00
Robin Townsend 1184b71396 Format with Prettier 2023-04-19 15:54:39 -04:00
Robin Townsend 56bd54a645 Disable keyboard shortcuts when focus is in a modal 2023-04-19 15:51:44 -04:00
Robin Townsend 18fa1371d3 Use a ref for spacebarHeld
because we can and it means fewer renders
2023-04-19 15:17:32 -04:00
David Baker afdce66896 Merge remote-tracking branch 'origin/main' into dbkr/prevent_keyrepeat_mute_spam 2023-01-13 11:57:02 +00:00
David Baker 1b08a5cac3 Rename file 2023-01-13 11:56:29 +00:00
David Baker a5977fc992 Rename to useCallViewKeyboardShortcuts 2023-01-13 11:52:40 +00:00