Skip to content

Commit 115c7ba

Browse files
committed
Fix recovery code pages button style
2 parents 1ac6b4b + d8cf9ad commit 115c7ba

File tree

3 files changed

+29
-25
lines changed

3 files changed

+29
-25
lines changed

resources/authgear/static/authgear.css

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -778,7 +778,7 @@ h1, h2, h3, h4, h5, h6 {
778778
.btn.primary-btn, .btn.light-btn {
779779
height: 36px;
780780
border-radius: 2px;
781-
padding: 0 24px;
781+
padding: 0 20px;
782782
}
783783

784784
.btn.action-btn {
@@ -1215,8 +1215,8 @@ h1, h2, h3, h4, h5, h6 {
12151215
margin: 0 20px 0 30px;
12161216
}
12171217

1218-
.recovery-code-action-section .action {
1219-
flex: 0 0 50%;
1218+
.recovery-code-action-section {
1219+
grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
12201220
}
12211221

12221222
.recovery-codes-container {

resources/authgear/templates/en/web/settings_recovery_code.html

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -23,24 +23,26 @@ <h1 class="primary-txt text-center margin-t-0 margin-b-10 text-xl font-bold">
2323
<p class="text-sm primary-txt text-center margin-t-0 margin-b-20">{{ template "recovery-code-consumption-description" }}</p>
2424
</section>
2525

26-
<section class="margin-b-20 flex flex-row recovery-code-action-section">
27-
<form method="post" class="action margin-h-4" novalidate>
26+
<section class="margin-b-20 grid gap-8 recovery-code-action-section">
27+
<form method="post" novalidate>
2828
{{ $.CSRFField }}
2929
<button class="btn primary-btn w-full" type="submit" name="x_action" value="regenerate">
3030
{{ template "get-new-code-button-label" }}
3131
</button>
3232
</form>
3333
{{ if $.IsSupportedMobilePlatform }}
34-
<button
35-
class="btn primary-btn margin-h-4 w-full action"
36-
type="button"
37-
data-copy-button-target="#recovery-code-content"
38-
data-copy-button-copy-label="{{ template "copy-button-label" }}"
39-
data-copy-button-copied-label="{{ template "copied-button-label" }}">
40-
{{ template "copy-button-label" }}
41-
</button>
34+
<div>
35+
<button
36+
class="btn primary-btn w-full"
37+
type="button"
38+
data-copy-button-target="#recovery-code-content"
39+
data-copy-button-copy-label="{{ template "copy-button-label" }}"
40+
data-copy-button-copied-label="{{ template "copied-button-label" }}">
41+
{{ template "copy-button-label" }}
42+
</button>
43+
</div>
4244
{{ else }}
43-
<form method="post" class="action margin-h-4" novalidate target="_blank">
45+
<form method="post" novalidate target="_blank">
4446
{{ $.CSRFField }}
4547
<button class="btn primary-btn w-full" type="submit" name="x_action" value="download" data-form-xhr="false">
4648
{{ template "download-button-label" }}

resources/authgear/templates/en/web/setup_recovery_code.html

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -23,25 +23,27 @@ <h1 class="primary-txt text-center margin-t-20 margin-b-10 text-xl font-bold">
2323
<p class="text-sm primary-txt text-center margin-t-0 margin-b-20">{{ template "recovery-code-consumption-description" }}</p>
2424
</section>
2525

26-
<section class="margin-b-20 flex flex-row recovery-code-action-section">
26+
<section class="margin-b-20 grid gap-8 recovery-code-action-section">
2727
{{ if $.IsSupportedMobilePlatform }}
28-
<button
29-
class="btn primary-btn margin-h-4 w-full action"
30-
type="button"
31-
data-copy-button-target="#recovery-code-content"
32-
data-copy-button-copy-label="{{ template "copy-button-label" }}"
33-
data-copy-button-copied-label="{{ template "copied-button-label" }}">
34-
{{ template "copy-button-label" }}
35-
</button>
28+
<div>
29+
<button
30+
class="btn primary-btn w-full"
31+
type="button"
32+
data-copy-button-target="#recovery-code-content"
33+
data-copy-button-copy-label="{{ template "copy-button-label" }}"
34+
data-copy-button-copied-label="{{ template "copied-button-label" }}">
35+
{{ template "copy-button-label" }}
36+
</button>
37+
</div>
3638
{{ else }}
37-
<form method="post" class="action margin-h-4" novalidate target="_blank">
39+
<form method="post" novalidate target="_blank">
3840
{{ $.CSRFField }}
3941
<button class="btn primary-btn w-full" type="submit" name="x_action" value="download" data-form-xhr="false">
4042
{{ template "download-button-label" }}
4143
</button>
4244
</form>
4345
{{ end }}
44-
<form method="post" class="action margin-h-4" novalidate>
46+
<form method="post" novalidate>
4547
{{ $.CSRFField }}
4648
<button class="btn primary-btn w-full" type="submit" name="x_action" value="proceed">
4749
{{ template "next-button-label" }}

0 commit comments

Comments
 (0)