Fix the issue with Chakra menus

This commit is contained in:
Mosh Hamedani 2023-03-03 09:44:02 -08:00
parent e54cdbab3e
commit c64514a5a6

View file

@ -1,4 +1,4 @@
import { Grid, GridItem, HStack, Show } from "@chakra-ui/react";
import { Box, Flex, Grid, GridItem, HStack, Show } from "@chakra-ui/react";
import { useState } from "react";
import GameGrid from "./components/GameGrid";
import GenreList from "./components/GenreList";
@ -38,10 +38,12 @@ function App() {
</GridItem>
</Show>
<GridItem area="main">
<HStack spacing={5} paddingLeft={2} marginBottom={5}>
<Flex paddingLeft={2} marginBottom={5}>
<Box marginRight={5}>
<PlatformSelector selectedPlatform={gameQuery.platform} onSelectPlatform={(platform) => setGameQuery({ ...gameQuery, platform}) } />
</Box>
<SortSelector sortOrder={gameQuery.sortOrder} onSelectSortOrder={(sortOrder) => setGameQuery({ ...gameQuery, sortOrder })} />
</HStack>
</Flex>
<GameGrid gameQuery={gameQuery} />
</GridItem>
</Grid>