🎨 Format template files

This commit is contained in:
Maxim Lebedev 2023-01-16 16:19:22 +06:00
parent 43af05a02b
commit 834d27d939
Signed by: toby3d
GPG Key ID: 1F14E25B7C119FC5
10 changed files with 301 additions and 287 deletions

View File

@ -101,13 +101,14 @@
{% endif %} {% endif %}
{% if p.CodeChallenge != "" %} {% if p.CodeChallenge != "" %}
{% for key, val := range map[string]string{
"code_challenge": p.CodeChallenge,
"code_challenge_method": p.CodeChallengeMethod.String(),
} %}
<input type="hidden" <input type="hidden"
name="code_challenge" name="{%s key %}"
value="{%s p.CodeChallenge %}"> value="{%s val %}">
{% endfor %}
<input type="hidden"
name="code_challenge_method"
value="{%s p.CodeChallengeMethod.String() %}">
{% endif %} {% endif %}
{% if p.Me != nil %} {% if p.Me != nil %}

View File

@ -292,19 +292,23 @@ func (p *AuthorizePage) StreamBody(qw422016 *qt422016.Writer) {
if p.CodeChallenge != "" { if p.CodeChallenge != "" {
//line web/authorize.qtpl:103 //line web/authorize.qtpl:103
qw422016.N().S(` qw422016.N().S(`
`)
//line web/authorize.qtpl:104
for key, val := range map[string]string{
"code_challenge": p.CodeChallenge,
"code_challenge_method": p.CodeChallengeMethod.String(),
} {
//line web/authorize.qtpl:107
qw422016.N().S(`
<input type="hidden" <input type="hidden"
name="code_challenge" name="`)
value="`) //line web/authorize.qtpl:109
//line web/authorize.qtpl:106 qw422016.E().S(key)
qw422016.E().S(p.CodeChallenge) //line web/authorize.qtpl:109
//line web/authorize.qtpl:106 qw422016.N().S(`"
qw422016.N().S(`">
<input type="hidden"
name="code_challenge_method"
value="`) value="`)
//line web/authorize.qtpl:110 //line web/authorize.qtpl:110
qw422016.E().S(p.CodeChallengeMethod.String()) qw422016.E().S(val)
//line web/authorize.qtpl:110 //line web/authorize.qtpl:110
qw422016.N().S(`"> qw422016.N().S(`">
`) `)
@ -312,78 +316,83 @@ func (p *AuthorizePage) StreamBody(qw422016 *qt422016.Writer) {
} }
//line web/authorize.qtpl:111 //line web/authorize.qtpl:111
qw422016.N().S(` qw422016.N().S(`
`)
//line web/authorize.qtpl:112
}
//line web/authorize.qtpl:112
qw422016.N().S(`
`) `)
//line web/authorize.qtpl:113 //line web/authorize.qtpl:114
if p.Me != nil { if p.Me != nil {
//line web/authorize.qtpl:113 //line web/authorize.qtpl:114
qw422016.N().S(` qw422016.N().S(`
<input type="hidden" <input type="hidden"
name="me" name="me"
value="`) value="`)
//line web/authorize.qtpl:116 //line web/authorize.qtpl:117
qw422016.E().S(p.Me.String()) qw422016.E().S(p.Me.String())
//line web/authorize.qtpl:116 //line web/authorize.qtpl:117
qw422016.N().S(`"> qw422016.N().S(`">
`) `)
//line web/authorize.qtpl:117 //line web/authorize.qtpl:118
} }
//line web/authorize.qtpl:117 //line web/authorize.qtpl:118
qw422016.N().S(` qw422016.N().S(`
`) `)
//line web/authorize.qtpl:119 //line web/authorize.qtpl:120
if len(p.Providers) > 0 { if len(p.Providers) > 0 {
//line web/authorize.qtpl:119 //line web/authorize.qtpl:120
qw422016.N().S(` qw422016.N().S(`
<select name="provider" <select name="provider"
autocomplete autocomplete
required> required>
`) `)
//line web/authorize.qtpl:124 //line web/authorize.qtpl:125
for _, provider := range p.Providers { for _, provider := range p.Providers {
//line web/authorize.qtpl:124 //line web/authorize.qtpl:125
qw422016.N().S(` qw422016.N().S(`
<option value="`) <option value="`)
//line web/authorize.qtpl:125 //line web/authorize.qtpl:126
qw422016.E().S(provider.UID) qw422016.E().S(provider.UID)
//line web/authorize.qtpl:125 //line web/authorize.qtpl:126
qw422016.N().S(`" qw422016.N().S(`"
`) `)
//line web/authorize.qtpl:126 //line web/authorize.qtpl:127
if provider.UID == "mastodon" { if provider.UID == "mastodon" {
//line web/authorize.qtpl:126 //line web/authorize.qtpl:127
qw422016.N().S(`selected`) qw422016.N().S(`selected`)
//line web/authorize.qtpl:126 //line web/authorize.qtpl:127
} }
//line web/authorize.qtpl:126 //line web/authorize.qtpl:127
qw422016.N().S(`> qw422016.N().S(`>
`) `)
//line web/authorize.qtpl:128 //line web/authorize.qtpl:129
qw422016.E().S(provider.Name) qw422016.E().S(provider.Name)
//line web/authorize.qtpl:128 //line web/authorize.qtpl:129
qw422016.N().S(` qw422016.N().S(`
</option> </option>
`) `)
//line web/authorize.qtpl:130 //line web/authorize.qtpl:131
} }
//line web/authorize.qtpl:130 //line web/authorize.qtpl:131
qw422016.N().S(` qw422016.N().S(`
</select> </select>
`) `)
//line web/authorize.qtpl:132 //line web/authorize.qtpl:133
} else { } else {
//line web/authorize.qtpl:132 //line web/authorize.qtpl:133
qw422016.N().S(` qw422016.N().S(`
<input type="hidden" <input type="hidden"
name="provider" name="provider"
value="direct"> value="direct">
`) `)
//line web/authorize.qtpl:136 //line web/authorize.qtpl:137
} }
//line web/authorize.qtpl:136 //line web/authorize.qtpl:137
qw422016.N().S(` qw422016.N().S(`
<button type="submit" <button type="submit"
@ -391,9 +400,9 @@ func (p *AuthorizePage) StreamBody(qw422016 *qt422016.Writer) {
value="deny"> value="deny">
`) `)
//line web/authorize.qtpl:142 //line web/authorize.qtpl:143
p.StreamT(qw422016, "Deny") p.StreamT(qw422016, "Deny")
//line web/authorize.qtpl:142 //line web/authorize.qtpl:143
qw422016.N().S(` qw422016.N().S(`
</button> </button>
@ -402,39 +411,39 @@ func (p *AuthorizePage) StreamBody(qw422016 *qt422016.Writer) {
value="allow"> value="allow">
`) `)
//line web/authorize.qtpl:149 //line web/authorize.qtpl:150
p.StreamT(qw422016, "Allow") p.StreamT(qw422016, "Allow")
//line web/authorize.qtpl:149 //line web/authorize.qtpl:150
qw422016.N().S(` qw422016.N().S(`
</button> </button>
</form> </form>
</main> </main>
`) `)
//line web/authorize.qtpl:153 //line web/authorize.qtpl:154
} }
//line web/authorize.qtpl:153 //line web/authorize.qtpl:154
func (p *AuthorizePage) WriteBody(qq422016 qtio422016.Writer) { func (p *AuthorizePage) WriteBody(qq422016 qtio422016.Writer) {
//line web/authorize.qtpl:153 //line web/authorize.qtpl:154
qw422016 := qt422016.AcquireWriter(qq422016) qw422016 := qt422016.AcquireWriter(qq422016)
//line web/authorize.qtpl:153 //line web/authorize.qtpl:154
p.StreamBody(qw422016) p.StreamBody(qw422016)
//line web/authorize.qtpl:153 //line web/authorize.qtpl:154
qt422016.ReleaseWriter(qw422016) qt422016.ReleaseWriter(qw422016)
//line web/authorize.qtpl:153 //line web/authorize.qtpl:154
} }
//line web/authorize.qtpl:153 //line web/authorize.qtpl:154
func (p *AuthorizePage) Body() string { func (p *AuthorizePage) Body() string {
//line web/authorize.qtpl:153 //line web/authorize.qtpl:154
qb422016 := qt422016.AcquireByteBuffer() qb422016 := qt422016.AcquireByteBuffer()
//line web/authorize.qtpl:153 //line web/authorize.qtpl:154
p.WriteBody(qb422016) p.WriteBody(qb422016)
//line web/authorize.qtpl:153 //line web/authorize.qtpl:154
qs422016 := string(qb422016.B) qs422016 := string(qb422016.B)
//line web/authorize.qtpl:153 //line web/authorize.qtpl:154
qt422016.ReleaseByteBuffer(qb422016) qt422016.ReleaseByteBuffer(qb422016)
//line web/authorize.qtpl:153 //line web/authorize.qtpl:154
return qs422016 return qs422016
//line web/authorize.qtpl:153 //line web/authorize.qtpl:154
} }

View File

@ -62,12 +62,14 @@
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta name="viewport"
content="width=device-width, initial-scale=1.0">
{%= p.Head() %} {%= p.Head() %}
<title>{%= p.Title() %}</title> <title>{%= p.Title() %}</title>
</head> </head>
<body class="page__body body"> <body class="page__body body">
{%= p.Body() %} {%= p.Body() %}
@ -91,7 +93,8 @@
<footer> <footer>
<small> <small>
{%= p.T("version") %} {%= p.T("version") %}
<a href="https://{%s path %}/commit/{%s vcsRevision %}" target="_blank"> <a href="https://{%s path %}/commit/{%s vcsRevision %}"
target="_blank">
{%s vcsRevision[:7] -%} {%s vcsRevision[:7] -%}
</a> </a>
</small> </small>

View File

@ -237,19 +237,19 @@ func StreamTemplate(qw422016 *qt422016.Writer, p Page) {
p.StreamLang(qw422016) p.StreamLang(qw422016)
//line web/baseof.qtpl:61 //line web/baseof.qtpl:61
qw422016.N().S(`"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> `) qw422016.N().S(`"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> `)
//line web/baseof.qtpl:67 //line web/baseof.qtpl:68
p.StreamHead(qw422016) p.StreamHead(qw422016)
//line web/baseof.qtpl:67 //line web/baseof.qtpl:68
qw422016.N().S(` <title>`) qw422016.N().S(` <title>`)
//line web/baseof.qtpl:69 //line web/baseof.qtpl:70
p.StreamTitle(qw422016) p.StreamTitle(qw422016)
//line web/baseof.qtpl:69 //line web/baseof.qtpl:70
qw422016.N().S(`</title> </head> <body class="page__body body"> `) qw422016.N().S(`</title> </head> <body class="page__body body"> `)
//line web/baseof.qtpl:72 //line web/baseof.qtpl:74
p.StreamBody(qw422016) p.StreamBody(qw422016)
//line web/baseof.qtpl:72 //line web/baseof.qtpl:74
qw422016.N().S(` `) qw422016.N().S(` `)
//line web/baseof.qtpl:75 //line web/baseof.qtpl:77
var path, vcsRevision string var path, vcsRevision string
if bi, ok := debug.ReadBuildInfo(); ok { if bi, ok := debug.ReadBuildInfo(); ok {
@ -264,94 +264,94 @@ func StreamTemplate(qw422016 *qt422016.Writer, p Page) {
} }
} }
//line web/baseof.qtpl:88
qw422016.N().S(` `)
//line web/baseof.qtpl:90 //line web/baseof.qtpl:90
qw422016.N().S(` `)
//line web/baseof.qtpl:92
if vcsRevision != "" { if vcsRevision != "" {
//line web/baseof.qtpl:90 //line web/baseof.qtpl:92
qw422016.N().S(` <footer> <small> `) qw422016.N().S(` <footer> <small> `)
//line web/baseof.qtpl:93 //line web/baseof.qtpl:95
p.StreamT(qw422016, "version") p.StreamT(qw422016, "version")
//line web/baseof.qtpl:93 //line web/baseof.qtpl:95
qw422016.N().S(` <a href="https://`) qw422016.N().S(` <a href="https://`)
//line web/baseof.qtpl:94 //line web/baseof.qtpl:96
qw422016.E().S(path) qw422016.E().S(path)
//line web/baseof.qtpl:94 //line web/baseof.qtpl:96
qw422016.N().S(`/commit/`) qw422016.N().S(`/commit/`)
//line web/baseof.qtpl:94 //line web/baseof.qtpl:96
qw422016.E().S(vcsRevision) qw422016.E().S(vcsRevision)
//line web/baseof.qtpl:94 //line web/baseof.qtpl:96
qw422016.N().S(`" target="_blank"> `) qw422016.N().S(`" target="_blank"> `)
//line web/baseof.qtpl:95 //line web/baseof.qtpl:98
qw422016.E().S(vcsRevision[:7]) qw422016.E().S(vcsRevision[:7])
//line web/baseof.qtpl:95 //line web/baseof.qtpl:98
qw422016.N().S(`</a> </small> </footer> `) qw422016.N().S(`</a> </small> </footer> `)
//line web/baseof.qtpl:99 //line web/baseof.qtpl:102
} }
//line web/baseof.qtpl:99 //line web/baseof.qtpl:102
qw422016.N().S(` </body> </html> `) qw422016.N().S(` </body> </html> `)
//line web/baseof.qtpl:102 //line web/baseof.qtpl:105
} }
//line web/baseof.qtpl:102 //line web/baseof.qtpl:105
func WriteTemplate(qq422016 qtio422016.Writer, p Page) { func WriteTemplate(qq422016 qtio422016.Writer, p Page) {
//line web/baseof.qtpl:102 //line web/baseof.qtpl:105
qw422016 := qt422016.AcquireWriter(qq422016) qw422016 := qt422016.AcquireWriter(qq422016)
//line web/baseof.qtpl:102 //line web/baseof.qtpl:105
StreamTemplate(qw422016, p) StreamTemplate(qw422016, p)
//line web/baseof.qtpl:102 //line web/baseof.qtpl:105
qt422016.ReleaseWriter(qw422016) qt422016.ReleaseWriter(qw422016)
//line web/baseof.qtpl:102 //line web/baseof.qtpl:105
} }
//line web/baseof.qtpl:102 //line web/baseof.qtpl:105
func Template(p Page) string { func Template(p Page) string {
//line web/baseof.qtpl:102 //line web/baseof.qtpl:105
qb422016 := qt422016.AcquireByteBuffer() qb422016 := qt422016.AcquireByteBuffer()
//line web/baseof.qtpl:102 //line web/baseof.qtpl:105
WriteTemplate(qb422016, p) WriteTemplate(qb422016, p)
//line web/baseof.qtpl:102 //line web/baseof.qtpl:105
qs422016 := string(qb422016.B) qs422016 := string(qb422016.B)
//line web/baseof.qtpl:102 //line web/baseof.qtpl:105
qt422016.ReleaseByteBuffer(qb422016) qt422016.ReleaseByteBuffer(qb422016)
//line web/baseof.qtpl:102 //line web/baseof.qtpl:105
return qs422016 return qs422016
//line web/baseof.qtpl:102 //line web/baseof.qtpl:105
} }
//line web/baseof.qtpl:104 //line web/baseof.qtpl:107
func (p *BaseOf) StreamT(qw422016 *qt422016.Writer, format string, args ...interface{}) { func (p *BaseOf) StreamT(qw422016 *qt422016.Writer, format string, args ...interface{}) {
//line web/baseof.qtpl:104 //line web/baseof.qtpl:107
qw422016.N().S(` `) qw422016.N().S(` `)
//line web/baseof.qtpl:105 //line web/baseof.qtpl:108
qw422016.E().S(p.Printer.Sprintf(format, args...)) qw422016.E().S(p.Printer.Sprintf(format, args...))
//line web/baseof.qtpl:105 //line web/baseof.qtpl:108
qw422016.N().S(` `) qw422016.N().S(` `)
//line web/baseof.qtpl:106 //line web/baseof.qtpl:109
} }
//line web/baseof.qtpl:106 //line web/baseof.qtpl:109
func (p *BaseOf) WriteT(qq422016 qtio422016.Writer, format string, args ...interface{}) { func (p *BaseOf) WriteT(qq422016 qtio422016.Writer, format string, args ...interface{}) {
//line web/baseof.qtpl:106 //line web/baseof.qtpl:109
qw422016 := qt422016.AcquireWriter(qq422016) qw422016 := qt422016.AcquireWriter(qq422016)
//line web/baseof.qtpl:106 //line web/baseof.qtpl:109
p.StreamT(qw422016, format, args...) p.StreamT(qw422016, format, args...)
//line web/baseof.qtpl:106 //line web/baseof.qtpl:109
qt422016.ReleaseWriter(qw422016) qt422016.ReleaseWriter(qw422016)
//line web/baseof.qtpl:106 //line web/baseof.qtpl:109
} }
//line web/baseof.qtpl:106 //line web/baseof.qtpl:109
func (p *BaseOf) T(format string, args ...interface{}) string { func (p *BaseOf) T(format string, args ...interface{}) string {
//line web/baseof.qtpl:106 //line web/baseof.qtpl:109
qb422016 := qt422016.AcquireByteBuffer() qb422016 := qt422016.AcquireByteBuffer()
//line web/baseof.qtpl:106 //line web/baseof.qtpl:109
p.WriteT(qb422016, format, args...) p.WriteT(qb422016, format, args...)
//line web/baseof.qtpl:106 //line web/baseof.qtpl:109
qs422016 := string(qb422016.B) qs422016 := string(qb422016.B)
//line web/baseof.qtpl:106 //line web/baseof.qtpl:109
qt422016.ReleaseByteBuffer(qb422016) qt422016.ReleaseByteBuffer(qb422016)
//line web/baseof.qtpl:106 //line web/baseof.qtpl:109
return qs422016 return qs422016
//line web/baseof.qtpl:106 //line web/baseof.qtpl:109
} }

View File

@ -12,7 +12,8 @@
{% func (p *HomePage) Head() %} {% func (p *HomePage) Head() %}
{%= p.BaseOf.Head() %} {%= p.BaseOf.Head() %}
{% for i := range p.Client.RedirectURI %} {% for i := range p.Client.RedirectURI %}
<link rel="redirect_uri" href="{%s p.Client.RedirectURI[i].String() %}"> <link rel="redirect_uri"
href="{%s p.Client.RedirectURI[i].String() %}">
{% endfor %} {% endfor %}
{% endfunc %} {% endfunc %}

View File

@ -41,128 +41,128 @@ func (p *HomePage) StreamHead(qw422016 *qt422016.Writer) {
for i := range p.Client.RedirectURI { for i := range p.Client.RedirectURI {
//line web/home.qtpl:14 //line web/home.qtpl:14
qw422016.N().S(` <link rel="redirect_uri" href="`) qw422016.N().S(` <link rel="redirect_uri" href="`)
//line web/home.qtpl:15 //line web/home.qtpl:16
qw422016.E().S(p.Client.RedirectURI[i].String()) qw422016.E().S(p.Client.RedirectURI[i].String())
//line web/home.qtpl:15 //line web/home.qtpl:16
qw422016.N().S(`"> `) qw422016.N().S(`"> `)
//line web/home.qtpl:16 //line web/home.qtpl:17
} }
//line web/home.qtpl:16 //line web/home.qtpl:17
qw422016.N().S(` `) qw422016.N().S(` `)
//line web/home.qtpl:17 //line web/home.qtpl:18
} }
//line web/home.qtpl:17 //line web/home.qtpl:18
func (p *HomePage) WriteHead(qq422016 qtio422016.Writer) { func (p *HomePage) WriteHead(qq422016 qtio422016.Writer) {
//line web/home.qtpl:17 //line web/home.qtpl:18
qw422016 := qt422016.AcquireWriter(qq422016) qw422016 := qt422016.AcquireWriter(qq422016)
//line web/home.qtpl:17 //line web/home.qtpl:18
p.StreamHead(qw422016) p.StreamHead(qw422016)
//line web/home.qtpl:17 //line web/home.qtpl:18
qt422016.ReleaseWriter(qw422016) qt422016.ReleaseWriter(qw422016)
//line web/home.qtpl:17 //line web/home.qtpl:18
} }
//line web/home.qtpl:17 //line web/home.qtpl:18
func (p *HomePage) Head() string { func (p *HomePage) Head() string {
//line web/home.qtpl:17 //line web/home.qtpl:18
qb422016 := qt422016.AcquireByteBuffer() qb422016 := qt422016.AcquireByteBuffer()
//line web/home.qtpl:17 //line web/home.qtpl:18
p.WriteHead(qb422016) p.WriteHead(qb422016)
//line web/home.qtpl:17 //line web/home.qtpl:18
qs422016 := string(qb422016.B) qs422016 := string(qb422016.B)
//line web/home.qtpl:17 //line web/home.qtpl:18
qt422016.ReleaseByteBuffer(qb422016) qt422016.ReleaseByteBuffer(qb422016)
//line web/home.qtpl:17 //line web/home.qtpl:18
return qs422016 return qs422016
//line web/home.qtpl:17 //line web/home.qtpl:18
} }
//line web/home.qtpl:19 //line web/home.qtpl:20
func (p *HomePage) StreamBody(qw422016 *qt422016.Writer) { func (p *HomePage) StreamBody(qw422016 *qt422016.Writer) {
//line web/home.qtpl:19 //line web/home.qtpl:20
qw422016.N().S(` <header class="h-app h-x-app"> <img class="u-logo" src="`) qw422016.N().S(` <header class="h-app h-x-app"> <img class="u-logo" src="`)
//line web/home.qtpl:22 //line web/home.qtpl:23
qw422016.E().S(p.Client.GetLogo().String()) qw422016.E().S(p.Client.GetLogo().String())
//line web/home.qtpl:22 //line web/home.qtpl:23
qw422016.N().S(`" alt="`) qw422016.N().S(`" alt="`)
//line web/home.qtpl:23 //line web/home.qtpl:24
qw422016.E().S(p.Client.GetName()) qw422016.E().S(p.Client.GetName())
//line web/home.qtpl:23 //line web/home.qtpl:24
qw422016.N().S(`" crossorigin="anonymous" decoding="async" height="140" importance="high" referrerpolicy="no-referrer-when-downgrade" width="140"> <h1> <a class="p-name u-url" href="`) qw422016.N().S(`" crossorigin="anonymous" decoding="async" height="140" importance="high" referrerpolicy="no-referrer-when-downgrade" width="140"> <h1> <a class="p-name u-url" href="`)
//line web/home.qtpl:33 //line web/home.qtpl:34
qw422016.E().S(p.Client.GetURL().String()) qw422016.E().S(p.Client.GetURL().String())
//line web/home.qtpl:33 //line web/home.qtpl:34
qw422016.N().S(`"> `) qw422016.N().S(`"> `)
//line web/home.qtpl:35 //line web/home.qtpl:36
qw422016.E().S(p.Client.GetName()) qw422016.E().S(p.Client.GetName())
//line web/home.qtpl:35 //line web/home.qtpl:36
qw422016.N().S(` </a> </h1> </header> <main> <form class="" method="get" action="/authorize" enctype="application/x-www-form-urlencoded" accept-charset="utf-8" target="_self"> `) qw422016.N().S(` </a> </h1> </header> <main> <form class="" method="get" action="/authorize" enctype="application/x-www-form-urlencoded" accept-charset="utf-8" target="_self"> `)
//line web/home.qtpl:48 //line web/home.qtpl:49
for name, value := range map[string]string{ for name, value := range map[string]string{
"client_id": p.Client.ID.String(), "client_id": p.Client.ID.String(),
"redirect_uri": p.Client.RedirectURI[0].String(), "redirect_uri": p.Client.RedirectURI[0].String(),
"response_type": domain.ResponseTypeCode.String(), "response_type": domain.ResponseTypeCode.String(),
"state": p.State, "state": p.State,
} { } {
//line web/home.qtpl:53 //line web/home.qtpl:54
qw422016.N().S(` <input type="hidden" name="`) qw422016.N().S(` <input type="hidden" name="`)
//line web/home.qtpl:55 //line web/home.qtpl:56
qw422016.E().S(name) qw422016.E().S(name)
//line web/home.qtpl:55 //line web/home.qtpl:56
qw422016.N().S(`" value="`) qw422016.N().S(`" value="`)
//line web/home.qtpl:56 //line web/home.qtpl:57
qw422016.E().S(value) qw422016.E().S(value)
//line web/home.qtpl:56 //line web/home.qtpl:57
qw422016.N().S(`"> `) qw422016.N().S(`"> `)
//line web/home.qtpl:57 //line web/home.qtpl:58
} }
//line web/home.qtpl:57 //line web/home.qtpl:58
qw422016.N().S(` `) qw422016.N().S(` `)
//line web/home.qtpl:59 //line web/home.qtpl:60
for _, scope := range []domain.Scope{ for _, scope := range []domain.Scope{
domain.ScopeEmail, domain.ScopeEmail,
domain.ScopeProfile, domain.ScopeProfile,
} { } {
//line web/home.qtpl:62 //line web/home.qtpl:63
qw422016.N().S(` <input type="hidden" name="scope[]" value="`) qw422016.N().S(` <input type="hidden" name="scope[]" value="`)
//line web/home.qtpl:65 //line web/home.qtpl:66
qw422016.E().S(scope.String()) qw422016.E().S(scope.String())
//line web/home.qtpl:65 //line web/home.qtpl:66
qw422016.N().S(`"> `) qw422016.N().S(`"> `)
//line web/home.qtpl:66 //line web/home.qtpl:67
} }
//line web/home.qtpl:66 //line web/home.qtpl:67
qw422016.N().S(` <input type="url" name="me" placeholder="https://example.com/" inputmode="url" autocomplete="url" required> <button type="submit">`) qw422016.N().S(` <input type="url" name="me" placeholder="https://example.com/" inputmode="url" autocomplete="url" required> <button type="submit">`)
//line web/home.qtpl:75 //line web/home.qtpl:76
p.StreamT(qw422016, "Sign In") p.StreamT(qw422016, "Sign In")
//line web/home.qtpl:75 //line web/home.qtpl:76
qw422016.N().S(`</button> </form> </main> `) qw422016.N().S(`</button> </form> </main> `)
//line web/home.qtpl:78 //line web/home.qtpl:79
} }
//line web/home.qtpl:78 //line web/home.qtpl:79
func (p *HomePage) WriteBody(qq422016 qtio422016.Writer) { func (p *HomePage) WriteBody(qq422016 qtio422016.Writer) {
//line web/home.qtpl:78 //line web/home.qtpl:79
qw422016 := qt422016.AcquireWriter(qq422016) qw422016 := qt422016.AcquireWriter(qq422016)
//line web/home.qtpl:78 //line web/home.qtpl:79
p.StreamBody(qw422016) p.StreamBody(qw422016)
//line web/home.qtpl:78 //line web/home.qtpl:79
qt422016.ReleaseWriter(qw422016) qt422016.ReleaseWriter(qw422016)
//line web/home.qtpl:78 //line web/home.qtpl:79
} }
//line web/home.qtpl:78 //line web/home.qtpl:79
func (p *HomePage) Body() string { func (p *HomePage) Body() string {
//line web/home.qtpl:78 //line web/home.qtpl:79
qb422016 := qt422016.AcquireByteBuffer() qb422016 := qt422016.AcquireByteBuffer()
//line web/home.qtpl:78 //line web/home.qtpl:79
p.WriteBody(qb422016) p.WriteBody(qb422016)
//line web/home.qtpl:78 //line web/home.qtpl:79
qs422016 := string(qb422016.B) qs422016 := string(qb422016.B)
//line web/home.qtpl:78 //line web/home.qtpl:79
qt422016.ReleaseByteBuffer(qb422016) qt422016.ReleaseByteBuffer(qb422016)
//line web/home.qtpl:78 //line web/home.qtpl:79
return qs422016 return qs422016
//line web/home.qtpl:78 //line web/home.qtpl:79
} }

View File

@ -30,7 +30,7 @@
type="url" type="url"
name="subject" name="subject"
inputmode="url" inputmode="url"
placeholder="https://bob.example.org" placeholder="https://bob.example.org/"
required> required>
</div> </div>

View File

@ -46,7 +46,7 @@ func (p *TicketPage) StreamBody(qw422016 *qt422016.Writer) {
//line web/ticket.qtpl:28 //line web/ticket.qtpl:28
p.StreamT(qw422016, "Recipient") p.StreamT(qw422016, "Recipient")
//line web/ticket.qtpl:28 //line web/ticket.qtpl:28
qw422016.N().S(`</label> <input id="subject" type="url" name="subject" inputmode="url" placeholder="https://bob.example.org" required> </div> <div> <label for="resource">`) qw422016.N().S(`</label> <input id="subject" type="url" name="subject" inputmode="url" placeholder="https://bob.example.org/" required> </div> <div> <label for="resource">`)
//line web/ticket.qtpl:38 //line web/ticket.qtpl:38
p.StreamT(qw422016, "Resource") p.StreamT(qw422016, "Resource")
//line web/ticket.qtpl:38 //line web/ticket.qtpl:38