fromJson static method
Instantiate FBorder from Json
Implementation
static FBorder fromJson(final Map<String, dynamic> doc) {
try {
return FBorder(
style: FBorderStyle.fromJson(doc[DBKeys.borderStyle] as String),
width: FMargins.fromJson(doc[DBKeys.margins] as dynamic),
fill: FFill.fromJson(doc[DBKeys.fill] as Map<String, dynamic>),
);
} catch (e) {
return const FBorder(
style: FBorderStyle(
value: BorderStyle.none,
),
width: FMargins(
margins: [0, 0, 0, 0],
marginsTablet: [0, 0, 0, 0],
marginsDesktop: [0, 0, 0, 0],
),
fill: FFill(),
);
}
}