Generates a map representing the InteractionGoal.
InteractionGoal
Map<String, dynamic> toMap() { return {'type': type, 'elementIds': elementIds}; }