Hide footer on fleetdm.com until the page is loaded (#2848)

* added a jquery function to show footer once the page is rendered

* Update layout.ejs

* fix lint error
This commit is contained in:
eashaw 2021-11-09 13:37:53 -06:00 committed by GitHub
parent d9556b3f7f
commit 2e7c092e1e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -123,7 +123,8 @@
<%- body %>
<div style="background-color: #182147;" purpose="page-footer">
<%/* Note: footer is hidden until the page is loaded. See «script» tag at the bottom of this file. */%>
<div style="background-color: #182147;" class="invisible" purpose="page-footer" data-hide-until-rendered>
<div style="max-width: 1248px;" purpose="footer-container" class="container-fluid d-flex flex-column flex-sm-row align-items-sm-end justify-content-center justify-content-sm-between">
<div class="d-flex flex-column order-first justify-content-start">
<div class="d-flex pb-4 pr-4">
@ -332,5 +333,12 @@
})();
</script>
<% /* Keep footer hidden until the document is ready (prevents flicker that is especially unattractive on mobile) */ %>
<script>
$(function() {
$('[data-hide-until-rendered]').removeClass('invisible'); // Note: invisible is a bootstrap 4 class
});
</script>
</body>
</html>