Commit Graph

1007 Commits

Author SHA1 Message Date
Daniel Abramov
b1d7631994 Fix LiveKit's device selection during the call 2023-06-02 19:55:41 +02:00
Daniel Abramov
991129e470 Experimental version of LiveKit with EC that works! 2023-06-02 19:12:28 +02:00
Daniel Abramov
ee1819a0b6 Quick way to replace matrix JS SDK with LiveKit 2023-06-02 17:02:47 +02:00
Daniel Abramov
fb9dd7ff71 Use LiveKit's react hooks for devices
More reliable device management.
2023-05-30 20:56:25 +02:00
Daniel Abramov
f4f5c1ed31 Start using LiveKit SDK for media devices
This version is not supposed to properly work, this is a work in
progress.

Main changes:
* Completely removed the PTT logic (for simplicity, it could be
  introduced later).
* Abstracted away the work with the media devices.
* Defined confined interfaces of the affected components so that they
  only get the data that they need without importing Matris JS SDK or
  LiveKit SDK, so that we can exchange their "backend" at any time.
* Started using JS/TS SDK from LiveKit as well as their React SDK to
  define the state of the local media devices and local streams.
2023-05-30 15:21:22 +02:00
Šimon Brandner
c6f85c7ab8
Update js-sdk
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2023-02-17 15:04:10 +01:00
Enrico Schwendig
1548a5673f
Extend developer view with media debug information (#909)
* interceptor: add MediaStream feed debug interceptor

- interceptor displays nick name for default and nick name + user id if user gast
- interceptor displays track id  + media stream ids
2023-02-15 16:04:05 +01:00
David Baker
8ffdf34b0a Merge remote-tracking branch 'origin/main' into feature_sfu 2023-02-02 14:42:38 +00:00
David Baker
579b91abff
Revert "Yarn upgrade" 2023-02-02 14:32:44 +00:00
David Baker
9de7fe81f2 Merge branch 'main' into feature_sfu 2023-02-02 13:48:44 +00:00
David Baker
e1abbd5291 Yarn upgrade
Along with some type fixes to make typescript happy again. Hopefully
they are sensible.
2023-02-02 12:49:54 +00:00
Šimon Brandner
ab70926274
Delint
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2023-01-31 11:04:48 +01:00
Šimon Brandner
6ff8215e7a
Reduce diff
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2023-01-31 11:01:21 +01:00
Šimon Brandner
c492fcd448
Always show debug info
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2023-01-31 11:00:13 +01:00
Šimon Brandner
abb43bfe59
Show debug only conditionally
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2023-01-30 22:07:00 +01:00
Šimon Brandner
807a6a8545
Add call feed size debug info
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2023-01-30 20:43:21 +01:00
Šimon Brandner
3d0906a145
Merge remote-tracking branch 'upstream/main' into feature_sfu
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2023-01-25 17:13:01 +01:00
David Baker
d2631a3e02 Fix the rageshake modal on mobile
As per comment

Unsure if this is the best fix - ideally we wouldn't go into no-controls
mode at all, but this part doesn't know whether the dialog is open so
the only thing we could really do is tweak the threshold, or possibly
guess based on width instead?
2023-01-23 17:52:02 +00:00
David Baker
d65464e4db Avoid duplicate PTT button 'unhold' events
We called the 'unhold' function even if the button wasn't held which
probably will have been generating unmute events even when we weren't
muted.

Also use separate handlers for events so we can have specific log lines
(and also see where the event comes from when caught in the debugger).
2023-01-23 16:53:24 +00:00
David Baker
4f8bd18efd Don't try to register users until client is loaded 2023-01-20 17:59:57 +00:00
David Baker
47c2e9e101 Don't crash if we can't find our own member event 2023-01-20 12:10:58 +00:00
David Baker
81997624d4 Fix joining rooms by ID
We use this in embedded mode. Regressed by https://github.com/vector-im/element-call/pull/860

Lowercasing room IDs obviously makes them break, so… don't do that.
2023-01-20 10:51:52 +00:00
David Baker
7e1033f5a4
Add colon in comment
Co-authored-by: Šimon Brandner <simon.bra.ag@gmail.com>
2023-01-20 09:35:50 +00:00
David Baker
524f530dce Lowercase room alias before joining 2023-01-19 19:20:42 +00:00
David Baker
e1c4042d15 Add units to constant 2023-01-17 10:16:55 +00:00
David Baker
8284d0da60 Don't crash if no stream on callfeed 2023-01-16 18:10:50 +00:00
David Baker
860aff4958 Change rageshake persistence to throttled flushing
Rather than every 30 seconds. This way we'll save logs for sessions
lasting less than 30 seconds which we previously didn't. Also save
on window unload just in case that doesn't catch everything.

Plus remove some more unused params.
2023-01-16 17:27:49 +00:00
David Baker
13b1dcf785 Mostly cosmetic fixes to rageshake
* Remove duplicate copyright header
 * Remove ts-ignores by just using the objects directly rather than via
   event.target
 * Use error.message rather than errorCode which TS doesn't know about
   and may or may not exist.
 * Remove some unused things like the skip rageshake function and
   the option to init rageshakes without storage.
 * Turn single function with a boolean param to make it take two entirely
   separate code paths into two functions.
2023-01-16 16:43:45 +00:00
David Baker
abd909c03a Log undecryptable to-device events
Listen for the new undecryptable to-device event event and log
events for it in Posthog & Sentry, and make it visible in the
call flow diagram.
2023-01-13 18:27:22 +00:00
Šimon Brandner
c0bc52cdf2
Merge remote-tracking branch 'upstream/feature_sfu' into feature_simulcast
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2023-01-13 17:48:01 +01:00
Šimon Brandner
e0f0dccc55
Reduce diff
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2023-01-13 17:42:15 +01:00
Šimon Brandner
4e64c71a4c
Merge remote-tracking branch 'upstream/main' into feature_sfu
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2023-01-13 17:40:05 +01: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
843e7690fa
Merge pull request #845 from vector-im/dbkr/disable_keyboard_shortcuts_rageshake
Disable keyboard shortcuts when feedback modal is open
2023-01-13 11:55:51 +00:00
David Baker
a5977fc992 Rename to useCallViewKeyboardShortcuts 2023-01-13 11:52:40 +00:00
David Baker
f2193302c1 Prevent mute event spam from key repeats 2023-01-12 18:26:21 +00:00
David Baker
9ba4ce429f Disable keyboard shortcuts when feedback modal is open 2023-01-12 17:31:19 +00:00
David Baker
5f26534496 Use IndexedDB storage in dev mode, just without the worker
As per comment, we can't use workers in Vite dev mode. We previously
fell back to the memory store but this ends up with it working significantly
differently in dev mode to production, eg. dev mode would always start
by doing an initial sync, so old to-device messages would arrive again.

There's no need to fall all the way back to the memory store though,
we can use the IndexedDB store without the worker.
2023-01-12 15:17:46 +00:00
Šimon Brandner
72a02b1b01
Add proper (un)subscribe logic
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2023-01-10 21:00:30 +01:00
Robin
4e0f4a8dc7
Merge pull request #835 from robintown/unmuted-when-speaking
Work around mute state updates being slow
2023-01-09 13:35:05 -05:00
Šimon Brandner
0d151452ba
Merge pull request #833 from vector-im/SimonBrandner/feat/hide-audio 2023-01-09 19:28:04 +01:00
Robin Townsend
4fd76f9599 Work around mute state updates being slow
Since the app already determines when someone is speaking, we can use that information to make it less obvious when to-device messages are being slow to deliver mute state updates.
2023-01-09 11:10:59 -05:00
Šimon Brandner
881054e265
Hide local volume controls for tiles with no audio
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2023-01-07 10:09:20 +01:00
Šimon Brandner
53b21688b9
Merge branch 'feature_sfu' into feature_simulcast
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2023-01-07 09:49:21 +01:00
Šimon Brandner
7dc6455225
Merge remote-tracking branch 'upstream/main' into feature_sfu
Signed-off-by: Šimon Brandner <simon.bra.ag@gmail.com>
2023-01-07 09:47:55 +01:00
Robin Townsend
468e389324 Leave audio elements unmuted regardless of mute state 2023-01-06 10:26:10 -05:00
Timo
e5135a41ba
Add call id to mute events (#827) 2023-01-05 11:05:22 +01:00
Timo
67d1c29d6a
decrease wait after call ended to 10ms (#825)
* decrease wait after call ended to 10ms

* new order of widget requests to avoid pip flicker
2023-01-05 00:01:57 +01:00
Robin Townsend
faa8f95f97 Reduce the size of the local feed in 1:1 calls at small window sizes 2023-01-04 08:38:24 -05:00