Profile class

Example:

Profile(
  text: avatar[index],
  radius: 35,
  randomGradient: true,
  randomColor: false,
)
Inheritance
Available extensions

Constructors

Profile.new({Key? key, required double? radius, required String? text, OnPickerChange? onPickerChange, OnPickerChangeWeb? onPickerChangeWeb, OnPickerCompleted? onPickerCompleted, OnFilePickerCompleted? onFilePickerCompleted, OnBytesPickerCompleted? onBytesPickerCompleted, String? image, String? imageNetwork, Gradient? gradientBackgroundColor, double elevation = 0, Color? shadowColor = Colors.black, bool isBorderAvatar = false, Color? backgroundColor = Colors.green, BottomSheetStyles? bottomSheetStyles, Gradient? gradientWidthBorder = const LinearGradient(colors: [Colors.blue, Colors.deepPurple]), Color iconColor = Colors.black, double widthBorder = 5.0, Color backgroundColorCamera = Colors.white, IconData? icon = Icons.camera, OptionsCrop? optionsCrop, OptionsCropWindMacLinux? optionsCropWindMacLinux, TextStyle? style = const TextStyle(fontSize: 25, color: Colors.white, fontWeight: FontWeight.bold), bool randomColor = true, bool randomGradient = false, bool useMaterialColorForGradient = true, bool mixColorForGradient = false, Widget? child})

Properties

backgroundColor Color?
backgroundColor: The background color of the profile (can be null).
getter/setter pair
backgroundColorCamera Color
backgroundColorCamera: Color background picker
final
bottomSheetStyles BottomSheetStyles?
BottomSheetStyles: Configuration for customizing the bottom sheet's appearance and behavior.
final
child Widget?
child: The child widget to display inside the avatar.
final
elevation double
elevation: Elevation color.
final
gradientBackgroundColor Gradient?
gradientBackgroundColor: The gradient background of the profile (can be null).
getter/setter pair
gradientWidthBorder Gradient?
gradientWidthBorder: The gradient for the profile's border (default: linear gradient from blue to deep purple).
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
icon IconData?
icon: Icon picker
final
iconColor Color
iconColor: Color picker icon
final
image String?
image: The imageAssets for the profile.
final
imageNetwork String?
imageNetwork: The image URL for the profile.
final
isBorderAvatar bool
The isBorderAvatar parameter, if true, creates a border for the avatar. This border contains a circular border with a default width of 5 and a color of LinearGradient. If this parameter is false, no border will be created for the avatar.
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
mixColorForGradient bool
mixColorForGradient: Mix color for gradient. Default = false
final
onBytesPickerCompleted OnBytesPickerCompleted?
onBytesPickerCompleted: Callback when bytes are ready.
final
onFilePickerCompleted OnFilePickerCompleted?
onFilePickerCompleted: Callback when file is ready.
final
onPickerChange OnPickerChange?
onPickerChange: An optional property in the Picker class that allows you to call a callback when the picker value changes. This callback has a parameter named value that passes the new value of the picker to it.
final
onPickerChangeWeb OnPickerChangeWeb?
onPickerChangeWeb: An optional property in the Picker class that allows you to call a callback when the picker value changes.
final
onPickerCompleted OnPickerCompleted?
onPickerCompleted: Callback when both file and bytes are available.
final
optionsCrop OptionsCrop?
OptionsCrop: Configuration options for image cropping functionality.
final
optionsCropWindMacLinux → OptionsCropWindMacLinux?
final
radius double?
radius: The radius of the profile radius = 35.
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
shadowColor Color?
shadowColor: Create shadow widget (can be null).
final
style TextStyle?
style: The text style (default: font size 25, white color, and bold).
final
text String?
text: The text to display on the profile.
final
useMaterialColorForGradient bool
useMaterialColorForGradient: Use material color for gradient. Default = true
final
widthBorder double
widthBorder: The border width of the profile widthBorder = 0.0.
final

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() State<Profile>
Creates the mutable state for this widget at a given location in the tree.
override
debugDescribeChildren() List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a one-line detailed description of the object.
inherited
toStringShort() String
A short, textual description of this widget.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited