mirror of
https://github.com/appwrite/console.git
synced 2026-06-06 19:27:48 +00:00
fix: logs copy
This commit is contained in:
@@ -33,6 +33,7 @@
|
||||
export let hideScrollButtons = false;
|
||||
export let height = 'auto';
|
||||
export let fullHeight = false;
|
||||
export let emptyCopy = 'No logs available';
|
||||
|
||||
let { status, buildLogs } = deployment;
|
||||
|
||||
@@ -56,6 +57,18 @@
|
||||
});
|
||||
return () => unsubscribe();
|
||||
});
|
||||
|
||||
function setCopy() {
|
||||
if (status === 'failed') {
|
||||
return 'Your deployment has failed.';
|
||||
} else if (status === 'building') {
|
||||
return 'Build is starting.';
|
||||
} else if (status === 'processing') {
|
||||
return 'Your deployment is processing.';
|
||||
} else {
|
||||
return emptyCopy;
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<Layout.Stack gap="xl">
|
||||
@@ -79,7 +92,7 @@
|
||||
{fullHeight}
|
||||
{height}
|
||||
showScrollButton={!hideScrollButtons}
|
||||
logs={buildLogs || 'No logs available'}
|
||||
logs={buildLogs || setCopy()}
|
||||
bind:theme={$app.themeInUse} />
|
||||
{/key}
|
||||
</Layout.Stack>
|
||||
|
||||
@@ -39,7 +39,8 @@
|
||||
bind:deployment={data.deployment}
|
||||
bind:site={data.site}
|
||||
hideScrollButtons
|
||||
height="calc(100dvh - 430px)" />
|
||||
height="calc(100dvh - 430px)"
|
||||
emptyCopy="No logs available yet..." />
|
||||
</Fieldset>
|
||||
</Layout.Stack>
|
||||
<svelte:fragment slot="aside">
|
||||
|
||||
@@ -130,8 +130,6 @@
|
||||
title="Create site"
|
||||
bind:showExitModal
|
||||
href={`${base}/project-${$page.params.project}/sites/`}
|
||||
column
|
||||
columnSize="s"
|
||||
confirmExit>
|
||||
<Form bind:this={formComponent} onSubmit={create} bind:isSubmitting>
|
||||
<Layout.Stack gap="xl">
|
||||
|
||||
@@ -1,30 +1,32 @@
|
||||
<script lang="ts">
|
||||
import { base } from '$app/paths';
|
||||
import { page } from '$app/stores';
|
||||
import { Card } from '$lib/components';
|
||||
import { Button } from '$lib/elements/forms';
|
||||
import { app } from '$lib/stores/app';
|
||||
import { IconDownload } from '@appwrite.io/pink-icons-svelte';
|
||||
import { Icon, Image, Layout, Typography } from '@appwrite.io/pink-svelte';
|
||||
import { Layout, Typography } from '@appwrite.io/pink-svelte';
|
||||
</script>
|
||||
|
||||
<Card padding="xs">
|
||||
<Layout.Stack gap="xxs">
|
||||
<Typography.Text variant="m-500">Don't have a site yet?</Typography.Text>
|
||||
<Typography.Text variant="m-400">
|
||||
Download our starter kit, and deploy in seconds.
|
||||
Deploy the JavaScript starter template in seconds.
|
||||
</Typography.Text>
|
||||
</Layout.Stack>
|
||||
|
||||
<Layout.Stack>
|
||||
<Image
|
||||
<!-- <Image
|
||||
ratio="16/9"
|
||||
src={$app.themeInUse === 'dark'
|
||||
? `${base}/images/sites/screenshot-placeholder-dark.svg`
|
||||
: `${base}/images/sites/screenshot-placeholder-light.svg`}
|
||||
alt="preview" />
|
||||
alt="preview" /> -->
|
||||
|
||||
<Button fullWidth secondary href="#">
|
||||
<Icon icon={IconDownload} slot="start" /> Starter kit
|
||||
<Button
|
||||
fullWidth
|
||||
secondary
|
||||
href={`${base}/project-${$page.params.project}/sites/create-site/templates/template-starter-for-js`}>
|
||||
Deploy
|
||||
</Button>
|
||||
</Layout.Stack>
|
||||
</Card>
|
||||
|
||||
Reference in New Issue
Block a user