🚨 FIX: Loading screen блокирует клики - принудительное удаление из DOM
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
2025-11-25 12:39:50 +09:00
parent c91df27dfa
commit 012ec02145
2 changed files with 26 additions and 5 deletions

View File

@@ -10,11 +10,13 @@ document.addEventListener('DOMContentLoaded', function() {
loadingScreen.style.opacity = '0';
loadingScreen.style.pointerEvents = 'none';
setTimeout(() => {
loadingScreen.style.display = 'none';
loadingScreen.remove(); // Полностью удаляем элемент
console.log('SmartSolTech: Loading screen removed');
// Полностью удаляем элемент из DOM
if (loadingScreen.parentNode) {
loadingScreen.parentNode.removeChild(loadingScreen);
console.log('SmartSolTech: Loading screen completely removed from DOM');
}
}, 300);
}, 500); // Уменьшили время ожидания
}, 200); // Уменьшили время ожидания до 200ms
} else {
console.log('SmartSolTech: Loading screen not found');
}

View File

@@ -35,10 +35,29 @@
{% block extra_styles %}{% endblock %}
{% block extra_head %}{% endblock %}
<!-- Emergency Loading Screen Script -->
<script>
// Emergency fallback - remove loading screen immediately if JS fails
document.addEventListener('DOMContentLoaded', function() {
setTimeout(function() {
const loadingScreen = document.getElementById('loading-screen');
if (loadingScreen) {
loadingScreen.style.opacity = '0';
loadingScreen.style.pointerEvents = 'none';
setTimeout(function() {
if (loadingScreen.parentNode) {
loadingScreen.parentNode.removeChild(loadingScreen);
}
}, 300);
}
}, 100); // Очень быстро убираем
});
</script>
</head>
<body>
<!-- Loading Screen -->
<div id="loading-screen" class="position-fixed top-0 start-0 w-100 h-100 d-flex align-items-center justify-content-center" style="background: var(--bg-light); z-index: 9999;">
<div id="loading-screen" class="position-fixed top-0 start-0 w-100 h-100 d-flex align-items-center justify-content-center" style="background: var(--bg-light); z-index: 9999; transition: opacity 0.3s ease;">
<div class="loading-spinner"></div>
</div>