Skip to content

Commit 02bfb04

Browse files
perf(web): the model picker sidebar compiles with the React Compiler
Co-Authored-By: Claude Opus 5.5 <[email protected]>
1 parent 70d60e0 commit 02bfb04

2 files changed

Lines changed: 7 additions & 1 deletion

File tree

‎apps/web/reactCompiledFiles.ts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,4 +96,5 @@ export const REACT_COMPILED_FILES = [
9696
"apps/web/src/components/pullRequest/PullRequestDetailPanel.tsx",
9797
"apps/web/src/components/ThreadTerminalDrawer.tsx",
9898
"apps/web/src/components/settings/SettingsPanels.tsx",
99+
"apps/web/src/components/chat/ModelPickerSidebar.tsx",
99100
] as const;

‎apps/web/src/components/chat/ModelPickerSidebar.tsx‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,12 @@ export const ModelPickerSidebar = memo(function ModelPickerSidebar(props: {
6565
return;
6666
}
6767
setSelectedIndicatorTop(selectedItem.offsetTop + selectedItem.offsetHeight / 2 - 10);
68-
}, [props.instanceEntries, props.selectedInstanceId, showFavorites]);
68+
}, [
69+
// oxlint-disable-next-line react/exhaustive-effect-dependencies -- Adding, removing or reordering providers moves the selected item, so the indicator re-measures.
70+
props.instanceEntries,
71+
props.selectedInstanceId,
72+
showFavorites,
73+
]);
6974

7075
return (
7176
<Toolbar.Root

0 commit comments

Comments
 (0)