diff options
Diffstat (limited to 'templates/gitlist.qtpl.go')
-rw-r--r-- | templates/gitlist.qtpl.go | 215 |
1 files changed, 109 insertions, 106 deletions
diff --git a/templates/gitlist.qtpl.go b/templates/gitlist.qtpl.go index 29adbc6..601dbb2 100644 --- a/templates/gitlist.qtpl.go +++ b/templates/gitlist.qtpl.go @@ -7,159 +7,162 @@ package templates //line templates/gitlist.qtpl:1 import "git.gabrielgio.me/cerrado/pkg/service" -//line templates/gitlist.qtpl:3 +//line templates/gitlist.qtpl:2 +import "context" + +//line templates/gitlist.qtpl:4 import ( qtio422016 "io" qt422016 "github.com/valyala/quicktemplate" ) -//line templates/gitlist.qtpl:3 +//line templates/gitlist.qtpl:4 var ( _ = qtio422016.Copy _ = qt422016.AcquireByteBuffer ) -//line templates/gitlist.qtpl:4 +//line templates/gitlist.qtpl:5 type GitListPage struct { Respositories []*service.Repository About []byte } -//line templates/gitlist.qtpl:10 -func (p *GitListPage) StreamTitle(qw422016 *qt422016.Writer) { -//line templates/gitlist.qtpl:10 +//line templates/gitlist.qtpl:11 +func (p *GitListPage) StreamTitle(qw422016 *qt422016.Writer, ctx context.Context) { +//line templates/gitlist.qtpl:11 qw422016.N().S(`Git | List`) -//line templates/gitlist.qtpl:10 +//line templates/gitlist.qtpl:11 } -//line templates/gitlist.qtpl:10 -func (p *GitListPage) WriteTitle(qq422016 qtio422016.Writer) { -//line templates/gitlist.qtpl:10 +//line templates/gitlist.qtpl:11 +func (p *GitListPage) WriteTitle(qq422016 qtio422016.Writer, ctx context.Context) { +//line templates/gitlist.qtpl:11 qw422016 := qt422016.AcquireWriter(qq422016) -//line templates/gitlist.qtpl:10 - p.StreamTitle(qw422016) -//line templates/gitlist.qtpl:10 +//line templates/gitlist.qtpl:11 + p.StreamTitle(qw422016, ctx) +//line templates/gitlist.qtpl:11 qt422016.ReleaseWriter(qw422016) -//line templates/gitlist.qtpl:10 +//line templates/gitlist.qtpl:11 } -//line templates/gitlist.qtpl:10 -func (p *GitListPage) Title() string { -//line templates/gitlist.qtpl:10 +//line templates/gitlist.qtpl:11 +func (p *GitListPage) Title(ctx context.Context) string { +//line templates/gitlist.qtpl:11 qb422016 := qt422016.AcquireByteBuffer() -//line templates/gitlist.qtpl:10 - p.WriteTitle(qb422016) -//line templates/gitlist.qtpl:10 +//line templates/gitlist.qtpl:11 + p.WriteTitle(qb422016, ctx) +//line templates/gitlist.qtpl:11 qs422016 := string(qb422016.B) -//line templates/gitlist.qtpl:10 +//line templates/gitlist.qtpl:11 qt422016.ReleaseByteBuffer(qb422016) -//line templates/gitlist.qtpl:10 +//line templates/gitlist.qtpl:11 return qs422016 -//line templates/gitlist.qtpl:10 +//line templates/gitlist.qtpl:11 } -//line templates/gitlist.qtpl:12 -func (p *GitListPage) StreamNavbar(qw422016 *qt422016.Writer) { -//line templates/gitlist.qtpl:12 - StreamNavbar(qw422016, Git) -//line templates/gitlist.qtpl:12 +//line templates/gitlist.qtpl:13 +func (p *GitListPage) StreamNavbar(qw422016 *qt422016.Writer, ctx context.Context) { +//line templates/gitlist.qtpl:13 + StreamNavbar(qw422016, ctx, Git) +//line templates/gitlist.qtpl:13 } -//line templates/gitlist.qtpl:12 -func (p *GitListPage) WriteNavbar(qq422016 qtio422016.Writer) { -//line templates/gitlist.qtpl:12 +//line templates/gitlist.qtpl:13 +func (p *GitListPage) WriteNavbar(qq422016 qtio422016.Writer, ctx context.Context) { +//line templates/gitlist.qtpl:13 qw422016 := qt422016.AcquireWriter(qq422016) -//line templates/gitlist.qtpl:12 - p.StreamNavbar(qw422016) -//line templates/gitlist.qtpl:12 +//line templates/gitlist.qtpl:13 + p.StreamNavbar(qw422016, ctx) +//line templates/gitlist.qtpl:13 qt422016.ReleaseWriter(qw422016) -//line templates/gitlist.qtpl:12 +//line templates/gitlist.qtpl:13 } -//line templates/gitlist.qtpl:12 -func (p *GitListPage) Navbar() string { -//line templates/gitlist.qtpl:12 +//line templates/gitlist.qtpl:13 +func (p *GitListPage) Navbar(ctx context.Context) string { +//line templates/gitlist.qtpl:13 qb422016 := qt422016.AcquireByteBuffer() -//line templates/gitlist.qtpl:12 - p.WriteNavbar(qb422016) -//line templates/gitlist.qtpl:12 +//line templates/gitlist.qtpl:13 + p.WriteNavbar(qb422016, ctx) +//line templates/gitlist.qtpl:13 qs422016 := string(qb422016.B) -//line templates/gitlist.qtpl:12 +//line templates/gitlist.qtpl:13 qt422016.ReleaseByteBuffer(qb422016) -//line templates/gitlist.qtpl:12 +//line templates/gitlist.qtpl:13 return qs422016 -//line templates/gitlist.qtpl:12 +//line templates/gitlist.qtpl:13 } -//line templates/gitlist.qtpl:14 -func (p *GitListPage) StreamContent(qw422016 *qt422016.Writer) { -//line templates/gitlist.qtpl:14 +//line templates/gitlist.qtpl:15 +func (p *GitListPage) StreamContent(qw422016 *qt422016.Writer, ctx context.Context) { +//line templates/gitlist.qtpl:15 qw422016.N().S(` <div class="row"> <div class="col-md-6 order-last order-md-first"> <div class="event-list"> `) -//line templates/gitlist.qtpl:18 +//line templates/gitlist.qtpl:19 for _, r := range p.Respositories { -//line templates/gitlist.qtpl:18 +//line templates/gitlist.qtpl:19 qw422016.N().S(` <div class="event"> <h4> <a href="/`) -//line templates/gitlist.qtpl:21 +//line templates/gitlist.qtpl:22 qw422016.E().S(r.Name) -//line templates/gitlist.qtpl:21 +//line templates/gitlist.qtpl:22 qw422016.N().S(`/">`) -//line templates/gitlist.qtpl:21 +//line templates/gitlist.qtpl:22 qw422016.E().S(r.Name) -//line templates/gitlist.qtpl:21 +//line templates/gitlist.qtpl:22 qw422016.N().S(`</a> </h4> </hr> <p>`) -//line templates/gitlist.qtpl:24 +//line templates/gitlist.qtpl:25 qw422016.E().S(r.Description) -//line templates/gitlist.qtpl:24 +//line templates/gitlist.qtpl:25 qw422016.N().S(`</p> <p> <a href="/`) -//line templates/gitlist.qtpl:26 +//line templates/gitlist.qtpl:27 qw422016.E().S(r.Name) -//line templates/gitlist.qtpl:26 +//line templates/gitlist.qtpl:27 qw422016.N().S(`/log/`) -//line templates/gitlist.qtpl:26 +//line templates/gitlist.qtpl:27 qw422016.E().S(r.Ref) -//line templates/gitlist.qtpl:26 +//line templates/gitlist.qtpl:27 qw422016.N().S(`/">log</a> <a href="/`) -//line templates/gitlist.qtpl:27 +//line templates/gitlist.qtpl:28 qw422016.E().S(r.Name) -//line templates/gitlist.qtpl:27 +//line templates/gitlist.qtpl:28 qw422016.N().S(`/tree/`) -//line templates/gitlist.qtpl:27 +//line templates/gitlist.qtpl:28 qw422016.E().S(r.Ref) -//line templates/gitlist.qtpl:27 +//line templates/gitlist.qtpl:28 qw422016.N().S(`/">tree</a> <a href="/`) -//line templates/gitlist.qtpl:28 +//line templates/gitlist.qtpl:29 qw422016.E().S(r.Name) -//line templates/gitlist.qtpl:28 +//line templates/gitlist.qtpl:29 qw422016.N().S(`/refs/">refs</a> </p> </div> `) -//line templates/gitlist.qtpl:31 +//line templates/gitlist.qtpl:32 } -//line templates/gitlist.qtpl:31 +//line templates/gitlist.qtpl:32 qw422016.N().S(` </div> </div> <div id="about" class="col-md-4 order-first order-md-last"> `) -//line templates/gitlist.qtpl:35 +//line templates/gitlist.qtpl:36 qw422016.N().Z(p.About) -//line templates/gitlist.qtpl:35 +//line templates/gitlist.qtpl:36 qw422016.N().S(` <div class="alert alert-warning text-center" role="alert"> This project is under development, things may be broken or incomplete. @@ -167,65 +170,65 @@ func (p *GitListPage) StreamContent(qw422016 *qt422016.Writer) { </div> </div> `) -//line templates/gitlist.qtpl:41 +//line templates/gitlist.qtpl:42 } -//line templates/gitlist.qtpl:41 -func (p *GitListPage) WriteContent(qq422016 qtio422016.Writer) { -//line templates/gitlist.qtpl:41 +//line templates/gitlist.qtpl:42 +func (p *GitListPage) WriteContent(qq422016 qtio422016.Writer, ctx context.Context) { +//line templates/gitlist.qtpl:42 qw422016 := qt422016.AcquireWriter(qq422016) -//line templates/gitlist.qtpl:41 - p.StreamContent(qw422016) -//line templates/gitlist.qtpl:41 +//line templates/gitlist.qtpl:42 + p.StreamContent(qw422016, ctx) +//line templates/gitlist.qtpl:42 qt422016.ReleaseWriter(qw422016) -//line templates/gitlist.qtpl:41 +//line templates/gitlist.qtpl:42 } -//line templates/gitlist.qtpl:41 -func (p *GitListPage) Content() string { -//line templates/gitlist.qtpl:41 +//line templates/gitlist.qtpl:42 +func (p *GitListPage) Content(ctx context.Context) string { +//line templates/gitlist.qtpl:42 qb422016 := qt422016.AcquireByteBuffer() -//line templates/gitlist.qtpl:41 - p.WriteContent(qb422016) -//line templates/gitlist.qtpl:41 +//line templates/gitlist.qtpl:42 + p.WriteContent(qb422016, ctx) +//line templates/gitlist.qtpl:42 qs422016 := string(qb422016.B) -//line templates/gitlist.qtpl:41 +//line templates/gitlist.qtpl:42 qt422016.ReleaseByteBuffer(qb422016) -//line templates/gitlist.qtpl:41 +//line templates/gitlist.qtpl:42 return qs422016 -//line templates/gitlist.qtpl:41 +//line templates/gitlist.qtpl:42 } -//line templates/gitlist.qtpl:43 -func (p *GitListPage) StreamScript(qw422016 *qt422016.Writer) { -//line templates/gitlist.qtpl:43 +//line templates/gitlist.qtpl:44 +func (p *GitListPage) StreamScript(qw422016 *qt422016.Writer, ctx context.Context) { +//line templates/gitlist.qtpl:44 qw422016.N().S(` `) -//line templates/gitlist.qtpl:44 +//line templates/gitlist.qtpl:45 } -//line templates/gitlist.qtpl:44 -func (p *GitListPage) WriteScript(qq422016 qtio422016.Writer) { -//line templates/gitlist.qtpl:44 +//line templates/gitlist.qtpl:45 +func (p *GitListPage) WriteScript(qq422016 qtio422016.Writer, ctx context.Context) { +//line templates/gitlist.qtpl:45 qw422016 := qt422016.AcquireWriter(qq422016) -//line templates/gitlist.qtpl:44 - p.StreamScript(qw422016) -//line templates/gitlist.qtpl:44 +//line templates/gitlist.qtpl:45 + p.StreamScript(qw422016, ctx) +//line templates/gitlist.qtpl:45 qt422016.ReleaseWriter(qw422016) -//line templates/gitlist.qtpl:44 +//line templates/gitlist.qtpl:45 } -//line templates/gitlist.qtpl:44 -func (p *GitListPage) Script() string { -//line templates/gitlist.qtpl:44 +//line templates/gitlist.qtpl:45 +func (p *GitListPage) Script(ctx context.Context) string { +//line templates/gitlist.qtpl:45 qb422016 := qt422016.AcquireByteBuffer() -//line templates/gitlist.qtpl:44 - p.WriteScript(qb422016) -//line templates/gitlist.qtpl:44 +//line templates/gitlist.qtpl:45 + p.WriteScript(qb422016, ctx) +//line templates/gitlist.qtpl:45 qs422016 := string(qb422016.B) -//line templates/gitlist.qtpl:44 +//line templates/gitlist.qtpl:45 qt422016.ReleaseByteBuffer(qb422016) -//line templates/gitlist.qtpl:44 +//line templates/gitlist.qtpl:45 return qs422016 -//line templates/gitlist.qtpl:44 +//line templates/gitlist.qtpl:45 } |