add "loading ..."

This commit is contained in:
Sven Fuchs 2012-07-06 14:39:06 +02:00
parent 267ad6c752
commit a43eb1916c
8 changed files with 51 additions and 39 deletions

View File

@ -1,6 +1,8 @@
{{#with view}} {{#with view}}
{{#unless build.isLoaded}} {{#unless build.isLoaded}}
Loading ... <div id="build" class="loading">
<span>Loading</span>
</div>
{{else}} {{else}}
<div id="build" {{bindAttr class="color"}}> <div id="build" {{bindAttr class="color"}}>
<dl id="summary"> <dl id="summary">

View File

@ -18,8 +18,8 @@
</li> </li>
{{/view}} {{/view}}
{{else}} {{else}}
<li class="loading"> <div class="loading">
<p>Loading</p> <span>Loading</span>
</li> </div>
{{/each}} {{/each}}
<ul> <ul>

View File

@ -1,7 +1,5 @@
{{#with view.repository}} {{#if view.repository.isLoaded}}
{{#unless isLoaded}} {{#with view.repository}}
Loading ...
{{else}}
<div id="repository"> <div id="repository">
<h3> <h3>
<a {{bindAttr href="view.urlGithub"}}>{{slug}}</a> <a {{bindAttr href="view.urlGithub"}}>{{slug}}</a>
@ -15,5 +13,10 @@
<li><a class="forks" title="Forks" {{bindAttr href="view.urlGithubNetwork"}}>{{stats.forks}}</a></li> <li><a class="forks" title="Forks" {{bindAttr href="view.urlGithubNetwork"}}>{{stats.forks}}</a></li>
</ul> </ul>
</div> </div>
{{/unless}} {{/with}}
{{/with}} {{else}}
<div id="repository" class="loading">
<span>Loading</span>
</div>
{{/if}}

View File

@ -1,6 +1,6 @@
require 'ext/jquery' require 'ext/jquery'
responseTime = 0 responseTime = 10000
repositories = [ repositories = [
{ id: 1, owner: 'travis-ci', name: 'travis-core', slug: 'travis-ci/travis-core', build_ids: [1, 2], last_build_id: 1, last_build_number: 1, last_build_result: 0, last_build_finished_at: '2012-07-02T00:00:00Z', description: 'Description of travis-core' }, { id: 1, owner: 'travis-ci', name: 'travis-core', slug: 'travis-ci/travis-core', build_ids: [1, 2], last_build_id: 1, last_build_number: 1, last_build_result: 0, last_build_finished_at: '2012-07-02T00:00:00Z', description: 'Description of travis-core' },

View File

@ -72,6 +72,14 @@ pre::-webkit-scrollbar-thumb:horizontal
.display .display
display: block !important display: block !important
.loading
padding: 15px 25px 0 0
span
padding-right: 25px
font-size: 13px
color: #aaa
background: inline-image('spinner.gif') no-repeat right 4px
.emoji .emoji
vertical-align: middle vertical-align: middle
width: 20px width: 20px

View File

@ -45,13 +45,7 @@
height: 100% height: 100%
background: no-repeat center left background: no-repeat center left
&.loading #repositories
font-size: 13px .loading
color: #999 padding: 15px 25px 15px 30px
background-color: #fff background-color: #fff
p
display: inline-block
margin: 0 0 0 -10px
padding-right: 25px
background: inline-image('spinner.gif') no-repeat right 6px

File diff suppressed because one or more lines are too long

View File

@ -101,13 +101,25 @@ pre::-webkit-scrollbar-thumb:horizontal {
} }
/* line 75, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */ /* line 75, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */
.loading {
padding: 15px 25px 0 0;
}
/* line 77, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */
.loading span {
padding-right: 25px;
font-size: 13px;
color: #aaaaaa;
background: url('data:image/gif;base64,R0lGODlhEAAIAPMHAP///+vr66CgoN7e3rW1tYuLi/X19Wtra3t7e87OzsbGxqGhodfX142NjZaWlqurqyH/C05FVFNDQVBFMi4wAwEAAAAh/hoiQ3JlYXRlZCB3aXRoIENoaW1wbHkuY29tIgAh+QQACgD/ACwAAAAAEAAIAAADKXiq0P7glHmglRSMPUDgBlZUQ/B5ZhBOo2Z2qSqSL2qumaEbwK7PFkgCACH5BAAKAP8ALAAAAAAQAAgAAAQwsKCJwLkH6F2Er0dRZJvWfZaYBUNrnAKoAkEdvF6cjrSNoyGe7QaT8QxIpISyI5UiACH5BAAKAP8ALAAAAAAQAAgAAAQvcIkpALoInL0F+Y41ZUdhHh4oCqRZoB8RIqPmwirN2mcqr61ebFYrnSQUC4b3igAAIfkEAAoA/wAsAAAAABAACAAABDAQyCmqACijQpYnQEMQDWZxSgqKpFmhajiWyEmkyjq7ApzLrdqr8wHSThOKBaMpRAAAIfkEAAoA/wAsAAAAABAACAAABDMQyEmBuGKxxBl4y/IADmEKzKAmwMItpEmg6sC6CVye6dq+MV7tBtzNNp1PaGQUVJ6YTAQAIfkEAAoA/wAsAAAAABAACAAABC8QyEmrBSknQJYnxiAGgCIqnKKCQUuaA0qoCuuWZ7oa7pvPO4PQgNFwPAvCZQmIAAAh+QQACgD/ACwAAAAAEAAIAAAEKRDISau1LGlmhg+A5wGJyAUoOKADaRqpyrremYZzWRs8D/QGQGZzKQIiACH5BAAKAP8ALAAAAAAQAAgAAAMhCLrc/iyMGcCcQNLAueVD1o3eAIpk90koZ7wvABvyDEEJADs=') no-repeat right 4px;
}
/* line 83, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */
.emoji { .emoji {
vertical-align: middle; vertical-align: middle;
width: 20px; width: 20px;
height: 20px; height: 20px;
} }
/* line 80, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */ /* line 88, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */
.help { .help {
display: inline-block; display: inline-block;
height: 19px; height: 19px;
@ -118,7 +130,7 @@ pre::-webkit-scrollbar-thumb:horizontal {
cursor: pointer; cursor: pointer;
} }
/* line 89, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */ /* line 97, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */
.context_help_caption { .context_help_caption {
text-align: left; text-align: left;
font-size: 16px; font-size: 16px;
@ -127,27 +139,27 @@ pre::-webkit-scrollbar-thumb:horizontal {
border-bottom: 1px solid #cccccc; border-bottom: 1px solid #cccccc;
} }
/* line 96, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */ /* line 104, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */
.context_help { .context_help {
display: none; display: none;
} }
/* line 99, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */ /* line 107, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */
.context_help_body { .context_help_body {
font-size: 1em; font-size: 1em;
line-height: 1.429; line-height: 1.429;
margin: 1.429em 0; margin: 1.429em 0;
} }
/* line 105, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */ /* line 113, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */
#facebox .content { #facebox .content {
display: block !important; display: block !important;
} }
/* line 107, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */ /* line 115, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */
#facebox .close { #facebox .close {
display: none; display: none;
} }
/* line 109, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */ /* line 117, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/application.sass */
#facebox pre::-webkit-scrollbar { #facebox pre::-webkit-scrollbar {
height: 0; height: 0;
width: 0; width: 0;
@ -241,19 +253,12 @@ body#home {
height: 100%; height: 100%;
background: no-repeat center left; background: no-repeat center left;
} }
/* line 48, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/left/repositories.sass */
#repositories li.loading { /* line 49, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/left/repositories.sass */
font-size: 13px; #repositories .loading {
color: #999999; padding: 15px 25px 15px 30px;
background-color: white; background-color: white;
} }
/* line 53, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/left/repositories.sass */
#repositories li.loading p {
display: inline-block;
margin: 0 0 0 -10px;
padding-right: 25px;
background: url('data:image/gif;base64,R0lGODlhEAAIAPMHAP///+vr66CgoN7e3rW1tYuLi/X19Wtra3t7e87OzsbGxqGhodfX142NjZaWlqurqyH/C05FVFNDQVBFMi4wAwEAAAAh/hoiQ3JlYXRlZCB3aXRoIENoaW1wbHkuY29tIgAh+QQACgD/ACwAAAAAEAAIAAADKXiq0P7glHmglRSMPUDgBlZUQ/B5ZhBOo2Z2qSqSL2qumaEbwK7PFkgCACH5BAAKAP8ALAAAAAAQAAgAAAQwsKCJwLkH6F2Er0dRZJvWfZaYBUNrnAKoAkEdvF6cjrSNoyGe7QaT8QxIpISyI5UiACH5BAAKAP8ALAAAAAAQAAgAAAQvcIkpALoInL0F+Y41ZUdhHh4oCqRZoB8RIqPmwirN2mcqr61ebFYrnSQUC4b3igAAIfkEAAoA/wAsAAAAABAACAAABDAQyCmqACijQpYnQEMQDWZxSgqKpFmhajiWyEmkyjq7ApzLrdqr8wHSThOKBaMpRAAAIfkEAAoA/wAsAAAAABAACAAABDMQyEmBuGKxxBl4y/IADmEKzKAmwMItpEmg6sC6CVye6dq+MV7tBtzNNp1PaGQUVJ6YTAQAIfkEAAoA/wAsAAAAABAACAAABC8QyEmrBSknQJYnxiAGgCIqnKKCQUuaA0qoCuuWZ7oa7pvPO4PQgNFwPAvCZQmIAAAh+QQACgD/ACwAAAAAEAAIAAAEKRDISau1LGlmhg+A5wGJyAUoOKADaRqpyrremYZzWRs8D/QGQGZzKQIiACH5BAAKAP8ALAAAAAAQAAgAAAMhCLrc/iyMGcCcQNLAueVD1o3eAIpk90koZ7wvABvyDEEJADs=') no-repeat right 6px;
}
/* line 1, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/main.sass */ /* line 1, /Volumes/Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/main.sass */
#main { #main {
position: relative; position: relative;