Skip to content

Commit

Permalink
feat: file name 및 component 이름 변경 (#109)
Browse files Browse the repository at this point in the history
  • Loading branch information
selfishAltruism committed Mar 22, 2024
1 parent 4570248 commit da5f93f
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/pages/circle/home/CircleHomePage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ const CircleHomePage: React.FC = observer(() => {
<Circle.ListFrame
items={circles}
emptyText={'아직 등록된 동아리가 없어요!'}
ListComponent={!isMobile ? Circle.WebSlider : Circle.Slider}
ListComponent={isMobile ? Circle.MobileSlider : Circle.WebSlider}
/>
<H2>내 동아리</H2>
<Circle.ListFrame
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { ClearButton } from '@/components';
import { PAGE_URL } from '@/configs/path';
import { usePageUiStore } from '@/hooks';

export const CircleSlideCard: React.FC<{ model: Model.Circle }> = memo(
export const CircleMobileSlideCard: React.FC<{ model: Model.Circle }> = memo(
({ model: { id: circleId, mainImage, name, newLineDescription } }) => {
const { push } = useHistory();
const [isFlipped, setFlip] = useState(false);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ import { observer } from 'mobx-react-lite';
import { useState } from 'react';
import { Carousel } from 'react-responsive-carousel';

import { CircleSlideCard } from './CircleSlideCard';
import { CircleMobileSlideCard } from './CircleMobileSlideCard';
import { ListComponent } from '../CircleListFrame';

export const CircleSlider: ListComponent = observer(({ items }) => {
export const CircleMobileSlider: ListComponent = observer(({ items }) => {
const [config] = useState({
autoPlay: false,
// XXX: swipe 이후 자동으로 움직이는 버그가 있음
Expand All @@ -25,7 +25,7 @@ export const CircleSlider: ListComponent = observer(({ items }) => {
return (
<StyledCarousel {...config}>
{items.map(item => (
<CircleSlideCard key={item.id} model={item} />
<CircleMobileSlideCard key={item.id} model={item} />
))}
</StyledCarousel>
);
Expand Down
2 changes: 1 addition & 1 deletion src/pages/circle/home/components/MobileSlider/index.ts
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export { CircleSlider as Slider } from './CircleSlider';
export { CircleMobileSlider as MobileSlider } from './CircleMobileSlider';
2 changes: 1 addition & 1 deletion src/pages/circle/home/components/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
export * from './List';
export * from './Slider';
export * from './MobileSlider';
export * from './WebSlider';

export { CircleListFrame as ListFrame } from './CircleListFrame';

0 comments on commit da5f93f

Please sign in to comment.