fix(lotus): Wave-1 audit fixes (EC1–EC6)
- EC1: lotusQuality — track + clearTimeout the 500ms settle re-apply per room
(was leaking a timer that fired on torn-down rooms).
- EC2/EC3: lotusQuality + lotusAudioInject drive off vm.allConnections$ instead
of the remote-gated livekitRoomItems$ (were no-ops when alone), matching
lotusDenoise.
- EC4: lotusDecorations resets its roster to {} on teardown so a decoration from
a previous call can't render on a shared user in the next one.
- EC5: hoisted a stable useSyncExternalStore subscribe fn (was re-subscribing
every tile render).
- EC6: lotusFocus only sets the spotlight when the userId field is present
(a partial payload no longer clears the pin).
tsc clean. Needs a republish to ship.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
02666c0c04
commit
0ffe247929
@@ -38,10 +38,13 @@ export function startLotusAudioInject(vm: CallViewModel): () => void {
|
||||
const w = widget;
|
||||
if (!w) return () => undefined;
|
||||
|
||||
// Track the set of connected LiveKit rooms to publish into.
|
||||
// Track the set of connected LiveKit rooms to publish into. Drive off the
|
||||
// LOCAL participant's connection(s), not `livekitRoomItems$` — that stream
|
||||
// omits rooms with no remote members, so inject would no-op while you're
|
||||
// alone. Map the connections to their livekit rooms like `lotusDenoise.ts`.
|
||||
let rooms: LivekitRoom[] = [];
|
||||
const sub = vm.livekitRoomItems$.subscribe((items) => {
|
||||
rooms = items.map((i) => i.livekitRoom);
|
||||
const sub = vm.allConnections$.subscribe((data) => {
|
||||
rooms = data.getConnections().map((c) => c.livekitRoom);
|
||||
});
|
||||
|
||||
// In-flight clips, so we can abort them on teardown (unmount / vm change /
|
||||
|
||||
Reference in New Issue
Block a user