1
0
Fork 0
mirror of synced 2024-06-29 11:31:06 +12:00

Add empty state text to automate page and consistently style empty states

This commit is contained in:
Andrew Kingston 2020-09-30 15:06:47 +01:00
parent cf4b5a6fbf
commit c7cb8e4c68
5 changed files with 24 additions and 11 deletions

View file

@ -51,9 +51,9 @@
<style>
section {
display: flex;
flex-direction: row;
justify-content: center;
align-items: flex-start;
flex-direction: column;
justify-content: flex-start;
align-items: center;
overflow: auto;
height: 100%;
position: relative;

View file

@ -3,6 +3,7 @@
import Arrow from "./Arrow.svelte"
import { flip } from "svelte/animate"
import { fade, fly } from "svelte/transition"
import { automationStore } from "builderStore"
export let automation
export let onSelect
@ -17,8 +18,14 @@
blocks = blocks.concat(automation.definition.steps || [])
}
}
$: automationCount = $automationStore.automations?.length ?? 0
</script>
{#if automationCount === 0}
<i>Create your first automation to get started</i>
{:else if automation == null}
<i>Select an automation to edit</i>
{/if}
<section class="canvas">
{#each blocks as block, idx (block.id)}
<div
@ -35,6 +42,13 @@
</section>
<style>
i {
font-size: var(--font-size-xl);
color: var(--grey-4);
padding: var(--spacing-xl) 40px;
align-self: flex-start;
}
section {
position: absolute;
padding: 40px;

View file

@ -20,8 +20,7 @@
<style>
i {
font-size: 20px;
padding-bottom: 10px;
font-size: var(--font-size-xl);
color: var(--grey-4);
}
</style>

View file

@ -23,12 +23,13 @@
{#if $backendUiStore.models.length === 0}
<i>Create your first table to start building</i>
{:else}Please select a table{/if}
{:else}
<i>Select a table to edit</i>
{/if}
<style>
i {
font-size: 20px;
padding-bottom: 10px;
font-size: var(--font-size-xl);
color: var(--grey-4);
}
</style>

View file

@ -15,13 +15,12 @@
{#if $backendUiStore.selectedDatabase._id && selectedView}
<ViewDataTable view={selectedView} />
{:else}
<i>create your first table to start building</i>
<i>Create your first table to start building</i>
{/if}
<style>
i {
font-size: 20px;
margin-right: 10px;
font-size: var(--font-size-xl);
color: var(--grey-4);
}
</style>