From 2c22b619c55fe251b221bf3e68f534c1a4128d76 Mon Sep 17 00:00:00 2001 From: Amadeus Demarzi Date: Sun, 27 Jul 2014 23:59:17 -0700 Subject: [PATCH] A few homepage optimizations. * Improved iOS timing from pop in to breathing. Shouldn't distort as much * Hide tag line when page is loading to not make it pop in then out --- website/source/javascripts/app/Engine.Typewriter.js | 1 + website/source/javascripts/app/Engine.js | 5 +---- website/source/javascripts/app/Init.js | 5 ++--- website/source/stylesheets/_jumbotron.less | 1 + 4 files changed, 5 insertions(+), 7 deletions(-) diff --git a/website/source/javascripts/app/Engine.Typewriter.js b/website/source/javascripts/app/Engine.Typewriter.js index 9629a822a..61762c41c 100644 --- a/website/source/javascripts/app/Engine.Typewriter.js +++ b/website/source/javascripts/app/Engine.Typewriter.js @@ -6,6 +6,7 @@ Engine.Typewriter = function(element){ this.element = element; this.content = this.element.textContent.split(''); this.element.innerHTML = ''; + this.element.style.visibility = 'visible'; }; Engine.Typewriter.prototype = { diff --git a/website/source/javascripts/app/Engine.js b/website/source/javascripts/app/Engine.js index 8d1e93774..a918be3b0 100644 --- a/website/source/javascripts/app/Engine.js +++ b/website/source/javascripts/app/Engine.js @@ -93,12 +93,9 @@ Engine = Base.extend({ .then(function(){ this.showShapes = true; }, this) - .wait(800) + .wait(1000) .then(function(){ this.logo.startBreathing(); - }, this) - .wait(200) - .then(function(){ this.showGrid = true; }, this) .wait(1000) diff --git a/website/source/javascripts/app/Init.js b/website/source/javascripts/app/Init.js index 6e3ce2653..074c95d8d 100644 --- a/website/source/javascripts/app/Init.js +++ b/website/source/javascripts/app/Init.js @@ -66,10 +66,9 @@ var Init = { Pages: { 'page-home': function(){ - var jumbotron; if (isIE) { - jumbotron = document.getElementById('jumbotron'); - jumbotron.className += ' static'; + document.getElementById('jumbotron').className += ' static'; + document.getElementById('tag-line').style.visibility = 'visible'; return; } diff --git a/website/source/stylesheets/_jumbotron.less b/website/source/stylesheets/_jumbotron.less index 21edba78a..14b33dbbf 100755 --- a/website/source/stylesheets/_jumbotron.less +++ b/website/source/stylesheets/_jumbotron.less @@ -121,6 +121,7 @@ top:540px; color:#fff; text-align:center; + visibility:hidden; font-family: 'Lato', "Helvetica Neue", Helvetica, Arial, sans-serif; font-weight: 200;