Commit Graph
100 Commits
Author SHA1 Message Date
RobinandGitHub 8f841dfb59 Merge pull request #3363 from element-hq/toger5/fix-initial-device-selection-in-controlled-devices-mode
Fix initial selection when using controlled media
2025-06-25 13:47:42 -04:00
Robin f4d590c703 Use consistent name for preferred device IDs 2025-06-25 13:42:31 -04:00
Robin f3419f94c3 Fix empty string IDs not counting as devices 2025-06-25 13:40:39 -04:00
Robin 3b1ce22b71 Fold map operation into combineLatest 2025-06-25 13:38:47 -04:00
RobinandGitHub daa931c3c4 Merge pull request #3358 from element-hq/robin/remove-forward-ref
Remove usages of forwardRef
2025-06-24 08:32:03 -04:00
Robin 0f8c4675cf Make condition simpler 2025-06-24 08:28:15 -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
Robin 0c27610119 Remove usages of forwardRef
It has been deprecated in React 19, which allows functional components to receive refs just like any other prop.
2025-06-23 23:06:33 -04:00
RobinandGitHub f86c9fe0a0 Merge pull request #3355 from element-hq/renovate/major-compound
Update dependency @vector-im/compound-web to v8
2025-06-23 22:10:07 -04: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
RobinandGitHub 7f4a5a8bab Merge pull request #3338 from element-hq/renovate/compound
Update dependency @vector-im/compound-design-tokens to v4.0.4
2025-06-16 08:50:53 -04: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 4f1450aaf0 Replace react-use-clipboard with copy-to-clipboard
We didn't need the complexity of the (admittedly very small) React hook, and the package hasn't declared compatibility with React 19, so let's just switch to copying things manually via copy-to-clipboard.
2025-06-09 11:53:58 -04:00
Robin 8704b44b78 Update test snapshots for React 19 changes 2025-06-09 11:48:01 -04:00
Robin 0ee11af3c5 Upgrade react-spring to v10
For React 19 compatibility.
2025-06-09 11:47:47 -04:00
RobinandGitHub e0ce58b2a2 Merge pull request #3320 from element-hq/revert-3319-revert-3313-misc/migrate-to-maven-central-portal
Upgrade Android publishing to use Maven Central Portal (again)
2025-06-06 10:18:20 -04:00
RobinandGitHub b0587fcfb3 Avoid reactivity bugs in how we track external state (#3316)
* Avoid reactivity bugs in how we track external state

Many of our hooks which attempt to bridge external state from an EventEmitter or EventTarget into React had subtle bugs which could cause them to fail to react to certain updates. The conditions necessary for triggering these bugs are explained by the tests that I've included.

In the majority of cases, I don't think we were triggering these bugs in practice. They could've become problems if we refactored our components in certain ways. The one concrete case I'm aware of in which we actually triggered such a bug was the race condition with the useRoomEncryptionSystem shared secret logic (addressed by a1110af6d5).

But, particularly with all the weird reactivity issues we're debugging this week, I think we need to eliminate the possibility that any of the bugs in these hooks are the cause of our current headaches.

* Reuse useTypedEventEmitterState in useLocalStorage

* Fix type error
2025-06-05 13:54:57 +02:00
RobinandGitHub 7851b9c289 Merge pull request #3318 from element-hq/robin/deep-compare
Use the same function for deep equality everywhere
2025-06-04 18:12:08 -04:00
Robin 15bcaef3a5 Use the same function for deep equality everywhere 2025-06-04 17:41:42 -04:00
RobinandGitHub 26efbc1389 Merge pull request #3317 from element-hq/robin/reactive-members
Always render audio from the current set of participants
2025-06-04 17:25:29 -04:00
Robin 929367c9ce Always render audio from the current set of participants
We forgot to tell React that we need the audio renderer to react to changes in the set of MatrixRTC participants; instead we had it referencing rtcSession.memberships non-reactively.

Now, I'm not 100% confident that this is going to fix the "speaking from the void" issues observed in the wild, because I can't reproduce them and, in my testing, the InCallView component always seemed to be rendered redundantly when the MatrixRTC participants change, even though we hadn't explicitly stated that it needs to react. (This makes sense as we haven't memoized the component.) But it's worth a shot.
2025-06-04 17:21:48 -04:00
RobinandGitHub ef41ef85eb Merge pull request #3311 from element-hq/robin/break-safari-loop
Break loop in acquiring media on Safari
2025-06-04 11:58:56 -04:00
RobinandGitHub d9b91778b1 Merge pull request #3304 from element-hq/renovate/embedded-package-dependencies
Update embedded package dependencies
2025-06-04 11:56:52 -04:00
RobinandGitHub 2f6bae5e5e Merge pull request #3313 from element-hq/misc/migrate-to-maven-central-portal
Upgrade Android publishing to use Maven Central Portal
2025-06-04 11:56:11 -04: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
Robin 83bfb721e7 Break loop in acquiring media on Safari 2025-06-03 17:22:20 -04:00
RobinandGitHub 64e27152c6 Merge pull request #3307 from element-hq/renovate/livekit-components
Update dependency @livekit/components-react to v2.9.9
2025-06-03 09:40:48 -04:00
RobinandGitHub f4a5ca9e84 Merge pull request #3306 from element-hq/renovate/compound
Update dependency @vector-im/compound-design-tokens to v4.0.3
2025-06-03 09:39:26 -04:00
RobinandGitHub 931cc9ddd7 Merge pull request #3305 from element-hq/renovate/all-minor-patch
Update all non-major dependencies
2025-06-03 09:27:44 -04:00
Robin 65846dcf7d Revert eslint-plugin-matrix-org to 2.1.0
See 7eae5b0ffb.
2025-06-03 09:22:44 -04:00
RobinandGitHub 5f8a8d4c5b Merge pull request #3294 from element-hq/fkwp/docker_compose/resolve_conflicting_ports
Fix Playwright tests
2025-05-30 10:42:05 -04:00
RobinandGitHub d2534748eb Merge pull request #3300 from element-hq/robin/synchronize-blocked
Run the 'Prevent blocked' check whenever a PR branch is updated
2025-05-30 10:26:10 -04:00
RobinandGitHub fbafc9f3f6 Merge pull request #3301 from element-hq/renovate/npm-vite-vulnerability
Update dependency vite to v6.2.7 [SECURITY]
2025-05-28 18:20:30 -04:00
RobinandGitHub 61d2da2259 Merge pull request #3036 from element-hq/renovate/major-compound
Update dependency @vector-im/compound-design-tokens to v4
2025-05-28 18:13:37 -04:00
Robin 0661486676 Merge branch 'livekit' into renovate/major-compound 2025-05-28 18:07:30 -04:00
Robin 07a4244c05 Upgrade Compound Web to v7.12.0 2025-05-28 18:04:29 -04:00
RobinandGitHub 03f92ed6e4 Merge pull request #3172 from element-hq/renovate/livekit-components
Update LiveKit components
2025-05-28 17:43:07 -04:00
Robin 469ec63fec Fix LiveKit types import 2025-05-28 17:34:33 -04:00
Robin 50caca7bd3 Merge branch 'livekit' into renovate/livekit-components 2025-05-28 17:26:03 -04:00
RobinandGitHub 81caa3321f Merge pull request #3186 from element-hq/renovate/all-minor-patch
Update all non-major dependencies
2025-05-28 17:22:38 -04:00
Robin 3c3fce96e7 Upgrade to OpenTelemetry v2 SDKs
Necessitated by our minor version upgrade of @opentelemetry/exporter-trace-otlp-http.
2025-05-28 17:17:31 -04:00
Robin e757f7af6b Run the 'Prevent blocked' check whenever a PR branch is updated
Because we're now requiring the 'Prevent blocked' check to pass before merging a PR, GitHub Actions now expects it to be associated with the latest Git ref of the PR's branch whenever the branch is updated. Therefore we need to re-run the workflow on the 'synchronize' event.
2025-05-28 17:00:57 -04:00
Robin 7eae5b0ffb Revert eslint-plugin-matrix-org to 2.1.0
Because the latest version requires eslint-plugin-unicorn v57, which requires eslint v9, and eslint-plugin-matrix-org is not yet compatible with eslint v9.
2025-05-28 16:25:21 -04:00
RobinandGitHub 0971a15c40 Merge pull request #3270 from element-hq/robin/audio-output-controls
Audio device controls for mobile native audio device selection
2025-05-22 14:09:04 -04:00
Robin 78c59bb41c Fix formatting 2025-05-22 14:03:33 -04:00
Robin 045d861ad1 Merge branch 'livekit' into robin/audio-output-controls 2025-05-22 14:00:19 -04:00
RobinandGitHub a21da9417c Merge pull request #3285 from element-hq/robin/reset-develop
Reset to develop branch of matrix-js-sdk
2025-05-22 13:10:56 -04:00
Robin 821c6e3763 Reset to develop branch of matrix-js-sdk
Now that the toger5/add-room-key-fallback-on-encryption-manager-not-supported branch has been merged, we can reset to develop. (And need to, actually, because that branch is deleted.)
2025-05-22 11:59:36 -04:00
RobinandGitHub aeae964e97 Merge pull request #3177 from element-hq/robin/reintroduce-update-state
Improve the reliability of state changes in widget mode
2025-05-21 13:09:13 -04:00
Robin e4924df8fb Reference matrix-js-sdk by branch name
Rather than by commit, which makes it hard to tell whether we're using mainline matrix-js-sdk or not.
2025-05-21 12:59:31 -04:00
Robin c473d1fa8f Update matrix-widget-api to support update_state action 2025-05-20 17:54:57 -04:00
Robin 57f312494f Update matrix-js-sdk to support update_state action 2025-05-20 17:54:30 -04:00
RobinandTimo 53adfa4497 WIP 2025-05-14 19:07:36 +02:00
RobinandGitHub 6281628e4e Merge pull request #3258 from element-hq/robin/webcodecs-update
Remove patched version of WebCodecs types
2025-05-09 10:54:23 -04:00
Robin 9f727b904b Remove patched version of WebCodecs types
The patch has now been upstreamed to @types/dom-webcodecs.
2025-05-09 10:48:09 -04:00
RobinandGitHub a4a6a16482 Merge pull request #2812 from element-hq/toger5/track-processor-blur
Add background blur feature for supported devices
2025-04-29 22:25:02 +02:00
Robin eeb3a1a991 Add license notices to inlined type declarations 2025-04-29 22:19:00 +02:00
Robin c0c498aa04 Merge branch 'livekit' into toger5/track-processor-blur 2025-04-29 13:02:23 +02:00
Robin 9f5eae0ac1 Clean up a string 2025-04-29 13:02:02 +02:00
RobinandGitHub f92c683bc1 Merge pull request #3237 from element-hq/robin/fix-playwright-invite
Fix Playwright tests in Firefox
2025-04-29 13:01:45 +02:00
Robin dfb9eb4b1f Upgrade Playwright to fix Element's unsupported browser warning 2025-04-29 12:41:23 +02:00
Robin fa0af6403e Fix Playwright tests in Firefox
As explained by the comment.
2025-04-29 12:25:35 +02:00
Robin 9df0f58117 Inline a patched version of WebCodecs types 2025-04-29 12:07:16 +02:00
Robin 0b82dcf701 Upgrade TypeScript for ImageBufferSource support 2025-04-28 18:10:58 +02:00
Robin 8f1761442b Fix tests 2025-04-28 16:37:53 +02:00
Robin 7d0117903e Don't lie about the type of the video track 2025-04-28 16:01:34 +02:00
Robin cd9035b5fc Make background blurring actually react to track restarts 2025-04-28 16:00:03 +02:00
Robin 02ce1f701a Document the background transformer a bit better 2025-04-28 15:59:32 +02:00
Robin e88e0b1901 Import the segmenter model in a more statically-analyzable way 2025-04-28 15:58:50 +02:00
Robin c91cc79162 Remove unneeded Knip override for MediaPipe 2025-04-28 15:57:29 +02:00
Robin 31032994a5 Merge branch 'livekit' into toger5/track-processor-blur 2025-04-25 17:23:20 +02:00
RobinandGitHub dc5d1369bf Merge pull request #3229 from element-hq/robin/upgrade-livekit
Return to latest livekit-client version (2.11.3)
2025-04-24 11:35:29 +02:00
Robin a6696c2304 Return to latest livekit-client version (2.11.3)
This latest release of livekit-client fixes the regression observed in https://github.com/element-hq/element-call/issues/3219.
2025-04-23 11:59:13 +02:00
Robin 3fc4cc908e Cleanup + use a better check for blurring support 2025-04-22 19:20:43 +02:00
Robin 63ad4a3ad3 Get blurring working again 2025-04-22 18:32:01 +02:00
Robin 7142122a74 Dedupe Mediapipe dependencies 2025-04-22 18:05:31 +02:00
Robin b7b3fde202 Upgrade LiveKit track processors 2025-04-22 18:00:41 +02:00
RobinandGitHub 8fd99ed23e Merge pull request #3222 from element-hq/robin/revert-livekit
Revert livekit-client to 2.10.0
2025-04-22 17:21:45 +02:00
Robin e751248fee Revert livekit-client to 2.10.0
Closes https://github.com/element-hq/element-call/issues/3219.
2025-04-22 16:31:44 +02:00
Robin 3243afd061 Merge branch 'livekit' into toger5/track-processor-blur 2025-04-18 12:32:03 +02:00
RobinandGitHub f845397b87 Merge pull request #3093 from element-hq/toger5/src-to-lib-import
Transition from consuming js-sdk source to `lib` (build output)
2025-03-27 16:13:05 -04:00
Robin aab4efe03a Use type imports consistently 2025-03-27 16:09:59 -04:00
Robin eb18cbef78 Consolidate imports 2025-03-27 16:04:03 -04:00
Robin ae339ea5cc Fix formatting issues 2025-03-27 14:47:01 -04:00
Robin 33700d1529 Merge branch 'livekit' into toger5/src-to-lib-import 2025-03-27 14:35:08 -04:00
RobinandGitHub 21140f6f2c Merge pull request #3095 from element-hq/robin/berry
Upgrade to Yarn v4 (Berry)
2025-03-27 14:21:10 -04:00
Robin 6927a92ad3 Improve comments in linker plugin 2025-03-27 14:16:16 -04:00
Robin f99eb3c88f Merge branch 'livekit' into robin/berry 2025-03-27 14:07:24 -04:00
Robin a993d8cd26 Streamline the linker hook messages 2025-03-27 14:05:10 -04:00
RobinandGitHub fe382cfc0b Merge pull request #3053 from element-hq/robin/posthog-logout
Enable analytics only while authenticated
2025-03-24 10:14:48 -04:00
Robin 0ed1564d3e Merge branch 'livekit' into robin/posthog-logout 2025-03-24 10:10:28 -04:00
RobinandGitHub 1138a21b57 Merge pull request #3118 from element-hq/robin/errors-outside-boundary
Fix join errors mistakenly showing a generic error screen
2025-03-21 17:20:52 -04:00
Robin cd5ecb2352 Rename error boundary hook
It doesn't check whether it's actually used inside a GroupCallErrorBoundary, and it's generally useful for interacting with any error boundary, so I'm giving it a generic name to reflect this.
2025-03-21 15:17:41 -04:00
Robin 9a5dd10e27 Show errors that occur in GroupCallView using the error boundary
We were previously using the useGroupCallErrorBoundary hook to surface errors that happened during joining, but because that part is outside the GroupCallErrorBoundary it just ended up sending them to the app-level error boundary where they got displayed with a more generic message.
2025-03-21 14:59:27 -04:00
RobinandGitHub 246e6a6322 Merge pull request #3111 from element-hq/robin/test-ci
Move all tests into one workflow, give them clear names
2025-03-19 09:57:55 -04:00
RobinandGitHub 4a2f44a0de Merge pull request #3112 from element-hq/robin/blocked-conflicts
Run the 'prevent blocked' workflow even if PR has conflicts
2025-03-18 15:43:21 -04:00
Robin a304f37705 Run the 'prevent blocked' workflow even if PR has conflicts
See the description of pull_request versus pull_request_target documented at https://docs.github.com/en/actions/writing-workflows/choosing-when-your-workflow-runs/events-that-trigger-workflows#pull_request.
2025-03-18 14:45:07 -04:00
Robin f2ff1919cb Move all tests into one workflow, give them clear names
The Playwright tests had no name before, making it confusing to add them to the branch protection requirements.
2025-03-18 13:48:52 -04:00
RobinandGitHub 7d6a60a6ad Merge pull request #3110 from element-hq/robin/participant-limits
Show "insufficient capacity" when hitting participant limits
2025-03-18 13:37:43 -04:00
Robin 45c3c7a37e Show "insufficient capacity" when hitting participant limits 2025-03-18 13:33:36 -04:00