Datatable handles incorrectly new line characters in textarea field

Description

Reproduction Steps:

1. Build Master
2. Go to Demos/datatable folder and open index.html
3. Double click on a city cell to edit content
4. Write a new line character and a text

Actual result: content will be "New York<br>Budapest"
Expected result: content is
"New York
Budapest"

5. Double click again on this cell to edit content

Actual result: content in the editor will be "New YorknBudapest"
Expected result: content in the editor is
"New York
Budapest"

Please watch my attached gif

Environment

None

Attachments

1
  • 28 Dec 2016, 07:09 AM

Activity

Show:

Cristina Rodríguez YrezábalNovember 30, 2018 at 3:34 AM
Edited

Hi and ,

One of our customers has also reported this problem, this time the one described in LPS-87962. In this case, you can check that the script field in the Kaleo Designer also contains the <br> codes when it is saved. This makes the script eventually fail because of formatting issues.

As you can see this is the same problem from the Kaleo Description field mentioned in AUI-3112, but now, as I mentioned, the script field is a multiline textarea one.

That's why I, like , also wondered if any progress has been made related to this issue, or if you have any tip or idea on how to proceed with a valid solution without causing any 'known' regressions. I'm currently working on it but I haven't found any 'solid' fix so far, except for the one that changes the AlloyUIVersion of the related modules to an older one.

Thank you very much in advance.

Gregory BretallJanuary 25, 2018 at 9:40 AM

Hi ,

One of our new TSE's was working on this same issue as documented over on LPS-77385. We are interested in continuing devleoping a solution for this but were wondering if you had any guidance or progress that had already been made towards fixing this issue without causing the regressions discussed in https://liferay.atlassian.net/browse/AUI-3112#icft=AUI-3112. Please let me know if you have any information that could help with the creation of a solution for this.

Thanks,
Greg

Jonathan MakJuly 28, 2017 at 10:25 AM

Jonathan MakJuly 21, 2017 at 9:43 AM

Arthur ChenJune 26, 2017 at 1:54 AM
Edited

Hi ,

I am working on LPP-26001.
After debugging, I found commit of "AUI-3094 Using editor instance's output formatter" is causing the bug in LPP-26001(which actually has more issues than the description provided by CSE, for example, the date format is insistent between added on spreadsheet and added on normal view. Also the the date entered on spreadsheet will crash on normal view).
I can fix LPP-26001 by changing outputformatter to inputformatter, but I am not sure what was the problem you were trying to fix with "AUI-3094 Using editor instance's output formatter".

Also, according to API decritption, the formatValue() function is supposed to take an inputformatter.

I will send you a pull request, if you can take a look.

Edit: I have created a new https://liferay.atlassian.net/browse/AUI-3112#icft=AUI-3112 ticket, and updated that LPP description.

Completed
Created December 28, 2016 at 6:47 AM
Updated October 20, 2021 at 1:03 AM
Resolved October 20, 2021 at 1:03 AM

Flag notifications