Open Bug 1874860 Opened 2 years ago Updated 2 years ago

Text Prompt is limited to 5000 chars

Categories

(Firefox for Android :: General, defect)

All
Android
defect

Tracking

()

People

(Reporter: jackyzy823, Unassigned)

Details

From: https://old.reddit.com/r/firefox/comments/1920qq2/potential_bug_prompt_dialog_box_character_limit/

I've encountered a potential bug with the Android prompt dialog box. I'm trying to paste in a ~16,000 character string (it's a game save), but the text field is truncating it to the first 5,000 characters. I've encountered it on more than one website, and in both Firefox and Firefox Nightly.

Steps to reproduce

  1. Go to https://ducdat0507.github.io/communitree/
  2. Select Settings > Saving > Export to clipboard
  3. Select Import and paste in the copied string

Expected behavior

Could paste full string

Actual behavior

Could only paste first 5000 chars.

Any additional information?

The text prompt dialog code: https://searchfox.org/mozilla-mobile/rev/0db65a3e08fc3a0423d312ba1e624e90572cb565/firefox-android/android-components/components/feature/prompts/src/main/java/mozilla/components/feature/prompts/dialog/TextPromptDialogFragment.kt#71

It is the limitation of Android's TextView (base class of EditText)

Note that due to performance reasons, by setting single line for the EditText, the maximum text length is set to 5000 if no other character limitation are applied.

Summary: Text Prompt is limit to 5000 chars → Text Prompt is limited to 5000 chars

The severity field is not set for this bug.
:tthibaud, could you have a look please?

For more information, please visit BugBot documentation.

Flags: needinfo?(tthibaud)
Severity: -- → S3
Flags: needinfo?(tthibaud)
You need to log in before you can comment on or make changes to this bug.