Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

bug(keyboard): Android `WindowInsetsAnimationCompat.Callback` does not filter by `Type.ime()` — any inset animation re-emits keyboardWillShow/keyboardDidShow (or the hide pair) with the current IME state

オープン 初心者向け
#2,616 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
72/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
android, java
領域
backend, mobile

調査の方向性

Keyboard.java の onStart(animation, bounds) と onEnd(animation) の付近から始めてください。issue には、アニメーションタイプのマスクがチェックされていないと書かれています。WindowInsetsAnimationCompat がどのようにタイプマスクを公開しているか、既存のコールバックがどのようにキーボードイベントを発行するかを調べてください。Type.ime() に関係しないアニメーションではキーボードイベントが発生せず、IME アニメーションでは期待される表示イベントと非表示イベントが引き続き発生すれば完了です。

索引モデルが issue の本文から書いたものです。

説明

triage
Plugin

Keyboard 8.0.6

Current Behavior

Keyboard.java L90–128: onStart(animation, bounds) (L90) and onEnd(animation) (L114) never inspect animation.getTypeMask(). For every WindowInsetsAnimation dispatched to the root view they read insets.isVisible(Type.ime()) and emit:

  • keyboardWillShow + keyboardDidShow (with the current IME height) if the keyboard happens to be visible,
  • keyboardWillHide + keyboardDidHide otherwise.

So an animation of the system bars (immersive mode toggling, navigation-bar hide/show, a status-bar animation triggered by an overlay) while the keyboard is open replays a full show sequence to JS although the keyboard did not move; with the keyboard closed it replays a hide sequence although nothing was open.

Observed on the Android 14 emulator (API 34, Pixel 6 profile, 1080×2400 @ 420 dpi, Gboard, 3-button navigation), app with @capacitor/keyboard 8.0.6 and @capacitor/status-bar 8.0.4, listeners on all four events, trigger = StatusBar.hide() followed 1.2 s later by StatusBar.show() (both animate the status-bar inset through WindowInsetsControllerCompat; the keyboard itself was not touched):

Keyboard open and settled (keyboardHeight: 336 had been reported once):

ms after hide() event payload
40 keyboardWillShow {keyboardHeight: 336}
1241 keyboardDidShow {keyboardHeight: 336}
1251 keyboardWillShow {keyboardHeight: 336}
1766 keyboardDidShow {keyboardHeight: 336}

Keyboard closed:

ms after hide() event
30 keyboardWillHide
1219 keyboardDidHide
1230 keyboardWillHide
1747 keyboardDidHide

Four keyboard events per status-bar round trip in both states, with nothing having changed about the keyboard. An app that animates its composer on keyboardWillShow/keyboardWillHide re-runs that animation each time (and, with the keyboard closed, runs a hide ride for a keyboard that was never open).

Expected Behavior

Keyboard events describe the keyboard: an animation of the status or navigation bars, with the keyboard not moving, produces none.

主要言語
Java
スター
685
フォーク
691
平均マージ
16時間 33分
マージ済み PR(30日)
1

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

ionic-team/capacitor-plugins のほかの issue

ionic-team/capacitor-plugins の issue をすべて見る

似ている issue

Java の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。