copyWith method
- @useResult
- Brightness? keyboardAppearance,
- Color? cursorColor,
- double? cursorWidth,
- bool? cursorOpacityAnimates()?,
- Size? itemSize,
- FVariantsDelta<
FOtpFieldItemVariantConstraint, FOtpFieldItemVariant, FOtpFieldItemStyle, FOtpFieldItemStyleDelta> ? itemStyles, - EdgeInsetsGeometryDelta? dividerPadding,
- Size? dividerSize,
- FVariantsValueDelta<
FOtpFieldItemVariantConstraint, FOtpFieldItemVariant, Color, Delta> ? dividerColor, - EdgeInsetsGeometryDelta? labelPadding,
- EdgeInsetsGeometryDelta? descriptionPadding,
- EdgeInsetsGeometryDelta? errorPadding,
- EdgeInsetsGeometryDelta? childPadding,
- FLabelMotionDelta? labelMotion,
- FVariantsDelta<
FFormFieldVariantConstraint, FFormFieldVariant, TextStyle, TextStyleDelta> ? labelTextStyle, - FVariantsDelta<
FFormFieldVariantConstraint, FFormFieldVariant, TextStyle, TextStyleDelta> ? descriptionTextStyle, - FVariantsDelta<
FFormFieldErrorVariantConstraint, FFormFieldErrorVariant, TextStyle, TextStyleDelta> ? errorTextStyle,
Returns a copy of this FOtpFieldStyle with the given properties replaced.
See customizing widget styles.
Parameters
- FOtpFieldStyle.keyboardAppearance - The appearance of the keyboard.
- FOtpFieldStyle.cursorColor - The color of the cursor.
- FOtpFieldStyle.cursorWidth - The width of the cursor.
- FOtpFieldStyle.cursorOpacityAnimates - Whether the cursor opacity animates.
- FOtpFieldStyle.itemSize - The item size.
- FOtpFieldStyle.itemStyles - The item styles per variant.
- FOtpFieldStyle.dividerPadding - The divider's padding.
- FOtpFieldStyle.dividerSize - The divider's size.
- FOtpFieldStyle.dividerColor - The divider's color.
- FOtpFieldStyle.labelPadding - The label's padding.
- FOtpFieldStyle.descriptionPadding - The description's padding.
- FOtpFieldStyle.errorPadding - The error's padding.
- FOtpFieldStyle.childPadding - The child's padding.
- FOtpFieldStyle.labelMotion - The motion properties for error animations.
- FOtpFieldStyle.labelTextStyle - The label's text style.
- FOtpFieldStyle.descriptionTextStyle - The description's text style.
- FOtpFieldStyle.errorTextStyle - The error's text style.
Implementation
@useResult
FOtpFieldStyle copyWith({
Brightness? keyboardAppearance,
Color? cursorColor,
double? cursorWidth,
bool? Function()? cursorOpacityAnimates,
Size? itemSize,
FVariantsDelta<FOtpFieldItemVariantConstraint, FOtpFieldItemVariant, FOtpFieldItemStyle, FOtpFieldItemStyleDelta>?
itemStyles,
EdgeInsetsGeometryDelta? dividerPadding,
Size? dividerSize,
FVariantsValueDelta<FOtpFieldItemVariantConstraint, FOtpFieldItemVariant, Color, Delta>? dividerColor,
EdgeInsetsGeometryDelta? labelPadding,
EdgeInsetsGeometryDelta? descriptionPadding,
EdgeInsetsGeometryDelta? errorPadding,
EdgeInsetsGeometryDelta? childPadding,
FLabelMotionDelta? labelMotion,
FVariantsDelta<FFormFieldVariantConstraint, FFormFieldVariant, TextStyle, TextStyleDelta>? labelTextStyle,
FVariantsDelta<FFormFieldVariantConstraint, FFormFieldVariant, TextStyle, TextStyleDelta>? descriptionTextStyle,
FVariantsDelta<FFormFieldErrorVariantConstraint, FFormFieldErrorVariant, TextStyle, TextStyleDelta>? errorTextStyle,
}) => .new(
keyboardAppearance: keyboardAppearance ?? this.keyboardAppearance,
cursorColor: cursorColor ?? this.cursorColor,
cursorWidth: cursorWidth ?? this.cursorWidth,
cursorOpacityAnimates: cursorOpacityAnimates == null ? this.cursorOpacityAnimates : cursorOpacityAnimates(),
itemSize: itemSize ?? this.itemSize,
itemStyles: FOtpFieldItemStyles(itemStyles?.call(this.itemStyles) ?? this.itemStyles),
dividerPadding: dividerPadding?.call(this.dividerPadding) ?? this.dividerPadding,
dividerSize: dividerSize ?? this.dividerSize,
dividerColor: dividerColor?.call(this.dividerColor) ?? this.dividerColor,
labelPadding: labelPadding?.call(this.labelPadding) ?? this.labelPadding,
descriptionPadding: descriptionPadding?.call(this.descriptionPadding) ?? this.descriptionPadding,
errorPadding: errorPadding?.call(this.errorPadding) ?? this.errorPadding,
childPadding: childPadding?.call(this.childPadding) ?? this.childPadding,
labelMotion: labelMotion?.call(this.labelMotion) ?? this.labelMotion,
labelTextStyle: labelTextStyle?.call(this.labelTextStyle) ?? this.labelTextStyle,
descriptionTextStyle: descriptionTextStyle?.call(this.descriptionTextStyle) ?? this.descriptionTextStyle,
errorTextStyle: errorTextStyle?.call(this.errorTextStyle) ?? this.errorTextStyle,
);