M7LivelynessStepItem.fromMap constructor

M7LivelynessStepItem.fromMap(
  1. Map<String, dynamic> map
)

Implementation

factory M7LivelynessStepItem.fromMap(Map<String, dynamic> map) {
  return M7LivelynessStepItem(
    step: M7LivelynessStep.values[map['step'] ?? 0],
    title: map['title'] ?? '',
    thresholdToCheck: map['thresholdToCheck']?.toDouble(),
    isCompleted: map['isCompleted'] ?? false,
    detectionColor:
        map['detectionColor'] != null ? Color(map['detectionColor']) : null,
  );
}