{#if arg != undefined}
{#if !checked && arg.type === 'javascript'} {'${...}'} {/if}
{ const type = e.detail ? 'javascript' : 'static' const staticTemplate = isStaticTemplate(inputCats[argName]) if (type === 'javascript') { arg.expr = getDefaultExpr( i ?? -1, argName, staticTemplate ? `\`${arg.value ?? ''}\`` : arg.value ) arg.value = undefined propertyType = 'javascript' } else { arg.value = staticTemplate ? codeToStaticTemplate(arg.expr) : undefined arg.expr = undefined propertyType = 'static' } arg.type = type }} />
{#if propertyType === undefined || !checked} { if (detail.pickerVariation === 'connect') { connectProperty(argName, detail.propPath) } else { const toAppend = `\$\{${detail.propPath}}` arg.value = `${arg.value ?? ''}${toAppend}` if (monacos[argName]) { monacos[argName].setCode(arg.value) } if (isStaticTemplate(inputCats[argName])) { setPropertyType(arg.value) } } }} > focusProp(argName)} label={argName} bind:editor={monacos[argName]} bind:description={schema.properties[argName].description} bind:value={arg.value} type={schema.properties[argName].type} required={schema.required.includes(argName)} bind:pattern={schema.properties[argName].pattern} bind:valid={inputCheck[argName]} defaultValue={schema.properties[argName].default} bind:enum_={schema.properties[argName].enum} bind:format={schema.properties[argName].format} contentEncoding={schema.properties[argName].contentEncoding} bind:itemsType={schema.properties[argName].items} displayHeader={false} bind:inputCat={inputCats[argName]} on:input={(e) => { if (isStaticTemplate(inputCats[argName])) { setPropertyType(e.detail.rawValue) } }} >
overlays[argName]?.focus('connect')}>
{:else if checked} {#if arg.expr != undefined} { monacos[argName].insertAtCursor(event.detail.propPath) }} >
focusProp(argName, true)} bind:code={arg.expr} lang="javascript" class="few-lines-editor" {extraLib} extraLibPath="file:///node_modules/@types/windmill@{i}/index.d.ts" shouldBindKey={false} />
{/if} {:else}

Not recognized arg type {arg.type}

{/if} {:else}

Arg at {argName} is undefined

{/if}