diff --git a/code/frontend/src/components/Answer/Answer.tsx b/code/frontend/src/components/Answer/Answer.tsx index 3fb6e867d..1f689a20e 100644 --- a/code/frontend/src/components/Answer/Answer.tsx +++ b/code/frontend/src/components/Answer/Answer.tsx @@ -40,7 +40,7 @@ export const Answer = ({ if(chevronIsExpanded && refContainer.current){ refContainer.current.scrollIntoView({ behavior:'smooth'}); } - }, [isRefAccordionOpen]); + }, [chevronIsExpanded,isRefAccordionOpen]); const createCitationFilepath = (citation: Citation, index: number, truncate: boolean = false) => { let citationFilename = "";