Fix SF list selection

This commit is contained in:
nickofolas 2022-04-09 08:41:03 -05:00
parent 236a5cd645
commit 48895c8d2d

@ -111,7 +111,12 @@ export function SourceFilesElement(): React.ReactElement {
const maxLevel = getMaxLevel(sfObj);
return (
<ListItemButton key={i + 1} onClick={() => setSelectedSf(e)} selected={selectedSf === e} sx={{ py: 0 }}>
<ListItemButton
key={i + 1}
onClick={() => setSelectedSf(e)}
selected={selectedSf.n === e.n}
sx={{ py: 0 }}
>
<ListItemText
disableTypography
primary={<Typography>{sfObj.name}</Typography>}