Skip to content

Commit d5f61b3

Browse files
Merge pull request #144 from back4app/fix-admin-success-step
fix: Admin success step
2 parents f659d1a + 444257f commit d5f61b3

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

src/dashboard/B4aAdminPage/B4aAdminModal.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ const renderHostInput = (domain) => {
3636
const renderConfirmStep = () => {
3737
return <div className={`${styles['elements-wrapper']} ${styles['congrats-box']}`}>
3838
<p className={styles['congrats-message']}>Congratulations, your Admin App is active!</p>
39-
<a target='_blank'></a>
39+
<a className={styles['anchor-url']} target='_blank'></a>
4040
</div>
4141
}
4242

@@ -96,9 +96,9 @@ const show = async ({domain, setState, createAdmin, createClasses, createAdminHo
9696
html: renderConfirmStep(),
9797
showCancelButton: false,
9898
confirmButtonText: 'Got it!',
99-
onBeforeOpen: () => {
99+
onOpen: () => {
100100
const a = Swal.getContent().querySelector('a')
101-
a.href = a.text = adminURL
101+
if (a) a.href = a.text = adminURL
102102
},
103103
preConfirm: () => {
104104
if (typeof back4AppNavigation !== 'undefined' && typeof back4AppNavigation.onCreateAdminHostEvent === 'function')

src/dashboard/B4aAdminPage/B4aAdminPage.scss

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@
22
.elements-wrapper {
33
display: flex;
44
justify-content: center;
5+
flex-wrap: wrap;
6+
}
7+
8+
.anchor-url {
9+
flex-basis: 100%;
10+
text-align: center;
511
}
612

713
.inline-elements {

0 commit comments

Comments
 (0)