mirror of
https://github.com/appwrite/console.git
synced 2026-06-06 19:27:48 +00:00
fix: messages and bug.
This commit is contained in:
@@ -3,10 +3,7 @@
|
||||
import { Click } from '$lib/actions/analytics';
|
||||
import { Button } from '$lib/elements/forms';
|
||||
import { HeaderAlert } from '$lib/layout';
|
||||
import {
|
||||
hideBillingHeaderRoutes,
|
||||
upgradeURL
|
||||
} from '$lib/stores/billing';
|
||||
import { hideBillingHeaderRoutes, upgradeURL } from '$lib/stores/billing';
|
||||
import { currentPlan, organization } from '$lib/stores/organization';
|
||||
import SelectProjectCloud from './selectProjectCloud.svelte';
|
||||
import { toLocaleDate } from '$lib/helpers/date';
|
||||
@@ -30,8 +27,9 @@
|
||||
type="warning"
|
||||
title="Action required: You have more than {$currentPlan.projects} projects.">
|
||||
<svelte:fragment>
|
||||
Choose which projects to keep before {toLocaleDate($organization.billingNextInvoiceDate)} or upgrade
|
||||
to Pro. Projects over the limit will be blocked after this date.
|
||||
Choose which projects to keep before {toLocaleDate(
|
||||
$organization.billingNextInvoiceDate
|
||||
)} or upgrade to Pro. Projects over the limit will be blocked after this date.
|
||||
</svelte:fragment>
|
||||
<svelte:fragment slot="buttons">
|
||||
<Button
|
||||
|
||||
@@ -148,9 +148,12 @@
|
||||
{/if}
|
||||
|
||||
{#if selectedProjects.length === $currentPlan?.projects}
|
||||
{@const difference = projects.length - selectedProjects.length}
|
||||
{@const messagePrefix =
|
||||
difference > 1 ? `${difference} projects` : `${difference} project`}
|
||||
<Alert.Inline
|
||||
status="warning"
|
||||
title={`${projects.length - selectedProjects.length} projects will be archived on ${toLocaleDate($organization.billingNextInvoiceDate)}`}>
|
||||
title={`${messagePrefix} will be archived on ${toLocaleDate($organization.billingNextInvoiceDate)}`}>
|
||||
<span>
|
||||
{@html formatProjectsToArchive()}
|
||||
will be archived.
|
||||
|
||||
@@ -292,9 +292,11 @@
|
||||
</Table.Root>
|
||||
</div>
|
||||
{#if selectedProjects.length === allowedProjectsToKeep}
|
||||
{@const difference = projects.length - selectedProjects.length}
|
||||
{@const messagePrefix = difference > 1 ? `${difference} projects` : `${difference} project`}
|
||||
<Alert.Inline
|
||||
status="warning"
|
||||
title={`${projects.length - selectedProjects.length} projects will be archived on ${toLocaleDate($organization.billingNextInvoiceDate)}`}>
|
||||
title={`${messagePrefix} will be archived on ${toLocaleDate($organization.billingNextInvoiceDate)}`}>
|
||||
{formatProjectsToArchive()} will be archived
|
||||
</Alert.Inline>
|
||||
{/if}
|
||||
|
||||
@@ -134,8 +134,11 @@
|
||||
</Layout.Stack>
|
||||
|
||||
{#if isCloud && $currentPlan?.projects && $currentPlan?.projects > 0 && data.organization.projects.length > 0 && $canWriteProjects && (projectsToArchive.length > 0 || data.projects.total > $currentPlan.projects)}
|
||||
{@const difference = projectsToArchive}
|
||||
{@const messagePrefix =
|
||||
difference.length > 1 ? `${difference} projects` : `${difference} project`}
|
||||
<Alert.Inline
|
||||
title={`${projectsToArchive.length} projects will be archived on ${toLocaleDate($organization.billingNextInvoiceDate)}`}>
|
||||
title={`${messagePrefix} will be archived on ${toLocaleDate($organization.billingNextInvoiceDate)}`}>
|
||||
<Typography.Text>Upgrade your plan to restore archived projects</Typography.Text>
|
||||
<svelte:fragment slot="actions">
|
||||
<Button
|
||||
|
||||
Reference in New Issue
Block a user