BaseCupertinoInteractiveKeyboard class

Base wrapper for CupertinoInteractiveKeyboard with cross-platform support

Provides iOS-style interactive keyboard dismissal with fallback to standard keyboard handling on other platforms. Uses the actual cupertino_interactive_keyboard package for authentic drag-to-dismiss functionality on iOS.

Features:

  • Native iOS interactive keyboard dismissal with drag gestures
  • Keyboard height tracking and animation
  • Custom keyboard toolbar support
  • Cross-platform Material Design fallback
  • Tap-to-dismiss functionality
  • Apple HIG compliant keyboard behavior

Apple HIG implementation:

  • Interactive dismissal with drag gestures using native implementation
  • Smooth keyboard animation curves
  • Proper safe area handling
  • Keyboard toolbar integration
  • Haptic feedback support (when available)

Example usage:

BaseCupertinoInteractiveKeyboard(
  child: Column(
    children: [
      TextField(
        decoration: InputDecoration(
          hintText: 'Type something...',
        ),
      ),
      // Other content
    ],
  ),
  onKeyboardHeightChanged: (height) {
    print('Keyboard height: $height');
  },
  enableInteractiveDismissal: true,
)
Inheritance

Constructors

BaseCupertinoInteractiveKeyboard({Key? key, required Widget child, ValueChanged<double>? onKeyboardHeightChanged, ValueChanged<bool>? onKeyboardVisibilityChanged, bool enableInteractiveDismissal = true, Widget? keyboardToolbar, bool dismissOnTap = true, Duration animationDuration = const Duration(milliseconds: 250), Curve animationCurve = Curves.easeInOut, BaseParam? baseParam})
Creates a Cupertino interactive keyboard wrapper
const

Properties

animationCurve → Curve
Animation curve for keyboard transitions
final
animationDuration → Duration
Animation duration for keyboard transitions
final
baseParam → BaseParam?
Personalization parameters, gets platform parameters first, then mode parameters
finalinherited
child → Widget
The child widget to wrap with interactive keyboard functionality
final
dismissOnTap → bool
Whether to dismiss keyboard when tapping outside
final
enableInteractiveDismissal → bool
Whether to enable interactive dismissal with gestures
final
hashCode → int
The hash code for this object.
no setterinherited
key → Key?
Controls how one widget replaces another widget in the tree.
finalinherited
keyboardToolbar → Widget?
Optional keyboard toolbar widget
final
onKeyboardHeightChanged → ValueChanged<double>?
Callback for keyboard height changes
final
onKeyboardVisibilityChanged → ValueChanged<bool>?
Callback for keyboard visibility changes
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

beforeBuild(BuildContext context) → void
Called before build
inherited
beforeBuildByCupertino(BuildContext context) → void
Called before buildByCupertino
inherited
beforeBuildByCupertinoNative(BuildContext context) → void
Called before buildByCupertinoNative (native iOS implementation)
inherited
beforeBuildByMaterial(BuildContext context) → void
Called before buildByMaterial
inherited
build(BuildContext context) → Widget
Describes the part of the user interface represented by this widget.
inherited
buildByCupertino(BuildContext context) → Widget
build on cupertino mode (Flutter implementation)
buildByCupertinoNative(BuildContext context) → dynamic
build on cupertino mode with native iOS components (cupertino_native package) This is called when baseParam.nativeIOS = true Default implementation falls back to buildByCupertino()
inherited
buildByMaterial(BuildContext context) → Widget
build on material mode
commonBuild(BuildContext context, BaseParam? baseParam) → dynamic
inherited
createElement() → StatelessElement
Creates a StatelessElement to manage this widget's location in the tree.
inherited
debugDescribeChildren() → List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
getBuildMode(BaseParam? baseParam) → WidgetBuildMode
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) → String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String
Returns a one-line detailed description of the object.
inherited
toStringShort() → String
A short, textual description of this widget.
inherited
valueOf(String key, dynamic value) → dynamic
inherited
valueOfBaseParam(BaseParam? baseParam, String key, dynamic value) → dynamic
No reflection available in Dart First get value from platform, then from mode, finally from value itself
inherited

Operators

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