VooFormConfig class
Configuration for form styling and behavior
Constructors
- VooFormConfig.new({LabelPosition labelPosition = LabelPosition.above, LabelStyle labelStyle = LabelStyle.normal, FieldVariant fieldVariant = FieldVariant.outlined, VooSpacingSize fieldSize = VooSpacingSize.md, double fieldSpacing = 16.0, double sectionSpacing = 24.0, double? maxFormWidth, bool showFieldIcons = true, bool showRequiredIndicator = true, String requiredIndicator = '*', ErrorDisplayMode errorDisplayMode = ErrorDisplayMode.below, ButtonPosition submitButtonPosition = ButtonPosition.bottomRight, ButtonStyle? submitButtonStyle, EdgeInsetsGeometry? padding, EdgeInsetsGeometry? margin, Color? backgroundColor, BoxDecoration? decoration, bool centerOnLargeScreens = true, ResponsiveColumns gridColumns = const ResponsiveColumns(), ThemeData? themeOverrides, VooFieldOptions? defaultFieldOptions})
-
const
- VooFormConfig.compact()
-
Create a config for compact forms
factory
- VooFormConfig.desktop()
-
Create a config optimized for desktop with centered form
factory
- VooFormConfig.material()
-
Create a config for material design forms
factory
- VooFormConfig.mobile()
-
Create a config optimized for mobile
factory
Properties
- backgroundColor → Color?
-
Background color
final
- centerOnLargeScreens → bool
-
Whether form should be centered on large screens
final
- decoration → BoxDecoration?
-
Border decoration
final
- defaultFieldOptions → VooFieldOptions?
-
Default field options that apply to all fields
final
- errorDisplayMode → ErrorDisplayMode
-
Error display mode
final
- fieldSize → VooSpacingSize
-
Field size (small, medium, large)
final
- fieldSpacing → double
-
Spacing between fields
final
- fieldVariant → FieldVariant
-
Field variant (outlined, filled, underlined)
final
- gridColumns → ResponsiveColumns
-
Number of columns for grid layout on different screen sizes
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- labelPosition → LabelPosition
-
Label position relative to field
final
- labelStyle → LabelStyle
-
Label style variant
final
- margin → EdgeInsetsGeometry?
-
Form margin
final
- maxFormWidth → double?
-
Max width for form on large screens
final
- padding → EdgeInsetsGeometry?
-
Form padding
final
- requiredIndicator → String
-
Required indicator text or symbol
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- sectionSpacing → double
-
Spacing between sections
final
- showFieldIcons → bool
-
Whether to show field icons
final
- showRequiredIndicator → bool
-
Whether to show required indicator
final
- submitButtonPosition → ButtonPosition
-
Submit button position
final
- submitButtonStyle → ButtonStyle?
-
Submit button style
final
- themeOverrides → ThemeData?
-
Custom theme overrides
final
Methods
-
copyWith(
{LabelPosition? labelPosition, LabelStyle? labelStyle, FieldVariant? fieldVariant, VooSpacingSize? fieldSize, double? fieldSpacing, double? sectionSpacing, double? maxFormWidth, bool? showFieldIcons, bool? showRequiredIndicator, String? requiredIndicator, ErrorDisplayMode? errorDisplayMode, ButtonPosition? submitButtonPosition, ButtonStyle? submitButtonStyle, EdgeInsetsGeometry? padding, EdgeInsetsGeometry? margin, Color? backgroundColor, BoxDecoration? decoration, bool? centerOnLargeScreens, ResponsiveColumns? gridColumns, ThemeData? themeOverrides}) → VooFormConfig -
getColumnCount(
BuildContext context) → int - Get responsive column count based on screen context
-
getFieldPadding(
) → EdgeInsetsGeometry - Get field padding based on size
-
getLabelStyle(
BuildContext context) → TextStyle? - Get label text style based on configuration
-
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