added message to indicate empty feed on user and repo dashboard screens

This commit is contained in:
Brad 2014-06-05 16:48:45 -07:00
parent 072dbd95b1
commit 6a57b1b626
3 changed files with 59 additions and 29 deletions

View file

@ -19,3 +19,6 @@ Some of the fundamental changes include
Normally I wouldn't post experimental code in such disarray, but given the amount of activity around Normally I wouldn't post experimental code in such disarray, but given the amount of activity around
the project I wanted to give the community visibility into these changes. I could also use the help! the project I wanted to give the community visibility into these changes. I could also use the help!
I'm tracking my TODO list here:
https://gist.github.com/bradrydzewski/85b7720c276a70a1bed5

View file

@ -33,12 +33,12 @@
<a class="{{"pure-button"}}" href="{{$__amber_16}}"> <a class="{{"pure-button"}}" href="{{$__amber_16}}">
<i class="{{"fa"}} {{"fa-cog"}}"></i> <i class="{{"fa"}} {{"fa-cog"}}"></i>
</a> </a>
</header> </header>{{$repo := .Repo}}{{$__amber_17 := .Repo.Active}}{{if $__amber_17}}{{if .Commits}}
<section class="{{"pure-u-3-5"}}">{{$repo := .Repo}} <section class="{{"pure-u-3-5"}}">
<div class="{{"commit-list"}}">{{range $commit := .Commits}}{{$__amber_17 := $repo.Name}}{{$__amber_18 := $repo.Owner}}{{$__amber_19 := $repo.Remote}}{{$__amber_20 := __amber_add "/" $__amber_19}}{{$__amber_21 := __amber_add $__amber_20 "/"}}{{$__amber_22 := __amber_add $__amber_21 $__amber_18}}{{$__amber_23 := __amber_add $__amber_22 "/"}}{{$__amber_24 := __amber_add $__amber_23 $__amber_17}}{{$__amber_25 := __amber_add $__amber_24 "/branch/"}}{{$__amber_26 := __amber_add $__amber_25 .Branch}}{{$__amber_27 := __amber_add $__amber_26 "/commit/"}}{{$__amber_28 := __amber_add $__amber_27 .Sha}} <div class="{{"commit-list"}}">{{range $commit := .Commits}}{{$__amber_18 := $repo.Name}}{{$__amber_19 := $repo.Owner}}{{$__amber_20 := $repo.Remote}}{{$__amber_21 := __amber_add "/" $__amber_20}}{{$__amber_22 := __amber_add $__amber_21 "/"}}{{$__amber_23 := __amber_add $__amber_22 $__amber_19}}{{$__amber_24 := __amber_add $__amber_23 "/"}}{{$__amber_25 := __amber_add $__amber_24 $__amber_18}}{{$__amber_26 := __amber_add $__amber_25 "/branch/"}}{{$__amber_27 := __amber_add $__amber_26 .Branch}}{{$__amber_28 := __amber_add $__amber_27 "/commit/"}}{{$__amber_29 := __amber_add $__amber_28 .Sha}}
<a class="{{"pure-g"}} {{"commit-item"}}" data-status="{{.Status}}" href="{{$__amber_28}}"> <a class="{{"pure-g"}} {{"commit-item"}}" data-status="{{.Status}}" href="{{$__amber_29}}">
<div class="{{"pure-u-1-8"}}">{{$__amber_29 := __amber_add "https://secure.gravatar.com/avatar/" .Gravatar}}{{$__amber_30 := __amber_add $__amber_29 "?s=48&d=identicon"}} <div class="{{"pure-u-1-8"}}">{{$__amber_30 := __amber_add "https://secure.gravatar.com/avatar/" .Gravatar}}{{$__amber_31 := __amber_add $__amber_30 "?s=48&d=identicon"}}
<img src="{{$__amber_30}}" /> <img src="{{$__amber_31}}" />
</div> </div>
<div class="{{"pure-u-3-4"}}"> <div class="{{"pure-u-3-4"}}">
<h2>{{.Message}}</h2> <h2>{{.Message}}</h2>
@ -54,13 +54,25 @@
<div class="{{"pure-u-1"}} {{"pure-menu"}} {{"pure-menu-open"}}"> <div class="{{"pure-u-1"}} {{"pure-menu"}} {{"pure-menu-open"}}">
<a class="{{"pure-menu-heading"}}">Recent Branches</a> <a class="{{"pure-menu-heading"}}">Recent Branches</a>
<ul>{{range $commit := .Branches}} <ul>{{range $commit := .Branches}}
<li>{{$__amber_31 := $repo.Name}}{{$__amber_32 := $repo.Owner}}{{$__amber_33 := $repo.Remote}}{{$__amber_34 := __amber_add "/" $__amber_33}}{{$__amber_35 := __amber_add $__amber_34 "/"}}{{$__amber_36 := __amber_add $__amber_35 $__amber_32}}{{$__amber_37 := __amber_add $__amber_36 "/"}}{{$__amber_38 := __amber_add $__amber_37 $__amber_31}}{{$__amber_39 := __amber_add $__amber_38 "/branch/"}}{{$__amber_40 := __amber_add $__amber_39 .Branch}} <li>{{$__amber_32 := $repo.Name}}{{$__amber_33 := $repo.Owner}}{{$__amber_34 := $repo.Remote}}{{$__amber_35 := __amber_add "/" $__amber_34}}{{$__amber_36 := __amber_add $__amber_35 "/"}}{{$__amber_37 := __amber_add $__amber_36 $__amber_33}}{{$__amber_38 := __amber_add $__amber_37 "/"}}{{$__amber_39 := __amber_add $__amber_38 $__amber_32}}{{$__amber_40 := __amber_add $__amber_39 "/branch/"}}{{$__amber_41 := __amber_add $__amber_40 .Branch}}
<a data-status="{{.Status}}" href="{{$__amber_40}}">{{.Branch}}</a> <a data-status="{{.Status}}" href="{{$__amber_41}}">{{.Branch}}</a>
</li>{{end}} </li>{{end}}
</ul> </ul>
</div> </div>
</section> </section>
</div> </div>{{else}}
<section class="{{"pure-u-1"}}">
<div class="{{"alert"}} {{"alert-info"}}">Your Build history is empty. Push to your remote repository to trigger a build. </div>
</section>{{end}}{{else}}
<section class="{{"pure-u-1"}}">
<div class="{{"alert"}} {{"alert-info"}}">This Repository is not yet active. Please activate to start testing commits.</div>
<br />
<form class="{{"pure-form"}} {{"pure-form-stacked"}}">
<div class="{{"pure-controls"}}">
<button class="{{"pure-button"}} {{"pure-button-primary"}}">Click to Active Repository</button>
</div>
</form>
</section>{{end}}
</article> </article>
</div> </div>
<script src="{{"//cdnjs.cloudflare.com/ajax/libs/jquery/2.0.3/jquery.min.js"}}"></script> <script src="{{"//cdnjs.cloudflare.com/ajax/libs/jquery/2.0.3/jquery.min.js"}}"></script>

View file

@ -13,30 +13,45 @@ block content
a.pure-button[href="/"+Repo.Remote+"/"+Repo.Owner+"/"+Repo.Name+"/settings"] a.pure-button[href="/"+Repo.Remote+"/"+Repo.Owner+"/"+Repo.Name+"/settings"]
i.fa.fa-cog i.fa.fa-cog
section.pure-u-3-5 $repo=Repo
$repo=Repo if Repo.Active
div.commit-list if Commits
each $commit in Commits section.pure-u-3-5
a.pure-g.commit-item[data-status=Status][href="/"+$repo.Remote+"/"+$repo.Owner+"/"+$repo.Name+"/branch/"+Branch+"/commit/"+Sha] div.commit-list
div.pure-u-1-8 each $commit in Commits
img[src="https://secure.gravatar.com/avatar/"+Gravatar+"?s=48&d=identicon"] a.pure-g.commit-item[data-status=Status][href="/"+$repo.Remote+"/"+$repo.Owner+"/"+$repo.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 div.pure-u-3-4
h2 #{Message} h2 #{Message}
span.commit-sha #{ShaShort} span.commit-sha #{ShaShort}
span.commit-branch #{Branch} span.commit-branch #{Branch}
span.commit-date.timeago[title=FinishedString] span.commit-date.timeago[title=FinishedString]
div.pure-u-2-5
section.pure-g.branches
div.pure-u-1.pure-menu.pure-menu-open
a.pure-menu-heading Recent Branches
ul
each $commit in Branches
li
a[data-status=Status][href="/"+$repo.Remote+"/"+$repo.Owner+"/"+$repo.Name+"/branch/"+Branch] #{Branch}
div.pure-u-2-5 else
section.pure-g.branches section.pure-u-1
div.pure-u-1.pure-menu.pure-menu-open div.alert.alert-info
a.pure-menu-heading Recent Branches | Your Build history is empty. Push to your remote repository to trigger a build.
ul
each $commit in Branches
li
a[data-status=Status][href="/"+$repo.Remote+"/"+$repo.Owner+"/"+$repo.Name+"/branch/"+Branch] #{Branch}
else
section.pure-u-1
div.alert.alert-info
| This Repository is not yet active. Please activate to start testing commits.
br
form.pure-form.pure-form-stacked
div.pure-controls
button.pure-button.pure-button-primary Click to Active Repository
block append scripts block append scripts
script script
$(document).ready(function() { $(document).ready(function() {