From b4b90fcaebc6f1179ab7cbaa6f3ff0b0ff7b8afc Mon Sep 17 00:00:00 2001 From: Martin McKeaveney Date: Fri, 29 May 2020 16:06:23 +0100 Subject: [PATCH] styling, bug fixes, client library state updates --- .../builderStore/store/workflow/Workflow.js | 9 +- .../workflow/SetupPanel/SetupPanel.svelte | 42 ++--- .../WorkflowBuilder/WorkflowBuilder.svelte | 10 +- .../WorkflowList/WorkflowList.svelte | 6 + .../WorkflowPanel/WorkflowPanel.svelte | 36 +++-- .../[application]/workflow/_layout.svelte | 8 +- .../client/src/api/workflow/orchestrator.js | 19 +++ packages/client/src/createApp.js | 24 ++- packages/client/src/state/bbComponentApi.js | 9 +- packages/client/src/state/eventHandlers.js | 6 +- packages/client/src/state/stateManager.js | 143 +++++++++--------- 11 files changed, 166 insertions(+), 146 deletions(-) diff --git a/packages/builder/src/builderStore/store/workflow/Workflow.js b/packages/builder/src/builderStore/store/workflow/Workflow.js index 4a7daa5279..2b495ef49b 100644 --- a/packages/builder/src/builderStore/store/workflow/Workflow.js +++ b/packages/builder/src/builderStore/store/workflow/Workflow.js @@ -40,8 +40,13 @@ export default class Workflow { block = block.next } - // delete the block found - previous.next = block.next || {} + // delete the block matching your id + if (!block.next) { + delete previous.next + } else { + previous.next = block.next + } + } createUiTree() { diff --git a/packages/builder/src/pages/[application]/workflow/SetupPanel/SetupPanel.svelte b/packages/builder/src/pages/[application]/workflow/SetupPanel/SetupPanel.svelte index a7417002de..d91eb3ffaf 100644 --- a/packages/builder/src/pages/[application]/workflow/SetupPanel/SetupPanel.svelte +++ b/packages/builder/src/pages/[application]/workflow/SetupPanel/SetupPanel.svelte @@ -1,14 +1,15 @@ @@ -31,15 +32,15 @@
Setup
-
- {#if workflowBlock} - - - {:else if $workflowStore.currentWorkflow} + {#if workflowBlock} + + + {:else if $workflowStore.currentWorkflow} +
@@ -54,19 +55,22 @@ Some User Access Stuff Here
- - {/if} -
+
+ + {/if}