diff --git a/web/app/components/workflow/nodes/human-input/components/delivery-method/recipient/email-input.tsx b/web/app/components/workflow/nodes/human-input/components/delivery-method/recipient/email-input.tsx index 1e7cd1ca71..d32ff37627 100644 --- a/web/app/components/workflow/nodes/human-input/components/delivery-method/recipient/email-input.tsx +++ b/web/app/components/workflow/nodes/human-input/components/delivery-method/recipient/email-input.tsx @@ -50,7 +50,8 @@ const EmailInput = ({ const setInputFocus = () => { setIsFocus(true) - inputRef.current?.focus() + const input = inputRef.current?.children[0] as HTMLInputElement + input?.focus() } const handleValueChange = (e: React.ChangeEvent) => { @@ -90,8 +91,8 @@ const EmailInput = ({ setOpen(false) } else if (e.key === 'Backspace') { - e.preventDefault() if (searchKey === '' && value.length > 0) { + e.preventDefault() onDelete(value[value.length - 1]) setSearchKey('') setOpen(false) @@ -122,7 +123,7 @@ const EmailInput = ({ crossAxis: -40, }} > - +