Flutter profile page ui design

 Today in this post we are going to make an attractive profile UI of flutter. In which there will be dashboard, Personal information, KYC information, Bank information, Withdrawal Transaction, order history, Account setting, Customer support, Logout and also there will be a detail screen of all this, on clicking its detail screen will open.


ProfileScreen.dart
  
  import 'package:ecom/profile_detail_screens/KYC_detail.dart';
import 'package:flutter/material.dart';

import 'home.dart';
import 'profile_detail_screens/Bank_detail.dart';
import 'profile_detail_screens/Personal_detail.dart';
import 'profile_detail_screens/dashboard_detail.dart';


class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      debugShowCheckedModeBanner: false,
      home: ProfileScreen(),
    );
  }
}

class ProfileScreen extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        backgroundColor: Colors.white,
        elevation: 0,
        toolbarHeight: 80,
        leading: Container(
          margin: EdgeInsets.all(6),
          decoration: BoxDecoration(
            shape: BoxShape.circle,
            color: Colors.white,
            border: Border.all(
              color: Colors.grey,
              width: 0.1,
            ),
          ),
          child: IconButton(
            icon: Icon(Icons.arrow_back, color: Colors.black),
            onPressed: () {
              Navigator.push(
                context,
                MaterialPageRoute(builder: (context) => Homesc()),
              );
            },
          ),
        ),
        centerTitle: true,
        title: Text("Profile", style: TextStyle(fontSize: 20, color: Color(0xff025dff))),
      ),
      backgroundColor: Colors.grey[200],
      body: Column(
        children: [
          Container(
            padding: EdgeInsets.all(16),
            color: Colors.white,
            child: Row(
              children: [
                CircleAvatar(
                  radius: 30,
                  backgroundColor: Colors.grey[300],
                  child: Icon(Icons.person, size: 30, color: Colors.black54),
                ),
                SizedBox(width: 12),
                Column(
                  crossAxisAlignment: CrossAxisAlignment.start,
                  children: [
                    Text("Welcome,", style: TextStyle(fontSize: 14)),
                    Text("Abhinav Arora", style: TextStyle(fontSize: 18, fontWeight: FontWeight.bold)),
                  ],
                ),
              ],
            ),
          ),

          SizedBox(height: 1),

          Expanded(
            child: Container(
              color: Colors.white,
              child: ListView(
                children: [
                  buildMenuItem(Icons.home, "Dashboard", context, Dashboard_detail()),
                  buildMenuItem(Icons.person, "Personal Information", context, PersonalDetail()),
                  buildMenuItem(Icons.verified_user, "KYC Information" ,context, KYCDetail()),
                  buildMenuItem(Icons.account_balance, "Bank Information", context ,BankDetailsScreen() ),
                  buildMenuItem(Icons.account_balance_wallet, "Wallet Transaction", context),
                  buildMenuItem(Icons.history, "Order History", context),
                  buildMenuItem(Icons.settings, "Account Setting", context),
                  buildMenuItem(Icons.support_agent, "Customer Support",context),
                  buildMenuItem(Icons.logout, "Logout", context,  null, Colors.red),
                ],
              ),
            ),
          ),
        ],
      ),
    );
  }

  Widget buildMenuItem(IconData icon, String title, BuildContext context, [Widget? screen, Color? iconColor]) {
    return ListTile(
      leading: Icon(icon, color: iconColor ?? Colors.black),
      title: Text(title, style: TextStyle(fontSize: 16)),
      trailing: Icon(Icons.arrow_forward_ios, size: 16),
      onTap: () {
        if (screen != null) {
          Navigator.push(
            context,
            MaterialPageRoute(builder: (context) => screen),
          );
        }
      },
    );
  }
}

Run

Create a file named Profile screen, paste the code given by us inside it and run it.
If you face any problem, you can also contact us.

Output  






If you want to buy its complete source code, then click on the payment button given below and make the payment. After making the payment, you can download its complete source code. And after downloading, you can input this project in your Android studio and after inputting, you can use it very easily. Even after that if you face any problem, you can contact us.

Post a Comment

0 Comments