CNButtonConfig class

Configuration for CNButton with default values.

Constructors

CNButtonConfig({EdgeInsets? padding, double? borderRadius, double? minHeight, double? imagePadding, CNImagePlacement imagePlacement = CNImagePlacement.leading, CNButtonStyle style = CNButtonStyle.glass, double? width, bool shrinkWrap = false, String? glassEffectUnionId, String? glassEffectId, bool glassEffectInteractive = true, int? maxLines = 1, MainAxisAlignment? contentAlignment})
Creates a configuration for CNButton.
const

Properties

borderRadius → double?
Border radius for button corners. If null, uses capsule shape (always round).
final
contentAlignment → MainAxisAlignment?
Alignment of the button content along the main axis.
final
glassEffectId → String?
Optional ID for glass effect morphing transitions.
final
glassEffectInteractive → bool
Whether to make the glass effect interactive.
final
glassEffectUnionId → String?
Optional ID for glass effect union.
final
hashCode → int
The hash code for this object.
no setterinherited
imagePadding → double?
Padding between image and text (spacing in HStack).
final
imagePlacement → CNImagePlacement
Image placement relative to text when both are present.
final
maxLines → int?
Maximum number of lines for button text.
final
minHeight → double?
Minimum height for the button.
final
padding → EdgeInsets?
Padding for button content. If null, uses default EdgeInsets(top: 8.0, leading: 12.0, bottom: 8.0, trailing: 12.0).
final
props → List<Object?>
The list of properties that will be used to determine whether two instances are equal.
no setter
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
shrinkWrap → bool
If true, sizes the control to its intrinsic width.
final
stringify → bool?
If set to true, the toString method will be overridden to output this instance's props.
no setterinherited
style → CNButtonStyle
Visual style to apply.
final
width → double?
Fixed width used in icon/round mode.
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

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