From 28c28b2fc0ef9dc5541ccf17d3469ee20476e977 Mon Sep 17 00:00:00 2001 From: Josh Corbett Date: Sun, 21 Apr 2024 23:18:23 -0600 Subject: [PATCH] fix: :bug: handle trigger phrase form submits --- .../subpanels/ModelPanel/TriggerPhrases.tsx | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/invokeai/frontend/web/src/features/modelManagerV2/subpanels/ModelPanel/TriggerPhrases.tsx b/invokeai/frontend/web/src/features/modelManagerV2/subpanels/ModelPanel/TriggerPhrases.tsx index ec707352c7..9352d7996c 100644 --- a/invokeai/frontend/web/src/features/modelManagerV2/subpanels/ModelPanel/TriggerPhrases.tsx +++ b/invokeai/frontend/web/src/features/modelManagerV2/subpanels/ModelPanel/TriggerPhrases.tsx @@ -77,9 +77,17 @@ export const TriggerPhrases = () => { [updateModel, selectedModelKey, triggerPhrases] ); + const onTriggerPhraseAddFormSubmit = useCallback( + (e: React.FormEvent) => { + e.preventDefault(); + addTriggerPhrase(); + }, + [addTriggerPhrase] + ); + return ( -
+ {t('modelManager.triggerPhrases')}