Commit Graph
16 Commits
Author SHA1 Message Date
ancsemi 537fdde129 v1.4.7: YouTube fix, PFP upload fix, gray space fix, late joiner streams, /play search, Spotify->YT, PiP opacity, stream PiP overlays 2026-02-13 22:02:54 -05:00
ancsemi e728f1af1c v1.5.0: Channel context menu, Dark Souls campfire rework, mobile leaderboard REST API, effect speed sliders
- Replace gear dropdown with '...' hover button on channel items in sidebar
- Context menu: mute (all users), toggle streams/music, delete (admin-only)
- Dark Souls: 50-75% dimmer, higher reach (55vh), sporadic campfire flicker
- Shippy Container: REST API (/api/high-scores) fallback when window.opener is null (mobile fix)
- Auth token passed to game via URL hash for mobile score submission
- Effect Speed slider for all dynamic-effect themes (CRT, FFX, Ice, Nord, Dark Souls, Bloodborne, Matrix, Cyberpunk, LoTR)
- CSS --fx-mult custom property controls all animation durations
- Theme effect audit: all selectors verified, no mismatches
2026-02-13 11:45:10 -05:00
ancsemi a0409e17fb Fix PFP upload, hide/show streams, pop-out music player, YouTube embed fix
- Fix: PFP upload button - wrapped _initSliderFills Object.defineProperty in try-catch
  so it can't crash the HavenApp constructor and prevent _setupAvatarUpload from running
- Add: Hide/show individual stream tiles - eye button on each tile, hidden-streams bar
  with restore buttons, stream count label shows hidden count
- Add: Pop-out music player - opens YouTube/Spotify/SoundCloud embed in separate window,
  minimizes in-app panel, shows indicator when pop-out window is active
- Fix: YouTube 'Video unavailable' for clients - added origin parameter to embed URL,
  added ws: to CSP connectSrc (required for HTTP-mode Socket.IO connections)
2026-02-12 23:47:28 -05:00
ancsemi 138c7a2b9d v1.4.6: Fix slider tracks, YouTube embeds, double screen share, pop-out soft-lock, music sync, music panel reopen, late joiner music state
- Fix: Slider fill tracks now use injected <style> rules targeting ::-webkit-slider-runnable-track per-slider, bypassing Chrome shadow DOM limitation
- Fix: YouTube embeds use youtube.com/embed/ (not youtube-nocookie.com) to resolve 'Video unavailable' for other users
- Fix: Removed duplicate screen share tile creation from shareScreen() in voice.js
- Fix: PiP leavepictureinpicture event now on video element (not pipWindow)
- Fix: Transparent overlay on music iframes to force synced controls
- Fix: Music panel X minimizes with reopenable indicator in channel header
- Fix: Server tracks active music per voice room and sends to late joiners
2026-02-12 22:45:45 -05:00
ancsemi 2aa3499abe v1.4.4 Profile pictures, modernized emojis, AIM sounds, admin custom sounds
Added:
- User profile picture upload (2MB max, magic-byte validated PNG/JPEG/GIF/WebP)
- Avatar rendering in messages + online-users list with letter fallback
- Socket-based avatar sync (set-avatar event, real-time propagation)
- Emoji picker expanded to 500+ emojis across 10 categories (new: Monkeys, Faces)
- Modern emojis: side-eyes, monkeys, melting face, shushing, etc.
- AIM Classic synthesized sounds: message ding, door open, door close, nudge
- Join/Leave sound selectors in Settings with AIM options
- Admin custom sound upload system (1MB max, MP3/OGG/WAV/WebM)
- Custom sounds management UI with preview + delete
- Audio file playback engine with caching in NotificationManager

Changed:
- Emoji categories restructured from 8 to 10
- CSP mediaSrc updated for audio data URI support
- Message rendering uses img tags for PFP with onerror fallback
- Online users show 24px avatar circles
- All 10 theme avatar borders extended to img variant
2026-02-12 13:56:36 -05:00
ancsemi ed80125ed9 v1.3.9 fix stale-cache command breakage, mobile tap-to-reveal toolbar
Fixed: static file caching changed from 1h maxAge to always-revalidate with ETags, preventing stale JS after server restarts

Improved: mobile message actions (react/reply/pin/edit/delete) hidden by default, revealed with a tap on the message, cleaned up phone UI significantly
2026-02-12 07:18:13 -05:00
ancsemi 7423a83242 v1.3.3: bug fixes, TenorGIPHY migration, custom theme picker
Fixed:
- Upload error handling (check HTTP status before JSON parse)
- Screen share X button (minimize instead of destroy streams)
- Online users visibility (show all connected users server-wide)
- DM button feedback (toast, disable, scroll to channel)

Changed:
- Replaced Tenor GIF API with GIPHY (endpoints, client patterns, README)

Added:
- Custom theme with canvas-based HSV triangle colour picker
- Theme persists in localStorage, applies on page load without flash
2026-02-11 22:10:40 -05:00
ancsemi d7f91ee4da v1.3.2: Security hardening II + QoL features
Security:
- Upload serving: Content-Disposition: attachment for non-images
- Image magic-byte validation (JPEG/PNG/GIF/WebP headers checked)
- CSP tightened: ws: removed, wss: only
- Inline onerror handler replaced with delegated JS listener
- Password min raised to 8 chars
- Account enumeration mitigated on registration

QoL:
- Password change from settings (POST /api/auth/change-password)
- Emoji picker: 8 categories, search bar, 280+ emojis
- /butt slash command
2026-02-11 21:41:58 -05:00
ancsemi 8718754a56 v1.3.1 Security hardening
- GIF endpoints: require auth + rate limit (30/min/IP)

- Health endpoint: strip version fingerprint

- Port 3001 redirect: rate limit, timeouts, fix open redirect

- Link preview: rate limit + DNS rebinding SSRF protection

- HSTS, Permissions-Policy, Referrer-Policy, X-Content-Type-Options

- Server timeouts: headers 15s, request 30s, keepalive 65s, socket 120s
2026-02-11 21:23:08 -05:00
ancsemi 255629d2d4 v1.3.0: DMs, user status, channel topics, file sharing, persistent unread
Features:
- Direct messages: private 1-on-1 via DM button in member list
- User status: online/away/dnd/invisible with custom text + auto-away
- Channel topics: admin-editable topic bar below channel header
- File sharing: upload PDFs, docs, audio, video, archives (25 MB limit)
- Persistent read state: server-tracked unread counts survive refresh

Database:
- New read_positions table for unread tracking
- New columns: users.status, users.status_text
- New columns: channels.topic, channels.is_dm
- New column: messages.original_name
- All migrations are safe for existing DBs

UI:
- Status picker dropdown in sidebar
- DM section in channel list
- File attachment cards with type icons
- Inline audio/video players in chat
- Status dots colored by user status
- Topic bar with click-to-edit for admins

Server:
- /api/upload-file endpoint with expanded MIME whitelist
- set-status, set-channel-topic, start-dm, mark-read socket events
- get-channels returns topic, is_dm, unread counts
- emitOnlineUsers includes status data
- Idle detection with 5-min auto-away
2026-02-11 20:44:05 -05:00
ancsemi 415ff761e4 v1.2.0: comprehensive bug hunt + voice UX + pinning + link previews + GIF search
Security fixes:
- Admin username hijack via rename (critical)
- XSS via unescaped quotes in _escapeHtml (critical)
- SSRF protection on /api/link-preview
- API key leak in get-server-settings to non-admins
- Cross-channel reaction removal without verification
- Voice signaling (offer/answer/ICE) without room membership check
- Typing indicator without channel membership check

Bug fixes:
- Voice audio: single MediaStreamSource splits to analyser + gain
- Talking indicator: 300ms hysteresis for smooth detection
- Screen share: SDP rollback, event.streams[0], track.onunmute
- GIF send broken: wrong property names silently dropped all GIFs
- Reconnect recovery: re-emit channel/state events on socket reconnect
- Screen share privacy: stopScreenShare() on viewer close
- Auto-scroll: force flag after message append
- Delete-user FK violation: clean up all related tables
- Delete-channel: remove associated pinned_messages
- Delete-message: remove associated pinned_messages
- LIKE wildcard injection in search-messages

Performance:
- N+1 query in get-messages replaced with 3 batch queries

Features (from prior uncommitted work):
- Voice join/leave audio cues, talking indicators
- Multi-stream screen sharing with tiled grid
- Message pinning (admin-only, 50/channel cap)
- Enhanced markdown: fenced code blocks, blockquotes
- Link previews with OG metadata + 30min cache
- Tenor GIF search with admin-configurable API key

Docs:
- README updated with new features, voice/screen share docs
- CHANGELOG v1.2.0 entry with full details
- Version bumped to 1.2.0
2026-02-11 20:33:29 -05:00
ancsemi 330e8f6f25 Fix voice audio, talking indicator, screen share, and GIF setup UX
Voice audio (Bug 2):
- Guard _playAudio against duplicate Web Audio graph creation
- Prevents multiple GainNodes competing for the same stream

Talking indicator (Bug 3):
- Already fixed: 300ms hysteresis hold timer in both local and remote
  talk detection (prevents flicker from micro-pauses between syllables)

Screen share (Bug 4):
- Add SDP rollback in voice-offer handler for renegotiation glare
- Guard voice-answer handler against stale answers after rollback
- Use event.streams[0] in ontrack for proper stream association
- Add track.onunmute to re-trigger screen display when data arrives
- Mute all screen share video tiles (prevents browser autoplay block)
- Explicit vid.play() call as autoplay backup

GIF search (Bug 1):
- Tenor API key can now be set from the admin GIF picker UI
- Stored in server_settings DB table (no .env editing needed)
- Server checks DB first, falls back to TENOR_API_KEY env var
- Shows step-by-step setup guide when key is missing
- Non-admins see a clear 'ask your admin' message
2026-02-11 19:40:19 -05:00
ancsemi 31644c4d39 Voice UX polish, message pinning, markdown, link previews
- Voice join/leave audio cues (ascending/descending synth tones)
- Talking indicator: username glows with accent pulse when speaking
- Multi-stream screen sharing: CSS Grid tile layout, per-user labels
- Fix remoteStream variable reference bug in voice.js _createPeer
- Message pinning (admin-only): pin/unpin with DB table, panel, 50-pin limit
- Enhanced markdown: fenced code blocks, blockquotes, improved inline code
- Link previews: server-side OG metadata fetch with 30-min cache, preview cards
- CSP updated for preview images
- .gitignore: exclude .vs/
2026-02-11 19:18:30 -05:00
ancsemi d34e165585 feat: Tenor GIF integration with search picker
- GIF button next to emoji picker opens search/browse panel
- Server-side proxy keeps Tenor API key hidden from clients
- Trending GIFs shown by default, live search with debounce
- Click a GIF to send it as an inline image in chat
- Tenor URLs auto-detected and rendered as inline images
- CSP updated to allow media.tenor.com images
- TENOR_API_KEY added to .env.example (optional, free)
- Full CSS theming for GIF picker panel
2026-02-11 17:24:02 -05:00
ancsemi 5a11a910b3 feat: move all user data to external directory (%APPDATA%\Haven or ~/.haven)
- Database, .env, certs, and uploads now stored outside the code directory
- Auto-migration moves existing data from old locations on first launch
- SSL certs auto-detected in data dir (no .env config needed)
- New src/paths.js module as single source of truth for all data paths
- HAVEN_DATA_DIR env var for custom data location override
- Updated Start Haven.bat, start.sh, README, GUIDE, .env.example
- Bumped version to 1.1.0
2026-02-11 16:52:46 -05:00
ancsemi b7b8b1bb86 v1.0.0 Haven public release 2026-02-11 00:15:56 -05:00