fix: remove flash

This commit is contained in:
Markos Gogoulos 2025-09-29 16:32:22 +03:00
parent f4ab60e894
commit 7e0931dd5e
4 changed files with 80 additions and 67 deletions

View File

@ -55,6 +55,10 @@ export function renderPage(idSelector, PageComponent) {
appSidebar
);
}
if (document.body.classList.contains('js-loading')) {
document.body.classList.remove('js-loading');
}
}
export function renderEmbedPage(idSelector, PageComponent) {
@ -63,4 +67,8 @@ export function renderEmbedPage(idSelector, PageComponent) {
if (appContent && PageComponent) {
ReactDOM.render(<PageComponent />, appContent);
}
if (document.body.classList.contains('js-loading')) {
document.body.classList.remove('js-loading');
}
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -32,12 +32,17 @@
</style>
{% endif %}
<style>
.js-loading .page-main-wrap {
visibility: hidden;
}
</style>
{% endblock head %}
</head>
<body>
<body class="js-loading">
{% block beforecontent %}{% endblock %}