forked from tsai/budibase
12 changed files with 263 additions and 118 deletions
@ -0,0 +1,58 @@ |
|||
<script> |
|||
import { ModalContent, Icon, Detail } from "@budibase/bbui" |
|||
|
|||
let inputToggled |
|||
let outputToggled |
|||
</script> |
|||
|
|||
<ModalContent |
|||
showCloseIcon={false} |
|||
showConfirmButton={false} |
|||
title="Test Automation" |
|||
cancelText="Close" |
|||
> |
|||
<div class="splitHeader"> |
|||
<div |
|||
on:click={() => { |
|||
inputToggled = !inputToggled |
|||
}} |
|||
class="toggle" |
|||
> |
|||
{#if inputToggled} |
|||
<Icon size="M" name="ChevronDown" /> |
|||
{:else} |
|||
<Icon size="M" name="ChevronRight" /> |
|||
{/if} |
|||
<Detail size="S">Input</Detail> |
|||
</div> |
|||
</div> |
|||
|
|||
<div class="splitHeader"> |
|||
<div |
|||
on:click={() => { |
|||
outputToggled = !outputToggled |
|||
}} |
|||
class="toggle" |
|||
> |
|||
{#if outputToggled} |
|||
<Icon size="M" name="ChevronDown" /> |
|||
{:else} |
|||
<Icon size="M" name="ChevronRight" /> |
|||
{/if} |
|||
<Detail size="S">Output</Detail> |
|||
</div> |
|||
</div> |
|||
</ModalContent> |
|||
|
|||
<style> |
|||
.splitHeader { |
|||
cursor: pointer; |
|||
display: flex; |
|||
justify-content: space-between; |
|||
} |
|||
|
|||
.toggle { |
|||
display: flex; |
|||
align-items: center; |
|||
} |
|||
</style> |
|||
@ -0,0 +1,15 @@ |
|||
<script> |
|||
import { automationStore } from "builderStore" |
|||
import { params } from "@roxi/routify" |
|||
|
|||
if ($params.automation) { |
|||
const automation = $automationStore.automations.find( |
|||
m => m._id === $params.automation |
|||
) |
|||
if (automation) { |
|||
automationStore.actions.select(automation) |
|||
} |
|||
} |
|||
</script> |
|||
|
|||
<slot /> |
|||
Loading…
Reference in new issue