fancy (read: ugly) hack to fix firefox css transition FOUC

This commit is contained in:
Thibault Duplessis 2015-04-12 15:38:36 +02:00
parent 9bc84ec203
commit 6501a1788a
3 changed files with 8 additions and 1 deletions

View file

@ -40,7 +40,7 @@ chessground: Boolean = true)(body: Html)(implicit ctx: Context)
<link href="@routes.Blog.atom()" type="application/atom+xml" rel="alternate" title="Latest blog posts" />
@langAnnotations
</head>
<body class="base @List(
<body class="preload base @List(
ctx.currentTheme.cssClass,
ctx.currentTheme3d.cssClass,
ctx.currentBg,

View file

@ -569,6 +569,8 @@ lichess.storage = {
else if (lichess.tournament) startTournament(document.getElementById('tournament'), lichess.tournament);
else if (lichess.simul) startSimul(document.getElementById('simul'), lichess.simul);
document.body.classList.remove('preload');
$('#lichess').on('click', '.socket-link:not(.disabled)', function() {
lichess.socket.send($(this).data('msg'), $(this).data('data'));
});

View file

@ -1,3 +1,8 @@
/* https://css-tricks.com/transitions-only-after-page-load/ */
body.preload * {
transition: none !important;
-webkit-transition: none !important;
}
body,
ul,
ol,