copyWith method

AdeptDropDownTheme copyWith({
  1. bool? isSearch,
  2. BoxDecoration? boxDecoration,
  3. Widget? suffixWidget,
  4. CardThemeData? cardTheme,
  5. AdeptTextFieldTheme? searchBoxTheme,
  6. TextStyle? itemTextStyle,
  7. bool? isClose,
  8. double? height,
  9. TextStyle? labelTextStyle,
  10. TextStyle? hintTextStyle,
  11. TextStyle? valueTextStyle,
  12. EdgeInsets? labelPadding,
  13. EdgeInsets? fieldPadding,
  14. Color? multiSelectItemBgColor,
})

Creates a copy of this theme but with the given fields replaced with the new values.

Implementation

AdeptDropDownTheme copyWith({
  /// isSearch for search option visible or invisible in dropdown
  bool? isSearch,

  /// use for boxDecoration
  BoxDecoration? boxDecoration,

  /// use for suffixWidget
  Widget? suffixWidget,

  /// use drop down decoration
  CardThemeData? cardTheme,

  /// Drop down search box theme
  AdeptTextFieldTheme? searchBoxTheme,

  /// Drop Down Text Style
  TextStyle? itemTextStyle,

  /// Is Close Visible
  bool? isClose,

  ///
  double? height,

  // From base class: TextThemeMdl
  TextStyle? labelTextStyle,
  TextStyle? hintTextStyle,
  TextStyle? valueTextStyle,
  EdgeInsets? labelPadding,
  EdgeInsets? fieldPadding,
  Color? multiSelectItemBgColor,
}) {
  return AdeptDropDownTheme(
    labelTextStyle: labelTextStyle ?? this.labelTextStyle,
    hintTextStyle: hintTextStyle ?? this.hintTextStyle,
    valueTextStyle: valueTextStyle ?? this.valueTextStyle,
    labelPadding: labelPadding ?? this.labelPadding,
    fieldPadding: fieldPadding ?? this.fieldPadding,
    isSearch: isSearch ?? this.isSearch,
    boxDecoration: boxDecoration ?? this.boxDecoration,
    suffixWidget: suffixWidget ?? this.suffixWidget,
    cardTheme: cardTheme ?? this.cardTheme,
    searchBoxTheme: searchBoxTheme ?? this.searchBoxTheme,
    itemTextStyle: itemTextStyle ?? this.itemTextStyle,
    height: height ?? this.height,
    isClose: isClose ?? this.isClose,
    multiSelectItemBgColor:
        multiSelectItemBgColor ?? this.multiSelectItemBgColor,
  );
}