InputHintFeature class

Adds a hint/info button to the input field with a popover.

Displays an icon button that shows a popover with additional information when clicked. Optionally supports keyboard shortcuts (F1) to open the hint.

Example:

TextField(
  features: [
    InputHintFeature(
      popupBuilder: (context) => const Text('Enter your email'),
      icon: Icon(Icons.help),
    ),
  ],
)
Inheritance

Constructors

InputHintFeature({InputFeatureVisibility visibility = InputFeatureVisibility.always, bool skipFocusTraversal = true, required WidgetBuilder popupBuilder, InputFeaturePosition position = InputFeaturePosition.trailing, Widget? icon, bool enableShortcuts = true})
Creates an InputHintFeature.
const

Properties

enableShortcuts bool
Whether to enable keyboard shortcut (F1) to show the hint.
final
hashCode int
The hash code for this object.
no setterinherited
icon Widget?
Custom icon to display (defaults to info icon).
final
popupBuilder WidgetBuilder
Builder for the hint popover content.
final
position InputFeaturePosition
Position of the hint button.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
skipFocusTraversal bool
Whether to skip this feature in focus traversal.
finalinherited
visibility InputFeatureVisibility
Visibility mode for this input feature.
finalinherited

Methods

createState() InputFeatureState<InputFeature>
Creates the state for this input feature.
override
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