Class: CharacterCount

FormComponents. CharacterCount


new CharacterCount()

CharacterCount
A component used to count the number of characters in various input fields.
When the characters limit is reached, the component will mark it's isValid state as false.

Properties:
Name Type Argument Description
input String <optional>

user input to be counted

limit Number

component will mark itself invalid if characters exceed this limit

Source:
See:

Methods


<private, static> _buildDisplayString()

Build a the character limit counter display.
E.g. "43/100"

Source:
Returns:
Type
String

<static> componentWillReceiveProps()

Allow the component's isValid state to be set through the props

Source:
Returns:
Type
null

<static> getDefaultProps()

Set the default character limit to be zero

Source:
Returns:
Type
Object

<static> getInitialState()

Gets the initial state of the component.

Source:
Returns:
Type
Object

<static> isInputValid()

Check if the input's character count has exceeded the limit

Source:
Returns:
Type
Boolean

<static> render()

Renders the TextArea component.

Source:
Returns:
Type
JSX