diff --git a/assets/img_holder.png b/assets/img_holder.png new file mode 100644 index 0000000..9c66a54 Binary files /dev/null and b/assets/img_holder.png differ diff --git a/lib/consts/texts.dart b/lib/consts/texts.dart index f2abdb8..58a3e9a 100644 --- a/lib/consts/texts.dart +++ b/lib/consts/texts.dart @@ -30,4 +30,38 @@ const tLanguages = "Languages"; const tOtherSkills= "Other Skills"; const tBio= "bio"; -const tSaveBtn= "Save"; \ No newline at end of file +const tSaveBtn= "Save"; + +//? -> User Registration +String signUpTxt = "Sign Up"; +const tPassTxt = "Password"; +const tRegBtn = "Save"; +const welcomeTxt = "Almost there, please enter your credentials \nto continue."; + +const signUpFullNameTft = "Enter your fullname"; +const signUpEmailTft = "Enter your e-mail"; +const signUpPasswordTft = "Enter your e-mail"; +const tSelectCity = "Enter City"; +const signUpTermsTxt = "Agree to our"; +const signUpConditionTxt = "I agree to the"; +const tTermsAndConditions = "Terms of service"; +const signUpLoginTxt = "Login"; +const signUpHaveAnAccountTxt = "Already have an account?"; +const signUpWithGoogle = "Sign in with Google"; +const signUpWithApple = "Sign up with Apple"; +const signUpWithFacebook = "Sign up with Facebook"; + +//? -> Company Registration +String comRegTitle = "Welcome"; +String comSubTitle = "Enter Company or individual credentials to proceed"; + +String comName = "Enter Company Name"; +String comEmail = "example@companyName.com"; +String comAddress = "Enter Address of the company"; +String comPhone = "Enter phone number of company"; +String comCity = "Enter City e.g Mogadishu"; +String comCountry = "Enter Country e.g Somalia"; + + +String comAddresses = "Location:"; +String comIndustry = "Industry Type:"; diff --git a/lib/main.dart b/lib/main.dart index b373eae..a4e5362 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -5,6 +5,8 @@ import 'package:job_finder/views/pages/applied_page.dart'; import 'package:job_finder/views/pages/home_page.dart'; import 'package:job_finder/views/pages/login_page.dart'; import 'package:job_finder/views/pages/on_boarding.dart'; +import 'package:job_finder/views/pages/registrations/conpany.dart'; +import 'package:job_finder/views/pages/registrations/user_reg.dart'; import 'package:job_finder/views/pages/user_type_page.dart'; import 'consts/colors.dart'; @@ -25,7 +27,7 @@ class JobFinder extends StatelessWidget { scaffoldBackgroundColor: const Color(0xfff4f4f4) ), debugShowCheckedModeBanner: false, - home: OnBoarding(), + home: const OnBoarding(), ); } } diff --git a/lib/util/helpers/custom_text_field.dart b/lib/util/helpers/custom_text_field.dart new file mode 100644 index 0000000..97f269a --- /dev/null +++ b/lib/util/helpers/custom_text_field.dart @@ -0,0 +1,61 @@ +import 'package:flutter/material.dart'; +import 'package:font_awesome_flutter/font_awesome_flutter.dart'; +import 'package:job_finder/mixins/input_border_decoration.dart'; +import '../../consts/colors.dart'; +import '../../mixins/messages.dart'; +class CustomTextField extends StatelessWidget + with TextFieldBorderDecorator, Messages { + const CustomTextField({ + Key? key, + required this.txtInputType, + required this.hintText, + required this.prefixIcon, + this.obscureTxt, + this.isHidenTxt, + this.showOrHidePassword, + }); + + final TextInputType txtInputType; + final String hintText; + final Icon prefixIcon; + final bool? obscureTxt; + final bool? isHidenTxt; + final VoidCallback? showOrHidePassword; + + @override + Widget build(BuildContext context) { + bool isPasswordType = txtInputType == TextInputType.visiblePassword; + + return Container( + margin: EdgeInsets.symmetric(horizontal: 10), + decoration: BoxDecoration( + color: Colors.grey[300], + borderRadius: BorderRadius.circular(4), + ), + child: TextFormField( + keyboardType: txtInputType, + textAlign: TextAlign.start, + obscureText: obscureTxt ?? false, + decoration: InputDecoration( + contentPadding: EdgeInsets.fromLTRB(10, 14, 10, 10), + border: InputBorder.none, + focusedBorder: InputBorder.none, + hintText: hintText, + + suffixIcon: isPasswordType + ? (isHidenTxt ?? false + ? IconButton( + icon: FaIcon(FontAwesomeIcons.eye), + onPressed: showOrHidePassword, + ) + : IconButton( + icon: FaIcon(FontAwesomeIcons.eyeSlash), + onPressed: showOrHidePassword, + )) + : null, + prefixIcon: prefixIcon, + ), + ), + ); + } +} diff --git a/lib/util/profile.dart b/lib/util/profile.dart index d43dc98..fc8da9f 100644 --- a/lib/util/profile.dart +++ b/lib/util/profile.dart @@ -7,19 +7,6 @@ class ProfileImage extends StatelessWidget { final double? paddingAll; - const ProfileImage( - {super.key, - required this.imagePath, - this.color, - this.paddingAll, - }); - - @override - Widget build(BuildContext context) { - return CircleAvatar( - radius: 60, - backgroundColor: color ?? Colors.white, - final bool asBackgroundImage; final double radius; const ProfileImage({ diff --git a/lib/views/components/login_mode_profile.dart b/lib/views/components/login_mode_profile.dart index f1a3887..29c679f 100644 --- a/lib/views/components/login_mode_profile.dart +++ b/lib/views/components/login_mode_profile.dart @@ -20,7 +20,7 @@ class LoginModeProfile extends StatelessWidget { children: [ Padding( padding: const EdgeInsets.only(top: 10), - child: ProfileImage(imagePath: "assets/google.png",imgHeight: 20,imgWidth: 20), + child: ProfileImage(imagePath: "assets/google.png"), ), SizedBox(height: 4,), diff --git a/lib/views/pages/home_page.dart b/lib/views/pages/home_page.dart index a6033d0..08be5a2 100644 --- a/lib/views/pages/home_page.dart +++ b/lib/views/pages/home_page.dart @@ -25,64 +25,19 @@ import '../components/job_header.dart'; import '../components/login_mode_profile.dart'; -class Home extends StatelessWidget with BuildListViewJobCard { - const Home({super.key}); - static var categories = [ - "Software Engineering", - "UI/UX Designer", - "Database Admin", - "Graphic Designer", - "Analytical", - "Help Desk" - ]; - static List jobs = [ - Job( - jobTitle: "Agency Business Lead", - corporation: "Google, Inc", - companyLogoPath: "assets/google.png", - jobDescription: - "In publishing and graphic design, Lorem ipsum is a placeholder text commonly used to demonstrate the visual form of a document or a typeface without relying", - numberOfApplicants: 19, - timePosted: - timeago.format(DateTime.now().subtract(Duration(minutes: 6)))), - Job( - jobTitle: "Software Tester", - corporation: "Afro Tech", - companyLogoPath: "assets/afro.png", - jobDescription: - "In publishing and graphic design, Lorem ipsum is a placeholder text commonly used to demonstrate", - numberOfApplicants: 100, - timePosted: timeago.format(DateTime.now().subtract(Duration(days: 2)))), - - - Job(jobTitle: "Social Media Marketer", corporation: "Hilaal, Inc", companyLogoPath: "assets/hilal.png", - jobDescription: "In publishing and graphic design, Lorem ipsum is a placeholder text commonly used to demonstrate", - numberOfApplicants: 300 , - softSkills: ["Design","Teaching","Blender","Copy Writing","Canva"], - about: "We are seeking a talented Social Media Marketer to elevate our brand's online presence and engagement. In this role, you'll be responsible for crafting captivating content, managing social media platforms, and driving meaningful interactions with our target audience. Your creative approach and strategic thinking will play a pivotal role in expanding our brand's influence in the digital landscape. As a Social Media Marketer, you'll have the exciting opportunity to develop and implement dynamic social media strategies across various platforms. Your eye for engaging visuals and ability to craft compelling captions will help us effectively convey our brand's message and values. By staying up-to-date with the latest social media trends, you'll ensure our content remains fresh and relevant. Join our team and shape the way our audience perceives and engages with our brand on social media.", - timePosted: timeago.format(DateTime.now().subtract(Duration(days: 2)))), - Job( - jobTitle: "Web Developer", - corporation: "Tombal ICT", - companyLogoPath: "assets/hilal.png", - jobDescription: - "In publishing and graphic design, Lorem ipsum is a placeholder text commonly used to demonstrate", - numberOfApplicants: 300, - - timePosted: timeago.format(DateTime.now().subtract(Duration(days: 6)))) - -class Home extends StatefulWidget { + + class Home extends StatefulWidget { const Home({super.key}); @override State createState() => _HomeState(); -} + } -class _HomeState extends State with BottomNavigationBarMixin { + class _HomeState extends State with BottomNavigationBarMixin { final pages=[ - HomePage(), - AppliedPage(), + HomePage(), + AppliedPage(), ]; int currentIndex=0; @@ -90,151 +45,153 @@ class _HomeState extends State with BottomNavigationBarMixin { @override Widget build(BuildContext context) { - return Scaffold( - backgroundColor: Color(0xfff4f4f4), - appBar: AppBar( - backgroundColor: colors['white-color'], - foregroundColor: colors['secondary'], - centerTitle: true, - title: CText( - text: "Job Finder", - decorations: TextDecorations( - color: colors['secondary'] as Color, - weight: FontWeight.bold, - fontSize: 20), - ), - actions: [ - IconButton(onPressed: () { - showSearch(context: context, delegate: JobSearchDelegate(jobList: HomePage.jobs)); - }, icon: Icon(Icons.search)), - IconButton(onPressed: () {}, icon: Icon(Icons.refresh)), - ], - ), - bottomNavigationBar: curvedNavigationBar(currentIndex, - onClickIndex: (index){ - if(index>1) - return; - setState(() { - currentIndex=index; - }); - } - - ), - drawer: Drawer( - backgroundColor: Colors.white, - width: 230, - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - SizedBox( - width: double.maxFinite, - height: 280, - child: DrawerHeader( - decoration: BoxDecoration( - color: colors['primary']!.withOpacity(0.8) as Color, - borderRadius: - BorderRadius.only(bottomRight: Radius.circular(80))), - padding: EdgeInsets.all(0), - margin: EdgeInsets.all(0), - child: LoginModeProfile( - ), - ), - ), - Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - ListView.builder( - itemCount: menus.length, - shrinkWrap: true, - primary: false, - itemBuilder: (_,index){ - var menu=menus[index]; - return ListTile( - onTap: menu['onClick'] != null - ? ()=> menu['onClick'](context) - : null, - iconColor: colors['primary']!.withOpacity(0.7), - leading: menu['menuIcon'], - title: CText(text: menu['menuTitle'], - decorations: TextDecorations( - fontSize: 18, - family: "Poppins Medium" - ),), - trailing: menu['trailing'], - ); - }) - - ], - ) - ], - ), - ), - body: pages[currentIndex], - ); + return Scaffold( + backgroundColor: Color(0xfff4f4f4), + appBar: AppBar( + backgroundColor: colors['white-color'], + foregroundColor: colors['secondary'], + centerTitle: true, + title: CText( + text: "Job Finder", + decorations: TextDecorations( + color: colors['secondary'] as Color, + weight: FontWeight.bold, + fontSize: 20), + ), + actions: [ + IconButton(onPressed: () { + showSearch(context: context, delegate: JobSearchDelegate(jobList: HomePage.jobs)); + }, icon: Icon(Icons.search)), + IconButton(onPressed: () {}, icon: Icon(Icons.refresh)), + ], + ), + bottomNavigationBar: curvedNavigationBar(currentIndex, + onClickIndex: (index){ + if(index>1) + return; + setState(() { + currentIndex=index; + }); } -} + ), + drawer: Drawer( + backgroundColor: Colors.white, + width: 230, + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + SizedBox( + width: double.maxFinite, + height: 280, + child: DrawerHeader( + decoration: BoxDecoration( + color: colors['primary']!.withOpacity(0.8) as Color, + borderRadius: + BorderRadius.only(bottomRight: Radius.circular(80))), + padding: EdgeInsets.all(0), + margin: EdgeInsets.all(0), + child: LoginModeProfile( + ), + ), + ), + Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + ListView.builder( + itemCount: menus.length, + shrinkWrap: true, + primary: false, + itemBuilder: (_,index){ + var menu=menus[index]; + return ListTile( + onTap: menu['onClick'] != null + ? ()=> menu['onClick'](context) + : null, + iconColor: colors['primary']!.withOpacity(0.7), + leading: menu['menuIcon'], + title: CText(text: menu['menuTitle'], + decorations: TextDecorations( + fontSize: 18, + family: "Poppins Medium" + ),), + trailing: menu['trailing'], + ); + }) + + ], + ) + ], + ), + ), + body: pages[currentIndex], + ); + } + } -class JobSearchDelegate extends SearchDelegate with BuildListViewJobCard,NoDataErrorMixin{ + + class JobSearchDelegate extends SearchDelegate with BuildListViewJobCard,NoDataErrorMixin{ final List jobList; JobSearchDelegate({required this.jobList}):super( keyboardType: TextInputType.text -); + ); -@override + @override String? get searchFieldLabel => "Search Job..."; @override TextStyle? get searchFieldStyle => TextStyle( - color: colors['secondary'], - fontFamily: "Poppins Medium", - fontSize: 18 + color: colors['secondary'], + fontFamily: "Poppins Medium", + fontSize: 18 ); @override List? buildActions(BuildContext context) { - return[ - IconButton(onPressed: (){ - query=''; - }, icon: FaIcon(FontAwesomeIcons.xmark)) - ]; + return[ + IconButton(onPressed: (){ + query=''; + }, icon: FaIcon(FontAwesomeIcons.xmark)) + ]; } @override Widget? buildLeading(BuildContext context) { - return IconButton(onPressed: (){ - close(context, null); - }, icon: FaIcon(FontAwesomeIcons.angleLeft)); + return IconButton(onPressed: (){ + close(context, null); + }, icon: FaIcon(FontAwesomeIcons.angleLeft)); } @override Widget buildResults(BuildContext context) { - return buildJobListView(context, jobList); + return buildJobListView(context, jobList); } @override Widget buildSuggestions(BuildContext context) { - List matchedResults=[]; - for(var item in jobList) { - if(item.jobTitle.toLowerCase().contains(query.toLowerCase())) { - matchedResults.add(item); - } - } - if(matchedResults.isNotEmpty) { - return buildJobListView(context, matchedResults); - } - - return noDataError(context,close); + List matchedResults=[]; + for(var item in jobList) { + if(item.jobTitle.toLowerCase().contains(query.toLowerCase())) { + matchedResults.add(item); + } + } + if(matchedResults.isNotEmpty) { + return buildJobListView(context, matchedResults); } + return noDataError(context,close); + } + + + + } -} diff --git a/lib/views/pages/login_page.dart b/lib/views/pages/login_page.dart index a332744..a91ae8a 100644 --- a/lib/views/pages/login_page.dart +++ b/lib/views/pages/login_page.dart @@ -157,6 +157,7 @@ class _LoginState extends State with TextFieldBorderDecorator, Messages { icon: FaIcon(FontAwesomeIcons.eyeSlash), onPressed: _showOrHidePassword, ), + hintText: "Your Passcode", border: OutlineInputBorder(), enabledBorder: decorateBorder( diff --git a/lib/views/pages/registrations/conpany.dart b/lib/views/pages/registrations/conpany.dart new file mode 100644 index 0000000..94821ac --- /dev/null +++ b/lib/views/pages/registrations/conpany.dart @@ -0,0 +1,290 @@ +import 'package:flutter/material.dart'; +import 'package:font_awesome_flutter/font_awesome_flutter.dart'; +import 'package:job_finder/consts/texts.dart'; +import 'package:job_finder/util/helpers/custom_text_field.dart'; +import 'package:job_finder/util/helpers/text_helper.dart'; +import 'package:job_finder/util/text.dart'; + +import '../../../consts/colors.dart'; +import '../../../util/buton.dart'; + +class RegisterCompany extends StatelessWidget { + const RegisterCompany({super.key}); + + @override + Widget build(BuildContext context) { + final TextEditingController _textEditingController = TextEditingController(); + bool _isDropdownVisible = false; + List _options = ['Option 1', 'Option 2', 'Option 3', 'Option 4']; + String _selectedOption = ''; + bool _termsAndCondChecked = false; + return SafeArea( + child: Scaffold( + body: SingleChildScrollView( + child: Column( + children: [ + Container( + decoration: BoxDecoration(boxShadow: [ + BoxShadow( + color: Colors.white.withOpacity(0.8), // Shadow color + spreadRadius: 6, // Spread radius + blurRadius: 0, // Blur radius + offset: Offset(0, 10), // Offset in x and y directions + ), + ]), + margin: EdgeInsets.symmetric(horizontal: 20, vertical: 45), + padding: EdgeInsets.all(10), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + // mainAxisAlignment: MainAxisAlignment.start, + children: [ + Row( + children: [ + Expanded( + child: Container( + margin: EdgeInsets.only(left: 10), + // color: Colors.grey, + child: Column( + children: [ + Align( + alignment: Alignment.centerLeft, + child: CText( + text: comRegTitle, + decorations: TextDecorations( + fontSize: 24, + family: 'Roboto-Bold', + color: Colors.black, + ), + ), + ), + CText( + text: comSubTitle, + decorations: TextDecorations( + fontSize: 16, family: 'Roboto-Light'), + ), + ], + ), + ), + ), + Expanded( + child: Container( + child: Column( + children: [ + Center( + child: Container( + height: 80, + width: 80, + + margin: + const EdgeInsets.only(left: 16, top: 20), + decoration: BoxDecoration( + // color: Colors.red + ), + child: Stack( + children: [ + ClipRRect( + borderRadius: BorderRadius.circular(60), + child: Image.asset("assets/img_holder.png"), + ), + Positioned( + top: 40, + right: 0, + left: 45, + child: Container( + decoration: BoxDecoration( + color: colors['primary'], + shape: BoxShape.circle, + ), + child: IconButton( + onPressed: () { + // Handle camera icon press + }, + color: Colors.red, + icon: Icon(Icons.camera_alt_outlined,color: Colors.yellow,), + ), + ), + ), + ], + ), + ), + ), + ], + ), + )), + ], + ), + const SizedBox( + height: 20, + ), + CustomTextField( + txtInputType: TextInputType.text, + hintText: comName, + prefixIcon: Icon(FontAwesomeIcons.mountainCity)), + + const SizedBox( + height: 16, + ), + CustomTextField( + txtInputType: TextInputType.number, + hintText: comPhone, + prefixIcon: Icon(Icons.phone_outlined)), + const SizedBox( + height: 16, + ), + CustomTextField( + txtInputType: TextInputType.emailAddress, + hintText: comEmail, + prefixIcon: Icon(Icons.alternate_email)), + const SizedBox( + height: 16, + ), + const SizedBox(height: 8,), + Container( + margin: EdgeInsets.only(left: 10), + child: CText( + text: comAddresses, + decorations: TextDecorations( + fontSize: 16, family: 'Roboto-Light'), + ), + ), + const SizedBox(height: 8,), + CustomTextField( + txtInputType: TextInputType.text, + hintText: comCity, + prefixIcon: Icon(Icons.location_city_rounded), + ), + const SizedBox( + height: 16, + ), + + CustomTextField( + txtInputType: TextInputType.text, + hintText: comAddress, + prefixIcon: Icon(FontAwesomeIcons.addressBook)), + const SizedBox( + height: 16, + ), + CustomTextField( + txtInputType: TextInputType.text, + hintText: comCountry, + prefixIcon: Icon(Icons.flag), + ), + const SizedBox( + height: 16, + ), + Container( + margin: EdgeInsets.only(left: 10), + child: CText( + text: comIndustry, + decorations: TextDecorations( + fontSize: 16, family: 'Roboto-Light'), + ), + ), + const SizedBox(height: 16,), + TextField( + controller: _textEditingController, + onTap: () { + _isDropdownVisible = !_isDropdownVisible; + //Note: -> Add State make visible to the dropdown item + }, + decoration: const InputDecoration( + contentPadding: EdgeInsets.fromLTRB(10, 14, 10, 10), + // border: InputBorder.none, + // focusedBorder: InputBorder.none, + hintText: 'Select an option', + suffixIcon: Icon(Icons.arrow_drop_down), + ), + ), + if (_isDropdownVisible) + Container( + constraints: BoxConstraints(maxHeight: 150.0), + + child: ListView.builder( + itemCount: _options.length, + itemBuilder: (context, index) { + return InkWell( + onTap: () { + _selectedOption = _options[index]; + _textEditingController.text = _selectedOption; + _isDropdownVisible = false; + FocusScope.of(context).unfocus(); // Close the keyboard + //Note: -> Add State make visible to the dropdown item + }, + child: Padding( + padding: EdgeInsets.all(8.0), + child: Text(_options[index]), + ), + ); + }, + ), + ), + const SizedBox(height: 12,), + Row( + children: [ + Checkbox( + value: _termsAndCondChecked, + onChanged: (bool? newValue) { + //? -> Add here the state to check the checkbox + }, + ), + RichText( + text: TextSpan( + children: [ + TextSpan( + text: signUpConditionTxt, + style: TextStyle( + fontSize: 16, + fontFamily: 'Poppins-Light', + color: Colors.black)), + WidgetSpan( + child: SizedBox( + width: 5, + )), + WidgetSpan( + child: InkWell( + onTap: () { + // Handle the onTap action for the terms and conditions + }, + child: CText( + text: tTermsAndConditions, + // Apply the desired style for the TextButton-like text + decorations: TextDecorations( + fontSize: 16, + color: Colors.blue, + ), + ), + ), + ), + ], + ), + ), + ], + ), + const SizedBox(height: 8,), + Padding( + padding: const EdgeInsets.all(8.0), + child: CButton( + width: double.maxFinite, + padding: 14, + radius: 4, + backgroundColor: colors['secondary'], + widget: Center( + child: CText( + text: tRegBtn, + decorations: TextDecorations( + fontSize: 20, + family: 'Roboto-Regular', + color: Colors.white), + ), + )), + ), + ], + ), + ) + ], + ), + ), + ), + ); + } +} diff --git a/lib/views/pages/registrations/user_reg.dart b/lib/views/pages/registrations/user_reg.dart new file mode 100644 index 0000000..e8969ea --- /dev/null +++ b/lib/views/pages/registrations/user_reg.dart @@ -0,0 +1,215 @@ +import 'package:flutter/gestures.dart'; +import 'package:flutter/material.dart'; +import 'package:job_finder/consts/texts.dart'; +import 'package:job_finder/util/buton.dart'; +import 'package:job_finder/util/helpers/custom_text_field.dart'; +import 'package:job_finder/util/helpers/text_helper.dart'; +import 'package:job_finder/util/icon_image.dart'; +import 'package:job_finder/util/text.dart'; + +import '../../../consts/colors.dart'; +import '../login_page.dart'; + +class UserReg extends StatelessWidget { + const UserReg({super.key}); + + @override + Widget build(BuildContext context) { + bool _termsAndCondChecked = false; + return Scaffold( + body: SafeArea( + child: SingleChildScrollView( + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + /* Top Title Texts */ + Container( + margin: EdgeInsets.only(top: 50, left: 10), + child: CText( + text: signUpTxt, + decorations: TextDecorations( + fontSize: 26, + family: 'Roboto-Bold', + weight: FontWeight.bold, + color: Colors.black), + )), + const SizedBox( + height: 10, + ), + Container( + margin: const EdgeInsets.only(top: 10, left: 10), + child: CText( + text: welcomeTxt, + decorations: TextDecorations( + fontSize: 16, + family: 'Poppins-Light', + weight: FontWeight.normal), + )), + const SizedBox( + height: 16, + ), + const SizedBox( + height: 5, + ), + CustomTextField( + txtInputType: TextInputType.text, + hintText: signUpFullNameTft, + prefixIcon: Icon(Icons.person_outline_rounded)), + const SizedBox( + height: 16, + ), + const SizedBox( + height: 5, + ), + const CustomTextField( + txtInputType: TextInputType.emailAddress, + hintText: tEmail, + prefixIcon: Icon(Icons.email_outlined)), + const SizedBox( + height: 16, + ), + const SizedBox( + height: 5, + ), + const SizedBox( + height: 5, + ), + const CustomTextField( + txtInputType: TextInputType.visiblePassword, + hintText: tPassTxt, + prefixIcon: Icon(Icons.password)), + const SizedBox( + height: 16, + ), + const SizedBox( + height: 5, + ), + const CustomTextField( + txtInputType: TextInputType.phone, + hintText: tPhone, + prefixIcon: Icon(Icons.mobile_friendly)), + const SizedBox( + height: 16, + ), + const SizedBox( + height: 5, + ), + const CustomTextField( + txtInputType: TextInputType.datetime, + hintText: tSelectCity, + prefixIcon: Icon(Icons.location_city)), + const SizedBox( + height: 12, + ), + Row( + children: [ + Checkbox( + value: _termsAndCondChecked, + onChanged: (bool? newValue) { + //? -> Add here the state to check the checkbox + }, + ), + RichText( + text: TextSpan( + children: [ + TextSpan( + text: signUpConditionTxt, + style: TextStyle( + fontSize: 16, + fontFamily: 'Poppins-Light', + color: Colors.black)), + WidgetSpan( + child: SizedBox( + width: 5, + )), + WidgetSpan( + child: InkWell( + onTap: () { + // Handle the onTap action for the terms and conditions + }, + child: CText( + text: tTermsAndConditions, + // Apply the desired style for the TextButton-like text + decorations: TextDecorations( + fontSize: 16, + color: Colors.blue, + ), + ), + ), + ), + ], + ), + ), + ], + ), + Padding( + padding: const EdgeInsets.all(8.0), + child: CButton( + width: double.maxFinite, + padding: 14, + radius: 4, + backgroundColor: colors['primary'], + widget: Center( + child: CText( + text: tRegBtn, + decorations: TextDecorations( + fontSize: 20, + family: 'Roboto-Regular', + color: Colors.white), + ), + )), + ), + const SizedBox( + height: 5, + ), + Container( + margin: EdgeInsets.only(left: 12,right: 12), + child: Column( + children: [ + Center( + child: CText( + text: "OR", + decorations: TextDecorations(fontSize: 20), + )), + const SizedBox( + height: 12, + ), + SizedBox( + height: 45, + width: double.infinity, + child: OutlinedButton.icon( + onPressed: () {}, + icon: IconImage( + iconImagePath: "assets/google.png", + width: 40, + backgroundColor: Colors.transparent, + ), + label: CText(text: signUpWithGoogle,decorations: TextDecorations(fontSize: 18,),)), + ), + const SizedBox(height: 12,), + Text.rich( + TextSpan( + text: signUpHaveAnAccountTxt.toUpperCase(), + style: TextStyle(fontSize: 14,fontFamily: "Roboto-Bold"), + children: [ + TextSpan( + text: signUpLoginTxt.toUpperCase(), + style:TextStyle(color: colors['primary'],fontSize: 14,fontFamily: "Roboto-Bold"), + recognizer: TapGestureRecognizer() + ..onTap = () { + Navigator.push(context, MaterialPageRoute(builder: (context) => Login())); + } + ) + ] + ), + ) + ], + ), + ) + ], + ), + ), + ), + ); + } +} diff --git a/lib/views/pages/user_type_page.dart b/lib/views/pages/user_type_page.dart index 436e468..e7b1cf1 100644 --- a/lib/views/pages/user_type_page.dart +++ b/lib/views/pages/user_type_page.dart @@ -7,6 +7,8 @@ import 'package:job_finder/util/buton.dart'; import 'package:job_finder/util/helpers/text_helper.dart'; import 'package:job_finder/util/radio_listile_button.dart'; import 'package:job_finder/util/text.dart'; +import 'package:job_finder/views/pages/registrations/conpany.dart'; +import 'package:job_finder/views/pages/registrations/user_reg.dart'; class UserTypePage extends StatefulWidget { const UserTypePage({super.key}); @@ -103,6 +105,14 @@ class _UserTypePageState extends State { CButton( onClicked: (){ if(isSelected){ + if(user_profile == USER_PROFILE.company){ + Navigator.push(context, MaterialPageRoute(builder: (context) => RegisterCompany())); + } + else{ + if(user_profile == USER_PROFILE.applicant){ + Navigator.push(context, MaterialPageRoute(builder: (context) => UserReg())); + } + } // route registration page, with the value of Selected Profile return; } diff --git a/pubspec.lock b/pubspec.lock index 93784ef..c268e26 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -37,10 +37,10 @@ packages: dependency: transitive description: name: collection - sha256: "4a07be6cb69c84d677a6c3096fcf960cc3285a8330b4603e0d463d15d9bd934c" + sha256: f092b211a4319e98e5ff58223576de6c2803db36221657b46c82574721240687 url: "https://pub.dev" source: hosted - version: "1.17.1" + version: "1.17.2" cupertino_icons: dependency: "direct main" description: @@ -107,15 +107,6 @@ packages: url: "https://pub.dev" source: hosted version: "0.18.1" - - js: - dependency: transitive - description: - name: js - sha256: f2c445dce49627136094980615a031419f7f3eb393237e4ecd97ac15dea343f3 - url: "https://pub.dev" - source: hosted - version: "0.6.7" line_awesome_flutter: dependency: "direct main" description: @@ -124,7 +115,6 @@ packages: url: "https://pub.dev" source: hosted version: "2.0.0" - lints: dependency: transitive description: @@ -137,18 +127,18 @@ packages: dependency: transitive description: name: matcher - sha256: "6501fbd55da300384b768785b83e5ce66991266cec21af89ab9ae7f5ce1c4cbb" + sha256: "1803e76e6653768d64ed8ff2e1e67bea3ad4b923eb5c56a295c3e634bad5960e" url: "https://pub.dev" source: hosted - version: "0.12.15" + version: "0.12.16" material_color_utilities: dependency: transitive description: name: material_color_utilities - sha256: d92141dc6fe1dad30722f9aa826c7fbc896d021d792f80678280601aff8cf724 + sha256: "9528f2f296073ff54cb9fee677df673ace1218163c3bc7628093e7eed5203d41" url: "https://pub.dev" source: hosted - version: "0.2.0" + version: "0.5.0" meta: dependency: transitive description: @@ -190,10 +180,10 @@ packages: dependency: transitive description: name: source_span - sha256: dd904f795d4b4f3b870833847c461801f6750a9fa8e61ea5ac53f9422b31f250 + sha256: "53e943d4206a5e30df338fd4c6e7a077e02254531b138a15aec3bd143c1a8b3c" url: "https://pub.dev" source: hosted - version: "1.9.1" + version: "1.10.0" stack_trace: dependency: transitive description: @@ -230,10 +220,10 @@ packages: dependency: transitive description: name: test_api - sha256: eb6ac1540b26de412b3403a163d919ba86f6a973fe6cc50ae3541b80092fdcfb + sha256: "75760ffd7786fffdfb9597c35c5b27eaeec82be8edfb6d71d32651128ed7aab8" url: "https://pub.dev" source: hosted - version: "0.5.1" + version: "0.6.0" timeago: dependency: "direct main" description: @@ -250,6 +240,14 @@ packages: url: "https://pub.dev" source: hosted version: "2.1.4" + web: + dependency: transitive + description: + name: web + sha256: dc8ccd225a2005c1be616fe02951e2e342092edf968cf0844220383757ef8f10 + url: "https://pub.dev" + source: hosted + version: "0.1.4-beta" sdks: - dart: ">=3.0.6 <4.0.0" + dart: ">=3.1.0-185.0.dev <4.0.0" flutter: ">=1.17.0"