Skip to content

Commit cbca3ca

Browse files
authored
Merge pull request #141 from YAPP-Github/feature/PRODUCT-265
2 parents 1f205ec + ad8de4e commit cbca3ca

File tree

7 files changed

+145
-18
lines changed

7 files changed

+145
-18
lines changed

public/images/register/guide-1.png

549 Bytes
Loading

public/images/register/guide-2.png

802 Bytes
Loading

src/app/(search)/_components/SearchStoreBottomSheet/SearchStoreBottomSheet.tsx

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { useForm } from "react-hook-form";
77
import { useDebounce } from "react-simplikit";
88

99
import CircleCloseIcon from "@/assets/circle-close.svg";
10-
import InfoIcon from "@/assets/info.svg";
10+
import InfoFillIcon from "@/assets/info-fill.svg";
1111
import SearchIcon from "@/assets/search.svg";
1212
import { BottomSheet } from "@/components/ui/BottomSheet";
1313
import { Button } from "@/components/ui/Button";
@@ -160,7 +160,11 @@ export const SearchStoreBottomSheet = ({
160160
}
161161
helperText={
162162
<div className={styles.helperTextWrapper}>
163-
<InfoIcon width={16} height={16} className={styles.infoIcon} />
163+
<InfoFillIcon
164+
width={16}
165+
height={16}
166+
className={styles.infoIcon}
167+
/>
164168
<Text typo='caption1Md' color='text.alternative'>
165169
현재는 서울 지역 가게만 검색할 수 있어요.
166170
</Text>
Lines changed: 23 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,27 @@
1-
import { style } from "@vanilla-extract/css";
1+
import { globalStyle, style } from "@vanilla-extract/css";
22

3-
import { radius, semantic } from "@/styles";
3+
import { semantic } from "@/styles";
44

5-
export const searchBarContainer = style({
6-
display: "flex",
7-
height: "5.2rem",
8-
padding: "1.2rem",
9-
gap: "1.2rem",
10-
flex: "1 0 0",
11-
borderRadius: radius[160],
5+
export const registrationGuideBottomSheetTitle = style({
6+
padding: "2rem 2.4rem",
7+
});
8+
9+
export const registrationGuideInfo = style({
10+
padding: "1.6rem 2.4rem",
11+
borderRadius: "1.6rem",
1212
background: semantic.surface.gray,
1313
});
14+
15+
export const registrationGuideBottomSheetContent = style({
16+
paddingTop: "1.6rem",
17+
});
18+
19+
export const registrationGuideInfoDescription = style({
20+
color: semantic.text.alternative,
21+
});
22+
23+
export const registrationGuideInfoTitle = style({});
24+
25+
globalStyle(`${registrationGuideInfoTitle} b`, {
26+
color: semantic.text.primary,
27+
});

src/app/(store)/stores/register/_components/RegisterFunnel/_components/StoreInfoStep/StoreInfoStep.tsx

Lines changed: 108 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,20 @@
1+
import Image from "next/image";
12
import { overlay } from "overlay-kit";
23
import { useEffect, useState } from "react";
34

45
import { SearchStoreBottomSheet } from "@/app/(search)/_components/SearchStoreBottomSheet";
6+
import InfoIcon from "@/assets/info.svg";
57
import SearchIcon from "@/assets/search.svg";
8+
import { BottomSheet } from "@/components/ui/BottomSheet";
69
import { Button } from "@/components/ui/Button";
710
import { Spacer } from "@/components/ui/Spacer";
8-
import { VStack } from "@/components/ui/Stack";
11+
import { HStack, VStack } from "@/components/ui/Stack";
912
import { Text } from "@/components/ui/Text";
1013
import { TextField } from "@/components/ui/TextField";
1114
import { semantic } from "@/styles";
1215

16+
import * as styles from "./StoreInfoStep.css";
17+
1318
type StoreInfoStepProps = {
1419
onNext: ({
1520
storeName,
@@ -53,9 +58,25 @@ export const StoreInfoStep = ({
5358
소개해주실 수 있나요?
5459
</Text>
5560

56-
<Text as='p' typo='label1Md' color='text.alternative'>
57-
*프렌차이즈의 경우, 반려될 수 있습니다.
58-
</Text>
61+
<HStack gap={4} align='center'>
62+
<Text as='p' typo='label1Md' color='text.alternative'>
63+
검수된 맛집만 제공하여 기준에 따라 반려될 수 있어요.
64+
</Text>
65+
<button
66+
type='button'
67+
aria-label='가게 등록 주의사항'
68+
onClick={() => {
69+
overlay.open(({ isOpen, close }) => (
70+
<StoreRegistrationGuideBottomSheet
71+
open={isOpen}
72+
onOpenChange={close}
73+
/>
74+
));
75+
}}
76+
>
77+
<InfoIcon width={16} height={16} color={semantic.icon.primary} />
78+
</button>
79+
</HStack>
5980
</VStack>
6081
<Spacer size={44} />
6182

@@ -95,3 +116,86 @@ export const StoreInfoStep = ({
95116
</VStack>
96117
);
97118
};
119+
120+
type StoreRegistrationGuideBottomSheetProps = {
121+
open: boolean;
122+
onOpenChange: (open: boolean) => void;
123+
};
124+
125+
const GUIDE_INFO_LIST = [
126+
{
127+
iconUrl: "/images/register/guide-1.png",
128+
title: (
129+
<>
130+
<b>프랜차이즈 기준</b>은 어떻게 결정되나요?
131+
</>
132+
),
133+
description:
134+
"맥도날드나 스타벅스와 같은 대형 프랜차이즈는 등록이 어려워요.",
135+
},
136+
{
137+
iconUrl: "/images/register/guide-2.png",
138+
title: (
139+
<>
140+
응원은 <b>최대 3곳</b>까지 가능해요
141+
</>
142+
),
143+
description:
144+
"최대 3곳까지 가게를 응원할 수 있어요. 신중하게 가게를 응원해주세요.",
145+
},
146+
];
147+
148+
const StoreRegistrationGuideBottomSheet = ({
149+
open,
150+
onOpenChange,
151+
}: StoreRegistrationGuideBottomSheetProps) => {
152+
return (
153+
<BottomSheet.Root open={open} onOpenChange={onOpenChange}>
154+
<BottomSheet.Content>
155+
<BottomSheet.Title className={styles.registrationGuideBottomSheetTitle}>
156+
<Text typo='title3Sb' color='neutral.10'>
157+
가게를 등록할 때 주의할 사항이에요
158+
</Text>
159+
</BottomSheet.Title>
160+
<BottomSheet.Body
161+
className={styles.registrationGuideBottomSheetContent}
162+
>
163+
{GUIDE_INFO_LIST.map(({ title, description, iconUrl }, index) => (
164+
<VStack
165+
gap={10}
166+
className={styles.registrationGuideInfo}
167+
key={index}
168+
>
169+
<HStack align='center' gap={8}>
170+
<Image
171+
src={iconUrl}
172+
alt='가게 등록 주의사항'
173+
width={24}
174+
height={24}
175+
// TODO: 추후 제거
176+
unoptimized
177+
/>
178+
<Text
179+
as='h4'
180+
typo='body1Sb'
181+
color='text.normal'
182+
className={styles.registrationGuideInfoTitle}
183+
>
184+
{title}
185+
</Text>
186+
</HStack>
187+
<Text as='p' typo='body1Md' color='text.alternative'>
188+
{description}
189+
</Text>
190+
</VStack>
191+
))}
192+
</BottomSheet.Body>
193+
<BottomSheet.Footer>
194+
<Button size='fullWidth' onClick={() => onOpenChange(false)}>
195+
확인
196+
</Button>
197+
</BottomSheet.Footer>
198+
</BottomSheet.Content>
199+
</BottomSheet.Root>
200+
);
201+
};

src/assets/info-fill.svg

Lines changed: 3 additions & 0 deletions
Loading

src/assets/info.svg

Lines changed: 5 additions & 3 deletions
Loading

0 commit comments

Comments
 (0)