huridocs / uwazi

Uwazi is a web-based, open-source solution for building and sharing document collections
http://www.uwazi.io
MIT License
242 stars 80 forks source link

Input fields in Translations are loosing focus when start typing in them #6675

Closed salvalacruz closed 3 months ago

salvalacruz commented 7 months ago

Describe the bug Updating translation values under 'Settings > Translations' is very cumbersome. Whenever you click on a field in order to edit the value, the input field is loosing value after adding or deleting a character. You then have to click again in the field to able to proceed with the editing.

To Reproduce Steps to reproduce the behavior:

  1. Go to 'Settings > Translations'
  2. Click on 'Translate' for an item in the corresponding table
  3. Click on any input field with a translation value
  4. Start typing
  5. After entering or deleting a character the input field looses the focus

Expected behavior When the input field has the focus you must be able to type/delete any number of characters without the input field loosing the focus

Screenshots Input field with focus

image

Input field loosing focus after one character is typed

image

Device (please select all that apply)

Browser Safari 17.5, Firefox 128.0 on macOS Sonoma 14.5

Additional context Initial description when the issue was reporting: When entering to any translations screen from /settings/translations/, every time you type a character, the screen blinks in a strange way.

RafaPolit commented 6 months ago

This is happening when changing from dirty to non-dirty and the input is losing focus.

aphilop commented 4 months ago

After testing this in several instances, the blinking seems to be random, sometimes it happens and sometimes not. For me, the real problem here is that whenever you put the focus in a field and start typing, the field is losing focus after adding or deleting a character, making it cumbersome to update the translations (you have to click again in the field and then you can start typing more characters). I"ll rewrite the title and issue description to make the real problem more transparent.