From cd0b6a74d963a165ee945e648e4eadfd1308da81 Mon Sep 17 00:00:00 2001 From: Russell Ballestrini Date: Thu, 4 Jun 2026 12:52:30 -0400 Subject: [PATCH] =?UTF-8?q?zebra-spaces:=20kicked-self=20UI=20=E2=80=94=20?= =?UTF-8?q?hollow=20dot,=20leave/mute=20buttons=20hidden,=20status=20updat?= =?UTF-8?q?ed?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fox 2026-06-04: 'when a listener is kicked the get the green left states and still have a leave button even though they are out of the room — should be gone'. The peer-booted (self) branch tore down PCs + mic + cleared ACTIVE_CALL_KEY but left the UI looking like a connected listener — green dot, leave button visible, status still saying 'connected as listener'. Fix in the same case 'peer-booted' branch where m.uuid === myUUID: - dot flips to 'dot warn' (hollow / amber), not 'dot ok' (green) - status flips to 'kicked from this space' (or 'banned' if action=ban) - btn-leave hidden + disabled (no room to leave from anymore) - btn-mute hidden + disabled (no mic to toggle) - btn-enter re-enabled so the user can manually rejoin if they want --- web/zebra-spaces.html | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/web/zebra-spaces.html b/web/zebra-spaces.html index df01c8f..dee4665 100644 --- a/web/zebra-spaces.html +++ b/web/zebra-spaces.html @@ -4003,6 +4003,20 @@ async function handleSignal(raw){ sfuUnpublishGame().catch(()=>{}); sfuUnsubscribe().catch(()=>{}); dropMic(); + /* UI: kicked-self should NOT look like a connected listener + * still in the room. Flip dot from green/connected to a + * hollow/warn state, drop the leave button (already left), + * disable the mute button, and reset the status line. Fox + * 2026-06-04: 'kicked listener gets green left state and + * still has a leave button even though they are out of the + * room — should be gone'. */ + $('dot-call').className = 'dot warn'; + setStatus(m.action === 'ban' ? 'banned from this space' : 'kicked from this space', 'warn'); + $('btn-leave').classList.add('hidden'); + $('btn-leave').disabled = true; + $('btn-mute').classList.add('hidden'); + $('btn-mute').disabled = true; + $('btn-enter').disabled = false; } /* Authoritative tile teardown by pubkey — booted users can't be * publishing anything anymore by definition. The SFU side eviction @@ -5461,8 +5475,8 @@ logLine('', 'ready — pick a handle, type a rendezvous code, enter the space');