mini_widget
library
Functions
-
build2LineCell({required String label, required String value, Color labelColor = MiniColor.black, String? smallLabel, Color smallColor = MiniColor.black, Color valueColor = MiniColor.black, VoidCallback? voidCallback})
→ Widget
-
-
buildCheckCell({String? label, Color labelColor = Colors.black87, TextStyle? labelTextStyle, bool selected = false, Color selectColor = Colors.blue, ValueChanged<bool>? onSelected, EdgeInsets padding = const EdgeInsets.all(5)})
→ Widget
-
复选控件
-
buildCheckItem(String label, bool selected, {Color color = MiniColor.white, String? iconUrl})
→ Widget
-
选择菜单
-
buildColorCard({required Widget child, Color? lightColor, Color darkColor = const Color(0xFF4EE07A)})
→ Widget
-
-
buildErrorLineCell({required String errorText, IconData errorIcon = Icons.error, Color errorColor = Colors.red, double height = 40, Color backgroundColor = Colors.white})
→ Widget
-
-
buildFirstCheckItem(BuildContext context, String label, bool selected)
→ Widget
-
一级菜单标题
-
buildHeadCardCell({String? headText, String? rightHeadText, TextStyle? headTextStyle, TextStyle? rightHeadTextStyle, BuildContext? context, Widget? headChild, Widget? child, List? values, Color color = Colors.white, double tagWidth = 80, double miniHeight = 30, double fontSize = 16, EdgeInsetsGeometry valuePadding = const EdgeInsets.all(1), EdgeInsetsGeometry childPadding = const EdgeInsets.all(5), double paddingRight = 0.0, VoidCallback? onMoreTop, VoidCallback? onMoreLongPress})
→ Widget
-
构建头部+卡片
-
抬头
-
buildIconLineCell({required Icon icon, required String label, Color? labelColor, Color? valueColor, VoidCallback? voidCallback})
→ Widget
-
Icon + Text 横向显示
-
buildLineCell({required String title, Widget? titleChild, Widget? subTitle, Icon? icon, String? svgName, String? iconName, String? numString, bool showNext = true, Color color = Colors.white, Color titleColor = Colors.black, bool showLine = false, VoidCallback? onPressed})
→ Widget
-
-
buildListMoreCell({String? title, int allSize = 0, int size = -1, VoidCallback? onMoreTop, VoidCallback? onLongPress, String moreText = '更多 '})
→ Widget
-
列表带更多抬头
-
buildRadioCell({String? label, ValueChanged<bool>? onSelected, Color labelColor = Colors.black87, bool selected = false, Color selectColor = Colors.blue, TextStyle? labelTextStyle})
→ Widget
-
单选控件
-
buildSearchCell({String hint = '多关键字用空格分开搜索', TextEditingController? controller, bool enInput = true, ValueChanged<String>? onSubmitted, ValueChanged<String>? onChanged})
→ Widget
-
hint
- 搜索提示
enInput
- 是否可以录入
-
buildSearchSpan(String content, String searchText, {Color searchTextColor = Colors.red, TextStyle style = const TextStyle(color: Colors.black)})
→ Widget
-
创建搜索内容
-
buildSubCheckItem(BuildContext context, String label, bool selected)
→ Widget
-
二级菜单
-
buildTagSelectCell<T>(BuildContext context, String tag, {IconData iconData = Icons.keyboard_arrow_down, Widget? icon, Color? iconColor = const Color(0xffbcbcbc), double tagWidth = 100, String? hintText, double fontSize = 16, double miniHeight = 40, Color tagColor = const Color(0xff63728f), TextEditingController? controller, TextInputType? inputType, InputDecoration? inputDecoration, List<T>? items, BuildCheckChild<T>? buildCheckChild, bool autoHeight = true, VoidCallback? onTap, bool required = false, bool isEdit = true, int? valueMaxLines = 1, double paddingRight = 0.0, EdgeInsetsGeometry padding = const EdgeInsets.all(1), bool showLine = false, Color color = Colors.transparent, Widget? child, ValueChanged<int>? onItemSelected, double iconWidth = 40, TagCellStyle style = TagCellStyle.style2, double? dialogWidth})
→ Widget
-
onItemSelected
-1 代表无数据
-
buildTimeLineCell({String dealTime = '', String dealMan = '', String headUrl = '', Widget? headDefault, String title = '', String? memo, String? circularLabel, Color circularColor = Colors.blue, bool isState = false, bool isEnd = false})
→ Widget
-
-
defaultGetItemLabel(dynamic data)
→ String?
-
-
-
showConfirmDialog(BuildContext context, String content, {String? title, String? colorContent, String? cancelText, VoidCallback? onCancelPressed, String? okText, VoidCallback? onOkPressed, bool left = false})
→ void
-
-
showCustomizeDialog(BuildContext context, Widget widget, {bool barrierDismissible = true, Future<bool> onWillPop()?})
→ Future
-
-
showInputDialog(BuildContext context, ValueChanged<String> okCallback, {ValueChanged<String>? cancelCallback, String? hintText, required String title, TextStyle? titleTextStyle, String? message, int? maxLength, String? okText, String? cancelText, bool required = true, String? content, TextInputType? inputType, int? maxLines, int? minLength, double? width, int? maxNum})
→ void
-
-
showLoadingDialog(BuildContext context, {String hintText = '正在处理…', bool barrierDismissible = false, Future<bool> onWillPop()?})
→ void
-
-
showMassageDialog(BuildContext context, String content, {String? title, String? colorContent, String? buttonText = '知道了', VoidCallback? onPressed, TextStyle? titleStyle, bool left = false})
→ void
-
-
showMessageDialog(BuildContext context, {required String title, required String message, TextStyle? titleStyle, String backLabel = "知道了"})
→ dynamic
-
-
showOkDialog(BuildContext context, {required String title, required String message, TextStyle? titleStyle, String cancelLabel = '取消', String okLabel = "确认"})
→ Future<int?>
-