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

Ordered List is not working properly in all android devices

Open ThejazR opened this issue 3 years ago • 13 comments

For example in realme and samsung devices its showing as

1 Apple 1 Orange 1 Mango

Expected

  1. Apple
  2. orange
  3. mango

Alwasys 1 is coming the subsequent numbers like 2 , 3, .... are not coming.

ThejazR avatar Aug 27 '21 16:08 ThejazR

I'm also getting the same issue.

Seems like the editor creates a separate set of <ul>---</ul> while tapping either return-key or selecting any suggestion on keyboard

swalahamani avatar Sep 06 '21 11:09 swalahamani

Seems like related to #120

swalahamani avatar Sep 06 '21 11:09 swalahamani

@swalahamani You can fix this buy disabling the autocorrect or text prediction option from the mobile keyboard.

ThejazR avatar Sep 07 '21 09:09 ThejazR

@ThejazR Without disabling those options, Can I fix this error?

LOMFM avatar Sep 13 '21 09:09 LOMFM

I am also experiencing this on multiple Android devices. When I add a new number it works correctly until I try to focus the next list item in order to add text.

becomes

  1. text here

This issue also occurs for bullet lists.

apprisemobile-lyu avatar Sep 30 '21 15:09 apprisemobile-lyu

@swalahamani You can fix this by disabling the autocorrect or text prediction option from the mobile keyboard.

Yeah, that is correct. But it seems like the only way to do that is via the settings app and couldn't find any programmatical way.

swalahamani avatar Nov 12 '21 05:11 swalahamani

in editor.js
function formatParagraph(async) if (async == true) return; Can solved I don't know if there will be any other problems

shijinwu avatar Dec 16 '21 01:12 shijinwu

@shijinwu Can you provideinitialContentHTML for me to test

stulip avatar Dec 28 '21 06:12 stulip

@stulip This does not need initial content. Here are the steps to reproduce though:

  1. With the editor empty, type "Hello".
  2. Press Enter 2 times.
  3. Tap on the number list icon.
  4. Type "One" and then press enter.
  5. Type "Two".

Expected Output

Hello

  1. One
  2. Two

Actual Output:

Hello

1.One

1.Two

BadhanGanesh-HappyFox avatar Aug 10 '22 09:08 BadhanGanesh-HappyFox

RichEditor supports html props, which was forgotten to be mentioned in the documentation. I moved the createHtml function to my project and modified it to solve this problem. #245

Kirysha avatar Dec 16 '22 11:12 Kirysha

So whats the fix?

sujathasperi2022 avatar Apr 28 '23 10:04 sujathasperi2022

@sujathasperi2022

addEventListener(content, 'compositionstart', function(event){
    compositionStatus = 1;
})
addEventListener(content, 'compositionend', function (event){
    compositionStatus = 0;
    paragraphStatus && formatParagraph(true);
})

I commented out these lines in the html file these lines are only needed if you want to use hieroglyphs in your application.

Kirysha avatar Apr 28 '23 11:04 Kirysha

I added my idea to the pull request. You can watch this #314 .

Kirysha avatar May 18 '23 14:05 Kirysha