-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feat: 이용약관 페이지 추가를 위한 상품 탭 레이아웃 수정 #18
Conversation
@@ -10,7 +10,7 @@ import 'package:tuti/features/profile/views/profile_screen.dart'; | |||
import 'package:tuti/features/tutis/views/tuti_screen.dart'; | |||
import 'package:tuti/features/tutis/widgets/tuti_widgets/tuti_login_dialog.dart'; | |||
|
|||
import '../features/tutis/views/personal_branding_screen.dart'; | |||
import '../features/tutis/views/s_personal_branding.dart'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
디렉토리에서 파일을 찾을 때 이름을 찾는데 시간을 줄이기 위해 screen 파일은 앞글자를 따 s로 통일 시킬 예정입니다.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
카카오페이 가맹점 신청을 위해 임시로 데이터를 사용했습니다. 추후 서버에서 받아와 뿌릴 예정입니다.
this.subContents, | ||
this.subTitle, | ||
required this.onTap, | ||
}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
회사 관련 정보 객체를 만들어줬습니다.
일단은 회사 소개 관련 카드를 봤을 때 title, contents, subtitle, subcontents, ontap 메서드로 분해가 되어 이렇게 설정했습니다.
}, | ||
); | ||
|
||
List<CompanyInfo> companyInfos = [companyInfo, customerCenter]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
회사 정보 객체를 담은 배열 생성해주었고 이를 매핑하여 회사 정보 관련 카드를 동적으로 생성합니다.
); | ||
} else { | ||
return const SliverToBoxAdapter( | ||
child: CircularProgressIndicator(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
List형식으로 상품 컨테이너가 생성되고 있고 상품 컨테이너가 사용하는 Goods 정보는 서버에서 받아오는 AsyncValue 객체이기 때문에 이를 handle하기 위해 hasValue, hasError, else로 분기를 나눠 처리해습니다.
@@ -13,18 +13,20 @@ class TuTiBanner extends ConsumerWidget { | |||
{super.key, | |||
required this.onTap, | |||
required this.title, | |||
required this.subtitle}); | |||
required this.subtitle, | |||
this.margin}); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
객체 생성 시 constraintScaffold에서 제약 조건을 부과하고 있어 임의로 해당 배너의 크기를 조절하지 못하여 margin을 받아 custom하게 크기를 조절해주기 위해 margin을 받도록 했습니다.
style: Theme.of(context).textTheme.titleSmall!.copyWith( | ||
fontSize: 10.sp, | ||
color: Colors.black, | ||
fontWeight: FontWeight.w100), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Visibilty 위젯을 사용해 subContents는 null일 수도 있기 때문에 이를 처리하기 위해 visible에 해당 로직을 설정해 null일 땐 보이지 않도록, true일 때는 보이도록 설정했습니다.
GoRoute( | ||
name: TermsOfUseScreen.routeName, | ||
path: TermsOfUseScreen.routePath, | ||
builder: (context, state) => const TermsOfUseScreen()), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
이용약관 페이지로 이동시키기 위해 route를 추가해줬습니다.
Title
Feat: 이용약관 페이지 추가를 위한 상품 탭 레이아웃 수정
What type of PR is this?
Description
Related Issue number and link
Mobile & Desktop Screenshots/Recordings
default.mp4
Checklist:
To Reviewers
이용약관 카드 클릭 시 이용약관 페이지가 뜨도록 구현 예정입니다!