ColorfulDotsLoader class

ColorfulDotsLoader is a loading animation widget that displays colorful dots sliding horizontally.

The dots move back and forth within a container, with each dot following a staggered animation pattern. The animation loops infinitely, creating a smooth and dynamic effect.

Parameters:

  • colors : List
  • duration : int - the duration of the animation cycle in milliseconds (default is 1500).
  • loadingColor : Color - the color of the "Loading" text (default is white).
  • dotSize : double - the size of each dot in the animation (default is 27).
  • borderColor : Color - the color of the border around each dot (default is white).
  • height : double - the height of the entire loader container (default is 40).
  • width : double - the width of the entire loader container (default is 260).
  • fontSize : double - the font size of the "Loading" text (default is 20).

Example:

ColorfulDotsLoader(
  colors: [Colors.red, Colors.green, Colors.blue, Colors.yellow, Colors.pink, Colors.purple],
  duration: 1500,
  loadingColor: Colors.blue,
  dotSize: 27,
  borderColor: Colors.red,
  height: 40,
  width: 260,
  fontSize: 20,
)
Inheritance

Constructors

ColorfulDotsLoader.new({Key? key, required List<Color> colors, int duration = 1500, Color loadingColor = Colors.white, double dotSize = 27, Color borderColor = Colors.white, double height = 40, double width = 260, double fontSize = 20})
const

Properties

borderColor Color
final
colors List<Color>
final
dotSize double
final
duration int
final
fontSize double
final
hashCode int
The hash code for this object.
no setterinherited
height double
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
loadingColor Color
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
width double
final

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() State<ColorfulDotsLoader>
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