Skip to content

Commit

Permalink
Fix: GardGrid 3개 -> 4개
Browse files Browse the repository at this point in the history
  • Loading branch information
kimyouknow committed Mar 5, 2023
1 parent c2ec450 commit f2390e7
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 7 deletions.
3 changes: 2 additions & 1 deletion webapp/src/components/CardsGrid/CardsGrid.style.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,9 @@ export const Cards = styled.ul`
display: grid;
grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
gap: 40px 20px;
width: 100%;
width: 1580px;
height: 100%;
margin: 0 auto;
`;

export const Empty = styled.div`
Expand Down
2 changes: 1 addition & 1 deletion webapp/src/components/CardsGrid/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ export default function CardsGrid({
if (cards.length === 0 && isLoading)
return (
<S.Cards>
<SimpleListComponent Component={CardLoader} idx={3} />
<SimpleListComponent Component={CardLoader} idx={4} />
{children}
</S.Cards>
);
Expand Down
6 changes: 4 additions & 2 deletions webapp/src/hoc/WithInfiniteScroll.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import UpperButton from 'components/Common/UpperButton';
import Callback from 'pages/Callback';
import CardsGrid from 'components/CardsGrid';
import CardLoader from 'components/Common/Loader/CardLoader';
import SimpleListComponent from './SimpleListComponent';

WithInfiniteScroll.propTypes = {
CardComponent: PropTypes.func.isRequired,
Expand Down Expand Up @@ -100,7 +101,9 @@ export default function WithInfiniteScroll({
isLoading={isLoading}
>
<RefContainer isShow={refDisplay} ref={loadMoreRef}>
{cardList.length !== 0 && isLoading && !error.isError && <CardLoader />}
{cardList.length !== 0 && isLoading && !error.isError && (
<SimpleListComponent Component={CardLoader} idx={1} />
)}
</RefContainer>
</CardsGrid>
)}
Expand All @@ -111,5 +114,4 @@ export default function WithInfiniteScroll({

const RefContainer = styled.div`
display: ${({ isShow }) => isShow};
padding: 12px 0;
`;
6 changes: 4 additions & 2 deletions webapp/src/layouts/layout.style.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,15 @@ export const Header = styled.header`
`;

export const Main = styled.main`
max-width: 1180px;
max-width: 1700px;
margin: 0 auto;
padding-top: 30px;
display: flex;
justify-content: center;
`;

export const Full = styled.main`
max-width: 1180px;
max-width: 1700px;
height: 100vh;
margin: 0 auto;
${({ theme: { mixin } }) => mixin.flexCenter({})}
Expand Down
2 changes: 1 addition & 1 deletion webapp/src/pages/Callback/callback.style.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import styled, { css } from 'styled-components/macro';

export const Container = styled.div`
max-width: 1180px;
width: 100%;
height: 100vh;
${({ theme: { mixin } }) => mixin.flexCenter({})}
gap: 24px;
Expand Down

0 comments on commit f2390e7

Please sign in to comment.