Skip to content

Commit 5ed7bc5

Browse files
committed
Org domain
1 parent 69fadc3 commit 5ed7bc5

File tree

4 files changed

+15
-5
lines changed

4 files changed

+15
-5
lines changed

src/routes/(console)/organization-[organization]/domains/+page.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@
9393
{#if !isDomainVerified(domain)}
9494
<Badge
9595
variant="secondary"
96-
type="warning"
96+
type="error"
9797
content="Not verified"
9898
size="s" />
9999
{/if}

src/routes/(console)/organization-[organization]/domains/add-domain/+page.svelte

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
<script lang="ts">
22
import { base } from '$app/paths';
33
import { page } from '$app/state';
4+
import { goto } from '$app/navigation';
45
import { Button, Form } from '$lib/elements/forms';
56
import { InputDomain } from '$lib/elements/forms/index.js';
67
import { Wizard } from '$lib/layout';
@@ -23,7 +24,16 @@
2324
teamId: page.params.organization,
2425
domain: domainName.toLocaleLowerCase()
2526
});
26-
invalidate(Dependencies.DOMAINS);
27+
28+
await invalidate(Dependencies.DOMAINS);
29+
const verified = domain.nameservers.toLowerCase() === 'appwrite';
30+
if (verified) {
31+
addNotification({
32+
type: 'success',
33+
message: 'Domain verified successfully'
34+
});
35+
await goto(backPage);
36+
}
2737
} catch (error) {
2838
addNotification({
2939
type: 'error',

src/routes/(console)/organization-[organization]/domains/recordsCard.svelte

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@
3939
if (verified) {
4040
addNotification({
4141
type: 'success',
42-
message: 'Domain verified'
42+
message: 'Domain verified successfully'
4343
});
4444
4545
await goto(routeBase);
@@ -76,7 +76,7 @@
7676
{#if verified === false}
7777
<Badge
7878
variant="secondary"
79-
type="warning"
79+
type="error"
8080
size="xs"
8181
content="Verification failed" />
8282
{:else if verified === true}

src/routes/(console)/organization-[organization]/domains/retryDomainModal.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
show = false;
3737
addNotification({
3838
type: 'success',
39-
message: `${selectedDomain.domain} has been verified`
39+
message: 'Domain verified successfully'
4040
});
4141
} else {
4242
error =

0 commit comments

Comments
 (0)