copyWith method
InputChecklist
copyWith({
- FormattedText? title,
- List<
InputChecklistTask> ? tasks, - bool? othersCanAddTasks,
- bool? othersCanMarkTasksAsDone,
Returns a copy with the given fields replaced. For a nullable
field pass a function, e.g. field: () => null to clear it.
Implementation
InputChecklist copyWith({
FormattedText? title,
List<InputChecklistTask>? tasks,
bool? othersCanAddTasks,
bool? othersCanMarkTasksAsDone,
}) => InputChecklist(
title: title ?? this.title,
tasks: tasks ?? this.tasks,
othersCanAddTasks: othersCanAddTasks ?? this.othersCanAddTasks,
othersCanMarkTasksAsDone:
othersCanMarkTasksAsDone ?? this.othersCanMarkTasksAsDone,
);