Passport/pkg/views/authorize.gohtml

57 lines
1.3 KiB
Plaintext

<div class="left-part">
<img class="logo" alt="Logo" src="/favicon.png" width="64" height="64" />
<h1 class="title">{{.i18n.title}} {{.client.Name}}</h1>
<p class="caption">{{.i18n.caption}}</p>
</div>
<div class="right-part">
<div class="responsive-title-gap "></div>
<form class="action-form" action="{{.action_url}}" method="POST">
<div>
<div class="section-title">Description</div>
<div class="section-body">{{.client.Description}}</div>
</div>
<div>
<div class="section-title">Requested scopes</div>
<ul class="section-scope list-group">
{{range $_, $element := .scopes}}
<li class="monospace list-group-item">
{{$element}}
</li>
{{end}}
</ul>
</div>
<div class="action-form-buttons">
<button class="btn btn-secondary" type="button" id="decline-button">{{.i18n.decline}}</button>
<button class="btn btn-primary" type="submit">{{.i18n.approve}}</button>
</div>
</form>
</div>
<style>
.section-title {
font-weight: bold;
}
.section-scope {
margin-top: 4px;
margin-left: -8px;
margin-right: -8px;
}
.monospace {
font-family: "Roboto Mono", monospace;
}
</style>
<script>
$("#decline-button").on("click", () => {
history.back()
window.close()
})
</script>