feat(call): stop injecting CSS and key listeners into the call frame (#43)
CI / Build & Quality Checks (push) Successful in 3m5s
CI / Docker image build & smoke test (push) Skipped
CI / Secret scan (gitleaks) (push) Successful in 9s
CI / Trigger Desktop Build (push) Successful in 8s
CI / Playwright smoke (e2e) (push) Successful in 12m42s
CI / Build & Quality Checks (push) Successful in 3m5s
CI / Docker image build & smoke test (push) Skipped
CI / Secret scan (gitleaks) (push) Successful in 9s
CI / Trigger Desktop Build (push) Successful in 8s
CI / Playwright smoke (e2e) (push) Successful in 12m42s
Pins @lotusguild/element-call-embedded 0.25.0-lotus.19. - Styles: the fork now hides its own footer (`lotusHostControls=1`) and sets its root color-scheme from the theme, so the host no longer injects `#lotus-ec-styles` or sets inline styles on EC's DOM. The two other injected rules matched nothing in EC 0.25 (dead). The transparent background was already the fork's (`lotusTransparent`). - Hotkeys: PTT / deafen keys pressed with focus inside the call frame now arrive as `io.lotus.hotkey` (the host sends the codes via `io.lotus.set_hotkeys`), instead of listeners on the frame's window. The window binding stays only for a fork that doesn't report `hotkeys`. - Fixes (with lotus.19): pressing the deafen key M with focus in the call also hit EC's own "M = toggle mic" shortcut, so the first press turned the mic ON instead of deafening — even in push-to-talk mode. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PPmy3tPq869XDW4njjVaKA
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
024edbf546
commit
502b9dfd83
@@ -0,0 +1,40 @@
|
||||
import { test } from 'node:test';
|
||||
import assert from 'node:assert/strict';
|
||||
import { parseForkHotkeyReport } from './CallControl';
|
||||
|
||||
test('parseForkHotkeyReport: key reports keep only known boolean flags', () => {
|
||||
assert.deepEqual(
|
||||
parseForkHotkeyReport({
|
||||
type: 'keydown',
|
||||
code: 'Space',
|
||||
repeat: false,
|
||||
ctrlKey: false,
|
||||
altKey: 'yes',
|
||||
metaKey: false,
|
||||
shiftKey: true,
|
||||
editable: false,
|
||||
interactive: true,
|
||||
extra: 1,
|
||||
}),
|
||||
{
|
||||
type: 'keydown',
|
||||
code: 'Space',
|
||||
repeat: false,
|
||||
ctrlKey: false,
|
||||
altKey: false,
|
||||
metaKey: false,
|
||||
shiftKey: true,
|
||||
editable: false,
|
||||
interactive: true,
|
||||
},
|
||||
);
|
||||
assert.equal(parseForkHotkeyReport({ type: 'keyup', code: 'KeyM' })?.type, 'keyup');
|
||||
});
|
||||
|
||||
test('parseForkHotkeyReport: focus reports and junk', () => {
|
||||
assert.deepEqual(parseForkHotkeyReport({ type: 'focus' }), { type: 'focus' });
|
||||
assert.equal(parseForkHotkeyReport({ type: 'keydown' }), null);
|
||||
assert.equal(parseForkHotkeyReport({ type: 'click', code: 'Space' }), null);
|
||||
assert.equal(parseForkHotkeyReport(null), null);
|
||||
assert.equal(parseForkHotkeyReport('keydown'), null);
|
||||
});
|
||||
Reference in New Issue
Block a user