StacListView class

A Stac model representing Flutter's ListView.separated widget.

A scrollable, linear array of widgets that are separated by separator widgets.

dart StacListView( children: {"type": "text", "data": "Item 1"}, {"type": "text", "data": "Item 2"} , separator: {"type": "sizedBox", "height": 8.0}, // Example separator scrollDirection: StacAxis.vertical, reverse: false, physics: StacScrollPhysics(type: 'bouncingScrollPhysics'), // Example physics padding: StacEdgeInsets.all(10.0), // ... other properties )

json { "type": "listView", "children": {"type": "text", "data": "Item 1"}, {"type": "text", "data": "Item 2"} , "separator": {"type": "sizedBox", "height": 8.0}, "scrollDirection": "vertical", "reverse": false, "physics": {"type": "bouncingScrollPhysics"}, "padding": {"all": 10.0} // ... other properties }

Inheritance
Available extensions
Annotations
  • @JsonSerializable.new()

Constructors

StacListView({StacAxis? scrollDirection, bool? reverse, bool? primary, StacScrollPhysics? physics, bool? shrinkWrap, StacEdgeInsets? padding, bool? addAutomaticKeepAlives, bool? addRepaintBoundaries, bool? addSemanticIndexes, double? cacheExtent, List<StacWidget>? children, StacWidget? separator, int? semanticChildCount, StacDragStartBehavior? dragStartBehavior, StacScrollViewKeyboardDismissBehavior? keyboardDismissBehavior, String? restorationId, StacClip? clipBehavior})
Creates a StacListView.
const
StacListView.fromJson(Map<String, dynamic> json)
Creates a StacListView from JSON.
factory

Properties

addAutomaticKeepAlives → bool?
Whether to wrap each child in an AutomaticKeepAlive.
final
addRepaintBoundaries → bool?
Whether to wrap each child in a RepaintBoundary.
final
addSemanticIndexes → bool?
Whether to wrap each child in an IndexedSemantics.
final
cacheExtent → double?
The cache extent of the ListView.
final
children → List<StacWidget>?
The StacWidgets to display in the list.
final
clipBehavior → StacClip?
The content will be clipped (or not) according to this option.
final
dragStartBehavior → StacDragStartBehavior?
Determines the way that drag start behavior is handled.
final
hashCode → int
The hash code for this object.
no setterinherited
jsonData → Map<String, dynamic>?
Raw JSON data for this widget
finalinherited
keyboardDismissBehavior → StacScrollViewKeyboardDismissBehavior?
final
padding → StacEdgeInsets?
The amount of space by which to inset the children.
final
physics → StacScrollPhysics?
How the scroll view should respond to user input.
final
primary → bool?
Whether this is the primary scroll view associated with the parent PrimaryScrollController.
final
restorationId → String?
Restoration ID to save and restore the scroll offset of the scrollable.
final
reverse → bool?
Whether the scroll view scrolls in the reading direction.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
scrollDirection → StacAxis?
The axis along which the scroll view scrolls.
final
semanticChildCount → int?
The number of children that will contribute semantic information.
final
separator → StacWidget?
The StacWidget to display between list items as a separator.
final
shrinkWrap → bool?
Whether the extent of the scroll view in the scrollDirection should be determined by the contents being viewed.
final
type → String
Widget type identifier.
no setteroverride

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
parse(BuildContext context) → Widget?

Available on StacWidget?, provided by the StacWidgetParser extension

parsePreferredSizeWidget(BuildContext context) → PreferredSizeWidget?

Available on StacWidget?, provided by the StacWidgetParser extension

toJson() → Map<String, dynamic>
Converts this StacListView to JSON.
override
toString() → String
A string representation of this object.
inherited

Operators

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