We are currently in alpha version.
Please expect changes. If you find any issues, please report them on our github.
Textarea
Textareas are versatile UI elements that allow users to enter multi-line text. They provide a flexible, intuitive way to capture detailed input, enhancing form usability and user expression.
Basic textarea
html
Optional properties
Property | Type | Description |
---|---|---|
|
| Defines the textarea's shape. |
|
| Defines the textarea's resizing. |
| string | Defines the id of the textarea. |
| string | Defines the label attached to the textarea. |
| string | Defines the help text attached to the textarea. |
| string | Defines the placeholder of the textarea. |
| string | Defines the placeholder of the textarea. |
| string | Defines the default number of rows in the textarea. |
| string | Provides the ability to set custom error messages. |
| string | Allows overriding default styles by passing Tailwind CSS classes. Utilize the |
Supported directives
These are optional directives for radio content header only
Selector | Directive name | Description |
---|---|---|
| ZapLabelDirective | Import a directive |
| ZapFormFieldHelpTextDirective | Import a directive |
Example
Preview
Code
Provide a description
Global configurations
A list of global styles, including shape, size, color, font sizes, font weights, and letter spacing can be provided via themeLibrary
in the provideZapOption
provider.. If you have multi theme setup, you can also provide theme specific colors. These apply to all default variants through out the app unless component level styles are provided.
Example
app.config.ts
Shape and Size
Property | Description |
---|---|
| Defines the shape of the textarea. Can be |
Colors
You can provide each of these colors for different themes that you use
Property | Description |
---|---|
| Background color of the textarea. |
| Text color of the textarea. |
| Border color of the textarea. |
| Text color of the label |
| Text color of the placeholder |
| Background color of the textarea when hovered. |
| Border color of the textarea when hovered. |
| Text color of the textarea when hovered. |
| Background color of the textarea when focused. |
| Border color of the textarea when focused. |
| Ring color of the textarea when focused. |
| Text color of the textarea when focused. |
| Color for the icon |
| Text color of the help text |
Other styles
You can provide a bunch of other styles, that are not theme based but rather generic
Property | Description |
---|---|
| Defines the radius of the checkbox's corners. |
| Left padding of the checkbox. |
| Right padding of the checkbox. |
| Top padding of the checkbox. |
| Bottom padding of the checkbox. |
| Padding around the checkbox's content. |
| Width of the checkbox. |
| Height of the checkbox. |
| Font size of the checkbox's text. |
| Font weight of the checkbox's text. |
| Line height of the checkbox's text. |
| Letter spacing of the checkbox's text. |
| Font size of the label |
| Font weight of the label |
| Line height of the label |
| Letter spacing of the label |
| Font size of the placeholder |
| Font weight of the placeholder |
| Line height of the placeholder |
| Letter spacing of the placeholder |
| Font size of the help text |
| Font weight of the help text |
| Line height of the help text |
| Letter spacing of the help text |
| Font size of the icon |
| Font weight of the icon |
| Line height of the icon |
| Letter spacing of the icon |