From d924d3fa4fed7e961c968886b3d5dc317a53b080 Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Sat, 21 Feb 2026 11:41:59 +0200 Subject: [PATCH] fix(promoted_attributes): auto-complete interfering with value --- apps/client/src/widgets/PromotedAttributes.tsx | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/apps/client/src/widgets/PromotedAttributes.tsx b/apps/client/src/widgets/PromotedAttributes.tsx index 779fe6a300..f40307a900 100644 --- a/apps/client/src/widgets/PromotedAttributes.tsx +++ b/apps/client/src/widgets/PromotedAttributes.tsx @@ -37,7 +37,7 @@ interface CellProps { } type OnChangeEventData = TargetedEvent | InputEvent | JQuery.TriggeredEvent; -type OnChangeListener = (e: OnChangeEventData) => Promise; +type OnChangeListener = (e: OnChangeEventData) => void | Promise; export default function PromotedAttributes() { const { note, componentId, noteContext } = useNoteContext(); @@ -200,7 +200,11 @@ function LabelInput(props: CellProps & { inputId: string }) { }, [ cell, componentId, note, setCells ]); const extraInputProps: InputHTMLAttributes = {}; - useTextLabelAutocomplete(inputId, valueAttr, definition, onChangeListener); + useTextLabelAutocomplete(inputId, valueAttr, definition, (e) => { + if (e.currentTarget instanceof HTMLInputElement) { + setDraft(e.currentTarget.value); + } + }); // React to model changes. useEffect(() => {