copyWith method

Area copyWith({
  1. dynamic id,
  2. double? size,
  3. double? flex,
  4. double? min,
  5. double? max,
  6. dynamic data,
  7. AreaWidgetBuilder? builder,
})

Creates a copy of this Area with the given fields replaced with their.

Implementation

Area copyWith({
  dynamic id,
  double? size,
  double? flex,
  double? min,
  double? max,
  dynamic data,
  AreaWidgetBuilder? builder,
}) {
  return Area(
    id: id ?? this.id,
    size: size == null && flex == null ? this.size : size,
    flex: size == null && flex == null ? this.flex : flex,
    min: min ?? this.min,
    max: max ?? this.max,
    data: data ?? this.data,
    builder: builder ?? this.builder,
  );
}