gaufre: hide it if the server is unavailable

use visiblity: hidden instead of display: none to prevent layout shifts.
This commit is contained in:
Emmanuel Pelletier
2024-05-15 09:52:42 +02:00
parent bdf31c94a0
commit 1618bb1d1b
2 changed files with 6 additions and 0 deletions

View File

@@ -2,6 +2,8 @@
const BUTTON_CLASS = "js-lasuite-gaufre-btn"
let lastFocusedButton = null
window.document.documentElement.classList.add("lasuite--gaufre-loaded")
if ("requestIdleCallback" in window) {
requestIdleCallback(() => {
appendPopup()