RealGrid2 Guide
Editor
Multiline editor

Multi-line editor

Multi-line editor allows you to input multiple lines of text divided by line separators. The editor resizes to fit the text being entered. You can break lines with Ctrl+Enter.

The default line break key is ctrl+enter, but if you set the altEnterNewLine property to true, the line breaks when you type the alt+enter key.

You must apply the white-space CSS style to the column where you want to use a line break so that it is displayed as a line break when using \n.

//*.css
.multiline-editor{
   white-space: pre;
}

To set automatic line wrapping, you must set the white-space CSS style to pre-line in the column where you want to use line wrapping. In the case of English letters, words cannot be cut and line-wrapped; lines can only be broken with spaces or spacing.

//*.css
.multiline-editor{
   white-space: pre-line;
}
var columns = [
   {
       name: "CompanyName",
       fieldName: "CompanyName",
       width: "200",
       editor: {
           type: "multiline",
           altEnterNewLine:true
       },
       styleName: "multiline-editor",
       header: {
           text: "Multiline Edit",
           styleName: "orange-column multiline-editor"
       }
   },