+
{template.name}
{#each displayed as runtime}
{@const icon = getIconFromRuntime(runtime.name)}
{#if icon}
- -
+
-
+ -
+
+
diff --git a/src/routes/(console)/project-[project]/functions/templates/template-[template]/+page.svelte b/src/routes/(console)/project-[project]/functions/templates/template-[template]/+page.svelte
index 1137cf318..e07244345 100644
--- a/src/routes/(console)/project-[project]/functions/templates/template-[template]/+page.svelte
+++ b/src/routes/(console)/project-[project]/functions/templates/template-[template]/+page.svelte
@@ -22,9 +22,10 @@
- -
-
- Use cases {$template.useCases.length}
+
-
+
+ Use cases
+ {$template.useCases.length}
{#each $template.useCases as useCase}
@@ -32,9 +33,10 @@
{/each}
- -
-
- Runtimes {$template.runtimes.length}
+
-
+
+ Runtimes
+ {$template.runtimes.length}
{#each $template.runtimes as runtime}
@@ -42,12 +44,12 @@
{/each}
- -
+
-
Published by
@@ -58,7 +60,7 @@
-
+
+
+
diff --git a/src/routes/(console)/project-[project]/functions/wizard/step1.svelte b/src/routes/(console)/project-[project]/functions/wizard/step1.svelte
index 26b97c118..d8c08dd1e 100644
--- a/src/routes/(console)/project-[project]/functions/wizard/step1.svelte
+++ b/src/routes/(console)/project-[project]/functions/wizard/step1.svelte
@@ -52,6 +52,7 @@
{:else}
{:else}
-
+
{/if}
diff --git a/src/routes/(console)/project-[project]/messaging/topicsModal.svelte b/src/routes/(console)/project-[project]/messaging/topicsModal.svelte
index a2aad2b57..9c1e7e218 100644
--- a/src/routes/(console)/project-[project]/messaging/topicsModal.svelte
+++ b/src/routes/(console)/project-[project]/messaging/topicsModal.svelte
@@ -3,7 +3,7 @@
import { Button, FormList, InputCheckbox, InputSearch } from '$lib/elements/forms';
import { Table, TableBody, TableCell, TableRow } from '$lib/elements/table';
import { sdk } from '$lib/stores/sdk';
- import { Query, type Models, MessagingProviderType } from '@appwrite.io/console';
+ import { MessagingProviderType, type Models, Query } from '@appwrite.io/console';
import { createEventDispatcher } from 'svelte';
import { getTotal } from './wizard/store';
import ProviderType from './providerType.svelte';
@@ -22,6 +22,8 @@
let selected: Record = {};
let hasSelection = false;
+ let emptyTopicsExists = false;
+
function reset() {
offset = 0;
search = '';
@@ -36,16 +38,22 @@
if (!show) return;
const queries = [Query.limit(5), Query.offset(offset)];
- if (providerType === MessagingProviderType.Email) {
- queries.push(Query.greaterThan('emailTotal', 0));
- } else if (providerType === MessagingProviderType.Sms) {
- queries.push(Query.greaterThan('smsTotal', 0));
- } else if (providerType === MessagingProviderType.Push) {
- queries.push(Query.greaterThan('pushTotal', 0));
- }
-
const response = await sdk.forProject.messaging.listTopics(queries, search || undefined);
+ if (response.total !== 0) {
+ switch (providerType) {
+ case MessagingProviderType.Email:
+ emptyTopicsExists = response.topics.every((topic) => topic.emailTotal === 0);
+ break;
+ case MessagingProviderType.Sms:
+ emptyTopicsExists = response.topics.every((topic) => topic.smsTotal === 0);
+ break;
+ case MessagingProviderType.Push:
+ emptyTopicsExists = response.topics.every((topic) => topic.pushTotal === 0);
+ break;
+ }
+ }
+
totalResults = response.total;
topicResultsById = {};
response.topics.forEach((topic) => {
@@ -94,7 +102,9 @@
Select existing topics you want to send this message to its targets. The message will be
- sent only to targets.
+ sent only to
+
+ targets.
- {#if Object.keys(topicResultsById).length > 0}
+ {#if Object.keys(topicResultsById).length > 0 && !emptyTopicsExists}
@@ -155,9 +165,12 @@
+ text
+ >Documentation
+
+ >Clear search
+
@@ -166,15 +179,19 @@
- You have no topics. Create a topic to see them here.
+ You have no topics{emptyTopicsExists
+ ? ` with ${providerType.toUpperCase()} targets`
+ : ''}. Create a topic to see them here.
- Need a hand? Learn more in our .
+ >documentation
+
+ .
diff --git a/src/routes/(console)/project-[project]/messaging/wizard/emailFormList.svelte b/src/routes/(console)/project-[project]/messaging/wizard/emailFormList.svelte
index 693d209fb..b4568b02d 100644
--- a/src/routes/(console)/project-[project]/messaging/wizard/emailFormList.svelte
+++ b/src/routes/(console)/project-[project]/messaging/wizard/emailFormList.svelte
@@ -10,7 +10,7 @@
InputTextarea
} from '$lib/elements/forms';
import { Pill } from '$lib/elements';
- import { Modal } from '$lib/components';
+ import { CustomId, Modal } from '$lib/components';
import { user } from '$lib/stores/user';
import { clickOnEnter } from '$lib/helpers/a11y';
import { ID, MessagingProviderType } from '@appwrite.io/console';
@@ -113,5 +113,12 @@
Message ID
+ {:else}
+
{/if}
diff --git a/src/routes/(console)/project-[project]/messaging/wizard/pushFormList.svelte b/src/routes/(console)/project-[project]/messaging/wizard/pushFormList.svelte
index dc8a5b02a..3316183d1 100644
--- a/src/routes/(console)/project-[project]/messaging/wizard/pushFormList.svelte
+++ b/src/routes/(console)/project-[project]/messaging/wizard/pushFormList.svelte
@@ -38,7 +38,7 @@
Label
} from '$lib/elements/forms';
import { Pill } from '$lib/elements';
- import { Modal } from '$lib/components';
+ import { CustomId, Modal } from '$lib/components';
import { user } from '$lib/stores/user';
import { clickOnEnter } from '$lib/helpers/a11y';
import { ID, MessagingProviderType } from '@appwrite.io/console';
@@ -232,6 +232,13 @@
Message ID
+ {:else}
+
{/if}
+ {:else}
+
{/if}
diff --git a/src/routes/(console)/project-[project]/settings/GitDisconnectModal.svelte b/src/routes/(console)/project-[project]/settings/GitDisconnectModal.svelte
index b414f37bd..fa12b9e3b 100644
--- a/src/routes/(console)/project-[project]/settings/GitDisconnectModal.svelte
+++ b/src/routes/(console)/project-[project]/settings/GitDisconnectModal.svelte
@@ -51,11 +51,6 @@
bind:show={showGitDisconnect}
onSubmit={handleSubmit}
size="big">
-
- Are you sure you want to disconnect this git installation? This will affect future
- deployments to the following functions:
-
-
{#await loadFunctions()}
@@ -64,6 +59,10 @@
{:then functions}
{#if functions.total}
+
+ Are you sure you want to disconnect this git installation? This will affect future
+ deployments to the following functions:
+
{#each functions.functions as func}
@@ -73,7 +72,9 @@
{func.name}
-
+
Last deployed: {toLocaleDateTime(func.$updatedAt)}
diff --git a/src/routes/(console)/project-[project]/settings/GitInstallationModal.svelte b/src/routes/(console)/project-[project]/settings/GitInstallationModal.svelte
index 06e4fcae6..c846ff6a7 100644
--- a/src/routes/(console)/project-[project]/settings/GitInstallationModal.svelte
+++ b/src/routes/(console)/project-[project]/settings/GitInstallationModal.svelte
@@ -19,7 +19,7 @@
- Select a provider to import an existing git repositories.
+ Select a provider to import an existing git repository.
- Use cases {$template.useCases.length} +
+ Use cases + {$template.useCases.length}
- Runtimes {$template.runtimes.length} +
+ Runtimes + {$template.runtimes.length}
Published by
Select existing topics you want to send this message to its targets. The message will be
- sent only to