fix(ai): discard proposals when section context changes

This commit is contained in:
cesnimda
2026-11-03 15:24:55 +01:00
parent e5a979386d
commit a88310481f
10 changed files with 83 additions and 3 deletions
@@ -42,7 +42,7 @@ export default function AiSectionAssistant({ sectionName, text, context, documen
setBusy(false);
setApplying(false);
return () => { requestId.current += 1; };
}, [text, targetId, normalizedLanguage, targetLanguage, canUseAi]);
}, [text, targetId, context, sectionName, normalizedLanguage, targetLanguage, canUseAi]);
const discard = () => {
requestId.current += 1;