Commit Graph

16 Commits (master)

Author SHA1 Message Date
Noah 9c77bdb62e New Op commands and fixes with blocking admin users
Add moderation rules:

* You can apply rules in the settings.toml to enforce moderator restrictions on
  certain users, e.g. to force their camera to always be NSFW or bar them from
  sharing their webcam at all anymore.

Chat UI improvements around users blocking admin accounts:

* When a main website block is in place, the DMs button in the Who List shows
  as greyed out with a cross through, as if that user had closed their DMs.
* Admin users are always able to watch the camera of people who have blocked
  them. The broadcaster is not notified about the watch.

New operator commands:

* /cut username: to tell a user to turn off their webcam.
* /unmute-all: to lift all mutes on your side, e.g. so your moderator chatbot
  can still see public messages from users who have blocked it.
* /help-advanced: moved the more dangerous admin command documentation here.

Miscellaneous fixes:

* The admin commands now tolerate an @ prefix in front of usernames.
* The /nsfw command won't fire unless the user's camera is actually active and
  not marked as explicit.
2024-05-17 17:15:48 -07:00
Noah f36c83dbcc Add receive-only transceivers to remove Apple compat mode
* WebRTC functionality is now 100% working as intended for Safari and
  iPad browsers!
* The legacy WebRTC API had properties like offerToReceiveVideo
  available on createOffer(), to set up a receive-only channel, but the
  modern WebRTC API had removed these and Safari only supports the
  modern API.
* The modern solution for the same feature is to add a recvonly
  transceiver to the connection in place of offering a local video/audio
  stream to share.
2024-05-08 12:44:15 -07:00
Noah f094213a34 Improve WebRTC connection for Safari browsers 2024-05-07 20:54:13 -07:00
Noah 92a376786d Update to Bulma CSS 1.0
* Update the CSS and add a theme selector to the Chat Settings to force a
  light or dark mode theme (default is automatic).
2024-04-06 14:35:52 -07:00
Noah 8e87c377e8 Apple compatibility mode for WebRTC
* Try a new strategy to get Apple (iPad/iPhone) webcams to connect.
* "Apple compatibility mode" setting: on by default if iPad/iPhone is
  detected or can be opted into in the chat settings Misc tab.
* In Apple compat mode: when you open someone else's webcam, you always
  attach your local video on the WebRTC offer. This would normally make
  your video auto-open on the remote side, but the previous commit
  updates the chat page to ignore offered video if you did not opt-in to
  auto-open your viewer's camera.
* This should satisfy the two-way video call limitation in Safari: the
  iPad always shares its video and gets video from the person they are
  watching.
* If the person they are watching did not auto-open your video: they
  ignore the attached video on your offer and don't display it.
2024-01-11 20:33:57 -08:00
Noah bf59a7b6c9 Auto-mute other users' webcam sound channels 2024-01-11 19:45:32 -08:00
Noah 27380ec558 Status Message overhaul 2023-12-30 14:50:52 -08:00
Noah 0e0aac991d Polling API for the chat room 2023-12-10 18:43:18 -08:00
Noah d57d41ea3a Abstract WebSocket client into library 2023-12-10 16:09:00 -08:00
Noah fea1d1c7b9 Prefers non-explicit and option to expressly remember closed videos 2023-10-14 12:24:30 -07:00
Noah b5d0885c23 Compact-style message display options 2023-09-30 14:53:43 -07:00
Noah dbfd45794a More safely parse JSON from localStorage 2023-09-07 21:03:15 -07:00
Noah 8853f9882b Store sort order and explicit setting to localStorage 2023-09-07 20:05:52 -07:00
Noah d8cb1c7c11 Refactor more Vue components
Spin out components for:
* MessageBox: draw a chat message in the chat history panel as well as reused
  in the Report Modal.
* WhoListRow: provides a consistent UX for the Who List and Watching tab. On
  the Watching tab, the video button is replaced with the boot from video.

Other changes:
* Move VideoFlag into its own separate ES module.
* Emoji available reactions are moved into MessageBox.
* On WhoListRow: usernames are clickable to also open their profile page.
* On WhoListRow: the Watching tab is now sortable and follows the user's
  sort selection like the Online tab does.
2023-09-07 19:24:26 -07:00
Noah 8906e89a51 Refactor some modals and features into components
Move some chat modals into external components:
* LoginModal
* ExplicitOpenModal
* ReportModal
* The Photo Modal was hoisted into the main index.html page, because it is not
  a Vue component and relied on global onclick handlers and the DOM.

Spin off some external JS modules:
* isAppleWebkit moved to lib/browsers.js
* Local Storage management centralized and moved to lib/LocalStorage.js
2023-09-06 23:03:12 -07:00
Noah e728644a77 Port front-end over to Vue CLI (create-vue)
This commit makes an initial port of the front-end over to a proper Vue
CLI application. It seems to work from surface level testing.

Changes made:

* Rename web/static to public/static to place it into the Vue build path
  * Notes: web/static/js/BareRTC.js and web/templates/chat.html are now
    deprecated
* Rename web/static/js/sounds.js into src/lib/sounds.js making it a
  proper JavaScript module with exports.
* Fill out initial src/App.vue by copying and updating
  web/templates/chat.html and web/static/js/BareRTC.js into this module.
2023-09-06 17:15:02 -07:00