
Security News
Browserslist-rs Gets Major Refactor, Cutting Binary Size by Over 1MB
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
cordova-plugin-ionic-keyboard
Advanced tools
This plugin has been designed to work seamlessly with cordova-plugin-ionic-webview
, so make sure you have it installed first:
cordova plugin add cordova-plugin-ionic-keyboard --save
Boolean (true by default)
true
: Showing/hiding the keyboard will trigger some kind of resizing of the app (see KeyboardResizeMode)false
: Web will not be resized when the keyboard shows up.<preference name="KeyboardResize" value="true" />
String ('native' by default)
native
: The whole native webview will be resized when the keyboard shows/hides, it will affect the vh
relative unit.body
: Only the html <body>
element will be resized. Relative units are not affected, becuase the viewport does not change.ionic
: Only the html ion-app
element will be resized. Only for ionic apps.<preference name="KeyboardResizeMode" value="native" />
Hide the keyboard toolbar.
Set to true to hide the additional toolbar that is on top of the keyboard. This toolbar features the Prev, Next, and Done buttons.
Keyboard.hideFormAccessoryBar(value, successCallback);
Keyboard.hideFormAccessoryBar(true);
Keyboard.hideFormAccessoryBar(false);
Keyboard.hideFormAccessoryBar(null, (currentValue) => { console.log(currentValue); });
Hide the keyboard
Call this method to hide the keyboard
Keyboard.hide();
Show the keyboard
Call this method to show the keyboard.
Keyboard.show();
Determine if the keyboard is visible.
Read this property to determine if the keyboard is visible.
if (Keyboard.isVisible) {
// do something
}
This event is fired when the keyboard is fully closed.
Attach handler to this event to be able to receive notification when keyboard is closed.
window.addEventListener('keyboardDidHide', () => {
// Describe your logic which will be run each time keyboard is closed.
});
This event is fired when the keyboard is fully open.
Attach handler to this event to be able to receive notification when keyboard is opened.
window.addEventListener('keyboardDidShow', (ev) => {
// Describe your logic which will be run each time when keyboard is about to be shown.
console.log(event.keyboardHeight);
});
This event fires before keyboard will be shown.
Attach handler to this event to be able to receive notification when keyboard is about to be shown on the screen.
window.addEventListener('keyboardWillShow', (ev) => {
// Describe your logic which will be run each time when keyboard is about to be shown.
console.log(event.keyboardHeight);
});
This event is fired when the keyboard is fully closed.
Attach handler to this event to be able to receive notification when keyboard is about to be closed.
window.addEventListener('keyboardWillHide', () => {
// Describe your logic which will be run each time when keyboard is about to be closed.
});
FAQs
Ionic Keyboard Plugin
The npm package cordova-plugin-ionic-keyboard receives a total of 22,386 weekly downloads. As such, cordova-plugin-ionic-keyboard popularity was classified as popular.
We found that cordova-plugin-ionic-keyboard demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 19 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Browserslist-rs now uses static data to reduce binary size by over 1MB, improving memory use and performance for Rust-based frontend tools.
Research
Security News
Eight new malicious Firefox extensions impersonate games, steal OAuth tokens, hijack sessions, and exploit browser permissions to spy on users.
Security News
The official Go SDK for the Model Context Protocol is in development, with a stable, production-ready release expected by August 2025.