1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-23 19:53:43 +00:00

Update CL documentation (#5379)

This commit is contained in:
Oscar Hinton
2023-05-08 14:46:59 +02:00
committed by GitHub
parent f51ed1092d
commit d53f79e325
14 changed files with 313 additions and 218 deletions

View File

@@ -4,9 +4,9 @@ import { Meta } from "@storybook/addon-docs";
# `bitInput`
`bitInput` is an Angular directive to be used on `<input>`, `<select>`, and `<textarea>`
tags in order to provide standardized TailwindCss styling, error handling, and more.
It is meant to be used within a `<bit-form-field>` custom component.
`bitInput` is an Angular directive to be used on `<input>`, `<select>`, and `<textarea>` tags in
order to provide standardized TailwindCss styling, error handling, and more. It is meant to be used
within a `<bit-form-field>` custom component.
## Basic Usage Example
@@ -20,8 +20,8 @@ It is meant to be used within a `<bit-form-field>` custom component.
## Disabled `bitInput` and Error Handling
If you would like to be able to still show errors when an input is disabled for
specific validation scenarios, then set `[showErrorsWhenDisabled]="true"`
If you would like to be able to still show errors when an input is disabled for specific validation
scenarios, then set `[showErrorsWhenDisabled]="true"`
```html
<bit-form-field>
@@ -31,7 +31,8 @@ specific validation scenarios, then set `[showErrorsWhenDisabled]="true"`
</bit-form-field>
```
**NOTE:** Disabling a FormControl removes validation errors so you must manually set the errors after disabling:
**NOTE:** Disabling a FormControl removes validation errors so you must manually set the errors
after disabling:
```ts
get exampleFormCtrl(): FormControl {