Skip to content

Commit

Permalink
fix: couple of fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
TurtIeSocks committed Jan 10, 2024
1 parent 967a98d commit ac2a1c5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
5 changes: 3 additions & 2 deletions src/components/layout/drawer/Extras.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -47,14 +47,15 @@ const BaseS2Cells = () => {
const enabled = useStore((s) => !!s.filters.s2cells.enabled)
const [filters, setFilters] = useDeepStore('filters.s2cells.cells')
const safe = React.useMemo(() => filters || [], [filters])
if (!filters) return null
return (
<CollapsibleItem open={enabled}>
<ListItem>
<Select
sx={{ mx: 'auto', width: '90%' }}
value={safe}
renderValue={(selected) => selected.join(', ')}
renderValue={(selected) =>
Array.isArray(selected) ? selected.join(', ') : selected
}
multiple
onChange={({ target }) =>
setFilters(
Expand Down
3 changes: 1 addition & 2 deletions src/components/layout/drawer/Section.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,6 @@ const DrawerSection = ({ category }) => {
<List>
{category === 'pokemon' ? (
<PokemonDrawerMemo />
) : category === 'scanAreas' ? (
<Areas />
) : category === 'settings' ? (
<SettingsMenu />
) : (
Expand Down Expand Up @@ -107,6 +105,7 @@ const DrawerSection = ({ category }) => {
<ListItemText primary={t('advanced')} />
</ListItemButton>
)}
{category === 'scanAreas' && <Areas />}
</List>
</AccordionDetails>
</Accordion>
Expand Down

0 comments on commit ac2a1c5

Please sign in to comment.