Forum

Methodology

Toolbox

Platform

Community

desktop
touch-pad
touch-phone

textarea

Use this block for creating a text area that allows to enter multiple lines of a text.

Overview

Modifiers of the block

Modifier Acceptable values Use cases Description
width 'available' BEMJSON The maximum allowed width of the text area.
disabled true BEMJSON, JS The disabled state.
focused true BEMJSON, JS The block is in focus.
theme 'islands' BEMJSON A custom design.
size 's', 'm', 'l', 'xl' BEMJSON The size of the text area. Use sizes only for text areas when the theme modifier is set to islands.

Custom fields of the block

Field Type Description
name String The unique block name.
val String, Number Default content of the text area.
placeholder String The hint in the text area.
id String The unique identifier of the block.
tabIndex Number The order when navigating through controls on a page by pressing the Tab key.

Block description

Use the textarea block to create the text area that allows to enter multiple lines of the text.

Modifiers of the block

width modifier

Acceptable value:'available'.

Use cases: BEMJSON.

Use to set the maximum available width of the text area.

Open in a new window

disabled modifier

Acceptable value:true.

Use cases: BEMJSON, JS.

The modifier makes the block inactive. The disabled block is visible but not available for user actions.

Open in a new window

focused modifier

Acceptable value:true.

Use cases: BEMJSON, JS.

The modifier puts the focus on the block.

{
    block : 'textarea',
    mods : { theme : 'islands', size : 'm', focused : true },
    placeholder : 'Your text should be here'
}

theme modifier

Acceptable value:'islands'.

Use case: BEMJSON.

The modifier gives the block a custom design.

The islands theme requires the size modifier.

Open in a new window

size modifier

Acceptable values for the islands theme: 's', 'm', 'l', 'xl'.

Use case: BEMJSON.

Use the size modifier only for blocks with the islands theme.

Sets the size value for all types of text areas.

s

Open in a new window

m

Open in a new window

l

Open in a new window

xl

Open in a new window

Custom fields of the block

name field

Type: String.

Specifies the block unique name.

Open in a new window

val field

Type: String.

Specifies the content of the text area.

Open in a new window

placeholder field

Type: String.

Specifies the hint in the text area.

Open in a new window

id field

Type: String.

Specifies the text area unique ID.

Open in a new window

tabIndex field

Type: Number.

Specifies the tab order when pressing Tab to navigate between controls on a page.

Open in a new window

Block textarea

Augments:input