fix(frontend): Set settings as header and error handler as footer (#893)

This commit is contained in:
Faton Ramadani
2022-11-14 11:45:35 +01:00
committed by GitHub
parent 5211eb6738
commit 511bd020d1
4 changed files with 16 additions and 8 deletions
@@ -10,7 +10,7 @@
<div class="h-full overflow-hidden border-t">
<Splitpanes>
<Pane size={25} minSize={20} class="h-full">
<div class="grow overflow-auto p-4 bg-gray h-full bg-gray-50 relative">
<div class="grow overflow-auto bg-gray h-full bg-gray-50 relative">
{#if $flowStore.value.modules}
<FlowModuleSchemaMap bind:modules={$flowStore.value.modules} root />
{/if}
@@ -41,7 +41,7 @@
}
}}
class={classNames(
'border rounded-md p-2 bg-white text-sm cursor-pointer mt-4 flex flex-col overflow-x-hidden bottom-0 z-10 sticky',
'border rounded-md p-2 bg-white text-sm cursor-pointer flex flex-col overflow-x-hidden ',
$selectedId.includes('failure') ? 'outline outline-offset-1 outline-2 outline-slate-900' : ''
)}
>
@@ -73,11 +73,17 @@
$: confirmationModalOpen = indexToRemove !== undefined
</script>
<div class="flex flex-col justify-between w-full">
<ul class="w-full">
{#if root}
<div class="flex flex-col h-full">
{#if root}
<div class="flex-initial p-4 border-b">
<FlowSettingsItem />
<FlowInputsItem />
</div>
{/if}
<ul class="w-full flex-auto relative overflow-y-auto overflow-x-hidden p-4">
{#if root}
<li>
<FlowInputsItem />
</li>
{/if}
{#each modules as mod, index (mod.id ?? index)}
@@ -101,7 +107,9 @@
<InsertModuleButton on:click={() => insertNewModuleAtIndex(modules.length)} />
</ul>
{#if root}
<FlowErrorHandlerItem />
<div class="flex-none p-4 border-t">
<FlowErrorHandlerItem />
</div>
{/if}
</div>
@@ -9,7 +9,7 @@
const { select, selectedId, schedule } = getContext<FlowEditorContext>('FlowEditorContext')
$: settingsClass = classNames(
'border w-full rounded-md p-2 bg-white text-sm cursor-pointer flex items-center mb-4 sticky top-0 z-10',
'border w-full rounded-md p-2 bg-white text-sm cursor-pointer flex items-center',
$selectedId === 'settings' ? 'outline outline-offset-1 outline-2 outline-slate-900' : ''
)
</script>