saasitone/templ/layouts/auth.templ

43 lines
1.0 KiB
Plaintext
Raw Permalink Normal View History

2024-07-14 18:48:40 -07:00
package layouts
import (
"git.grosinger.net/tgrosinger/saasitone/pkg/page"
"git.grosinger.net/tgrosinger/saasitone/templ/components"
)
templ Auth(p page.Page, content templ.Component) {
<!DOCTYPE html>
<html lang="en">
<head>
@metatags(p)
@css()
@js()
</head>
<body>
<section class="hero is-info is-fullheight">
<div class="hero-body">
<div class="container">
<div class="columns is-centered">
<div class="column is-half">
if p.Title != "" {
<h1 class="title">{ p.Title }</h1>
}
<div class="box">
@components.Messages(p)
@content
<div class="content is-small has-text-centered" hx-boost="true">
<a href={ templ.URL(p.ToURL("login")) }>Login</a> &#9676;
<a href={ templ.URL(p.ToURL("register")) }>Create an account</a> &#9676;
<a href={ templ.URL(p.ToURL("forgot_password")) }>Forgot password?</a>
</div>
</div>
</div>
</div>
</div>
</div>
</section>
@footer(p)
</body>
</html>
}