Skip to content

Commit 09bd28e

Browse files
authored
fix: two console errors from #328 (#359)
1 parent 9c2aa1e commit 09bd28e

File tree

1 file changed

+13
-11
lines changed

1 file changed

+13
-11
lines changed

ui/src/components/Sidebar.tsx

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ function SidebarSettings() {
188188
<FormControlLabel
189189
control={
190190
<Switch
191-
checked={(apiKey && autoCompletion) as boolean}
191+
checked={!!(apiKey && autoCompletion)}
192192
size="small"
193193
color="warning"
194194
onChange={(event: React.ChangeEvent<HTMLInputElement>) => {
@@ -208,16 +208,18 @@ function SidebarSettings() {
208208
disableInteractive
209209
sx={{ display: "inline" }}
210210
>
211-
<IconButton
212-
size="small"
213-
sx={{ display: "inline" }}
214-
onClick={() => setSettingOpen(true)}
215-
disabled={isGuest}
216-
>
217-
<HelpOutlineOutlinedIcon
218-
sx={{ fontSize: 14 }}
219-
></HelpOutlineOutlinedIcon>
220-
</IconButton>
211+
<Box>
212+
<IconButton
213+
size="small"
214+
sx={{ display: "inline" }}
215+
onClick={() => setSettingOpen(true)}
216+
disabled={isGuest}
217+
>
218+
<HelpOutlineOutlinedIcon
219+
sx={{ fontSize: 14 }}
220+
></HelpOutlineOutlinedIcon>
221+
</IconButton>
222+
</Box>
221223
</Tooltip>
222224
</>
223225
}

0 commit comments

Comments
 (0)