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

Add a temp patch fixing Korean/Chinese characters input in RN 0.55.x (iOS). #4837

Merged
merged 1 commit into from
Jun 20, 2018

Conversation

mandrigin
Copy link
Contributor

@mandrigin mandrigin commented Jun 19, 2018

The fix itself is described here: facebook/react-native#19809

The patch:

  1. A copy of patched RCTUITextView.m file
  2. A pre-action in the "Build" scheme to patch the RN file. See more on
    pre-actions here: https://burcugeneci.wordpress.com/2016/05/25/scripts-we-love-xcode-builds-life-savers/
  3. A build step to fail the build if the file wasn't patched.

I don't use diffs or anything there because this patch will be applied before every build, essentially.

--

The follow-up issue for using our own RN fork: #4850

--

fixes: #4818
fixes: #4829

status: ready

@status-comment-bot
Copy link

status-comment-bot commented Jun 19, 2018

branch PR-4837:
apk uploaded to
ipa uploaded to https://i.diawi.com/Rm9PYp

@mandrigin
Copy link
Contributor Author

@lukaszfryc @annadanchenko I temporarily left only iOS build here, it turns out it is not that easy to set it up to a custom branch.

@lukaszfryc lukaszfryc self-assigned this Jun 20, 2018
@lukaszfryc
Copy link
Contributor

@mandrigin looks like it's working! At least for Chinese and Japanese. Previously, each new letter typed was considered individually. Now they are combined which is the expected result according.

But, when I test Korean, I don't notice any difference so I'm not sure if it's fixed there. I even tried your test scenario from facebook/react-native#19809 and my result is ㅍㅏㄹㅏㄴ하늘 instead of 파란하늘. @mandrigin does it work on your side?

Btw, also good news is that I can't reproduce #4818 on this build!

@mandrigin
Copy link
Contributor Author

@lukaszfryc yeah, I was actually testing it on a Korean keyboard, so both gifs in the PR are for it.
did you follow the exact steps? Which OS was it?

@lukaszfryc
Copy link
Contributor

@mandrigin I've just tested it again on Korean keyboard and it works. Strange, I think had to type some incorrect character previously that didn't match the word. I tested it again on iOS 11.4, 11.2.6 and compared with 0.9.20 to be sure of how it looks there and all looks fine 👍

Are we sure that it's not affecting Android and there is no need to test it there?

@mandrigin
Copy link
Contributor Author

yeah, the changes are in iOS-specific area, it doesn't even compile these files for Android

@lukaszfryc
Copy link
Contributor

lukaszfryc commented Jun 20, 2018

@mandrigin any other things apart from input / keyboard that maybe affected (on iOS)? If not, let's review and merge

@mandrigin
Copy link
Contributor Author

@lukaszfryc nope, the code specifically touches multi-line text input on iOS.

@lukaszfryc
Copy link
Contributor

OK. So this works fine. At least on iOS 11.4, 11.2.6 which I think it's enough to test it.

@mandrigin mandrigin force-pushed the bugfix/4829-characters-rn branch from abf2341 to 8f1856d Compare June 20, 2018 09:41
@mandrigin mandrigin changed the title [WIP] Fix Korean/Chinese characters input. Fix Korean/Chinese characters input. Jun 20, 2018
@mandrigin mandrigin requested review from jeluard, cammellos and rasom June 20, 2018 09:43
@mandrigin mandrigin changed the title Fix Korean/Chinese characters input. Add a temp patch fixing Korean/Chinese characters input in RN 0.55.x (iOS). Jun 20, 2018
The fix is described here: facebook/react-native#19809

The patch:
1. A copy of patched RCTUITextView.m file
2. A pre-action in the "Build" scheme to patch the RN file. See more on
   pre-actions here: https://burcugeneci.wordpress.com/2016/05/25/scripts-we-love-xcode-builds-life-savers/
3. A build step to fail the build if the file wasn't patched.

Signed-off-by: Igor Mandrigin <i@mandrigin.ru>
@mandrigin mandrigin force-pushed the bugfix/4829-characters-rn branch from 8f1856d to caba84e Compare June 20, 2018 11:33
@mandrigin mandrigin merged commit caba84e into develop Jun 20, 2018
@rasom rasom deleted the bugfix/4829-characters-rn branch June 26, 2018 09:43
@tonlen
Copy link

tonlen commented Jul 4, 2018

The single line still has problems

@lukaszfryc
Copy link
Contributor

@tonlen could you describe the single line issue in more details with steps how to reproduce it? Btw, have you tried to reproduce it on the latest version from app store 0.9.21?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Text input is broken for Korean, Chinese, Japanese characters Crash while typing chinese characters in chat
6 participants