Text Area rows and columns setting has not effect on the Ric

Posted by IramK on 13-Oct-2015 09:10

Hello,

I just noticed the setting to set the rows and columns of the Rich Text HTML editor in the design page has no longer has any effect on the size of the Rich Text HTML Text area editor. Is there another way to achieve this now in the New UI? Kindly let me know.

Cheers.

All Replies

Posted by Srinivas Panyala on 13-Oct-2015 09:29

Hi,

These properties are not applicable for Rich Text Editor. Please follow the below steps to adjust Rich Text Editor width & height.

1) Navigate to Design this page

2) Add a script component (Drag and drop from left side to section of Text area).

3) Paste the following code

<script>

   $(document).ready(function () {

       $("iframe").width(678);

       $("iframe").height(526);

   });

</script>

4) Click on save

Thanks

Srinivas

Posted by IramK on 13-Oct-2015 10:18

Hello @Srinivas,

The width setting does not work unfortunately. The width still stays the same. Any suggestions on how I can fix that please?

Posted by Mohammed Siraj on 13-Oct-2015 11:52

In New UI, TextArea field which is rendered as Rich Text Editor has been re-done using kendo controls & does not honor rows & cols settings.

Instead, to set dimension of TextArea - Rich Text Editor control, set dimensions on a wrapper div with class identifier 'rbs-editField-valueContainer-richTextEditor'.

Eg (via scripts):

var fieldContext = rbf_getFieldContext('TextAreaR'); //textArea field integration name

if (fieldContext) {

 var textAreaEl = fieldContext.getNode();

 var wrapperDiv = textAreaEl && textAreaEl.closest('.rbs-editField-valueContainer-richTextEditor');

 if (wrapperDiv) {

   wrapperDiv.width('50%');

 }

}

Eg (via stylesheet):

//will apply for all rich text editor controls in a page..

.rbs-editField-valueContainer-richTextEditor {

   width: 50%;

}

Posted by Charles Ford on 18-Apr-2018 06:29

Hello,

I tried setting a smaller height (with CSS then JS) but I've not been able to change the number of rows displayed!

Kindly let me know if it is possible to change the initial number of rows?

Thanks

--

Charles

Posted by Srinivas Panyala on 19-Apr-2018 05:17

Please use below script.

<script>

var fieldContext = rbf_getFieldContext('TextAreaField'); //textArea field integration name

if (fieldContext) {

var kendoEditor = fieldContext.getKendoConfig();

  kendoEditor.wrapper.height('50px');

 var iframeobj = kendoEditor.wrapper.find('iframe');

 iframeobj.height(50);

}

</script>

Thanks

Srinivas

Posted by Charles Ford on 24-Apr-2018 03:10

Hello Srinivas,

Thanks, that script has worked just fine.

This thread is closed