ResponsiveFlowLayout class

Un widget de layout responsivo que organiza sus hijos en múltiples filas.

Similar a Wrap, pero los hijos en cada fila se expanden para llenar el espacio horizontal disponible, respetando sus FlowItem.minWidth y FlowItem.maxWidth.

Este widget es especialmente útil para crear layouts de tarjetas o elementos que necesitan mantener un tamaño mínimo pero pueden expandirse para aprovechar el espacio disponible.

Ejemplo de uso:

ResponsiveFlowLayout(
  spacing: 16.0,
  runSpacing: 16.0,
  children: [
    FlowItem(
      minWidth: 200,
      maxWidth: 400,
      child: Card(child: Text('Item 1')),
    ),
    FlowItem(
      minWidth: 150,
      child: Card(child: Text('Item 2')),
    ),
  ],
)
Inheritance

Constructors

ResponsiveFlowLayout({Key? key, required List<FlowItem> children, double spacing = 8.0, double runSpacing = 8.0, HorizontalFlowAxisAlignment horizontalAxisAlignment = HorizontalFlowAxisAlignment.start, VerticalFlowAxisAlignment verticalAxisAlignment = VerticalFlowAxisAlignment.start})
Crea un ResponsiveFlowLayout con los parámetros especificados.
const

Properties

children List<FlowItem>
La lista de items a mostrar.
final
hashCode int
The hash code for this object.
no setterinherited
horizontalAxisAlignment HorizontalFlowAxisAlignment
La alineación horizontal de los elementos en cada fila.
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
runSpacing double
El espaciado vertical entre filas.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
spacing double
El espaciado horizontal entre elementos en una misma fila.
final
verticalAxisAlignment VerticalFlowAxisAlignment
La alineación vertical de todos los elementos en el diseño.
final

Methods

build(BuildContext context) Widget
Describes the part of the user interface represented by this widget.
override
createElement() StatelessElement
Creates a StatelessElement to manage this widget's location in the tree.
inherited
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