copyWith method

SheetProps copyWith({
  1. bool? isOpen,
  2. Widget? child,
  3. SheetPosition? position,
  4. SheetSizeVariant? size,
  5. void onClose()?,
  6. bool? showCloseButton,
  7. String? title,
  8. String? description,
  9. Widget? header,
  10. Widget? footer,
  11. bool? showBackdrop,
  12. bool? closeOnBackdropClick,
  13. bool? showDragHandle,
  14. String? maxWidth,
})

Implementation

SheetProps copyWith({
  bool? isOpen,
  Widget? child,
  SheetPosition? position,
  SheetSizeVariant? size,
  void Function()? onClose,
  bool? showCloseButton,
  String? title,
  String? description,
  Widget? header,
  Widget? footer,
  bool? showBackdrop,
  bool? closeOnBackdropClick,
  bool? showDragHandle,
  String? maxWidth,
}) {
  return SheetProps(
    isOpen: isOpen ?? this.isOpen,
    child: child ?? this.child,
    position: position ?? this.position,
    size: size ?? this.size,
    onClose: onClose ?? this.onClose,
    showCloseButton: showCloseButton ?? this.showCloseButton,
    title: title ?? this.title,
    description: description ?? this.description,
    header: header ?? this.header,
    footer: footer ?? this.footer,
    showBackdrop: showBackdrop ?? this.showBackdrop,
    closeOnBackdropClick: closeOnBackdropClick ?? this.closeOnBackdropClick,
    showDragHandle: showDragHandle ?? this.showDragHandle,
    maxWidth: maxWidth ?? this.maxWidth,
  );
}