This is a migrated thread and some comments may be shown as answers.

Unable to set small height for editor <textarea> (again).

3 Answers 961 Views
Editor
This is a migrated thread and some comments may be shown as answers.
Mikkel
Top achievements
Rank 1
Mikkel asked on 14 Oct 2013, 09:59 AM
I'm embedding an kendo.ui.editor in a UIWebView in an iOS application using html, css and javascript hosted on the device itself.

I am unable to force the height of my text area below 150px.
My html is this:
<body>
<div>
<textarea id="editor" style="width:100px;height:100px;">
</textarea>
<script>
$(document).ready(function() {
    $("#editor").kendoEditor( { encoded: false } ); } );
</script>
</div>
</body>
The above yield a text area which is 100px wide, but 150px high.
Controlling the width is no problem, and the height is also fine when giving a value above 150px.
The size of the UIWebView containing the editor is 500px wide and 250px high, but this size does not seem to affect the 150px limit.

I have tried various tweaks to the css (height, min-height, …), but to no avail…
Is there somewhere a limit on how low the height of an text area can go ?  Somehwere in the kendo css that I haven't found / browser defaults / something completely different ?

3 Answers, 1 is accepted

Sort by
0
Kiril Nikolov
Telerik team
answered on 14 Oct 2013, 12:50 PM
Hi Mikkel,

You can modify the height of the Editor by setting the height CSS property of the iframe that is used inside of it. Please check the following example:

http://jsbin.com/uQIhOPI/1/edit

I have removed the other tickets that you opened - I hope that this will not be a problem for you, as they were all with the same content. 
 
Regards,
Kiril Nikolov
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Andre Beauchamp
Top achievements
Rank 1
answered on 15 Dec 2014, 04:18 PM
Hi Kiril, 

The solution you proposed seems like a patch to a design problem.
It suggests to add css style for every editor on every page that uses a height lower than 250px which seems like a stretch considering that setting an inline style height of 100px on the textarea really should translate to a 100px after kendo applies the editor widget to it.

Also, the kendo editor in IE10 would apply a height of 0 to any textarea setting an inline height bellow 250px.
0
Kiril Nikolov
Telerik team
answered on 16 Dec 2014, 12:15 PM
Hello Andre,

Can you please open a separate support request with some runnable sample that we can test locally and advise you further?

Thanks for the cooperation.

Regards,
Kiril Nikolov
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
Editor
Asked by
Mikkel
Top achievements
Rank 1
Answers by
Kiril Nikolov
Telerik team
Andre Beauchamp
Top achievements
Rank 1
Share this question
or