parse method
Widget
parse(
- Map<
String, dynamic> map, - BuildContext buildContext,
- ClickListener? listener
override
parse the json map into a flutter widget.
Implementation
@override
Widget parse(Map<String, dynamic> map, BuildContext buildContext,
ClickListener? listener) {
return Column(
crossAxisAlignment: map.containsKey('crossAxisAlignment')
? parseCrossAxisAlignment(map['crossAxisAlignment'])
: CrossAxisAlignment.center,
mainAxisAlignment: map.containsKey('mainAxisAlignment')
? parseMainAxisAlignment(map['mainAxisAlignment'])
: MainAxisAlignment.start,
mainAxisSize: map.containsKey('mainAxisSize')
? parseMainAxisSize(map['mainAxisSize'])
: MainAxisSize.max,
textBaseline: map.containsKey('textBaseline')
? parseTextBaseline(map['textBaseline'])
: null,
textDirection: map.containsKey('textDirection')
? parseTextDirection(map['textDirection'])
: null,
verticalDirection: map.containsKey('verticalDirection')
? parseVerticalDirection(map['verticalDirection'])
: VerticalDirection.down,
children: DynamicWidgetBuilder.buildWidgets(
map['children'], buildContext, listener),
);
}