Also run login javascript when page is loaded

This commit is contained in:
Yohan Boniface 2023-12-29 16:11:08 +01:00 committed by Alexis Métaireau
parent ce22a2ee74
commit c6ce22f319

View file

@ -37,7 +37,10 @@
{% endblock content %} {% endblock content %}
{% block bottom_js %} {% block bottom_js %}
{{ block.super }} {{ block.super }}
<script type="text/javascript"> <script type="text/javascript">
window.addEventListener('DOMContentLoaded', (event => {
!(function () { !(function () {
const ui = new L.U.UI(document.querySelector('header')) const ui = new L.U.UI(document.querySelector('header'))
const xhr = new L.U.Xhr(ui) const xhr = new L.U.Xhr(ui)
@ -85,8 +88,10 @@
L.DomEvent.on(more, 'click', getMore, more) L.DomEvent.on(more, 'click', getMore, more)
} }
})(this) })(this)
}
}))
</script> </script>
{% endblock bottom_js %} {% endblock bottom_js %}
{% block footer %} {% block footer %}
{{ block.super }} {{ block.super }}
{% include "umap/content_footer.html" %} {% include "umap/content_footer.html" %}