ComponentConfig class

组件配置基类

Implementers

Constructors

ComponentConfig({ComponentType? type, Widget builder(BuildContext context)?, bool isFloating = false, bool hasAnimation = false, bool isCollapsible = false, bool initiallyExpanded = true, Color? backgroundColor, Duration animationDuration = const Duration(milliseconds: 300), AnimationType? animationType, double? width, double? height, EdgeInsets? margin, EdgeInsets? padding, Map<String, dynamic>? customProps, bool showToggleButton = false, bool isShow = true})
const
ComponentConfig.fromJson(Map<String, dynamic> json)
从 JSON 创建 ComponentConfig 实例
factory

Properties

animationDuration Duration
final
animationType AnimationType?
final
backgroundColor Color?
final
builder Widget Function(BuildContext context)?
final
customProps Map<String, dynamic>?
final
hasAnimation bool
final
hashCode int
The hash code for this object.
no setterinherited
height double?
final
initiallyExpanded bool
final
isCollapsible bool
final
isFloating bool
final
isShow bool
新增:是否显示该组件
final
isValid bool
验证配置有效性
no setter
margin EdgeInsets?
final
padding EdgeInsets?
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
showToggleButton bool
新增:是否显示切换按钮
final
type ComponentType?
final
width double?
final

Methods

copyWith({ComponentType? type, Widget builder(BuildContext context)?, bool? isFloating, bool? hasAnimation, bool? isCollapsible, bool? initiallyExpanded, Duration? animationDuration, AnimationType? animationType, double? width, double? height, EdgeInsets? margin, EdgeInsets? padding, Map<String, dynamic>? customProps, Color? backgroundColor, bool? showToggleButton, bool? isShow}) ComponentConfig
复制并修改配置
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
转换为 JSON
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited