Overview
Version 8.0 represents a major architectural shift where IQKeyboardManager has been split into smaller, focused libraries. This modular approach gives you more control over which features you include in your app.Keyboard Toolbar Changes
The most significant change in v8 is thatIQKeyboardManager.shared.enableAutoToolbar now defaults to false. The toolbar functionality has been moved to the IQKeyboardToolbarManager library.
Solution 1: Re-enable in IQKeyboardManager
If you want to keep using the toolbar with minimal changes:Solution 2: Use IQKeyboardToolbarManager Directly
For better modularity and control, use the new dedicated library:Features Moved to Independent Libraries
Many features have been extracted into their own libraries for better modularity:IQKeyboardToolbarManager
IQKeyboardToolbarManager
Repository: IQKeyboardToolbarManagerHandles all toolbar-related functionality including Previous/Next/Done buttons.Installation:
IQKeyboardNotification (formerly IQKeyboardListener)
IQKeyboardNotification (formerly IQKeyboardListener)
Repository: IQKeyboardNotificationProvides keyboard notification handling and state tracking.Migration:
IQTextInputViewNotification (formerly IQTextFieldViewListener)
IQTextInputViewNotification (formerly IQTextFieldViewListener)
Repository: IQTextInputViewNotificationHandles text field and text view editing notifications.Migration:
IQKeyboardReturnManager (formerly IQReturnKeyHandler)
IQKeyboardReturnManager (formerly IQReturnKeyHandler)
IQKeyboardToolbar (formerly IQToolbar)
IQKeyboardToolbar (formerly IQToolbar)
IQTextView
IQTextView
Repository: IQTextViewEnhanced UITextView with placeholder support.Migration: No code changes required, just add the separate library.
API Changes: IQKeyboardToolbarManager
If you’re using toolbar features, here are the key API migrations:Properties Moved
UITextField/UITextView Extensions
API Changes: IQKeyboardToolbar
Classes and configuration types have been renamed:Toolbar Extension Methods
Class Name Changes
IQPreviousNextView → IQDeepResponderContainerView
CocoaPods Subspecs
For easier migration, IQKeyboardManager v8 provides subspecs that automatically include the extracted libraries:Appearance Subspec
Keyboard appearance overriding has been moved to a subspec:Resign Subspec
Resign on touch outside functionality moved to a subspec:Migration Steps
Update Interface Builder Files
Search for
IQPreviousNextView in your storyboards/XIBs and update to:- Class:
IQDeepResponderContainerView - Module:
IQKeyboardToolbarManager
Update Class References
Replace renamed classes:
IQKeyboardListener→IQKeyboardNotification(different library)IQTextFieldViewListener→IQTextInputViewNotification(different library)IQReturnKeyHandler→IQKeyboardReturnManager(different library)IQToolbar→IQKeyboardToolbar(different library)IQToolbarConfiguration→IQKeyboardToolbarConfiguration
Benefits of v8 Architecture
Smaller Binary Size
Only include features you actually use, reducing app size
Better Modularity
Each feature is independently maintained and versioned
Faster Compilation
Smaller modules compile faster during development
Clearer Dependencies
Explicit dependencies make code more maintainable
Troubleshooting
Toolbar not showing
Toolbar not showing
Solution: Enable toolbar in AppDelegate:
Module 'IQKeyboardToolbarManager' not found
Module 'IQKeyboardToolbarManager' not found
Solution: Add the dependency to your package manager:
IQPreviousNextView class not found in Interface Builder
IQPreviousNextView class not found in Interface Builder
Solution: Change to
IQDeepResponderContainerView with module IQKeyboardToolbarManagerProperty 'toolbar' not found on UITextField
Property 'toolbar' not found on UITextField
Solution: Import the toolbar library and use
.iq wrapper:Need Help?
If you encounter issues during migration:- Check the GitHub Issues
- Review the individual library documentation
- Create a new issue with your specific problem
Incremental Migration: If the migration seems overwhelming, consider using the CocoaPods subspecs which automatically include the extracted libraries as dependencies.