@@ -13,10 +13,10 @@ Custom Fields includes 20+ pre-configured field types:
1313
1414| Field Type | Key | Data Type | Description |
1515| ------------| -----| -----------| -------------|
16- | ** Text Input** | ` text ` | String | Basic text input with validation |
17- | ** Email** | ` email ` | String | Email input with validation |
18- | ** Phone** | ` phone ` | String | Phone number input |
19- | ** Link** | ` link ` | String | URL validation and formatting |
16+ | ** Text Input** | ` text ` | Text | Basic text input with validation |
17+ | ** Email** | ` email ` | Multi-choice | Email input with validation |
18+ | ** Phone** | ` phone ` | Multi-choice | Phone number input |
19+ | ** Link** | ` link ` | Multi-choice | URL validation and formatting |
2020| ** Textarea** | ` textarea ` | Text | Multi-line text input |
2121| ** Rich Editor** | ` rich-editor ` | Text | WYSIWYG editor with formatting |
2222| ** Markdown Editor** | ` markdown-editor ` | Text | Markdown syntax with preview |
@@ -32,7 +32,7 @@ Custom Fields includes 20+ pre-configured field types:
3232| ** Toggle Buttons** | ` toggle-buttons ` | Single-choice | Button group selection |
3333| ** Date** | ` date ` | Date | Date picker |
3434| ** Date Time** | ` date-time ` | DateTime | Date and time picker |
35- | ** Color Picker** | ` color-picker ` | String | Visual color selection |
35+ | ** Color Picker** | ` color-picker ` | Text | Visual color selection |
3636| ** File Upload** | ` file-upload ` | String | File upload with validation |
3737| ** Record** | ` record ` | Multi-choice | Polymorphic model lookup |
3838
@@ -78,7 +78,7 @@ class StarRatingFieldType extends BaseFieldType
7878 public function configure(): FieldSchema
7979 {
8080 return FieldSchema::numeric()
81- ->key('star-rating')
81+ ->key('acme- star-rating')
8282 ->label('Star Rating')
8383 ->icon('heroicon-o-star')
8484 ->formComponent(function (CustomField $customField) {
@@ -292,7 +292,10 @@ enum FieldDataType: string
292292## Best Practices
293293
2942941 . ** Use Existing Filament Components** : Build on Filament's components like ` Select ` , ` TextInput ` , etc.
295- 2 . ** Follow Naming Conventions** : Use kebab-case for keys (e.g., ` star-rating ` , ` country-select ` )
295+ 2 . ** Follow Naming Conventions** :
296+ - Use ` kebab-case ` for keys (e.g., ` star-rating ` , ` country-select ` )
297+ - ** Use a project prefix** for custom types (e.g., ` acme-star-rating ` ) to avoid conflicts with built-in types
298+ - Only skip the prefix when intentionally replacing a built-in type
2962993 . ** Choose the Right Data Type** : Select the data type that matches how your field's values should be stored
2973004 . ** Use Closures for Flexibility** : For complex components, use closure-based definitions
2983015 . ** Test Your Components** : Ensure your field type works in forms, tables, and infolists
0 commit comments