Fix for class 'is-loading'

The class 'is-loading' was not properly removed from the body tag, disabling animations on the page.
This commit is contained in:
torkel104 2016-11-06 20:31:01 +01:00 committed by GitHub
parent dbaf520653
commit 9f35bfbd69
1 changed files with 6 additions and 6 deletions

View File

@ -4,6 +4,12 @@
Free for personal and commercial use under the CCA 3.0 license (html5up.net/license) Free for personal and commercial use under the CCA 3.0 license (html5up.net/license)
*/ */
$( window ).on( 'load', function() {
setTimeout( function() {
$('body').removeClass('is-loading');
})
});
(function($) { (function($) {
skel.breakpoints({ skel.breakpoints({
@ -25,12 +31,6 @@
// Disable animations/transitions until the page has loaded. // Disable animations/transitions until the page has loaded.
$body.addClass('is-loading'); $body.addClass('is-loading');
$window.on('load', function() {
window.setTimeout(function() {
$body.removeClass('is-loading');
}, 100);
});
// Fix: Placeholder polyfill. // Fix: Placeholder polyfill.
$('form').placeholder(); $('form').placeholder();