* Fixes issue #4290
* Changed the title from 'Accept Invitation' to 'Invitation to organistaion / Budibase'
* Changed the 'Please enter a password to set up your user.' to 'Please enter a password to get started.'
* Increased width to 300px to allow longer org names
This commit is contained in:
FlaminWrap 2022-08-10 23:04:52 +00:00 committed by GitHub
parent d1df31d2bc
commit 58f59c88b0
1 changed files with 17 additions and 6 deletions

View File

@ -1,13 +1,16 @@
<script>
import { Layout, Heading, Body, Button, notifications } from "@budibase/bbui"
import { goto, params } from "@roxi/routify"
import { users } from "stores/portal"
import { users, organisation } from "stores/portal"
import PasswordRepeatInput from "components/common/users/PasswordRepeatInput.svelte"
import Logo from "assets/bb-emblem.svg"
import { onMount } from "svelte"
const inviteCode = $params["?code"]
let password, error
$: company = $organisation.company || "Budibase"
async function acceptInvite() {
try {
await users.acceptInvite(inviteCode, password)
@ -17,16 +20,24 @@
notifications.error(error.message)
}
}
onMount(async () => {
try {
await organisation.init()
} catch (error) {
notifications.error("Error getting org config")
}
})
</script>
<section>
<div class="container">
<Layout>
<img src={Logo} alt="logo" />
<img alt="logo" src={$organisation.logoUrl || Logo} />
<Layout gap="XS" justifyItems="center" noPadding>
<Heading size="M">Accept Invitation</Heading>
<Heading size="M">Invitation to {company}</Heading>
<Body textAlign="center" size="M">
Please enter a password to set up your user.
Please enter a password to get started.
</Body>
</Layout>
<PasswordRepeatInput bind:error bind:password />
@ -46,7 +57,7 @@
}
.container {
margin: 0 auto;
width: 260px;
width: 300px;
display: flex;
flex-direction: column;
justify-content: flex-start;