luci-theme-material: fix loading view on href 2583/head
authorFlorian Eckert <fe@dev.tdt.de>
Fri, 11 Jan 2019 09:01:37 +0000 (10:01 +0100)
committerFlorian Eckert <fe@dev.tdt.de>
Wed, 27 Feb 2019 13:03:56 +0000 (14:03 +0100)
After opening an external hyperlink in a new browser tab, LuCI hangs in the
load screen. This commit will fix this issue.

Signed-off-by: Florian Eckert <fe@dev.tdt.de>
themes/luci-theme-material/htdocs/luci-static/material/js/script.js

index 3c25ed712def04aa6d0fc03d7c3049f4bc53247c..db9c99e118d26acaa0105d991fc327da3ed7a7cc 100755 (executable)
     $(".cbi-button-up").val("");
     $(".cbi-button-down").val("");
 
-
-    /**
-     * hook other "A Label" and add hash to it.
-     */
-    $("#maincontent > .container").find("a").each(function () {
-        var that = $(this);
-        var onclick = that.attr("onclick");
-        if (onclick == undefined || onclick == "") {
-            that.click(function () {
-                var href = that.attr("href");
-                if (href.indexOf("#") == -1) {
-                    $(".main > .loading").fadeIn("fast");
-                    return true;
-                }
-            });
-        }
-    });
-
     /**
      * Sidebar expand
      */