CommonActionSheet class
吸底列表弹框,可自定义标题文案 可通过配置CommonActionSheetItemStyle来设定 item 的样式
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatelessWidget
- CommonActionSheet
Constructors
-
CommonActionSheet({Key? key, required List<
CommonActionSheetItem> actions, String? title, Widget? titleWidget, String? cancelTitle, CommonActionSheetItemClickCallBack? clickCallBack, Color? separatorLineColor, Color spaceColor = const Color(0xfff8f8f8), int maxTitleLines = 2, double maxSheetHeight = 0, CommonActionSheetItemClickInterceptor? onItemClickInterceptor, ActionSheetConfig? themeData})
Properties
-
actions
→ List<
CommonActionSheetItem> -
每个选项相关的配置信息的列表
每个选项支持修改内容见CommonActionSheetItem
final
- cancelTitle → String?
-
取消按钮文本
final
- clickCallBack → CommonActionSheetItemClickCallBack?
-
Action Item 的点击事件
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- maxSheetHeight → double
-
列表最大高度限制,默认为屏幕高度减去上下安全距离
默认为0
final
- maxTitleLines → int
-
标题最大行数,默认为2
final
- onItemClickInterceptor → CommonActionSheetItemClickInterceptor?
-
Action Item 点击事件拦截回调
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- separatorLineColor → Color?
-
Action 之间分割线颜色,默认值 Color(0xfff0f0f0)
final
- spaceColor → Color
-
取消按钮与 Action 之间的分割线的颜色,默认值 Color(0xfff8f8f8)
final
- themeData ↔ ActionSheetConfig?
-
主题定制
getter/setter pair
- title → String?
-
ActionSheet 标题
final
- titleWidget → Widget?
-
title区域widget, 与 title 字段互斥,当 titleWidget 不为 null 时优先使用 titleWidget。
final
Methods
-
build(
BuildContext context) → Widget -
Describes the part of the user interface represented by this widget.
override
-
createElement(
) → StatelessElement -
Creates a StatelessElement to manage this widget's location in the tree.
inherited
-
debugDescribeChildren(
) → List< DiagnosticsNode> -
Returns a list of DiagnosticsNode objects describing this node's
children.
inherited
-
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toDiagnosticsNode(
{String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode -
Returns a debug representation of the object that is used by debugging
tools and by DiagnosticsNode.toStringDeep.
inherited
-
toString(
{DiagnosticLevel minLevel = DiagnosticLevel.info}) → String -
A string representation of this object.
inherited
-
toStringDeep(
{String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String -
Returns a string representation of this node and its descendants.
inherited
-
toStringShallow(
{String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a one-line detailed description of the object.
inherited
-
toStringShort(
) → String -
A short, textual description of this widget.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited