added message when build feed is empty

This commit is contained in:
Brad 2014-06-05 16:19:25 -07:00
parent 289312b678
commit b3f77d3226
4 changed files with 56 additions and 16 deletions

View file

@ -3461,6 +3461,19 @@ article.pure-g > .pure-u-3-4 {
margin-right: 15px;
display: inline-block;
}
.alert a:visited,
.alert a:active,
.alert a {
color: inherit;
}
.alert-info {
background: #f4f8fa;
color: #5bc0de;
border-left: 5px solid #5bc0de;
}
.alert-info:before {
content: "\f05a";
}
.alert[data-status="Success"] {
background: #D9F3EA;
border-left: 5px solid #40C598;

View file

@ -11,6 +11,22 @@
margin-right:15px;
display:inline-block;
}
a:visited,
a:active,
a {
color: inherit;
}
}
.alert-info {
background:#f4f8fa;
color: #5bc0de;
border-left: 5px solid #5bc0de;
&:before {
content: "\f05a";
}
}
.alert[data-status="Success"] {

View file

@ -30,7 +30,7 @@
<i class="{{"fa"}} {{"fa-plus"}}"></i>
</a>
</header>
<section>
<section>{{if .Feed}}
<div class="{{"activity-list"}}">{{range $commit := .Feed}}{{$__amber_5 := __amber_add "/" .Remote}}{{$__amber_6 := __amber_add $__amber_5 "/"}}{{$__amber_7 := __amber_add $__amber_6 .Owner}}{{$__amber_8 := __amber_add $__amber_7 "/"}}{{$__amber_9 := __amber_add $__amber_8 .Name}}{{$__amber_10 := __amber_add $__amber_9 "/branch/"}}{{$__amber_11 := __amber_add $__amber_10 .Branch}}{{$__amber_12 := __amber_add $__amber_11 "/commit/"}}{{$__amber_13 := __amber_add $__amber_12 .Sha}}
<a class="{{"pure-g"}} {{"activity-item"}}" data-status="{{.Status}}" href="{{$__amber_13}}">
<div class="{{"pure-u-1-8"}}">{{$__amber_14 := __amber_add "https://secure.gravatar.com/avatar/" .Gravatar}}{{$__amber_15 := __amber_add $__amber_14 "?s=48&d=identicon"}}
@ -48,7 +48,12 @@
<span class="{{"activity-date"}} {{"timeago"}}" title="{{.FinishedString}}"></span>
</div>
</a>{{end}}
</div>
</div>{{else}}
<div class="{{"alert"}} {{"alert-info"}}">
Your build feed is empty.
<a href="{{"/account/repos"}}">Setup</a>
your repositories to get started.
</div>{{end}}
</section>
</article>
</div>

View file

@ -10,21 +10,27 @@ block content
a[href="/account/repos"].pure-button
i.fa.fa-plus
section
div.activity-list
each $commit in Feed
a.pure-g.activity-item[data-status=Status][href="/"+Remote+"/"+Owner+"/"+Name+"/branch/"+Branch+"/commit/"+Sha]
div.pure-u-1-8
img[src="https://secure.gravatar.com/avatar/" + Gravatar + "?s=48&d=identicon"]
if Feed
div.activity-list
each $commit in Feed
a.pure-g.activity-item[data-status=Status][href="/"+Remote+"/"+Owner+"/"+Name+"/branch/"+Branch+"/commit/"+Sha]
div.pure-u-1-8
img[src="https://secure.gravatar.com/avatar/" + Gravatar + "?s=48&d=identicon"]
div.pure-u-3-4
h2
span #{Owner}
span.divider /
span #{Name}
p.activity-message #{Message}
span.activity-sha #{ShaShort}
span.activity-branch #{Branch}
span.activity-date.timeago[title=FinishedString]
div.pure-u-3-4
h2
span #{Owner}
span.divider /
span #{Name}
p.activity-message #{Message}
span.activity-sha #{ShaShort}
span.activity-branch #{Branch}
span.activity-date.timeago[title=FinishedString]
else
div.alert.alert-info
| Your build feed is empty.
a[href="/account/repos"] Setup
| your repositories to get started.
block append scripts
script