Skip to content
This repository has been archived by the owner on Apr 21, 2022. It is now read-only.

Commit

Permalink
Update README
Browse files Browse the repository at this point in the history
  • Loading branch information
RVxLab committed Apr 8, 2022
1 parent 48ba349 commit 0a68383
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,29 @@ public static function form(Form $form): Form
}
```

### Nullable

***Default: false***

To make the color picker nullable you can call the `nullable` method:

```php
public static function form(Form $form): Form
{
return $form
->schema([
\RVxLab\FilamentColorPicker\Forms\ColorPicker::make('color')
->nullable(),
]);
}
```

#### Known issue

Because Vanilla Picker does not handle null values properly the default initial value of a null-ed picker will be `#000000` or `#00000000` depending on the `alpha` setting.

This goes away when the picker is updated or the form is saved.

## Color swatch

To display a swatch on the table you can add the following column:
Expand Down

0 comments on commit 0a68383

Please sign in to comment.