Merge pull request #4 from TheNeikos/claude/fix-screenshare-stream-43ABB
Hide share button on browsers that lack getDisplayMedia
This commit is contained in:
commit
bd3a5e2af0
1 changed files with 3 additions and 2 deletions
|
|
@ -1004,8 +1004,9 @@
|
|||
// Update peer count
|
||||
peerCount.textContent = state.peers.size;
|
||||
|
||||
// Update sharing buttons
|
||||
startShareBtn.classList.toggle('hidden', state.isSharing);
|
||||
// Update sharing buttons (hide entirely if browser lacks getDisplayMedia)
|
||||
const canShare = !!navigator.mediaDevices?.getDisplayMedia;
|
||||
startShareBtn.classList.toggle('hidden', state.isSharing || !canShare);
|
||||
stopShareBtn.classList.toggle('hidden', !state.isSharing);
|
||||
|
||||
// Update screen list
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue