diff --git a/assets/icons/paper_tray.gif b/assets/icons/paper_tray.gif new file mode 100644 index 0000000..3c62e49 Binary files /dev/null and b/assets/icons/paper_tray.gif differ diff --git a/lib/main.dart b/lib/main.dart index 1fb6a0b..975646d 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -1,5 +1,6 @@ import 'package:code_l/auth/presentation/pages/login/login_page.dart'; import 'package:code_l/auth/presentation/pages/terms_and_conditions/terms_and_condition_page.dart'; +import 'package:code_l/sign_up/presentation/pages/pending_approval/pending_approval_page.dart'; import 'package:code_l/sign_up/presentation/pages/profile_interest/profile_intereset_page.dart'; import 'package:firebase_core/firebase_core.dart'; import 'package:flutter/material.dart'; @@ -27,7 +28,7 @@ class MyApp extends StatelessWidget { Widget build(BuildContext context) { return MaterialApp( title: 'Kakao Login Demo', - home: const LoginPage(), + home: const PendingApprovalPage(), theme: ThemeData( primarySwatch: Colors.blue, scaffoldBackgroundColor: Colors.white, diff --git a/lib/sign_up/presentation/pages/pending_approval/pending_approval_page.dart b/lib/sign_up/presentation/pages/pending_approval/pending_approval_page.dart new file mode 100644 index 0000000..57a8ed7 --- /dev/null +++ b/lib/sign_up/presentation/pages/pending_approval/pending_approval_page.dart @@ -0,0 +1,51 @@ +import 'package:code_l/auth/presentation/pages/login/login_page.dart'; +import 'package:code_l/sign_up/presentation/pages/pending_approval/widgets/pending_app_bar.dart'; +import 'package:code_l/sign_up/presentation/pages/pending_approval/widgets/pending_profile_button.dart'; +import 'package:flutter/cupertino.dart'; +import 'package:flutter/material.dart'; +import 'package:gif/gif.dart'; + +import '../../../../core/utills/design/app_gaps.dart'; +import '../../../../core/utills/design/app_typography.dart'; + +class PendingApprovalPage extends StatelessWidget { + const PendingApprovalPage({super.key}); + + @override + Widget build(BuildContext context) { + var screenWidth = MediaQuery.of(context).size.width; + return Scaffold( + appBar: PendingAppBar(), + bottomNavigationBar: PendingProfileButton( + enabled: true, + onPressed: (){Navigator.push( + context, + MaterialPageRoute( + builder: (context) => LoginPage(), + ), + );} + ), + body: SafeArea( + child: Padding( + padding: const EdgeInsets.all(AppGaps.gap24), + child: Column( + crossAxisAlignment: CrossAxisAlignment.center, + children: [ + SizedBox(height: 130,width: screenWidth,), + Gif( + image: AssetImage("assets/icons/paper_tray.gif"), + autostart: Autostart.loop, + placeholder: (context) => + const Center(child: CircularProgressIndicator()), + ), + Text("잠시만 기다려 주세요",style: AppTypography.header1,), + SizedBox(height: 24,), + Text("운영진들이 사용자님의 정보를",style: AppTypography.subtitle3,), + Text("확인 중 입니다.",style: AppTypography.subtitle3,), + ], + ), + ), + ), + ); + } +} diff --git a/lib/sign_up/presentation/pages/pending_approval/widgets/pending_app_bar.dart b/lib/sign_up/presentation/pages/pending_approval/widgets/pending_app_bar.dart new file mode 100644 index 0000000..fb00ce1 --- /dev/null +++ b/lib/sign_up/presentation/pages/pending_approval/widgets/pending_app_bar.dart @@ -0,0 +1,33 @@ +import 'package:code_l/core/utills/design/app_colors.dart'; +import 'package:code_l/core/utills/design/app_typography.dart'; +import 'package:flutter/material.dart'; + +class PendingAppBar extends StatelessWidget implements PreferredSizeWidget { + const PendingAppBar({super.key}); + + @override + Size get preferredSize => Size.fromHeight(56); + + @override + Widget build(BuildContext context) { + + return SafeArea( + child: Padding( + padding: const EdgeInsets.symmetric(horizontal: 12, vertical: 8), + child: Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + children: [ + SizedBox(width: 40,), + Text("승인 대기중",style: AppTypography.subtitle2,), + IconButton( + icon: Icon(Icons.close), + onPressed: () { + Navigator.pop(context); + }, + ), + ], + ), + ), + ); + } +} diff --git a/lib/sign_up/presentation/pages/pending_approval/widgets/pending_profile_button.dart b/lib/sign_up/presentation/pages/pending_approval/widgets/pending_profile_button.dart new file mode 100644 index 0000000..e15e511 --- /dev/null +++ b/lib/sign_up/presentation/pages/pending_approval/widgets/pending_profile_button.dart @@ -0,0 +1,45 @@ +import 'package:flutter/cupertino.dart'; + +import '../../../../../core/utills/design/app_colors.dart'; +import '../../../../../core/utills/design/app_gaps.dart'; +import '../../../../../core/utills/design/app_typography.dart'; + +class PendingProfileButton extends StatelessWidget { + final bool enabled; + final VoidCallback? onPressed; + final String text; + + const PendingProfileButton({ + super.key, + required this.enabled, + this.onPressed, + this.text = "작성한 코드프로필 보기", + }); + + @override + Widget build(BuildContext context) { + return Padding( + padding: const EdgeInsets.all(AppGaps.gap24), + child: GestureDetector( + onTap: enabled ? onPressed : null, + child: Container( + height: 54, + width: double.infinity, + padding: EdgeInsets.symmetric(vertical: 16), + alignment: Alignment.center, + decoration: BoxDecoration( + color: AppColors.white, + border: Border.all( + color: enabled ? AppColors.primary : AppColors.grey400, + ), + borderRadius: BorderRadius.circular(8), + ), + child: Text( + text, + style: AppTypography.subtitle2, + ), + ), + ), + ); + } +} diff --git a/pubspec.lock b/pubspec.lock index 704416c..732a124 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -328,6 +328,14 @@ packages: description: flutter source: sdk version: "0.0.0" + gif: + dependency: "direct main" + description: + name: gif + sha256: ade95694f1471da737922806818ffade2814d1d7f8d10af38ebcf36ace012bc0 + url: "https://pub.dev" + source: hosted + version: "2.3.0" glob: dependency: transitive description: diff --git a/pubspec.yaml b/pubspec.yaml index c932278..5fa8cb0 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -46,6 +46,7 @@ dependencies: screen_protector: ^1.4.2+1 sign_in_with_apple: ^7.0.1 image_picker: ^1.1.2 + gif: ^2.3.0 dev_dependencies: flutter_test: