WatchDis, peer-to-peer video & voice chat with low latency.
Prompts:
create a single-page static (HTML, CSS, JS only) webapp called "WatchDis" that uses PeerJS and other imported libraries to allow users to easily create a voice/video chat room and allow others to connect by just sharing a link or QR code and uses /? URL parameters for easily inserting peer IDs and reconnecting. There should be lots of error handling elaborately explaining what went wrong. The UI should be flexible to fit in unique layouts depending on mobile or desktop device view. The UI should be like the latest version of Google Material UI and use their principles, including the Roboto Flex font. Use icons + text combinations everywhere. Allow proper mic and camera accessing + gracefully continuing if any access is denied and can later re-ask for permission again. There should be light and dark theme switch. Should allow screen sharing and also automatically change the video bandwidth/resolution so that everything happens in real-time lag-free. Show network speeds and details in the corner of every user's 'frame'. Add any other features that you think might be useful here.