zebra-report: deploy — screen PC failure asks user to re-share

This commit is contained in:
russell@unturf.com 2026-06-03 12:45:40 -04:00
parent 1cddcda111
commit 119c406b8d
No known key found for this signature in database

View file

@ -2188,9 +2188,16 @@ async function sfuPublishScreen(){
if (s.track.kind === 'video') setSenderMaxBitrate(s, 6000000);
if (s.track.kind === 'audio') setSenderMaxBitrate(s, 256000);
}
watchPublishPC(pc, 'screen', sfuPublishScreen,
() => sfuScreenPC === pc,
() => { sfuScreenPC = null; sfuScreenPeerID = null; sfuScreenStream = null; });
/* Screen share CANNOT auto-rebuild like mic + camera — getDisplayMedia
* requires a fresh user gesture (transient activation). Auto-calling
* sfuPublishScreen() after a 'failed' state just fires the picker
* with no gesture and gets rejected. Instead: tear down on failed
* + surface the share button so the user can re-trigger themselves. */
pc.onconnectionstatechange = () => {
if (pc.connectionState !== 'failed' || sfuScreenPC !== pc) return;
logLine('err', 'sfu screen publish PC failed — tap "share screen" to re-share (browsers need a fresh click for screen capture)');
sfuUnpublishScreen().catch(()=>{});
};
logLine('', 'sfu: sharing screen as '+sfuScreenPeerID);
/* render a muted local preview so the publisher sees what they're
* sharing — SFU does not echo the publisher's own stream back */
@ -4003,8 +4010,8 @@ logLine('', 'ready — pick a handle, type a rendezvous code, enter the space');
<footer style="margin:2.2rem auto 0;font-size:0.65rem;color:#999;line-height:1.7;word-break:break-all;font-family:monospace">
<span id="pi-seal" style="color:#777;cursor:default;user-select:none" title="">page integrity</span> &nbsp;·&nbsp; built <span class="stamp-date">2026-06-03</span><br>
md5 <span class="stamp-md5">888efaf377b48e7e98a4f0abc676b5d6</span><br>
sha256 <span class="stamp-sha">43bc28425870401088dfc50fe4541f4a9790a3e0d84b6b6aa09ec01eceb56cd3</span><br>
md5 <span class="stamp-md5">e8f5b7a27ce32f07e7433dcc2cdd9b69</span><br>
sha256 <span class="stamp-sha">c95935103900464bbfa3e5259a0fb2a667bb06fd44084595f1749e03375870e1</span><br>
<span style="color:#bbb">hashes are of this page with these two fields zeroed — to verify, blank them and re-hash</span><br>
<span style="color:#bbb">one self-contained file — <strong>save a copy</strong> and verify against these hashes; point at your own servers with ?signal= and ?turncred=, or <a href="host-your-own.html" style="color:#999">host your own community</a></span>
</footer>