1
0
mirror of https://github.com/osmarks/mycorrhiza.git synced 2024-10-30 19:56:16 +00:00
mycorrhiza/views/auth.qtpl.go

604 lines
16 KiB
Go
Raw Normal View History

2020-11-14 13:03:06 +00:00
// Code generated by qtc from "auth.qtpl". DO NOT EDIT.
// See https://github.com/valyala/quicktemplate for details.
//line views/auth.qtpl:1
package views
2020-11-14 13:03:06 +00:00
//line views/auth.qtpl:1
import "net/http"
2020-11-14 13:03:06 +00:00
2021-02-23 14:36:12 +00:00
//line views/auth.qtpl:2
import "github.com/bouncepaw/mycorrhiza/cfg"
2021-02-23 14:36:12 +00:00
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:3
import "github.com/bouncepaw/mycorrhiza/l18n"
//line views/auth.qtpl:5
2020-11-14 13:03:06 +00:00
import (
qtio422016 "io"
qt422016 "github.com/valyala/quicktemplate"
)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:5
2020-11-14 13:03:06 +00:00
var (
_ = qtio422016.Copy
_ = qt422016.AcquireByteBuffer
)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:5
func StreamRegisterHTML(qw422016 *qt422016.Writer, rq *http.Request) {
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:5
qw422016.N().S(`
`)
//line views/auth.qtpl:7
lc := l18n.FromRequest(rq)
//line views/auth.qtpl:8
qw422016.N().S(`
<div class="layout">
<main class="main-width">
<section>
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:12
if cfg.AllowRegistration {
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:12
qw422016.N().S(`
<form class="modal" method="post" action="/register?`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:13
qw422016.E().S(rq.URL.RawQuery)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:13
qw422016.N().S(`" id="register-form" enctype="multipart/form-data" autocomplete="off">
<fieldset class="modal__fieldset">
2021-09-06 17:46:34 +00:00
<legend class="modal__title">`)
//line views/auth.qtpl:15
qw422016.E().S(lc.Get("auth.register_header", &l18n.Replacements{"name": cfg.WikiName}))
//line views/auth.qtpl:15
qw422016.N().S(`</legend>
2021-09-06 17:46:34 +00:00
<label for="register-form__username">`)
//line views/auth.qtpl:17
qw422016.E().S(lc.Get("auth.username"))
//line views/auth.qtpl:17
qw422016.N().S(`</label>
<br>
<input type="text" required autofocus id="login-form__username" name="username">
<br>
2021-09-06 17:46:34 +00:00
<label for="login-form__password">`)
//line views/auth.qtpl:21
qw422016.E().S(lc.Get("auth.password"))
//line views/auth.qtpl:21
qw422016.N().S(`</label>
<br>
<input type="password" required name="password">
2021-09-06 17:46:34 +00:00
<p>`)
//line views/auth.qtpl:24
qw422016.E().S(lc.Get("auth.password_tip"))
//line views/auth.qtpl:24
qw422016.N().S(`</p>
<p>`)
//line views/auth.qtpl:25
qw422016.E().S(lc.Get("auth.cookie_tip"))
//line views/auth.qtpl:25
qw422016.N().S(`</p>
<button class="btn" type="submit" value="Register">`)
//line views/auth.qtpl:26
qw422016.E().S(lc.Get("auth.register_button"))
//line views/auth.qtpl:26
qw422016.N().S(`</button>
<a class="btn btn_weak" href="/`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:27
qw422016.E().S(rq.URL.RawQuery)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:27
qw422016.N().S(`">`)
//line views/auth.qtpl:27
qw422016.E().S(lc.Get("ui.cancel"))
//line views/auth.qtpl:27
qw422016.N().S(`</a>
</fieldset>
</form>
2021-07-14 19:51:55 +00:00
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:30
streamtelegramWidgetHTML(qw422016, lc)
//line views/auth.qtpl:30
qw422016.N().S(`
2021-07-14 19:51:55 +00:00
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:31
2021-07-14 19:51:55 +00:00
} else if cfg.UseAuth {
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:31
2021-07-14 19:51:55 +00:00
qw422016.N().S(`
2021-09-06 17:46:34 +00:00
<p>`)
//line views/auth.qtpl:32
qw422016.E().S(lc.Get("auth.noregister"))
//line views/auth.qtpl:32
qw422016.N().S(`</p>
<p><a href="/`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:33
qw422016.E().S(rq.URL.RawQuery)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:33
qw422016.N().S(`">← `)
//line views/auth.qtpl:33
qw422016.E().S(lc.Get("auth.go_back"))
//line views/auth.qtpl:33
qw422016.N().S(`</a></p>
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:34
} else {
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:34
qw422016.N().S(`
2021-09-06 17:46:34 +00:00
<p>`)
//line views/auth.qtpl:35
qw422016.E().S(lc.Get("auth.noauth"))
//line views/auth.qtpl:35
qw422016.N().S(`</p>
<p><a href="/`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:36
qw422016.E().S(rq.URL.RawQuery)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:36
qw422016.N().S(`">← `)
//line views/auth.qtpl:36
qw422016.E().S(lc.Get("auth.go_back"))
//line views/auth.qtpl:36
qw422016.N().S(`</a></p>
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:37
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:37
qw422016.N().S(`
</section>
</main>
</div>
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:41
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:41
func WriteRegisterHTML(qq422016 qtio422016.Writer, rq *http.Request) {
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:41
qw422016 := qt422016.AcquireWriter(qq422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:41
StreamRegisterHTML(qw422016, rq)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:41
qt422016.ReleaseWriter(qw422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:41
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:41
func RegisterHTML(rq *http.Request) string {
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:41
qb422016 := qt422016.AcquireByteBuffer()
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:41
WriteRegisterHTML(qb422016, rq)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:41
qs422016 := string(qb422016.B)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:41
qt422016.ReleaseByteBuffer(qb422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:41
return qs422016
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:41
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:43
func StreamLoginHTML(qw422016 *qt422016.Writer, lc *l18n.Localizer) {
//line views/auth.qtpl:43
2020-11-14 13:03:06 +00:00
qw422016.N().S(`
2021-01-26 05:41:57 +00:00
<div class="layout">
<main class="main-width">
2020-11-14 13:03:06 +00:00
<section>
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:47
if cfg.UseAuth {
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:47
2020-11-14 13:03:06 +00:00
qw422016.N().S(`
2021-02-23 14:36:12 +00:00
<form class="modal" method="post" action="/login-data" id="login-form" enctype="multipart/form-data" autocomplete="on">
<fieldset class="modal__fieldset">
2021-09-06 17:46:34 +00:00
<legend class="modal__title">`)
//line views/auth.qtpl:50
qw422016.E().S(lc.Get("auth.login_header", &l18n.Replacements{"name": cfg.WikiName}))
//line views/auth.qtpl:50
2021-02-23 14:36:12 +00:00
qw422016.N().S(`</legend>
2021-09-06 17:46:34 +00:00
<label for="login-form__username">`)
//line views/auth.qtpl:51
qw422016.E().S(lc.Get("auth.username"))
//line views/auth.qtpl:51
qw422016.N().S(`</label>
2021-02-23 14:36:12 +00:00
<br>
<input type="text" required autofocus id="login-form__username" name="username" autocomplete="username">
<br>
2021-09-06 17:46:34 +00:00
<label for="login-form__password">`)
//line views/auth.qtpl:55
qw422016.E().S(lc.Get("auth.password"))
//line views/auth.qtpl:55
qw422016.N().S(`</label>
2021-02-23 14:36:12 +00:00
<br>
<input type="password" required name="password" autocomplete="current-password">
2021-09-06 17:46:34 +00:00
<p>`)
//line views/auth.qtpl:58
qw422016.E().S(lc.Get("auth.cookie_tip"))
//line views/auth.qtpl:58
qw422016.N().S(`</p>
<button class="btn" type="submit" value="Log in">`)
//line views/auth.qtpl:59
qw422016.E().S(lc.Get("auth.login_button"))
//line views/auth.qtpl:59
qw422016.N().S(`</button>
<a class="btn btn_weak" href="/">`)
//line views/auth.qtpl:60
qw422016.E().S(lc.Get("ui.cancel"))
//line views/auth.qtpl:60
qw422016.N().S(`</a>
2020-11-14 13:03:06 +00:00
</fieldset>
</form>
2021-07-14 19:51:55 +00:00
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:63
streamtelegramWidgetHTML(qw422016, lc)
//line views/auth.qtpl:63
2021-07-14 19:51:55 +00:00
qw422016.N().S(`
2020-11-14 13:03:06 +00:00
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:64
2020-11-14 13:03:06 +00:00
} else {
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:64
2020-11-14 13:03:06 +00:00
qw422016.N().S(`
2021-09-06 17:46:34 +00:00
<p>`)
//line views/auth.qtpl:65
qw422016.E().S(lc.Get("auth.noauth"))
//line views/auth.qtpl:65
qw422016.N().S(`</p>
<p><a class="btn btn_weak" href="/"> `)
//line views/auth.qtpl:66
qw422016.E().S(lc.Get("auth.go_home"))
//line views/auth.qtpl:66
qw422016.N().S(`</a></p>
2020-11-14 13:03:06 +00:00
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:67
2020-11-14 13:03:06 +00:00
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:67
2020-11-14 13:03:06 +00:00
qw422016.N().S(`
</section>
</main>
2021-01-26 05:41:57 +00:00
</div>
2020-11-14 13:03:06 +00:00
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:71
2020-11-14 13:03:06 +00:00
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:71
func WriteLoginHTML(qq422016 qtio422016.Writer, lc *l18n.Localizer) {
//line views/auth.qtpl:71
2020-11-14 13:03:06 +00:00
qw422016 := qt422016.AcquireWriter(qq422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:71
StreamLoginHTML(qw422016, lc)
//line views/auth.qtpl:71
2020-11-14 13:03:06 +00:00
qt422016.ReleaseWriter(qw422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:71
2020-11-14 13:03:06 +00:00
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:71
func LoginHTML(lc *l18n.Localizer) string {
//line views/auth.qtpl:71
2020-11-14 13:03:06 +00:00
qb422016 := qt422016.AcquireByteBuffer()
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:71
WriteLoginHTML(qb422016, lc)
//line views/auth.qtpl:71
2020-11-14 13:03:06 +00:00
qs422016 := string(qb422016.B)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:71
2020-11-14 13:03:06 +00:00
qt422016.ReleaseByteBuffer(qb422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:71
2020-11-14 13:03:06 +00:00
return qs422016
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:71
2020-11-14 13:03:06 +00:00
}
2021-07-14 19:51:55 +00:00
// Telegram auth widget was requested by Yogurt. As you can see, we don't offer user administrators control over it. Of course we don't.
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:74
func streamtelegramWidgetHTML(qw422016 *qt422016.Writer, lc *l18n.Localizer) {
//line views/auth.qtpl:74
2021-07-14 19:51:55 +00:00
qw422016.N().S(`
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:75
2021-07-14 19:51:55 +00:00
if cfg.TelegramEnabled {
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:75
2021-07-14 19:51:55 +00:00
qw422016.N().S(`
2021-09-06 17:46:34 +00:00
<p class="telegram-notice">`)
//line views/auth.qtpl:76
qw422016.E().S(lc.Get("auth.telegram_tip"))
//line views/auth.qtpl:76
qw422016.N().S(`</p>
2021-07-14 19:51:55 +00:00
<script async src="https://telegram.org/js/telegram-widget.js?15" data-telegram-login="`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:77
2021-07-14 19:51:55 +00:00
qw422016.E().S(cfg.TelegramBotName)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:77
2021-07-14 19:51:55 +00:00
qw422016.N().S(`" data-size="medium" data-userpic="false" data-auth-url="`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:77
2021-07-14 19:51:55 +00:00
qw422016.E().S(cfg.URL)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:77
2021-07-14 19:51:55 +00:00
qw422016.N().S(`/telegram-login"></script>
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:78
2021-07-14 19:51:55 +00:00
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:78
2021-07-14 19:51:55 +00:00
qw422016.N().S(`
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:79
2021-07-14 19:51:55 +00:00
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:79
func writetelegramWidgetHTML(qq422016 qtio422016.Writer, lc *l18n.Localizer) {
//line views/auth.qtpl:79
2021-07-14 19:51:55 +00:00
qw422016 := qt422016.AcquireWriter(qq422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:79
streamtelegramWidgetHTML(qw422016, lc)
//line views/auth.qtpl:79
2021-07-14 19:51:55 +00:00
qt422016.ReleaseWriter(qw422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:79
2021-07-14 19:51:55 +00:00
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:79
func telegramWidgetHTML(lc *l18n.Localizer) string {
//line views/auth.qtpl:79
2021-07-14 19:51:55 +00:00
qb422016 := qt422016.AcquireByteBuffer()
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:79
writetelegramWidgetHTML(qb422016, lc)
//line views/auth.qtpl:79
2021-07-14 19:51:55 +00:00
qs422016 := string(qb422016.B)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:79
2021-07-14 19:51:55 +00:00
qt422016.ReleaseByteBuffer(qb422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:79
2021-07-14 19:51:55 +00:00
return qs422016
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:79
2021-07-14 19:51:55 +00:00
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:81
func StreamLoginErrorHTML(qw422016 *qt422016.Writer, err string, lc *l18n.Localizer) {
//line views/auth.qtpl:81
2020-11-14 13:03:06 +00:00
qw422016.N().S(`
2021-01-26 05:41:57 +00:00
<div class="layout">
<main class="main-width">
2020-11-14 13:03:06 +00:00
<section>
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:85
2021-07-14 20:04:52 +00:00
switch err {
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:86
2020-11-14 13:03:06 +00:00
case "unknown username":
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:86
2020-11-14 13:03:06 +00:00
qw422016.N().S(`
2021-09-06 17:46:34 +00:00
<p class="error">`)
//line views/auth.qtpl:87
qw422016.E().S(lc.Get("auth.error_username"))
//line views/auth.qtpl:87
qw422016.N().S(`</p>
2020-11-14 13:03:06 +00:00
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:88
2020-11-14 13:03:06 +00:00
case "wrong password":
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:88
2020-11-14 13:03:06 +00:00
qw422016.N().S(`
2021-09-06 17:46:34 +00:00
<p class="error">`)
//line views/auth.qtpl:89
qw422016.E().S(lc.Get("auth.error_password"))
//line views/auth.qtpl:89
qw422016.N().S(`</p>
2020-11-14 13:03:06 +00:00
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:90
2020-11-14 13:03:06 +00:00
default:
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:90
2020-11-14 13:03:06 +00:00
qw422016.N().S(`
<p class="error">`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:91
2020-11-14 13:03:06 +00:00
qw422016.E().S(err)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:91
2020-11-14 13:03:06 +00:00
qw422016.N().S(`</p>
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:92
2020-11-14 13:03:06 +00:00
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:92
2020-11-14 13:03:06 +00:00
qw422016.N().S(`
2021-09-06 17:46:34 +00:00
<p><a href="/login"> `)
//line views/auth.qtpl:93
qw422016.E().S(lc.Get("auth.try_again"))
//line views/auth.qtpl:93
qw422016.N().S(`</a></p>
2020-11-14 13:03:06 +00:00
</section>
</main>
2021-01-26 05:41:57 +00:00
</div>
2020-11-14 13:03:06 +00:00
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:97
2020-11-14 13:03:06 +00:00
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:97
func WriteLoginErrorHTML(qq422016 qtio422016.Writer, err string, lc *l18n.Localizer) {
//line views/auth.qtpl:97
2020-11-14 13:03:06 +00:00
qw422016 := qt422016.AcquireWriter(qq422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:97
StreamLoginErrorHTML(qw422016, err, lc)
//line views/auth.qtpl:97
2020-11-14 13:03:06 +00:00
qt422016.ReleaseWriter(qw422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:97
2020-11-14 13:03:06 +00:00
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:97
func LoginErrorHTML(err string, lc *l18n.Localizer) string {
//line views/auth.qtpl:97
2020-11-14 13:03:06 +00:00
qb422016 := qt422016.AcquireByteBuffer()
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:97
WriteLoginErrorHTML(qb422016, err, lc)
//line views/auth.qtpl:97
2020-11-14 13:03:06 +00:00
qs422016 := string(qb422016.B)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:97
2020-11-14 13:03:06 +00:00
qt422016.ReleaseByteBuffer(qb422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:97
2020-11-14 13:03:06 +00:00
return qs422016
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:97
2020-11-14 13:03:06 +00:00
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:99
func StreamLogoutHTML(qw422016 *qt422016.Writer, can bool, lc *l18n.Localizer) {
//line views/auth.qtpl:99
2020-11-14 13:03:06 +00:00
qw422016.N().S(`
2021-01-26 05:41:57 +00:00
<div class="layout">
<main class="main-width">
2020-11-14 13:03:06 +00:00
<section>
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:103
2020-11-14 13:03:06 +00:00
if can {
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:103
2020-11-14 13:03:06 +00:00
qw422016.N().S(`
2021-09-06 17:46:34 +00:00
<h1>`)
//line views/auth.qtpl:104
qw422016.E().S(lc.Get("auth.logout_header"))
//line views/auth.qtpl:104
qw422016.N().S(`</h1>
<p><a href="/logout-confirm"><strong>`)
//line views/auth.qtpl:105
qw422016.E().S(lc.Get("auth.logout_button"))
//line views/auth.qtpl:105
qw422016.N().S(`</strong></a></p>
<p><a href="/">`)
//line views/auth.qtpl:106
qw422016.E().S(lc.Get("ui.cancel"))
//line views/auth.qtpl:106
qw422016.N().S(`</a></p>
2020-11-14 13:03:06 +00:00
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:107
2020-11-14 13:03:06 +00:00
} else {
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:107
2020-11-14 13:03:06 +00:00
qw422016.N().S(`
2021-09-06 17:46:34 +00:00
<p>`)
//line views/auth.qtpl:108
qw422016.E().S(lc.Get("auth.logout_anon"))
//line views/auth.qtpl:108
qw422016.N().S(`</p>
<p><a href="/login">`)
//line views/auth.qtpl:109
qw422016.E().S(lc.Get("auth.login_title"))
//line views/auth.qtpl:109
qw422016.N().S(`</a></p>
<p><a href="/"> `)
//line views/auth.qtpl:110
qw422016.E().S(lc.Get("auth.go_home"))
//line views/auth.qtpl:110
qw422016.N().S(`</a></p>
2020-11-14 13:03:06 +00:00
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:111
2020-11-14 13:03:06 +00:00
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:111
2020-11-14 13:03:06 +00:00
qw422016.N().S(`
</section>
</main>
2021-01-26 05:41:57 +00:00
</div>
2020-11-14 13:03:06 +00:00
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:115
2020-11-14 13:03:06 +00:00
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:115
func WriteLogoutHTML(qq422016 qtio422016.Writer, can bool, lc *l18n.Localizer) {
//line views/auth.qtpl:115
2020-11-14 13:03:06 +00:00
qw422016 := qt422016.AcquireWriter(qq422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:115
StreamLogoutHTML(qw422016, can, lc)
//line views/auth.qtpl:115
2020-11-14 13:03:06 +00:00
qt422016.ReleaseWriter(qw422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:115
2020-11-14 13:03:06 +00:00
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:115
func LogoutHTML(can bool, lc *l18n.Localizer) string {
//line views/auth.qtpl:115
2020-11-14 13:03:06 +00:00
qb422016 := qt422016.AcquireByteBuffer()
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:115
WriteLogoutHTML(qb422016, can, lc)
//line views/auth.qtpl:115
2020-11-14 13:03:06 +00:00
qs422016 := string(qb422016.B)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:115
2020-11-14 13:03:06 +00:00
qt422016.ReleaseByteBuffer(qb422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:115
2020-11-14 13:03:06 +00:00
return qs422016
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:115
2020-11-14 13:03:06 +00:00
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:117
func StreamLockHTML(qw422016 *qt422016.Writer, lc *l18n.Localizer) {
//line views/auth.qtpl:117
qw422016.N().S(`
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
2021-09-06 17:46:34 +00:00
<title>🔒 `)
//line views/auth.qtpl:123
qw422016.E().S(lc.Get("auth.lock_title"))
//line views/auth.qtpl:123
qw422016.N().S(`</title>
<link rel="shortcut icon" href="/static/favicon.ico">
<link rel="stylesheet" href="/static/style.css">
</head>
<body>
<main class="locked-notice">
<section class="locked-notice__message">
<p class="locked-notice__lock">🔒</p>
2021-09-06 17:46:34 +00:00
<h1 class="locked-notice__title">`)
//line views/auth.qtpl:131
qw422016.E().S(lc.Get("auth.lock_title"))
//line views/auth.qtpl:131
qw422016.N().S(`</h1>
<form class="locked-notice__login-form" method="post" action="/login-data" id="login-form" enctype="multipart/form-data" autocomplete="on">
2021-09-06 17:46:34 +00:00
<label for="login-form__username">`)
//line views/auth.qtpl:133
qw422016.E().S(lc.Get("auth.username"))
//line views/auth.qtpl:133
qw422016.N().S(`</label>
<br>
<input type="text" required autofocus id="login-form__username" name="username" autocomplete="username">
<br>
2021-09-06 17:46:34 +00:00
<label for="login-form__password">`)
//line views/auth.qtpl:137
qw422016.E().S(lc.Get("auth.password"))
//line views/auth.qtpl:137
qw422016.N().S(`</label>
<br>
<input type="password" required name="password" autocomplete="current-password">
<br>
2021-09-06 17:46:34 +00:00
<button class="btn" type="submit" value="Log in">`)
//line views/auth.qtpl:141
qw422016.E().S(lc.Get("auth.login_button"))
//line views/auth.qtpl:141
qw422016.N().S(`</button>
</form>
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:143
streamtelegramWidgetHTML(qw422016, lc)
//line views/auth.qtpl:143
2021-07-24 11:09:39 +00:00
qw422016.N().S(`
</section>
</main>
</body>
</html>
`)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:148
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:148
func WriteLockHTML(qq422016 qtio422016.Writer, lc *l18n.Localizer) {
//line views/auth.qtpl:148
qw422016 := qt422016.AcquireWriter(qq422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:148
StreamLockHTML(qw422016, lc)
//line views/auth.qtpl:148
qt422016.ReleaseWriter(qw422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:148
}
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:148
func LockHTML(lc *l18n.Localizer) string {
//line views/auth.qtpl:148
qb422016 := qt422016.AcquireByteBuffer()
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:148
WriteLockHTML(qb422016, lc)
//line views/auth.qtpl:148
qs422016 := string(qb422016.B)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:148
qt422016.ReleaseByteBuffer(qb422016)
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:148
return qs422016
2021-09-06 17:46:34 +00:00
//line views/auth.qtpl:148
}