toMapJs method
Implementation
String toMapJs(){
var map = '{';
map += '"name": "$name"';
if(id != null) map += ', "id": "$id"';
if(height != null) map += ', "height": "$height"';
if(width != null) map += ', "width": "$width"';
if(borderRadius != null) map += ', "borderRadius": "$borderRadius"';
if(colorHex != null) map += ', "colorHex": "$colorHex"';
if(textColorHex != null) map += ', "textColorHex": "$textColorHex"';
map += '}';
return map;
}