DrawerContentSingleSelectParams<T> constructor

DrawerContentSingleSelectParams<T>({
  1. required BuildContext context,
  2. OptionData<T>? initialValue,
  3. bool? isUseButton = true,
  4. required dynamic onItemSelected(
    1. OptionData<T>? optionData
    ),
  5. required Future<List<OptionData<T>>> initState(),
  6. BorderRadius? borderRadius,
  7. bool? withSearch,
  8. Widget? separator,
  9. String? searchHint,
  10. Widget? onLoading,
  11. Widget? onEmpty,
  12. Widget? onError,
  13. double height = 500,
  14. SearchTextFieldParams? searchParams,
})

Implementation

DrawerContentSingleSelectParams({
  required this.context,
  this.initialValue,
  this.isUseButton = true,
  required this.onItemSelected,
  required this.initState,
  this.borderRadius,
  this.withSearch,
  this.separator,
  this.searchHint,
  this.onLoading,
  this.onEmpty,
  this.onError,
  this.height = 500,
  this.searchParams,
}) : assert(height <= MediaQuery.of(context).size.height * .5,
          "Tinggi tidak boleh melebih setengah layar");