Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Change row count doesn't work in materialize css text area

In materialize css text area, is it possible to initialize the text area with a specific row count using "rows='20'" ? How can we increase the default row count ?

code which doesn't work:

<div class="input-field col s12">
   <textarea id="textarea1" class="materialize-textarea" rows="20" ></textarea>
   <label for="textarea1">Text</label>
</div>
like image 489
Amila Iddamalgoda Avatar asked Feb 06 '17 11:02

Amila Iddamalgoda


Video Answer


1 Answers

The default stylesheet is setting a height so you'll have to override that.

textarea.materialize-textarea{height: 6rem;}
like image 101
Serg Chernata Avatar answered Oct 02 '22 12:10

Serg Chernata