Skip to content

Commit

Permalink
refactor: Swiper 0.9.1 버전 반영
Browse files Browse the repository at this point in the history
  • Loading branch information
semnil5202 committed Jul 11, 2024
1 parent 6affad5 commit a86b235
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 44 deletions.
12 changes: 1 addition & 11 deletions frontend/src/components/Banner/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,7 @@ export default function Banner() {
};

return (
<Swiper
as="section"
width={1140}
height={400}
$simpleTab
$tabBoxPosition="bottom"
$isNotTabBoxShow
swipeable
swiper
autoplay
>
<Swiper as="section" width={1140} height={400} $tabBoxPosition="bottom" autoplay>
<Tab label="붕어빵 지도">
<Box cursor="pointer" onClick={goToBoongABbangTopic}>
<BannerImage
Expand Down
18 changes: 3 additions & 15 deletions frontend/src/components/PinImageContainer/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,7 @@ function PinImageContainer({ images, getPinData }: PinImageContainerProps) {
$errorDefaultSrc={NOT_FOUND_IMAGE}
/>
</div>
<RemoveImageIconWrapper
onClick={() => onRemovePinImage(image.id)}
>
<RemoveImageIconWrapper onClick={() => onRemovePinImage(image.id)}>
<RemoveImageButton />
</RemoveImageIconWrapper>
</ImageWrapper>
Expand All @@ -84,15 +82,7 @@ function PinImageContainer({ images, getPinData }: PinImageContainerProps) {

return (
<Wrapper>
<Swiper
as="ul"
width={330}
height={100}
$elementsOneTab={3}
swiper
swipeable
$isNotTabBoxShow
>
<Swiper as="ul" width={330} height={100} $slidePerTab={3}>
{images.map((image, index) => (
<Tab label={`${index}`} key={image.id}>
<ImageWrapper key={`image-${index}`}>
Expand All @@ -105,9 +95,7 @@ function PinImageContainer({ images, getPinData }: PinImageContainerProps) {
$errorDefaultSrc={NOT_FOUND_IMAGE}
/>
</div>
<RemoveImageIconWrapper
onClick={() => onRemovePinImage(image.id)}
>
<RemoveImageIconWrapper onClick={() => onRemovePinImage(image.id)}>
<RemoveImageButton />
</RemoveImageIconWrapper>
</ImageWrapper>
Expand Down
27 changes: 9 additions & 18 deletions frontend/src/components/TopicCardContainer/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,22 +30,11 @@ function TopicCardContainer({
<section>
<Flex $justifyContent="space-between" $alignItems="flex-end">
<Box>
<MediaText
as="h2"
color="black"
$fontSize="extraLarge"
$fontWeight="bold"
tabIndex={0}
>
<MediaText as="h2" color="black" $fontSize="extraLarge" $fontWeight="bold" tabIndex={0}>
{containerTitle}
</MediaText>
<Space size={0} />
<MediaText
color="gray"
$fontSize="default"
$fontWeight="normal"
tabIndex={0}
>
<MediaText color="gray" $fontSize="default" $fontWeight="normal" tabIndex={0}>
{containerDescription}
</MediaText>
</Box>
Expand All @@ -71,11 +60,13 @@ function TopicCardContainer({
as="ul"
width={1140}
height={300}
$elementsOneTab={5}
$elementsMediaQueries={[1180, 900, 660, 320]}
swiper
swipeable
$isNotTabBoxShow
$slidePerTab={5}
$breakPoints={{
1100: 4,
900: 3,
660: 2,
320: 1,
}}
>
{topics &&
topics.map(
Expand Down

0 comments on commit a86b235

Please sign in to comment.