From cffd2f29cdecbb1bce0c6460c17d8b9a7817cf4b Mon Sep 17 00:00:00 2001 From: Ruben Fiszel Date: Thu, 16 Jan 2025 17:02:10 +0100 Subject: [PATCH] diff --- frontend/src/lib/components/custom_ui.ts | 1 + .../flows/content/FlowModuleComponent.svelte | 4 ++-- .../flows/map/FlowModuleSchemaMap.svelte | 14 +++++++++++--- frontend/src/lib/components/graph/graphBuilder.ts | 2 +- 4 files changed, 15 insertions(+), 6 deletions(-) diff --git a/frontend/src/lib/components/custom_ui.ts b/frontend/src/lib/components/custom_ui.ts index 109136c37b..dd38077347 100644 --- a/frontend/src/lib/components/custom_ui.ts +++ b/frontend/src/lib/components/custom_ui.ts @@ -24,6 +24,7 @@ export type FlowBuilderWhitelabelCustomUi = { triggers?: boolean flowNode?: boolean hub?: boolean + hubCode?: boolean graph?: { aiBuilder?: boolean; dataflow?: boolean } stepInputs?: { ai?: boolean } stepAdvancedSettings?: boolean diff --git a/frontend/src/lib/components/flows/content/FlowModuleComponent.svelte b/frontend/src/lib/components/flows/content/FlowModuleComponent.svelte index f77d794a0b..70faa0b6df 100644 --- a/frontend/src/lib/components/flows/content/FlowModuleComponent.svelte +++ b/frontend/src/lib/components/flows/content/FlowModuleComponent.svelte @@ -287,7 +287,7 @@
- + {#if flowModule.value.type === 'rawscript'} {#if !noEditor} {#key flowModule.id} @@ -341,7 +341,7 @@ {/key} {/if} {:else if flowModule.value.type === 'script'} - {#if !noEditor} + {#if !noEditor && (customUi?.hubCode != false || flowModule?.value?.path?.startsWith('hub/'))}
{#key forceReload} ('FlowEditorContext') + const { + customUi, + selectedId, + moving, + history, + flowStateStore, + flowStore, + flowInputsStore, + pathStore + } = getContext('FlowEditorContext') const { primarySchedule, triggersCount } = getContext('TriggerContext') const { flowPropPickerConfig } = getContext('PropPickerContext') @@ -305,7 +313,7 @@