FLUTTER ECOSYSTEM

zeshanghayoomi/flutter_user_profile_avatar

एक सरल विजेट जो नेटवर्क से लोड की गई छवि को गोलाकार प्रोफ़ाइल छवि के रूप में प्रदर्शित करता है और छवि लोड होने के दौरान एक गोलाकार प्रगति इंडिकेटर प्रदर्शित करता है। साथ ही, नोटिफिकेशन बबल को प्रदर्शित करने की क्षमता भी है।

flutter_user_profile_avatar प्रोजेक्ट कवर
Stars
3
Forks
0
अंतिम पुश (UTC)
8 अग॰ 2024
प्रोजेक्ट स्थिति
सक्रिय
Zeshan Hossein Ghayoomi GitHub avatar
GITHUB User

Zeshan Hossein Ghayoomi ↗

Flutter Mobile App Developer at BT

BTLondon
भाषाएँDartRubySwiftKotlinObjective-C

इस रिपॉज़िटरी के पैकेज

उपयोग की गई निर्भरताएँ

निर्भरता सूची 3 आइटम
  • flutter{"sdk":"flutter"}
  • cached_network_image^3.4.0
  • flutter_testडेवलपमेंट{"sdk":"flutter"}

मूल README

यह अंग्रेज़ी मूल स्नैपशॉट है। नवीनतम सामग्री GitHub पर देखें।

README खोलें / बंद करें

Flutter User Profile Avatar

A simple widget that display round profile picture where the picture is fetched from network and displays circular progress indicator whilst the image is being loaded. Also, has the ability to display notification bubble.

https://raw.githubusercontent.com/zeshanghayoomi/flutter_user_profile_avatar/master/repo_assets/simulator.gif

How to use


UserProfileAvatar(
        avatarUrl: 'https://picsum.photos/id/237/5000/5000',
        onAvatarTap: () {
          print('Avatar Tapped..');
        },
        notificationCount: 10,
        notificationBubbleTextStyle: TextStyle(
          fontSize: 30,
          color: Colors.white,
          fontWeight: FontWeight.bold,
        ),
        avatarSplashColor: Colors.purple,
        radius: 100,
        isActivityIndicatorSmall: false,
        avatarBorderData: AvatarBorderData(
          borderColor: Colors.white,
          borderWidth: 5.0,
        ),
      )

Properties

  • avatarUrl
    The url for the image, if this set to null or empty then an empty user avatar gets displayed by default.

https://raw.githubusercontent.com/zeshanghayoomi/flutter_user_profile_avatar/master/repo_assets/1.png
  • onAvatarTap
    Use this to perform any action when the avatar gets tapped.

  • notificationCount
    Pass an int to display the notification bubble. 99+ gets displayed if notification count was larger than 100.

  • notificationBubbleTextStyle
    Used to style the notification count, if null then the default one will be applied.

  • avatarSplashColor
    Splash color when user taps on the avatar.

  • radius
    Use this to size the avatar.

    • minimum default radius is 15
    • maximum default radius is 150
  • isActivityIndicatorSmall
    use this to display small/large circular progress indicator (native) when image is loading, default is true.


https://raw.githubusercontent.com/zeshanghayoomi/flutter_user_profile_avatar/master/repo_assets/2.png https://raw.githubusercontent.com/zeshanghayoomi/flutter_user_profile_avatar/master/repo_assets/3.png
  • avatarBorderData
    Use this to apply border width and color of the avatar.