Completed
Last Updated: 24 Nov 2023 08:24 by ADMIN
Andreas
Created on: 08 Feb 2021 13:42
Category: Editor
Type: Bug Report
0
Editor with tagHelpers is adding unnecesarry new lines to the content

Bug report

When the Editor is configured by using tagHelpers and the configuration of the tools is on multiple lines additional new lines are added to the Editor content due to the tags used for the tool's configuration.

Reproduction of the problem

  1. In UI for ASP.NET Core app use the following Editor configuration:
<button onclick="getValue()">get Value</button>
Test-1:<br /><br /><br /><br />
<kendo-editor name="test1" tag="div" >         
    <tools>
        <tool name="viewHtml" />
    </tools>
</kendo-editor>  
<script>
    function getValue() {
          var editor1 = $("#test1").data("kendoEditor");
          console.log(editor1.value())                   
    };
</script>
  1. Enter for example "1"
  2. Click the 'get Value' button

Current behavior

The value of the editor has additional new lines. The additional lines could be observed also in the 'viewhtml' tool. (screencast)

Expected/desired behavior

There should be no additional new lines added to the Editor's content.

Workaround

Configure the Editor on a single line

<kendo-editor name="test1" tag="div"><tools><tool name="viewHtml" /></tools></kendo-editor>

Environment

  • Kendo UI version: 2021.1.119
  • Browser: [all ]
0 comments