toMap method
Implementation
Map<String, dynamic> toMap() => <String, dynamic>{
"top": rect!.top,
"left": rect!.left,
"width": rect!.width,
"height": rect!.height,
"color": color.toHex(),
if (opacity != 1.0) "opacity": opacity,
if (isText != null) "isText": isText,
};