소스 검색

Set title to include hostname if hostname is present

Christopher Mullins 6 년 전
부모
커밋
1799599ce9
2개의 변경된 파일8개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      dist/index.html.gz.h
  2. 6 0
      web/src/js/script.js

파일 크기가 너무 크기때문에 변경 상태를 표시하지 않습니다.
+ 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) {