Add stream count to tab title on homepage

Closes #2517
This commit is contained in:
JonnyWong16 2025-03-30 20:30:01 -07:00
commit e6c0a12dd5
No known key found for this signature in database
GPG key ID: B1F1F9807184697A

View file

@ -298,6 +298,8 @@
$('#currentActivityHeader-bandwidth-tooltip').tooltip({ container: 'body', placement: 'right', delay: 50 });
var title = document.title;
function getCurrentActivity() {
activity_ready = false;
@ -368,6 +370,8 @@
$('#currentActivityHeader').show();
document.title = stream_count + ' stream' + (stream_count > 1 ? 's' : '') + ' | ' + title;
sessions.forEach(function (session) {
var s = (typeof Proxy === "function") ? new Proxy(session, defaultHandler) : session;
var key = s.session_key;
@ -600,6 +604,8 @@
} else {
$('#currentActivityHeader').hide();
$('#currentActivity').html('<div id="dashboard-no-activity" class="text-muted">Nothing is currently being played.</div>');
document.title = title;
}
activity_ready = true;