私はテキストボックスを持っていて、jquery でキーアップイベントを接続しています。ユーザーがブラウザの自動修正機能を使用する場合を除いて、すべてがうまく機能します。
単語が修正された場合、jquery は keyup イベント (または私が知ることができるその他のイベント) を登録しません。
テキストボックスが自動修正によって変更されたときに呼び出されるイベントを取得するにはどうすればよいですか?
アップデート
ここに作業を行うコードスニペットがあります
$(function() {
//two styles of live field
var style1 = " Youth Congress";
var style2 = "Youth Congress Of ";
// #CharterName is the input text
// #dynamicName is the output span
function update() {
if (!$("#rb_NameStyle_Prepend").is(':checked')) {
$("#dynamicName").html($("#CharterName").val() + style1);
} else {
$("#dynamicName").html(style2 + $("#CharterName").val());
}
}
update();
#These are just radio buttons
$("#rb_NameStyle_Prepend").change(update);
$("#rb_NameStyle_Append").change(update);
// If I can find an event that is called on an autocorrect,
// I would just add it to the list
$("#CharterName").keyup(update);
$("#CharterName").blur(update);
$("#CharterName").change(update);
});