Commit Graph
205 Commits
Author SHA1 Message Date
Timo K c8098734cd one e2ee worker per session
Signed-off-by: Timo K <toger5@hotmail.de>
2025-09-19 17:50:43 +02:00
Timo K 9011ae4e1f temp
Signed-off-by: Timo K <toger5@hotmail.de>
2025-09-19 17:50:43 +02:00
Will HuntandGitHub 63122c7f6b Log when a track is unpublished or runs into an error (#3495) 2025-09-18 12:09:54 +01:00
Timo K f410a11934 unused import
Signed-off-by: Timo K <toger5@hotmail.de>
2025-08-26 18:13:04 +02:00
Timo K 3122ccf4e4 dont use deprecated defer
Signed-off-by: Timo K <toger5@hotmail.de>
2025-08-26 18:10:08 +02:00
Robin 8c1fa3fd70 Fix inaccurate copyright headers 2025-08-14 14:57:39 +02:00
TimoandGitHub 77ba88b76c Set available devices to empty map on safari. Safari does not allow changing output devices so the output device dialog is confusing. (#3426)
* Set available devices to empty map on safari.

Signed-off-by: Timo K <toger5@hotmail.de>

* better safari check

Signed-off-by: Timo K <toger5@hotmail.de>

---------

Signed-off-by: Timo K <toger5@hotmail.de>
2025-08-04 17:46:56 +02:00
TimoandGitHub 7971ea76cd Dont construct logger before rageshake initialization (#3434)
Signed-off-by: Timo K <toger5@hotmail.de>
2025-08-04 16:43:08 +02:00
Robin 879816ac6d Reset LiveKit connection timeouts to their defaults
I believe that the issue we were originally investigating using these increased timeouts was the fault of my earlier ISP in SW Virginia. I can't recall reproducing the exact issue on other networks.
2025-08-01 14:52:47 +02:00
Valere d294be8bd4 custom error for restricted SFU config error 2025-07-31 17:18:02 +02:00
Timo 6f0ffa84dc Merge branch 'livekit' into robin/behaviors 2025-07-14 19:03:18 +02:00
TimoandGitHub 8458d198c9 Fix bluetooth iOS issue (device auto switches from Bluetooth to speaker) (#3388)
* fix ios bluetooth

Signed-off-by: Timo K <toger5@hotmail.de>

* fix lints

Signed-off-by: Timo K <toger5@hotmail.de>

---------

Signed-off-by: Timo K <toger5@hotmail.de>
2025-07-14 12:53:09 +02:00
Robin 32bf1c30d2 Use Behaviors even more consistently 2025-07-11 23:53:59 -04:00
RobinandGitHub 3ffb118dc7 Modernize how we use React contexts (#3359)
* Replace useContext with use

The docs recommend the use hook because it is simpler and allows itself to be called conditionally.

* Simplify our context providers

React 19 lets you omit the '.Provider' bit.
2025-06-24 10:48:35 +02:00
5e2e94d794 Refactor media devices to live outside React as Observables (#3334)
* Refactor media devices to live outside React as Observables

This moves the media devices state out of React to further our transition to a MVVM architecture in which we can more easily model and store complex application state. I have created an AppViewModel to act as the overarching state holder for any future non-React state we end up creating, and the MediaDevices reside within this. We should move more application logic (including the CallViewModel itself) there in the future.

* Address review feedback

* Fixes from ios debugging session: (#3342)

- dont use preferred vs selected concept in controlled media. Its not needed since we dont use the id for actual browser media devices (the id's are not even actual browser media devices)
  - add more logging
  - add more conditions to not accidently set a deviceId that is not a browser deviceId but one provided via controlled.

---------

Co-authored-by: Timo <16718859+toger5@users.noreply.github.com>
2025-06-20 18:37:25 +02:00
TimoandGitHub 02f3f1b71a Improvements to audio renderer codebase. (#3308)
* Improvements to audio renderer codebase.

* review
2025-06-10 13:00:21 +00:00
TimoandGitHub a596eb71a9 add onAudioPlaybackStarted callback for controls (#3309)
* add onAudioTrackReady callback for controls

* more details in controls.md for `onAudioPlaybackStarted`
2025-06-10 12:35:04 +02:00
RobinandGitHub c8a1cae18b Merge pull request #2874 from element-hq/renovate/major-react-monorepo
Update react monorepo to v19 (major)
2025-06-09 11:59:26 -04:00
Robin 8704b44b78 Update test snapshots for React 19 changes 2025-06-09 11:48:01 -04:00
Timo 34724b7a8c revert "custom compare logic" 2025-06-05 14:39:06 +02:00
Timo b005f36ac7 custom compare logic 2025-06-05 14:36:43 +02:00
Robin 15bcaef3a5 Use the same function for deep equality everywhere 2025-06-04 17:41:42 -04:00
2f3e0b419d Leave issue refactor (#3302)
* Simplify key local storage management.

* Refactor useLivekit to only ever connect to one room.
This change also tries to make the code more explicit so that we only do the things we really need to do and rely less on react updating everything correctly.

It also surfaces, that we are currently implementing useLivekit in a way, so that we can change the encryption system on the fly and recreate the room. I am not sure this is a case we need to support?

* simplify the useLivekit hook even more
This is possible because we concluded that we do not need to be able to hot reload the e2ee system.

* review

* linter

* Update src/room/InCallView.tsx

Co-authored-by: Robin <robin@robin.town>

---------

Co-authored-by: Robin <robin@robin.town>
2025-06-04 20:51:13 +00:00
Robin 40b351d76d Ignore spurious 'devicechange' events
This gives us the additional insurance of breaking the Safari media acquisition loop at the source by admitting that they can be spurious in practice. Safari, why!?
2025-06-04 11:23:20 -04:00
Timo b8951944ab start with a couple of more logs 2025-05-27 17:38:45 +02:00
5374342d98 Disable device switching when in controlled audio devices mode (#3290)
* Disable device switching when in controlled audio devices mode

* Temporarily switch matrix-js-sdk to robin/embedded-no-update-state

To allow us to test this change on Element X, which does not yet support the update_state action.

* Also add a check for controlled audio devices in useAudioContext

* use develop branch

* fix tests

---------

Co-authored-by: Robin <robin@robin.town>
2025-05-23 15:54:47 +00:00
Timo f0403c80bc also add non deprecated audio url parameter 2025-05-22 19:18:04 +02:00
Timo 9f84a5cae0 Deprecate old naming and introduce new words 2025-05-22 18:58:18 +02:00
Timo a056a28423 review 2025-05-21 12:53:17 +02:00
Timo 435a7d0adb earpice -> earpiece 2025-05-20 16:37:14 +02:00
Timo a1759a46de rename everything to controlledMediaDevices to make it consistent with the actual name in the url parameters (controlledOutput is now only used for the hook that provides the output handle) 2025-05-20 15:30:02 +02:00
Timo 0412629871 fix start with for output devices. 2025-05-20 10:14:08 +02:00
Timo ed234a1ad1 change label on button 2025-05-19 19:44:19 +02:00
Timo 6d0697cf2f inform ios about earpice mode 2025-05-19 18:44:48 +02:00
Timo 5d6ec19ca0 Allow some controls to be set before the call view is loaded. 2025-05-19 14:14:08 +02:00
Timo 7f4b0a33f6 isBluetooth -> isExternalHeadset 2025-05-16 17:06:54 +02:00
Timo 35963bbc9e Add flags to optimize EC device handling 2025-05-16 15:50:19 +02:00
Timo acaf69ca1b add change audio button with callback on ios 2025-05-16 12:28:49 +02:00
Timo 7227c7b368 Merge branch 'livekit' into robin/audio-output-controls 2025-05-16 11:36:33 +02:00
Timo 2012b09845 review cleanup 2025-05-16 11:32:32 +02:00
TimoandGitHub b5fe55aef2 Add custom audio renderer for iPhone earpiece and only render joined participants (#3249)
* Add custom audio renderer to only render joined participants & add ios earpice workaround

fix left right to match chromium + safari
(firefox is swapped)

earpice as setting

Simpler code and documentation
The doc explains, what this class actually does and why it is so complicated.

Signed-off-by: Timo K <toger5@hotmail.de>

use only one audioContext, remove (non working) standby fallback

* Add tests

* use optional audio context and effect to initiate it + review
2025-05-15 20:46:39 +02:00
Timo 610e792394 rename setOutputDevices-> setAvailableOutputDevices 2025-05-15 17:20:12 +02:00
Timo 7fa534d70d refactor
- `MediaDevice`->`MediaDeviceHandle`
 - use just one provider and switch inside the
 MediaDevicesProvider between: controlledAudioOutput, webViewAudioOutput
 - fix muteAllAudio
2025-05-15 15:34:35 +02:00
Timo c8091ac111 Quickfix for testing 2025-05-15 11:37:01 +02:00
Timo f69c75322f add earpice mode 2025-05-14 19:55:08 +02:00
Timo f9b04ae38e temp 2025-05-14 19:07:36 +02:00
RobinandTimo 53adfa4497 WIP 2025-05-14 19:07:36 +02:00
86d80630c1 Fix connection leaks: Ensure that any pending connection open are cancelled/undo when ActiveCall is unmounted (#3255)
* Better logs for connection/component lifecycle

* fix: `AudioCaptureOptions` was causing un-necessary effect render

AudioCaptureOptions was a different object but with same internal values, use directly deviceId so that Object.is works properly

* fix: Livekit openned connection leaks

* review: rename to AbortHandles

* review: rename variable

---------

Co-authored-by: Timo <toger5@hotmail.de>
2025-05-14 18:41:22 +02:00
Timo 18a59dd7db use optional audio context and effect to initiate it + review 2025-05-14 17:23:42 +02:00
Timo 6b8c620bbb Add tests 2025-05-14 10:59:23 +02:00