react-native-zss-rich-text-editor icon indicating copy to clipboard operation
react-native-zss-rich-text-editor copied to clipboard

Not work in targetSdkVersion : 24 in android

Open boythan opened this issue 7 years ago • 18 comments

work well in IOS and android with targetSdkVersion < 24 but targetSdkVersion >=24. Please give some suggestions

boythan avatar Apr 03 '18 05:04 boythan

I can't see any issues with targetSdkVersion 24.

What is the error you encountered?

charpeni avatar Apr 03 '18 17:04 charpeni

@charpeni with targetSdkVersion 24, i can't do anything in RichTextEditor Screen, app get stuck.

boythan avatar Apr 04 '18 02:04 boythan

i same issue, ios work good but android with targetSdkVersion 25, can't do anything in RichTextEditor Screen

leanhforevo avatar Apr 06 '18 04:04 leanhforevo

Any update on this? Facing the same issue on targetSdkVersion 27

kaustubheksambekar avatar Apr 27 '18 06:04 kaustubheksambekar

any update for targetSdkVersion 27?

rasselll avatar Jun 04 '18 14:06 rasselll

Oh I see, with targetSdkVersion 27 and probably from 24, the editor is really slow and we can't select anything because the focus is lost. Looks like it may be related to the scroll event, I'll try to look at this.

If you find anything, feel free to ping me.

charpeni avatar Jun 04 '18 17:06 charpeni

The error is located in getCaretYPosition:

https://github.com/wix/react-native-zss-rich-text-editor/blob/2cad3349dbac79713065eed33a211e67dab2f680/src/editor.html#L1027-L1038

Especially with range.collapse(false). I'm still trying to find a clean way to fix this.

charpeni avatar Jun 04 '18 18:06 charpeni

did you manage to find any solutions to this?

rasselll avatar Jun 07 '18 12:06 rasselll

@charpeni did you have a solution now? tks

jeffie avatar Jun 11 '18 14:06 jeffie

@rasselll @jeffie i switched to use android native module lib and then map it to JS code. i used this lib in android native : https://github.com/wasabeef/richeditor-android

boythan avatar Jun 13 '18 04:06 boythan

targetSdkVersion 27, can't do anything ...

tzurae avatar Jun 13 '18 09:06 tzurae

A solution is available here: #115.

"react-native-zss-rich-text-editor": "https://github.com/charpeni/react-native-zss-rich-text-editor.git#fix-selection-focus",

charpeni avatar Jun 13 '18 15:06 charpeni

@charpeni It's still not working :(
but thank you : )

tzurae avatar Jun 14 '18 03:06 tzurae

@joey3060 have you rebuilt your app on Android? The fix is in editor.html and it needs to be copied by the gradle script. Otherwise, you'll get the old version.

charpeni avatar Jun 14 '18 03:06 charpeni

@charpeni it's working , thank you : )

tzurae avatar Jun 14 '18 03:06 tzurae

Hi,bro! I have followed the way as you say and in android 7.1.1 version, it , in fact, is fixed and worked normally, but in android 5.0.0, it cannot work that it can work before i have fixed as above. Can it fit just part of android version? Now, the problem is that if i fixed as you did, it can work well in android 7.1.1, but in android 5.0.0 it cannot work. If i don't fixed it followed you, it cannot work in android 7.1.1, but in android 5.0.0, it is normal.

jichangshuai avatar Jun 19 '18 01:06 jichangshuai

I've the same issue for for android >8.0, the editor is very slow and i can't highlight the text. Does anyone have any fix for this yet?

unamed000 avatar Jul 13 '18 03:07 unamed000

yeah, there is time lag when make bold,italics,underline and even colors... I have made a fix by forking the repo. https://github.com/mehthabt/react-native-zss-rich-text-editor. just install this repo in your dependency.

mehthabt avatar Nov 28 '19 08:11 mehthabt