From 77ba674ffcdbec157b632016160fff655c42f1bb Mon Sep 17 00:00:00 2001 From: Jason McBrayer Date: Fri, 29 Mar 2019 19:39:25 -0400 Subject: [PATCH] Fix title setting on enhanced navigation --- brutaldon/static/js/brutaldon-enhancements.js | 14 -------------- brutaldon/templates/base.html | 10 ++++++---- 2 files changed, 6 insertions(+), 18 deletions(-) diff --git a/brutaldon/static/js/brutaldon-enhancements.js b/brutaldon/static/js/brutaldon-enhancements.js index 299ac15..154ae41 100644 --- a/brutaldon/static/js/brutaldon-enhancements.js +++ b/brutaldon/static/js/brutaldon-enhancements.js @@ -3,20 +3,6 @@ String.prototype.trunc = return this.substr(0,n-1)+(this.length>n?'…':''); }; -function setTitle(user, page) -{ - document.title = `Brutaldon (${user}) – ${page}`; -} - -function afterPage(user, page) -{ - setTitle(user,page); - var menu = document.querySelector('#navMenu'); - menu.classList.remove('is-active'); - var burger = document.querySelector('.navbar-burger'); - burger.classList.remove('is-active'); - $('#page-load-indicator').hide(); -} function menuPrepare() { // Remove is-active from navbar menu diff --git a/brutaldon/templates/base.html b/brutaldon/templates/base.html index e0a7d28..638f5b8 100644 --- a/brutaldon/templates/base.html +++ b/brutaldon/templates/base.html @@ -71,7 +71,9 @@ - +
{% block navbar %} @@ -165,8 +167,7 @@ {% endblock %} -
+
{% block content %}

@@ -212,7 +213,8 @@ {% if preferences.lightbox %} Intercooler.ready(function () - { + { + document.title = $("title").html(); $('.attachments').each(function() { $(this).magnificPopup({ delegate: 'figure.attachment-image a',