diff options
-rw-r--r-- | docs/release-notes.md | 3 | ||||
-rw-r--r-- | src/SMAPI.Web/Views/LogParser/Index.cshtml | 4 | ||||
-rw-r--r-- | src/SMAPI.Web/wwwroot/Content/js/mods.js | 9 |
3 files changed, 12 insertions, 4 deletions
diff --git a/docs/release-notes.md b/docs/release-notes.md index fb6be0c0..99e05016 100644 --- a/docs/release-notes.md +++ b/docs/release-notes.md @@ -7,6 +7,9 @@ These changes have not been released yet. * SMAPI now prevents invalid event preconditions from crashing the game (thanks to berkayylmao!). * Fixed errors during early startup not shown before exit. +* For the web UI: + * When filtering the mod list, clicking a mod link now automatically adds it to the visible mods. + * For modders: * `this.Monitor.Log` now defaults to the `Trace` log level instead of `Debug`. * Fixed 'location list changed' verbose log not correctly listing changes. diff --git a/src/SMAPI.Web/Views/LogParser/Index.cshtml b/src/SMAPI.Web/Views/LogParser/Index.cshtml index babd0bd3..dff37d7d 100644 --- a/src/SMAPI.Web/Views/LogParser/Index.cshtml +++ b/src/SMAPI.Web/Views/LogParser/Index.cshtml @@ -17,10 +17,10 @@ { <meta name="robots" content="noindex" /> } - <link rel="stylesheet" href="~/Content/css/log-parser.css?r=20190314" /> + <link rel="stylesheet" href="~/Content/css/log-parser.css?r=20190515" /> <script src="https://cdn.jsdelivr.net/npm/vue@2.5.17/dist/vue.min.js" crossorigin="anonymous"></script> <script src="https://cdn.jsdelivr.net/npm/jquery@3.3.1/dist/jquery.min.js" crossorigin="anonymous"></script> - <script src="~/Content/js/log-parser.js?r=20190310"></script> + <script src="~/Content/js/log-parser.js?r=20190515"></script> <script> $(function() { smapi.logParser({ diff --git a/src/SMAPI.Web/wwwroot/Content/js/mods.js b/src/SMAPI.Web/wwwroot/Content/js/mods.js index 874fbf25..1c9562bb 100644 --- a/src/SMAPI.Web/wwwroot/Content/js/mods.js +++ b/src/SMAPI.Web/wwwroot/Content/js/mods.js @@ -87,8 +87,6 @@ smapi.modList = function (mods, enableBeta) { else delete data.filters.betaStatus; - window.boop = data.filters; - // init mods for (var i = 0; i < data.mods.length; i++) { var mod = mods[i]; @@ -188,6 +186,10 @@ smapi.modList = function (mods, enableBeta) { matchesFilters: function(mod, searchWords) { var filters = data.filters; + // check hash + if (location.hash === "#" + mod.Slug) + return true; + // check source if (!filters.source.value.open.value && mod.SourceUrl) return false; @@ -281,4 +283,7 @@ smapi.modList = function (mods, enableBeta) { } }); app.applyFilters(); + window.addEventListener("hashchange", function () { + app.applyFilters(); + }); }; |