diff --git a/frontend/src/lib/components/FlowPlugConnect.svelte b/frontend/src/lib/components/FlowPlugConnect.svelte index 2bd993b92a..c1002aa8df 100644 --- a/frontend/src/lib/components/FlowPlugConnect.svelte +++ b/frontend/src/lib/components/FlowPlugConnect.svelte @@ -4,6 +4,7 @@ import AnimatedButton from './common/button/AnimatedButton.svelte' export let connecting: boolean + export let id: undefined | string = undefined @@ -13,6 +14,7 @@ size="xs2" btnClasses={connecting ? 'text-blue-500' : 'text-primary'} on:click + {...id ? { id } : {}} > → diff --git a/frontend/src/lib/components/InputTransformForm.svelte b/frontend/src/lib/components/InputTransformForm.svelte index daa74ec208..d5f3ccb4d3 100644 --- a/frontend/src/lib/components/InputTransformForm.svelte +++ b/frontend/src/lib/components/InputTransformForm.svelte @@ -370,8 +370,8 @@ staticTemplate ? `\`${arg?.value?.toString().replaceAll('`', '\\`') ?? ''}\`` : arg.value - ? '(' + JSON.stringify(arg?.value, null, 4) + ')' - : '' + ? '(' + JSON.stringify(arg?.value, null, 4) + ')' + : '' ) } if (arg) { @@ -450,11 +450,12 @@ { - focusProp(argName, 'connect', (path) => { + focusProp?.(argName, 'connect', (path) => { connectProperty(path) - dispatch('change', { argName }) + dispatch('change', { argName, arg }) return true }) }} diff --git a/frontend/src/lib/components/InputTransformSchemaForm.svelte b/frontend/src/lib/components/InputTransformSchemaForm.svelte index 2b7f47a272..a3c05ce324 100644 --- a/frontend/src/lib/components/InputTransformSchemaForm.svelte +++ b/frontend/src/lib/components/InputTransformSchemaForm.svelte @@ -77,7 +77,7 @@ Object.keys(args ?? {}).includes(argName) && ((args[argName].type === 'static' && !args[argName].value) || (args[argName].type === 'javascript' && !args[argName].expr)) - ) + ) : []} {schema} /> diff --git a/frontend/src/lib/components/flows/content/FlowInput.svelte b/frontend/src/lib/components/flows/content/FlowInput.svelte index 705ba652d0..339bbde4f9 100644 --- a/frontend/src/lib/components/flows/content/FlowInput.svelte +++ b/frontend/src/lib/components/flows/content/FlowInput.svelte @@ -472,6 +472,7 @@
diff --git a/frontend/src/lib/components/flows/propPicker/PropPickerWrapper.svelte b/frontend/src/lib/components/flows/propPicker/PropPickerWrapper.svelte index 57df089a62..a1b2f57102 100644 --- a/frontend/src/lib/components/flows/propPicker/PropPickerWrapper.svelte +++ b/frontend/src/lib/components/flows/propPicker/PropPickerWrapper.svelte @@ -116,7 +116,7 @@ - import { createEventDispatcher, getContext } from 'svelte' + import { createEventDispatcher, getContext, tick } from 'svelte' import type { FlowEditorContext } from '../flows/types' import { updateProgress } from '$lib/tutorialUtils' import { @@ -42,12 +42,17 @@ description: 'Flows have inputs that can be used in the flow', onNextClick: () => { clickButtonBySelector('#flow-editor-virtual-Input') + tick() + .then(() => clickButtonBySelector('#add-flow-input-btn')) + .then(tick) + .then(() => setInputBySelector('input[placeholder="Field name"]', 'firstname')) + setTimeout(() => { driver.moveNext() }) } }, - element: '#svelvet-Input' + element: '#flow-editor-virtual-Input' }, { element: 'input[placeholder="Field name"]', @@ -55,7 +60,6 @@ title: 'Name your property', description: 'Give a name to your property. Here we will call it firstname', onNextClick: () => { - setInputBySelector('input[placeholder="Field name"]', 'firstname') setTimeout(() => { driver.moveNext() }) @@ -130,9 +134,11 @@ description: "Let's write a script for your flow", onNextClick: () => { clickButtonBySelector('#flow-editor-new-bun') - waitForElementLoading('#flow-editor-editor', () => { - driver.moveNext() - }) + tick().then(() => + waitForElementLoading('#flow-editor-editor', () => { + driver.moveNext() + }) + ) } } }, @@ -171,7 +177,7 @@ } }, { - element: '.key', + element: '#flow-editor-step-input .prop-picker-inputs', popover: { title: 'Connection mode', description: 'Once you pressed the connect button, you can choose what to connect to.',