Commit Graph

737 Commits

Author SHA1 Message Date
Šimon Brandner
e63b3d1b3e
Add support for audio sharing
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2022-07-16 09:08:38 +02:00
Robin Townsend
689835cc17 Merge branch 'main' into matroska 2022-07-15 16:56:52 -04:00
Robin Townsend
996c5f86c1 Refactor to use fewer else's 2022-07-15 16:08:26 -04:00
Robin Townsend
3fc8fe505b Merge branch 'main' into matroska 2022-07-15 14:38:12 -04:00
Robin Townsend
daeecc9b68 Add a missing type 2022-07-15 13:07:19 -04:00
Robin Townsend
982398b32f Remove unnecessary complexity from createRoom
With fae4c504c9, the changes from
b4a56f6dd7 are no longer necessary.
2022-07-15 13:05:06 -04:00
Robin Townsend
fae4c504c9 Consolidate all group call creation into useLoadGroupCall
This enables us to automatically create a group call in rooms that
exist, but contain no calls.
2022-07-15 12:59:54 -04:00
Robin Townsend
b4a56f6dd7 Wait for the created room to come down sync before placing a group call 2022-07-15 11:31:52 -04:00
Šimon Brandner
d5375ca9ed
Delint
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2022-07-15 11:22:13 +02:00
Šimon Brandner
eda8404144
Add UI for local volume control
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2022-07-15 11:18:56 +02:00
Timo K
e17a7cedb6 form_home 2022-07-14 19:20:52 +02:00
Šimon Brandner
4ad4cff23f
Add handling for local volume control
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2022-07-14 16:18:10 +02:00
David Baker
cc7a44dc17
Merge pull request #466 from vector-im/dbkr/check_indexeddb
Don't restore session unless crypto data is found
2022-07-14 13:43:21 +01:00
David Baker
873e68e1e1 Add notes from thinking through the need for storing what crypto db we use 2022-07-14 13:24:22 +01:00
David Baker
1eab957d85 Fix typescript syntax 2022-07-14 13:11:47 +01:00
David Baker
4c145af7a3 Don't restore session unless crypto data is found
Add a check to ensure that we find crypto data in the crypto store
when we're restoring a session and otherwise abort the session restore.

This will prevent us from restoring a session and generating new keys
when there was a previous session with different keys.

***This will force a logout for all users***

See the linked issue (and the comment in code) for more detail.

Fixes https://github.com/vector-im/element-call/issues/464
2022-07-14 13:07:30 +01:00
Robin Townsend
7fab4ca1ba Merge branch 'main' into matroska 2022-07-13 15:54:06 -04:00
David Baker
c1e45c4a30 Missed a file 2022-07-13 16:02:17 +01:00
David Baker
5784a005dc Auto-register if displayName URL param is given
Fixes https://github.com/vector-im/element-call/issues/442
2022-07-13 14:34:15 +01:00
David Baker
32907764b3 Add ptt URL param to control what mode rooms are created in 2022-07-11 13:23:03 +01:00
David Baker
5199fd2566 Prettier 2022-07-08 21:17:27 +01:00
David Baker
b31c6c6780 Bypass lobby in embedded mode 2022-07-08 20:55:18 +01:00
David Baker
aeec2c076e
Merge pull request #458 from vector-im/dbkr/fix_network_waiting_after_timeout
Fix 'waiting for network' after reaching time limit
2022-07-08 19:03:55 +01:00
David Baker
a81c48cc22 Fix 'waiting for network' after reaching time limit
If you spoke for the maximum amount of time and got cut off, the
next time you tried to speak you'd just get the 'waiting for network'
state. Key repeats would cause more delayed state timeouts to queue
up.
2022-07-08 15:52:32 +01:00
David Baker
6eb77b7c2f Fix types 2022-07-08 14:56:00 +01:00
David Baker
572caf6826
Merge pull request #453 from vector-im/dbkr/fix_facepile_display
Fix facepile display issues
2022-07-08 09:59:11 +01:00
David Baker
b0c8ceb302
Merge pull request #455 from vector-im/dbkr/fix_talkover
Fix talking collision not colliding properly
2022-07-08 09:51:26 +01:00
Timo K
619e3c4852 form 2022-07-07 23:40:29 +02:00
Timo
e5cfcb601b
Merge pull request #397 from toger5/ts_button 2022-07-07 22:03:28 +02:00
David Baker
2b92bf3694 Fix talking collision not colliding properly
The code was only entering the blocked state if the user was speaking,
which often won't be the case when another person starts speaking because
we'll have pressed the button but not got the ack back from the server
yet. Add the transmitblocked flag instead so we don't enter that state
again if we've already decided we've been blocked.

We were also starting with blocked = false and so resetting it when it
shouldn't have been reset.

Also requires https://github.com/matrix-org/matrix-js-sdk/pull/2502
2022-07-07 19:42:15 +01:00
David Baker
cd42d09ea9 Fix facepile display issues
Fixes https://github.com/vector-im/element-call/issues/434 and a
separate bug where the facepile would just disappear off to the left
(because we kept increasing the size even though we capped the number
of circles at 8 plus the overflow one).
2022-07-07 14:30:28 +01:00
Johannes Marbach
e8d99e15f7 Prevent empty device labels in audio preview
Fixes: #324
Signed-off-by: Johannes Marbach <johannesm@element.io>
2022-07-07 13:32:23 +02:00
Johannes Marbach
1308e52e42 Enumerate devices 2022-07-07 12:10:08 +02:00
Johannes Marbach
f6d356c5ce Prettify the thing 2022-07-07 10:31:44 +02:00
Johannes Marbach
eb2de869b8 Prevent empty device labels
Fixes: #324
Signed-off-by: Johannes Marbach <johannesm@element.io>
2022-07-07 10:21:38 +02:00
David Baker
655058a7e6 Remove the 'Take Me Home' link in embed mode 2022-07-06 18:27:30 +01:00
David Baker
775125c8a7 Fix view when another person is talking
Fixes https://github.com/vector-im/element-call/issues/445
2022-07-06 13:44:17 +01:00
Robin Townsend
4cb2306de0 Make button be constrained primarily by width rather than height 2022-07-05 15:49:48 -04:00
Robin Townsend
f15ee439a9 Fix page layout 2022-07-05 15:41:57 -04:00
Robin Townsend
b9a2473d19 Adapt walkie-talkie layout to hide controls at small sizes 2022-07-05 13:47:53 -04:00
Timo K
5b58223f9d fix refs 2022-07-05 17:44:09 +02:00
David Baker
984b02700e
Merge pull request #438 from vector-im/dbkr/e2e_config_param
Add config param to disable e2e for signalling
2022-07-05 13:21:28 +01:00
David Baker
2dcf043787 Fix the PTT button on mobile
We were using createRef() instead of useRef() in the hook, which
meant we were always creating a new ref object and never actually
getting the ref. This must have been working before the useEventTarget
stuff due to some quirk of React / hooks...
2022-07-05 11:06:32 +01:00
David Baker
6b03ae0dc3
Use the traditional syntax for not-equals
Co-authored-by: Šimon Brandner <simon.bra.ag@gmail.com>
2022-07-04 20:32:20 +01:00
David Baker
5dd5668389 Add config param to disable e2e for signalling 2022-07-04 20:10:13 +01:00
Robin Townsend
71a819fcf0 Produce a more informative error when running in an insecure context 2022-07-03 10:38:03 -04:00
Timo K
713136672a make className an optional param 2022-07-02 21:45:31 +02:00
Timo K
f1bd47be8c Merge branch 'main' into ts_button 2022-07-02 21:42:15 +02:00
Timo K
2e82960ae6 ButtonVariant ButtonSize 2022-07-02 21:20:53 +02:00
Robin Townsend
4a1a53d3ab Run prettier 2022-07-01 12:34:57 -04:00
Robin Townsend
be173a838d Update matrix-js-sdk 2022-07-01 12:08:15 -04:00
David Baker
623bd52e1f
Merge pull request #420 from vector-im/dbkr/embed_mode
Add embed mode
2022-07-01 13:12:19 +01:00
David Baker
5ebdf3e878
Use has on set
Co-authored-by: Robin <robin@robin.town>
2022-07-01 13:10:51 +01:00
David Baker
761eee2cdc Remove button props / style too 2022-07-01 13:10:08 +01:00
David Baker
c49e300247 Fix js-sdk imports to be from src
(For a curious definition of 'fix')
2022-06-29 10:31:17 +01:00
Timo
6d8e34762e
Merge pull request #395 from toger5/ts_profile
typescript `src/profile`
2022-06-28 18:47:54 +02:00
David Baker
33461f5ac2
Merge pull request #418 from vector-im/dbkr/catch_exceptions
Catch an exception & add log line on setsinkid
2022-06-28 15:15:25 +01:00
David Baker
4e3345482f Move setsinkid inside if statement 2022-06-28 15:12:59 +01:00
David Baker
7dc6fb27ea Add embed mode
2db23e4110
from postmessage_ptt branch done in a slightly nicer way
2022-06-28 15:08:14 +01:00
Robin
5ced94755b
Merge pull request #413 from robintown/update-js-sdk
Update matrix-js-sdk
2022-06-28 08:56:38 -04:00
David Baker
0ffd860fdb catch a couple of exceptions 2022-06-28 13:24:07 +01:00
Timo
05e786e3d6
Merge pull request #387 from toger5/ts_settings
typescript `src/settings`
2022-06-28 12:08:05 +02:00
Robin Townsend
d5e638c8f7 WIP 2022-06-27 17:41:07 -04:00
Robin Townsend
122ffeeab5 Update matrix-js-sdk 2022-06-21 11:32:07 -04:00
Robin Townsend
f2dbd5ff96 Move MediaElement interface to the global types file 2022-06-16 10:01:52 -04:00
Robin Townsend
dcae5ad5f2 Merge branch 'main' into chrome-spatial-aec 2022-06-16 09:56:27 -04:00
Robin Townsend
22dcb883b3 Fix waiting state not disappearing after the 20 second timeout 2022-06-14 23:38:40 -04:00
Robin Townsend
2e945780de Make the 'waiting for network' state work with spacebar 2022-06-14 16:53:56 -04:00
Robin Townsend
1d4ed6609d Preload PTT sounds correctly 2022-06-14 14:15:52 -04:00
Robin Townsend
74ccf7d820 Clean up useDelayedState 2022-06-14 12:13:59 -04:00
Robin Townsend
2eae6243bb Add a comment 2022-06-14 12:10:17 -04:00
Robin Townsend
276532e2e1 Add a 'waiting for network' state to walkie-talkie mode 2022-06-14 12:00:26 -04:00
Robin Townsend
fc07dd2af9 Convert useMediaStream to TypeScript 2022-06-13 17:24:25 -04:00
Robin Townsend
989712c2d5 Fix lints 2022-06-13 13:34:45 -04:00
Robin Townsend
ee43fcc91f Make AEC work with spatial audio on Chrome 2022-06-13 13:31:44 -04:00
Timo K
18ca92cec4 js->ts 2022-06-11 23:21:20 +02:00
Timo K
dc11814695 rename files js->ts 2022-06-11 15:23:33 +02:00
Timo K
17a31e0904 typing profile folder 2022-06-11 15:14:00 +02:00
Timo K
f990530031 Merge branch 'main' into ts_profile 2022-06-11 14:36:54 +02:00
Timo K
46f1f0f8e9 remove explicit any 2022-06-11 14:32:25 +02:00
Timo K
885e933948 fixes in useMediaHandler 2022-06-11 14:29:26 +02:00
Timo K
9b2e99c559 use React.ChangeEvent in SettingsModal 2022-06-11 14:28:54 +02:00
Timo K
60ed54d6d3 change rageshake.ts
to be more similar to the matrix-js version
2022-06-11 14:28:30 +02:00
David Baker
9fc4fbc3e7 Icon / styling fixes + typo
* Use icon from compound
 * Use warning colour
 * Fix capitalisation
2022-06-10 12:06:06 +01:00
David Baker
1f5ac411f6 Add warning if incompatible versionsd are being used
This will probably be overly sensitive until we start timing out
member events (ie. https://github.com/matrix-org/matrix-js-sdk/pull/2446
lands) because lots of calls might have old member events from people
who've joined previously.
2022-06-09 21:56:58 +01:00
Timo K
0aa29f775c linter 2022-06-08 17:22:46 +02:00
Timo K
a4a6105bc9 Merge branch 'main' into ts_settings 2022-06-08 16:40:51 +02:00
Timo K
23098131b8 couple of cleanups
ModalProps fixes
LogEntry interface
missing return promise
2022-06-08 16:36:22 +02:00
Robin
1a7211198b
Merge pull request #377 from robintown/spatial-audio-copy
Tweak spatial audio copy
2022-06-07 09:25:56 -04:00
Matthew Hodgson
4f9efb3563 last minute s/radio call/walkie-talkie call/ig 2022-06-07 13:31:19 +01:00
Timo K
190c57e853 typescript src/settings 2022-06-06 22:42:48 +02:00
Timo K
785eca7289 typescript src/profile 2022-06-06 22:33:13 +02:00
Robin Townsend
2667e78b43 sound → seem 2022-06-06 11:26:48 -04:00
Robin Townsend
b314e047c1 Tweak spatial audio copy 2022-06-06 11:19:40 -04:00
Robin Townsend
977016fbb2 Merge branch 'main' into organize-colors 2022-06-06 09:03:40 -04:00
Robin Townsend
8da492d00d Fix warning 2022-06-02 16:30:35 -04:00
Robin Townsend
7d87b8d1e5 'Webcam' → 'Camera' 2022-06-02 13:53:31 -04:00
David Baker
ecb139721b
Merge pull request #370 from vector-im/dbkr/avoid-browser-index-import
Fix app when built in production mode
2022-06-02 11:01:49 +01:00
Robin Townsend
aa45261b0d Organize colors 2022-06-01 11:48:17 -04:00
David Baker
017ec13981 Disable typescript warnings 2022-06-01 16:05:58 +01:00
David Baker
5282ab5f12 Merge remote-tracking branch 'origin/main' into dbkr/avoid-browser-index-import 2022-06-01 16:03:18 +01:00
David Baker
582e6637dc Merge remote-tracking branch 'origin/main' into dbkr/lower_sdk_timeout 2022-06-01 16:02:48 +01:00
David Baker
65804cd962
Merge pull request #358 from vector-im/dbkr/matrix-utils-ts
Convert matrix-utils to typescript
2022-06-01 16:02:20 +01:00
David Baker
0411e1cac8 Fix app when built in production mode
The recent typescripting appears to have caused the typescript
compiler to get confused about dependency references and start
refwrencing things like CRYPTO_ENABLED in the js-sdk before it's
defined them.

This avoids using things from the (javascript) browser-index import
and instead pulls everything in from the typescript files, then
fixes the resulting type failures, (in some cases with hacks).
2022-06-01 15:55:02 +01:00
Robin Townsend
d680a36cab Bump the animation size up a little bit more 2022-06-01 10:41:49 -04:00
Robin Townsend
25bde3560b Use color variables 2022-06-01 10:41:12 -04:00
Robin Townsend
ddac2ba5ef Merge branch 'main' into vu-animation 2022-06-01 10:31:04 -04:00
Robin
cd55098921
Merge pull request #365 from robintown/spatial-audio
Spatial audio
2022-06-01 09:17:04 -04:00
Robin
f1bdad0d7f
Merge pull request #366 from robintown/chrome-android-sink
Fix crash when setting audio output on Chrome for Android
2022-06-01 09:14:41 -04:00
Robin
9fac2c95e5
Merge pull request #368 from robintown/radio-button-cursor
Make PTTButton feel more clickable
2022-06-01 09:13:04 -04:00
David Baker
486d0abd30
Merge pull request #363 from vector-im/dbkr/ptt_connection_lost
Show when connection is lost on PTT mode
2022-06-01 10:24:53 +01:00
David Baker
d9bd48b9a6 Split out client sync listeber into separate useEffect 2022-06-01 10:21:44 +01:00
David Baker
64e30c89e3
Comment typo
Co-authored-by: Robin <robin@robin.town>
2022-06-01 10:13:20 +01:00
David Baker
1860eaae7a
Merge pull request #360 from vector-im/dbkr/consistent_sort
Sort call feeds consistently when choosing active speaker
2022-06-01 10:12:56 +01:00
David Baker
771424cbf0 Expand comment 2022-06-01 10:11:02 +01:00
David Baker
925a909ec1
Merge pull request #361 from vector-im/dbkr/usegroupcall_ts
Convert useGroupCall to TS
2022-06-01 10:07:12 +01:00
David Baker
f07ee54e05
Finish sentence
Co-authored-by: Robin <robin@robin.town>
2022-06-01 10:04:49 +01:00
David Baker
7ee2f630db Add more typers to useInteractiveLogin
otherwise apparently Typescript can't trace the MatrixClient type
through.
2022-06-01 09:59:59 +01:00
David Baker
626fdb9f79 Merge remote-tracking branch 'origin/main' into dbkr/matrix-utils-ts 2022-06-01 09:37:59 +01:00
David Baker
2cf40ff0b8 Fix room creation
The room alias is not part of the spec. Synapse returns it anyway,
but it's not part of the js-sdk types. We don't really need the
server to tell us what the alias is, so just generate it locally
instead.
2022-06-01 09:29:47 +01:00
David Baker
9edc1acc90 Add type to indexeddb variable 2022-06-01 09:07:00 +01:00
Robin Townsend
641e6c53b6 Make the animation smaller 2022-05-31 23:41:05 -04:00
Robin Townsend
14fbddf780 Make PTTButton feel more clickable 2022-05-31 18:08:42 -04:00
Robin Townsend
2a69b72bed Add a VU meter-style animation to radio mode 2022-05-31 18:01:34 -04:00
Robin Townsend
e21094b525 Fix crash when setting audio output on Chrome for Android 2022-05-31 16:21:35 -04:00
Robin Townsend
da3d038547 Make it work on Chrome 2022-05-31 16:11:39 -04:00
Robin Townsend
c6b90803f8 Add spatial audio capabilities 2022-05-31 13:36:15 -04:00
Robin Townsend
26251e1e60 Don't abuse useMemo for creating a MatrixClient 2022-05-31 10:33:10 -04:00
David Baker
e9b963080c Show when connection is lost on PTT mode 2022-05-30 16:28:16 +01:00
David Baker
1164e6f1e7 Add return type too 2022-05-30 15:53:44 +01:00
David Baker
21c7bb979e Convert useGroupCall to TS 2022-05-30 15:30:57 +01:00
David Baker
1ff9073a1a Sort call feeds consistently when choosing active speaker 2022-05-30 12:14:25 +01:00
David Baker
7ed2f9bd9a Lower timeout on js-sdk API call to 5s 2022-05-30 11:46:27 +01:00
David Baker
2cdbeb6f12 Fix imports 2022-05-30 11:41:59 +01:00
David Baker
7bd95621f1 More types 2022-05-30 11:28:16 +01:00
David Baker
a05501a909 Convert matrix-utils to typescript 2022-05-30 10:09:13 +01:00
Robin Townsend
e6960a1e15 TypeScriptify RegisterPage 2022-05-27 16:55:50 -04:00
Robin Townsend
c057713004 TypeScriptify useInteractiveRegistration 2022-05-27 16:55:50 -04:00
Robin Townsend
35e2135e3c TypeScriptify useInteractiveLogin 2022-05-27 14:52:32 -04:00
Robin Townsend
af74228f8e TypeScriptify useRecaptcha 2022-05-27 10:37:27 -04:00
Robin Townsend
9a44790450 TypeScriptify LoginPage 2022-05-27 10:37:00 -04:00
Robin Townsend
94380b64bd Set color-scheme to dark to make the focus ring on the dropdown button
legible
2022-05-26 14:12:25 -04:00
Robin Townsend
cbfd03f9c6 Add a dropdown to choose between video calls and radio calls 2022-05-26 13:52:06 -04:00
Robin Townsend
17fed7cd9c Prettyify 2022-05-24 16:55:53 -04:00
Robin Townsend
266861bdad Fix order of tiles in 1:1 layout 2022-05-24 16:54:33 -04:00
Robin Townsend
426e1a433b Make drag-and-drop smoother 2022-05-24 16:37:24 -04:00
Robin
3b8dfcec51
Merge pull request #349 from robintown/rate-limit
Handle rate limits when upgrading from a guest account
2022-05-24 07:45:24 -04:00
Robin
6f892edd5e
Merge pull request #348 from robintown/limit-width
Limit the width of the remote participant's video in 1:1 layout
2022-05-24 07:45:09 -04:00
Robin Townsend
59938cd46b Handle rate limits when upgrading from a guest account 2022-05-23 10:48:02 -04:00
Robin Townsend
a445bcd0b9 Limit the width of the remote participant's video in 1:1 layout 2022-05-23 09:59:55 -04:00