{"id":15716087,"url":"https://github.com/nossbigg/react-native-ios-keyboard-events","last_synced_at":"2025-10-07T20:54:55.813Z","repository":{"id":34670755,"uuid":"168165574","full_name":"nossbigg/react-native-ios-keyboard-events","owner":"nossbigg","description":"A library to detect an iOS device's keyboard stat, especially Split 🎳 and Floating 👻 keyboards!","archived":false,"fork":false,"pushed_at":"2023-01-03T16:12:47.000Z","size":3400,"stargazers_count":9,"open_issues_count":20,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-09-15T01:31:57.931Z","etag":null,"topics":["apple","events","ios","keyboard","react-native","split"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/nossbigg.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-01-29T14:10:57.000Z","updated_at":"2025-02-13T12:17:44.000Z","dependencies_parsed_at":"2023-01-15T08:30:23.481Z","dependency_job_id":null,"html_url":"https://github.com/nossbigg/react-native-ios-keyboard-events","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/nossbigg/react-native-ios-keyboard-events","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nossbigg%2Freact-native-ios-keyboard-events","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nossbigg%2Freact-native-ios-keyboard-events/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nossbigg%2Freact-native-ios-keyboard-events/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nossbigg%2Freact-native-ios-keyboard-events/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/nossbigg","download_url":"https://codeload.github.com/nossbigg/react-native-ios-keyboard-events/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/nossbigg%2Freact-native-ios-keyboard-events/sbom","scorecard":{"id":694731,"data":{"date":"2025-08-11","repo":{"name":"github.com/nossbigg/react-native-ios-keyboard-events","commit":"6551f0c10c995c34f86180a227d65b3bf881640a"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":1.6,"checks":[{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Code-Review","score":0,"reason":"Found 0/30 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Token-Permissions","score":-1,"reason":"No tokens found","details":null,"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Dangerous-Workflow","score":-1,"reason":"no workflows found","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Binary-Artifacts","score":9,"reason":"binaries present in source code","details":["Warn: binary detected: android/gradle/wrapper/gradle-wrapper.jar:1"],"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Pinned-Dependencies","score":-1,"reason":"no dependencies found","details":null,"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"Vulnerabilities","score":0,"reason":"72 existing vulnerabilities detected","details":["Warn: Project is vulnerable to: GHSA-j6gc-792m-qgm2","Warn: Project is vulnerable to: GHSA-pj73-v5mw-pm9j","Warn: Project is vulnerable to: GHSA-7627-mp87-jf6q","Warn: Project is vulnerable to: GHSA-g397-v4w5-4m79","Warn: Project is vulnerable to: GHSA-jphg-qwrw-7w9g","Warn: Project is vulnerable to: GHSA-5cm2-9h8c-rvfx","Warn: Project is vulnerable to: GHSA-968p-4wvh-cqc8","Warn: Project is vulnerable to: GHSA-67hx-6x53-jw92","Warn: Project is vulnerable to: GHSA-6chw-6frg-f759","Warn: Project is vulnerable to: GHSA-v88g-cgmw-v5xw","Warn: Project is vulnerable to: GHSA-93q8-gq69-wqmw","Warn: Project is vulnerable to: GHSA-fwr7-v2mv-hh25","Warn: Project is vulnerable to: GHSA-v6h2-p8h4-qcjw","Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg","Warn: Project is vulnerable to: GHSA-xp63-6vf5-xf3v","Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275","Warn: Project is vulnerable to: GHSA-gxpj-cx7g-858c","Warn: Project is vulnerable to: GHSA-w573-4hg7-7wgq","Warn: Project is vulnerable to: GHSA-fjxv-7rqg-78g4","Warn: Project is vulnerable to: GHSA-8r6j-v8pm-fqw3","Warn: Project is vulnerable to: MAL-2023-462","Warn: Project is vulnerable to: GHSA-765h-qjxv-5f44","Warn: Project is vulnerable to: GHSA-f2jv-r9rf-7988","Warn: Project is vulnerable to: GHSA-43f8-2h32-f4cj","Warn: Project is vulnerable to: GHSA-qqgx-2p2h-9c37","Warn: Project is vulnerable to: GHSA-896r-f27r-55mw","Warn: Project is vulnerable to: GHSA-9c47-m6qq-7p4h","Warn: Project is vulnerable to: GHSA-6c8f-qphg-qjgp","Warn: Project is vulnerable to: GHSA-p6mc-m468-83gw","Warn: Project is vulnerable to: GHSA-29mw-wpgm-hmr9","Warn: Project is vulnerable to: GHSA-35jh-r3h4-6jhm","Warn: Project is vulnerable to: GHSA-v8v8-6859-qxm4","Warn: Project is vulnerable to: GHSA-4xcv-9jjx-gfj3","Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv","Warn: Project is vulnerable to: GHSA-f8q6-p94x-37v3","Warn: Project is vulnerable to: GHSA-vh95-rmgr-6w4m","Warn: Project is vulnerable to: GHSA-xvch-5gv4-984h","Warn: Project is vulnerable to: GHSA-r683-j2x4-v87g","Warn: Project is vulnerable to: GHSA-w7rc-rwvf-8q5r","Warn: Project is vulnerable to: GHSA-5fw9-fq32-wv5p","Warn: Project is vulnerable to: GHSA-76c9-3jph-rj3q","Warn: Project is vulnerable to: GHSA-hj48-42vr-x3v9","Warn: Project is vulnerable to: GHSA-4cpg-3vgw-4877","Warn: Project is vulnerable to: GHSA-hrpp-h998-j3pp","Warn: Project is vulnerable to: GHSA-rxrc-rgv4-jpvx","Warn: Project is vulnerable to: GHSA-7f53-fmmv-mfjv","Warn: Project is vulnerable to: GHSA-p8p7-x288-28g6","Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw","Warn: Project is vulnerable to: GHSA-m6fv-jmcg-4jfg","Warn: Project is vulnerable to: GHSA-cm22-4g7w-348p","Warn: Project is vulnerable to: GHSA-g4rg-993r-mgx7","Warn: Project is vulnerable to: GHSA-gff7-g5r8-mg8m","Warn: Project is vulnerable to: GHSA-3jfq-g458-7qm9","Warn: Project is vulnerable to: GHSA-r628-mhmh-qjhw","Warn: Project is vulnerable to: GHSA-9r2w-394v-53qc","Warn: Project is vulnerable to: GHSA-5955-9wpr-37jh","Warn: Project is vulnerable to: GHSA-qq89-hq3f-393p","Warn: Project is vulnerable to: GHSA-f5x3-32g6-xq36","Warn: Project is vulnerable to: GHSA-52f5-9888-hmc6","Warn: Project is vulnerable to: GHSA-jgrx-mgxx-jf9v","Warn: Project is vulnerable to: GHSA-72xf-g2v4-qvf3","Warn: Project is vulnerable to: GHSA-662x-fhqg-9p8v","Warn: Project is vulnerable to: GHSA-394c-5j6w-4xmx","Warn: Project is vulnerable to: GHSA-78cj-fxph-m83p","Warn: Project is vulnerable to: GHSA-fhg7-m89q-25r3","Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q","Warn: Project is vulnerable to: GHSA-6fc8-4gx4-v693","Warn: Project is vulnerable to: GHSA-h6q6-9hqw-rwfv","Warn: Project is vulnerable to: GHSA-5fg8-2547-mr8q","Warn: Project is vulnerable to: GHSA-crh6-fp67-6883","Warn: Project is vulnerable to: GHSA-c4w7-xm78-47vh","Warn: Project is vulnerable to: GHSA-p9pc-299p-vxgp"],"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}}]},"last_synced_at":"2025-08-22T03:21:19.335Z","repository_id":34670755,"created_at":"2025-08-22T03:21:19.335Z","updated_at":"2025-08-22T03:21:19.335Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278846350,"owners_count":26056090,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-07T02:00:06.786Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["apple","events","ios","keyboard","react-native","split"],"created_at":"2024-10-03T21:44:00.553Z","updated_at":"2025-10-07T20:54:55.798Z","avatar_url":"https://github.com/nossbigg.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# react-native-ios-keyboard-events\n\n![Build Badge](https://travis-ci.com/nossbigg/react-native-ios-keyboard-events.svg?branch=master) [![codecov](https://codecov.io/gh/nossbigg/react-native-ios-keyboard-events/branch/master/graph/badge.svg)](https://codecov.io/gh/nossbigg/react-native-ios-keyboard-events) [![npm version](https://badge.fury.io/js/react-native-ios-keyboard-events.svg)](https://badge.fury.io/js/react-native-ios-keyboard-events)\n\n**A `react-native` library to detect an Apple iOS device's keyboard state.**\n\nEspecially useful if you need to detect a split or floating keyboard on an iPad (so that you can make UI adjustments to accomodate it)\n\nWorks _✨nicely✨_ with `KeyboardAvoidingView` 👍🏻\n\n![GIF Demo of library](docs/library-demo.gif)\n\nExample: [AppDemo.tsx](AppDemo.tsx)\n\n## Usage (tldr)\n\n1. Install the library\n\n```bash\nnpm install react-native-ios-keyboard-events\n```\n\n2. Create an `IOSKeyboardEvents` instance\n\n```javascript\nimport { createIOSKeyboardEvents } from \"react-native-ios-keyboard-events\";\nconst IOSKbEvents = createIOSKeyboardEvents();\n```\n\n3. Listen to keyboard state changes 😀\n\n```javascript\nIOSKbEvents.addListener(\n  \"some-listener-name\",\n  (newKeyboardState, previousState) =\u003e\n    console.log(`transition: ${previousState} -\u003e ${newKeyboardState}`),\n);\n```\n\n4. Close it when you're done\n\n```javascript\nIOSKbEvents.close();\n```\n\n## API\n\n### Constructor\n\n#### `createIOSKeyboardEvents(options)`\n\nCreates an `IOSKeyboardEvents` instance.\n\nThis method will attempt to detect the device model type by checking the device's window resolution (via `Dimensions.get`). It will error out if it is unable to find a matching device or if the library is run in a non-iOS device.\n\n`options`:\n\n- `keyboardEventDebounceTime`: (default: 100) Defines the time (in ms) to debounce sending updates to registered listeners. Increase to smoothen out keyboard state changes.\n\n(Note: keyboard state changes may flicker on certain transitions eg. `CLOSED` -\u003e `DOCKED`, due to the nature in which Apple sends out keyboard notifications and this library, in turn, interpreting the events)\n\n- `deviceModel`: Passes in a manually-defined `IDeviceModel` object. Useful when using custom keyboards. (note: if supplied, platform check will be ignored)\n\n### Instance Methods\n\n#### `.addListener(listenerName: string, callback: (newKeyboardState, previousState) =\u003e void)`\n\nAdds a listener to the `IOSKeyboardEvents` instance. Calls the callback on any keyboard state change.\n\nNote: Adding a new listener will override any existing listeners with the same `listenerName`.\n\n#### `.removeListener(listenerName: string)`\n\nRemoves the listener with the corresponding `listenerName`.\n\n#### `.close()`\n\nGracefully closes the `IOSKeyboardEvents` instance by unsubscribing from keyboard events, listeners, and timers.\n\n#### `.getKeyboardState()`\n\nReturns the present keyboard state.\n\nPossible `KeyboardState`s:\n\n- `CLOSED`\n- `MINIMIZED`\n- `DOCKED`\n- `UNDOCKED`\n- `SPLIT`\n- `FLOATING` (iOS v13)\n\n#### `.setKeyboardState(newKeyboardState: KeyboardState)`\n\nSets the instance's tracked keyboard state. Use it if, for one reason or another, the `IOSKeyboardEvents` instance's internal state is inconsistent with the actual keyboard state. (eg. Keyboard is `MINIMIZED` but instance reports as the keyboard being `DOCKED`). This may occur as this library listens to `Keyboard` events to determine the keyboard state.\n\nThrows an error if input is not a `KeyboardState` value.\n\nNote: This method does NOT do keyboard actions (eg. dismissing the keyboard)\n\n#### `.getDeviceModelInformation()`\n\nReturns the matched detected device. (or manually-defined `IDeviceModel` object)\n\n## Compatibility\n\n### Platform\n\n- `iOS` only\n- iOS versions `12.x` and `13.x`\n- `React Native` \u003e= 0.58.1\n- `React` \u003e= 16.6.3\n- Also works for iPhone-only apps on iPad\n\n### Supported Devices\n\n#### Phones\n\n- iPhone 5s/SE\n- iPhone 6/6s/7/8\n- iPhone 6/6s/7/8 Plus\n- iPhone X\n- iPhone XS/XS Max\n- iPhone XR\n- iPhone 11/11 Pro/11 Pro Max\n\n#### Tablets\n\n- iPad (5th/6th generation)\n- iPad Air/Air 2/3rd generation\n- iPad Pro (9.7-inch)\n- iPad Pro (10.5-inch)\n- iPad Pro (11-inch)\n- iPad Pro (12.9-inch) (1st/2nd/3rd generation)\n\n## Contributing\n\nBugs? Feature requests? Clarifications? Raise an issue/PR :)\n\n## Release notes\n\nSee [Release Notes](docs/release-notes.md)\n\n#### Dev box prerequisites\n\n- `react-native-cli`\n- xcode version \u003e=10\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnossbigg%2Freact-native-ios-keyboard-events","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnossbigg%2Freact-native-ios-keyboard-events","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnossbigg%2Freact-native-ios-keyboard-events/lists"}