Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

contenteditable属性を利用して作られた入力ボックスへの対応 #5

Open
mono0x opened this issue Apr 27, 2013 · 2 comments

Comments

@mono0x
Copy link
Contributor

mono0x commented Apr 27, 2013

私は今のところTwitterでしか見たことはありませんが、inputタグやtextareaタグの代わりに、contenteditable属性を利用してリッチな入力ボックスを提供している場合があるようです。

そこで、contenteditable属性を利用して作成された入力ボックスを認識し、アクションの無効化とvi like actionsの有効化が正しく行われるようにしてみました。コードは以下のとおりです。

mono0x/ChromeKeyconfig@f5aafe7

ただ、現状ではvi like actionsのカーソル移動の挙動に問題があるので、pull requestは送っていません。具体的には、CSSのoverflow:scrollが設定された入力ボックス (Twitterの入力ボックス) で、キャレットが移動した結果見えなくなるような場合に、スクロールせず、キャレットが見えない位置へ消えてしまいます。

解決方法がわからなかったため、不完全な状態での報告になり申し訳ありません。

@os0x
Copy link
Owner

os0x commented Apr 30, 2013

@mono0x
もし良ければ、アクションの無効化だけをpull requestして頂けますか?
ひとまずそれだけ取り込んでしまおうと思います。
手間でしたらこちらで作業します。

@mono0x
Copy link
Contributor Author

mono0x commented Apr 30, 2013

#6 としてpull requestしました。
とりあえず、contenteditable要素が付いている場合にはVi like actionsが動かないようにしています。
よろしくお願いします。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants