feat(editor): Easy $fromAI Button for AI Tools (#12587)

This commit is contained in:
Charlie Kolb
2025-02-05 08:42:50 +01:00
committed by GitHub
parent 182fc150be
commit 21773764d3
34 changed files with 1711 additions and 328 deletions

View File

@@ -55,6 +55,12 @@ const workflowsStore = useWorkflowsStore();
const isDragging = computed(() => ndvStore.isDraggableDragging);
function select() {
if (inlineInput.value) {
inlineInput.value.selectAll();
}
}
function focus() {
if (inlineInput.value) {
inlineInput.value.focus();
@@ -162,7 +168,7 @@ watch(isDragging, (newIsDragging) => {
onClickOutside(container, (event) => onBlur(event));
defineExpose({ focus });
defineExpose({ focus, select });
</script>
<template>
@@ -220,6 +226,7 @@ defineExpose({ focus });
<style lang="scss" module>
.expression-parameter-input {
position: relative;
flex-grow: 1;
:global(.cm-editor) {
background-color: var(--color-code-background);