Explorar el Código

Set title to include hostname if hostname is present

Christopher Mullins hace 6 años
padre
commit
1799599ce9
Se han modificado 2 ficheros con 8 adiciones y 2 borrados
  1. 2 2
      dist/index.html.gz.h
  2. 6 0
      web/src/js/script.js

La diferencia del archivo ha sido suprimido porque es demasiado grande
+ 2 - 2
dist/index.html.gz.h


+ 6 - 0
web/src/js/script.js

@@ -584,6 +584,12 @@ var loadSettings = function() {
       }
     });
 
+    if (val.hostname) {
+      var title = "MiLight Hub: " + val.hostname;
+      document.title = title;
+      $('.navbar-brand').html(title);
+    }
+
     if (val.group_id_aliases) {
       aliasesSelectize.clearOptions();
       Object.entries(val.group_id_aliases).forEach(function(entry) {