Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
 into S1/#608-fix-bottom-sheet
  • Loading branch information
lydiacho committed Feb 19, 2024
2 parents c63b48e + 2734ede commit eaa52ec
Show file tree
Hide file tree
Showing 14 changed files with 36 additions and 52 deletions.
11 changes: 5 additions & 6 deletions src/common/SmallTattooCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@ import { LabelCustomSmall } from '../assets/icon';
import { useNavigate } from 'react-router-dom';

const SmallTattooCard = ({
id,
stickerId,
img,
title,
discountRate,
price,
originalPrice,
isCustom,
}: {
id: number;
stickerId: number;
img: string;
title: string;
discountRate: number;
Expand All @@ -21,12 +21,11 @@ const SmallTattooCard = ({
}) => {
const navigate = useNavigate();

const handleClickItem = (id: number) => {
navigate(`/detail/${id}`);
const handleClickItem = (stickerId: number) => {
navigate(`/detail/${stickerId}`);
};

return (
<St.SmallTattooCardItem onClick={() => handleClickItem(id)}>
<St.SmallTattooCardItem onClick={() => handleClickItem(stickerId)}>
{isCustom && <LabelCustomSmall />}
<St.SmallTattooCardImage src={img} alt='작은 타투 이미지' />
<St.SmallTattooCardTitle>{title}</St.SmallTattooCardTitle>
Expand Down
7 changes: 4 additions & 3 deletions src/components/Custom/Common/OnBoardingFooter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -78,22 +78,23 @@ export default OnBoardingFooter;

const St = {
OnBoardingFooter: styled.footer`
position: sticky;
position: fixed;
bottom: 0;
display: flex;
justify-content: center;
align-items: center;
width: 100%;
max-width: 43rem;
height: 7rem;
background-color: ${({ theme }) => theme.colors.gray9};
background-color: ${({ theme }) => theme.colors.pink5};
z-index: 2;
`,

FooterText: styled.p`
color: ${({ theme }) => theme.colors.pink5};
color: ${({ theme }) => theme.colors.gray9};
${({ theme }) => theme.fonts.title_semibold_18};
`,
};
1 change: 1 addition & 0 deletions src/components/Custom/Common/Receipt/ReceiptDetail.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ const St = {
display: flex;
flex-direction: column;
padding-bottom: 5.8rem;
margin-bottom: 7rem;
min-height: calc(100dvh - 36.92rem);
`,
Expand Down
3 changes: 2 additions & 1 deletion src/components/Custom/Common/Receipt/ReceiptFooter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,11 @@ const St = {
display: flex;
justify-content: center;
align-items: center;
position: sticky;
position: fixed;
bottom: 0;
width: 100%;
max-width: 43rem;
height: 7rem;
background-color: ${({ theme }) => theme.colors.gray9};
Expand Down
21 changes: 1 addition & 20 deletions src/components/Custom/Common/Receipt/ReceiptLayout.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
import { useState } from 'react';
import BackBtn from '../../../../common/Header/BackBtn';
import CancelBtn from '../../../../common/Header/CancelBtn';
import CustomSizeEscapeModal from '../../../../common/Modal/EscapeModal/CustomSizeEscapeModal';
import Header from '../../../Header';
import PageLayout from '../../../PageLayout';
import ReceiptDetail from './ReceiptDetail';
Expand All @@ -15,23 +11,8 @@ interface ReceiptLayoutProps {
}

const ReceiptLayout = ({ receiptData, haveDesign }: ReceiptLayoutProps) => {
const [modalOn, setModalOn] = useState(false);

const renderReceiptLayoutHeader = () => {
return (
<Header
leftSection={<BackBtn />}
title='커스텀 타투'
rightSection={
<CancelBtn
modalOn={modalOn}
setModalOn={setModalOn}
targetModal={<CustomSizeEscapeModal setModalOn={setModalOn} />}
/>
}
transparent={true}
/>
);
return <Header title='커스텀 타투' transparent={true} />;
};

return (
Expand Down
1 change: 1 addition & 0 deletions src/components/Custom/Common/Size/CustomSelectSize.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ const St = {
width: 100%;
min-height: calc(100dvh - 13.6rem);
padding: 0 2rem;
margin-bottom: 7rem;
`,

SizeInfoContainer: styled.article`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ const St = {
flex-direction: column;
/* align-items: center; */
min-height: calc(100dvh - 13.6rem);
margin-bottom: 7rem;
`,
};

Expand Down
1 change: 0 additions & 1 deletion src/components/Custom/NoDesign/Img/CustomImgLayout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ const CustomImgLayout = ({
setPreviewURL,
}: CustomImgLayoutProps) => {
// const CUSTOM_VIEW_COUNT = 2;
console.log('customInfo: ', customInfo);
const [modalOn, setModalOn] = useState(false);
const [isActiveNext, setIsActiveNext] = useState(false);

Expand Down
3 changes: 2 additions & 1 deletion src/components/Custom/NoDesign/NoDesignFooter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,15 @@ export default NoDesignFooter;

const St = {
NoDesignFooter: styled.footer<{ $isActiveNext: boolean }>`
position: sticky;
position: fixed;
bottom: 0;
display: flex;
justify-content: center;
align-items: center;
width: 100%;
max-width: 43rem;
height: 7rem;
background-color: ${({ $isActiveNext, theme }) =>
Expand Down
3 changes: 2 additions & 1 deletion src/components/Custom/PriceFooter.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -63,14 +63,15 @@ const PriceFooter = ({

const St = {
CustomFooter: styled.footer`
position: sticky;
position: fixed;
bottom: 0;
display: flex;
justify-content: center;
align-items: center;
width: 100%;
max-width: 43rem;
height: 7rem;
background-color: ${({ theme }) => theme.colors.gray9};
Expand Down
30 changes: 14 additions & 16 deletions src/components/MyTattoo/MyLike.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,22 +9,20 @@ const MyLike = () => {
<CustomScrollContainer title={'LIKE'}>
{!error &&
!loading &&
response.map(
({ id, stickerId, mainImageUrl, name, price, discountPrice, discountRate }) => {
return (
<SmallTattooCard
key={id}
id={stickerId}
img={mainImageUrl}
title={name}
price={discountPrice}
originalPrice={price}
discountRate={discountRate}
isCustom={false}
/>
);
},
)}
response.map(({ stickerId, mainImageUrl, name, price, discountPrice, discountRate }) => {
return (
<SmallTattooCard
key={stickerId}
stickerId={stickerId}
img={mainImageUrl}
title={name}
price={discountPrice}
originalPrice={price}
discountRate={discountRate}
isCustom={false}
/>
);
})}
</CustomScrollContainer>
);
};
Expand Down
2 changes: 1 addition & 1 deletion src/components/Register/RegisterName.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const RegisterName = ({ setUserName }: RegisterNameProps) => {

<St.InputContentsWrapper>
<St.InputContent
placeholder='ex) 김타투'
placeholder='ex) 홍길동'
onChange={(e: React.ChangeEvent<HTMLInputElement>) => handleChangeInputContent(e)}
onInput={(e: React.ChangeEvent<HTMLInputElement>) => sliceMaxLength(e, 5, 'onlyString')}
></St.InputContent>
Expand Down
2 changes: 1 addition & 1 deletion src/constants/TitleInfo.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
export const TITLE = ['이름을 입력해주세요', '전화번호를 입력해주세요'];
export const TITLE = ['실명을 입력해주세요', '전화번호를 입력해주세요'];
export const SUB_TITLE = [
'주문 시 입금자명 확인을 위해 실명이 필요해요',
'주문 후 문자로 안내드리기 위해 필요해요.',
Expand Down
2 changes: 1 addition & 1 deletion src/page/DetailPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ const DetailPage = () => {
relatedResponse.map((el) => (
<SmallTattooCard
key={el.id}
id={el.id}
stickerId={el.id}
img={el.imageUrl}
title={el.name}
discountRate={el.discountRate}
Expand Down

0 comments on commit eaa52ec

Please sign in to comment.