react-native
react-native copied to clipboard
[IOS] [FIXED] - Fix TextInput's maxLength limit when use a non-English input method
Summary:
When using a non-English input method, and the TextInput’s maxLength is set, some temporary characters are also added to the maximum length, which should not be the case.
Changelog:
[IOS] [FIXED] - Fix TextInput's maxLength limit when use a non-English input method.
Test Plan:
Before fixed I can't input '65432黄'. 'huang' is the Chinese word for '黄'.
After fixed TextInput's maxLength can work for English input and a non-English input:
| Platform | Engine | Arch | Size (bytes) | Diff |
|---|---|---|---|---|
| android | hermes | arm64-v8a | 8,889,597 | -2 |
| android | hermes | armeabi-v7a | 7,940,123 | -1 |
| android | hermes | x86 | 9,287,481 | +1 |
| android | hermes | x86_64 | 9,191,300 | +0 |
| android | jsc | arm64-v8a | 9,479,590 | +0 |
| android | jsc | armeabi-v7a | 8,422,682 | -2 |
| android | jsc | x86 | 9,463,163 | +0 |
| android | jsc | x86_64 | 9,780,068 | -2 |
Base commit: c1eec4cc51c15037afea25351ffa0ea3a0f848f0 Branch: main
这个问题能得到解决吗,我也遇到了限制20个字符长度,由于我是中国用户,ios特殊的输入法会导致计算中文拼音而超长,但是实际上我并没有输入超过20个字
这个问题能得到解决吗,我也遇到了限制20个字符长度,由于我是中国用户,ios特殊的输入法会导致计算中文拼音而超长,但是实际上我并没有输入超过20个字
好久没人处理这个 pr 了,你可以用这个试试,好像 0.72+ 的都没问题,如果 crash 了就算了,可能会有冲突问题 https://www.npmjs.com/package/react-native-textinput-maxlength-fixed
这个问题能得到解决吗,我也遇到了限制20个字符长度,由于我是中国用户,ios特殊的输入法会导致计算中文拼音而超长,但是实际上我并没有输入超过20个字
好久没人处理这个 pr 了,你可以用这个试试,好像 0.72+ 的都没问题,如果 crash 了就算了,可能会有冲突问题 https://www.npmjs.com/package/react-native-textinput-maxlength-fixed
我的版本比较低,感谢大佬,我试试
This PR is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 7 days.
Didn't anyone review this?