Set minHeight in TextBox Multine and disable spell checking

Hi, 
I saw that to set the height of a Multine TextBox you have to set the style
     .text-multiline textarea {
         height: 500px! important;
     }
but this blocks the resizing of the textBox.
What should be set to have a minimum height and to leave free the resizing of the same?
Also, is it possible to disable spell checking?

thanks


3 Replies 1 reply marked as answer

SN Sevvandhi Nagulan Syncfusion Team November 24, 2020 02:31 PM UTC


Hi Salvatore, 


Greetings from Syncfusion support. 


Query 1: I saw that to set the height of a Multine TextBox you have to set the style 
     .text-multiline textarea { 
         height: 500px! important; 
    
but this blocks the resizing of the textBox. 
What should be set to have a minimum height and to leave free the resizing of the same? 


You can use the rows attribute for increasing the height of the Multiline textbox via HtmlAttributes. Refer to the below code, 

    <EditForm Model="@Data"> 
        <SfTextBox Multiline="true" @bind-Value="@Data.multiValue" CssClass="text-multiline" HtmlAttributes="@attr"></SfTextBox> 
    </EditForm> 
 
 
 
 
@code { 
 
    public model Data = new model(); 
 
    public class model 
    { 
        public string multiValue { get; set; } 
    } 
    public Dictionary<string, object> attr = new Dictionary<string, object>() 
    { 
        { "rows", "20"} 
    }; 
} 


Please find the sample below, 




Query 2: Also, is it possible to disable spell checking? 


We could not disable the browser spell check in code. However, we can disable the browser spell checking using below steps. 


1.       Go to the settings for Google Chrome. 
2.       Click the Menu icon at the top right corner of the browser. This is represented by 3 horizontal lines. 
3.       Click Settings. 
4.       Click Show advanced settings. 
5.       Click Language and input settings. 
6.       Make sure the check box next to Enable spell checking is unchecked, and then click Done. 

Please check the sample and let us know if you need further assistance. 
 

Regards, 
Sevvandhi N 


Marked as answer

TO Tommy July 31, 2021 04:44 PM UTC

This was one of the first hits for searching Syncfusion and disable spell check so I just thought I'd add that you can disable spell checking on a specific element by wrapping it in a <div> with spell checking disabled i.e.


<div spellcheck="false>

    <SfTextBox........ />

</div



SN Sevvandhi Nagulan Syncfusion Team August 2, 2021 10:20 AM UTC


Hi Tommy, 


Thanks for your suggestion. 


Regards, 
Sevvandhi N 




Loader.
Up arrow icon