Skip to main content


Java API


The text area component can be easily labeled without the needing to create an extra label component using the setAttribute() method and passing the desired label as a string, as shown below:

Show Code


It is also possible to set placeholder text within the component to better help users understand what type of input is expected. Similar to a label, this can be accomplished using the setAttribute() method:

Show Code


The text area can also be configured with spellchecking to help the user improve their input. Use the setAttribute() method to do this:

Show Code


DWCJ's text area comes with 5 expanses for quick styling without the use of CSS. Expanses are supported by use of a built-in enum class. Below are the various expanses supported for the text area component:

Show Code

Text Area Expanses
  • TextArea.Expanse.XSMALL
  • TextArea.Expanse.SMALL
  • TextArea.Expanse.MEDIUM
  • TextArea.Expanse.LARGE
  • TextArea.Expanse.XLARGE

Parts and CSS Properties