ExpandableFab class

A stateful widget that creates an expandable Floating Action Button (FAB).

This widget allows the integration of multiple action buttons within a single FAB. The FAB can toggle between an open and closed state, revealing or hiding the action buttons.

Inheritance

Constructors

ExpandableFab({Color? closeBackgroundColor, double closeElevation = 4.0, bool initialOpen = false, required List<ActionButton> children, required double distance, Color? closeShadowColor, double? openElevation, Widget? closeIcon, Widget? openIcon, Key? key})
Constructs an ExpandableFab.
const

Properties

children List<ActionButton>
A list of action buttons that are displayed when the FAB is expanded.
final
closeBackgroundColor Color?
The background color of the FAB when it is in the closed state. If null, a default color is used.
final
closeElevation double
The elevation of the FAB when it is in the closed state. Defaults to 4.0 if not specified.
final
closeIcon Widget?
The icon displayed on the FAB when it is in its closed state. If null, a default icon may be used.
final
closeShadowColor Color?
The color of the shadow cast by the FAB when it is in the closed state. If null, the default shadow color is used.
final
distance double
The distance between the main FAB and the expanded action buttons.
final
hashCode int
The hash code for this object.
no setterinherited
initialOpen bool
Determines whether the FAB is open or closed initially.
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
openElevation double?
The elevation of the FAB when it is in the open state. If null, a default elevation may be applied.
final
openIcon Widget?
The icon displayed on the FAB when it is in its open state. If null, a default icon may be used.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

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