gaufre: hide it if the server is unavailable
use visiblity: hidden instead of display: none to prevent layout shifts.
This commit is contained in:
@@ -84,3 +84,7 @@
|
||||
[data-fr-scheme="dark"] .lasuite-gaufre-btn--vanilla:active {
|
||||
background-color: #474747 !important;
|
||||
}
|
||||
|
||||
html:not(.lasuite--gaufre-loaded) .lasuite-gaufre-btn {
|
||||
visibility: hidden !important;
|
||||
}
|
||||
|
||||
@@ -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()
|
||||
|
||||
Reference in New Issue
Block a user