mirror of
https://github.com/jfmcbrayer/brutaldon
synced 2024-12-22 05:23:03 +01:00
Fix title setting on enhanced navigation
This commit is contained in:
parent
0939e5c1a1
commit
77ba674ffc
@ -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
|
||||
|
@ -71,7 +71,9 @@
|
||||
|
||||
|
||||
</head>
|
||||
<body ic-global-include='{"csrfmiddlewaretoken": "{{ csrf_token }}"}'>
|
||||
<body ic-enhance="true" ic-target="body"
|
||||
ic-global-indicator="#page-load-indicator"
|
||||
ic-global-include='{"csrfmiddlewaretoken": "{{ csrf_token }}"}'>
|
||||
<div id="page-load-indicator"></div>
|
||||
<div id="new-toot-modal" class="modal"></div>
|
||||
{% block navbar %}
|
||||
@ -165,8 +167,7 @@
|
||||
</nav>
|
||||
{% endblock %}
|
||||
|
||||
<main id="main" class="section" ic-enhance="true"
|
||||
ic-global-indicator="#page-load-indicator">
|
||||
<main id="main" class="section">
|
||||
<div class="container">
|
||||
{% block content %}
|
||||
<h1 class="title">
|
||||
@ -213,6 +214,7 @@
|
||||
{% if preferences.lightbox %}
|
||||
Intercooler.ready(function ()
|
||||
{
|
||||
document.title = $("title").html();
|
||||
$('.attachments').each(function() {
|
||||
$(this).magnificPopup({
|
||||
delegate: 'figure.attachment-image a',
|
||||
|
Loading…
Reference in New Issue
Block a user