feat #32: improve approval UI #12

Merged
faercol merged 1 commit from 32-authorization-ui into feature/10-ui 2023-11-04 08:33:07 +00:00
2 changed files with 25 additions and 29 deletions

View file

@ -63,7 +63,7 @@ body {
.form-buttons {
display: flex;
justify-content: center;
justify-content: space-between;
}
.form-input {
@ -91,4 +91,8 @@ body {
.button-accept {
background-color: var(--logo-blue);
}
.button-cancel {
background-color: var(--logo-pink);
}

View file

@ -1,42 +1,34 @@
{{ template "header.html" . }}
<div class="theme-panel">
<h2 class="theme-heading">Grant Access</h2>
<hr class="dex-separator">
<div>
<div class="container">
<div class="container-content">
{{ if .Scopes }}
<div class="dex-subtle-text">{{ .Client }} would like to:</div>
<ul class="dex-list">
<div>{{ .Client }} would like to:</div>
<ul>
{{ range $scope := .Scopes }}
<li>{{ $scope }}</li>
{{ end }}
</ul>
{{ else }}
<div class="dex-subtle-text">{{ .Client }} has not requested any personal information</div>
<div>{{ .Client }} has not requested any personal information</div>
{{ end }}
</div>
<hr class="dex-separator">
<div>
<div class="theme-form-row">
<form method="post">
<input type="hidden" name="req" value="{{ .AuthReqID }}" />
<input type="hidden" name="approval" value="approve">
<button type="submit" class="dex-btn theme-btn--success">
<span class="dex-btn-text">Grant Access</span>
</button>
</form>
</div>
<div class="theme-form-row">
<form method="post">
<input type="hidden" name="req" value="{{ .AuthReqID }}" />
<input type="hidden" name="approval" value="rejected">
<button type="submit" class="dex-btn theme-btn-provider">
<span class="dex-btn-text">Cancel</span>
</button>
</form>
</div>
<div class="form-buttons">
<form method="post" class="container-form">
<input type="hidden" name="req" value="{{ .AuthReqID }}" />
<input type="hidden" name="approval" value="approve">
<button type="submit" class="button button-accept">
<span>Grant Access</span>
</button>
</form>
<form method="post" class="container-form">
<input type="hidden" name="req" value="{{ .AuthReqID }}" />
<input type="hidden" name="approval" value="rejected">
<button type="submit" class="button button-cancel">
<span>Cancel</span>
</button>
</form>
</div>
</div>