expandable method

dynamic expandable(
  1. dynamic context,
  2. dynamic ref,
  3. dynamic taskList
)

Implementation

Widget expandable(BuildContext context, WidgetRef ref, TaskList taskList) {
  return ExpansionTile(
    initiallyExpanded: initiallyExpanded,
    leading: ActerIconWidget(
      iconSize: 30,
      color: convertColor(taskList.display()?.color(), iconPickerColors[0]),
      icon: ActerIcon.iconForTask(taskList.display()?.iconStr()),
    ),
    shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(10)),
    iconColor: Theme.of(context).colorScheme.onSurface,
    childrenPadding: const EdgeInsets.symmetric(horizontal: 10),
    title: title(context, taskList),
    subtitle: subtitle(ref, taskList),
    children:
        showOnlyTaskList
            ? []
            : [
              TaskItemsListWidget(
                taskList: taskList,
                showCompletedTask: showCompletedTask,
              ),
            ],
  );
}