1// Code generated by qtc from "gitlist.qtpl". DO NOT EDIT.
2// See https://github.com/valyala/quicktemplate for details.
3
4//line gitlist.qtpl:1
5package templates
6
7//line gitlist.qtpl:1
8import "git.gabrielgio.me/cerrado/pkg/service"
9
10//line gitlist.qtpl:2
11import "git.gabrielgio.me/cerrado/pkg/u"
12
13//line gitlist.qtpl:5
14import (
15 qtio422016 "io"
16
17 qt422016 "github.com/valyala/quicktemplate"
18)
19
20//line gitlist.qtpl:5
21var (
22 _ = qtio422016.Copy
23 _ = qt422016.AcquireByteBuffer
24)
25
26//line gitlist.qtpl:6
27type GitListPage struct {
28 Respositories []*service.Repository
29}
30
31//line gitlist.qtpl:11
32func (p *GitListPage) StreamTitle(qw422016 *qt422016.Writer) {
33//line gitlist.qtpl:11
34 qw422016.N().S(`Git | List`)
35//line gitlist.qtpl:11
36}
37
38//line gitlist.qtpl:11
39func (p *GitListPage) WriteTitle(qq422016 qtio422016.Writer) {
40//line gitlist.qtpl:11
41 qw422016 := qt422016.AcquireWriter(qq422016)
42//line gitlist.qtpl:11
43 p.StreamTitle(qw422016)
44//line gitlist.qtpl:11
45 qt422016.ReleaseWriter(qw422016)
46//line gitlist.qtpl:11
47}
48
49//line gitlist.qtpl:11
50func (p *GitListPage) Title() string {
51//line gitlist.qtpl:11
52 qb422016 := qt422016.AcquireByteBuffer()
53//line gitlist.qtpl:11
54 p.WriteTitle(qb422016)
55//line gitlist.qtpl:11
56 qs422016 := string(qb422016.B)
57//line gitlist.qtpl:11
58 qt422016.ReleaseByteBuffer(qb422016)
59//line gitlist.qtpl:11
60 return qs422016
61//line gitlist.qtpl:11
62}
63
64//line gitlist.qtpl:13
65func (p *GitListPage) StreamContent(qw422016 *qt422016.Writer) {
66//line gitlist.qtpl:13
67 qw422016.N().S(`
68`)
69//line gitlist.qtpl:14
70 for _, c := range u.ChunkBy(p.Respositories, 3) {
71//line gitlist.qtpl:14
72 qw422016.N().S(`
73<div class="row">
74 `)
75//line gitlist.qtpl:16
76 for _, r := range c {
77//line gitlist.qtpl:16
78 qw422016.N().S(`
79 <div class="col-md-4 g-0">
80 <div class="card">
81 <div class="card-header">
82 `)
83//line gitlist.qtpl:20
84 qw422016.E().S(r.Title)
85//line gitlist.qtpl:20
86 qw422016.N().S(`
87 </div>
88 <div class="card-body">
89 <p class="card-text">`)
90//line gitlist.qtpl:23
91 qw422016.E().S(r.Description)
92//line gitlist.qtpl:23
93 qw422016.N().S(`</p>
94 <a href="/`)
95//line gitlist.qtpl:24
96 qw422016.E().S(r.Name)
97//line gitlist.qtpl:24
98 qw422016.N().S(`" class="btn btn-primary">go to repository</a>
99 </div>
100 </div>
101 </div>
102 `)
103//line gitlist.qtpl:28
104 }
105//line gitlist.qtpl:28
106 qw422016.N().S(`
107</div>
108`)
109//line gitlist.qtpl:30
110 }
111//line gitlist.qtpl:30
112 qw422016.N().S(`
113`)
114//line gitlist.qtpl:31
115}
116
117//line gitlist.qtpl:31
118func (p *GitListPage) WriteContent(qq422016 qtio422016.Writer) {
119//line gitlist.qtpl:31
120 qw422016 := qt422016.AcquireWriter(qq422016)
121//line gitlist.qtpl:31
122 p.StreamContent(qw422016)
123//line gitlist.qtpl:31
124 qt422016.ReleaseWriter(qw422016)
125//line gitlist.qtpl:31
126}
127
128//line gitlist.qtpl:31
129func (p *GitListPage) Content() string {
130//line gitlist.qtpl:31
131 qb422016 := qt422016.AcquireByteBuffer()
132//line gitlist.qtpl:31
133 p.WriteContent(qb422016)
134//line gitlist.qtpl:31
135 qs422016 := string(qb422016.B)
136//line gitlist.qtpl:31
137 qt422016.ReleaseByteBuffer(qb422016)
138//line gitlist.qtpl:31
139 return qs422016
140//line gitlist.qtpl:31
141}
142
143//line gitlist.qtpl:33
144func (p *GitListPage) StreamScript(qw422016 *qt422016.Writer) {
145//line gitlist.qtpl:33
146 qw422016.N().S(`
147`)
148//line gitlist.qtpl:34
149}
150
151//line gitlist.qtpl:34
152func (p *GitListPage) WriteScript(qq422016 qtio422016.Writer) {
153//line gitlist.qtpl:34
154 qw422016 := qt422016.AcquireWriter(qq422016)
155//line gitlist.qtpl:34
156 p.StreamScript(qw422016)
157//line gitlist.qtpl:34
158 qt422016.ReleaseWriter(qw422016)
159//line gitlist.qtpl:34
160}
161
162//line gitlist.qtpl:34
163func (p *GitListPage) Script() string {
164//line gitlist.qtpl:34
165 qb422016 := qt422016.AcquireByteBuffer()
166//line gitlist.qtpl:34
167 p.WriteScript(qb422016)
168//line gitlist.qtpl:34
169 qs422016 := string(qb422016.B)
170//line gitlist.qtpl:34
171 qt422016.ReleaseByteBuffer(qb422016)
172//line gitlist.qtpl:34
173 return qs422016
174//line gitlist.qtpl:34
175}