Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message
Nova Enum Field

Nova Enum Field Laravel Package

simplesquid/nova-enum-field

Nova Enum Field adds a dedicated Laravel Nova field for PHP enums, letting you display and edit enum-backed model attributes as friendly selects or badges. Configure labels, colors, options, and validation for cleaner enum handling in Nova resources.

View on GitHub
Deep Wiki
Context7

A Laravel Nova field to add enums to resources.

Frequently asked questions about Nova Enum Field
How do I install simplesquid/nova-enum-field?
Install it with Composer using composer require simplesquid/nova-enum-field. Laravel package discovery registers the service provider, so there are no migrations to run and no manual provider wiring required. After that, swap an existing Select or Text field for the package field in your Nova resource and register the matching filters.
Which Laravel and Nova versions does nova-enum-field support?
Version 3.3.0 adds support for Laravel 12.x and Nova 5.x. That same release drops PHP 8.1 and Laravel 10.x, so older environments must stay on the previous release line. Always pin your Nova and Laravel constraints before upgrading the package.
Does nova-enum-field v3.3.0 still support Nova 4?
The release notes do not explicitly state whether Nova 4.x remains supported in v3.3.0, so treat the supported Nova range as an open question rather than an assumption. If your application is pinned to Nova 4, verify compatibility before adopting the update. Teams unable to move to Nova 5 may be stranded on the prior package release with no upgrade path short of a Nova upgrade.
How do I use the enum field inside a Nova resource?
Replace the existing field definition on your Nova resource with the package's enum field and point it at the enum-backed attribute. The field handles rendering enum values as friendly selects or badges on index and detail views. Pair it with the package's filters if you want enum-aware filtering on the resource index.
Can I customize enum labels, colors, options, and validation?
Yes. The field supports configuring labels, colors, the available options, and validation rules so enum handling stays clean inside Nova resources. This lets you present raw backed enum values as human-readable choices. Check the package source for the exact configuration API, since ecosystem documentation and examples are limited.
Does nova-enum-field provide enum-aware Nova filters?
Yes. The package ships index and filter implementations that understand BackedEnum values, which is its main differentiator over a plain Select field. If you only need display and edit without filtering, a stock Nova Select with an options map may be sufficient. Confirm you actually need the filter behavior before adding the dependency.
Do my model attributes need to be PHP backed enums to use this package?
Yes. The field renders native PHP BackedEnum values, so your string or integer columns and class constants must already be modeled as backed enums. If they are not, the integration is blocked on an enum refactor, which is the real cost rather than the field swap. Plan that refactor before adopting the package.
Is nova-enum-field safe to use in production?
It is a thin presentation-layer Nova field with low blast radius, but it has roughly 52 stars, zero dependents, and a single-maintainer shop with no SLA. Score and adoption signal indicate negligible production validation, so assume you are an early adopter and budget time for reading the source. The package is MIT licensed and small, so fork-and-vendor is a realistic contingency that caps risk at hours of engineering.
What are the alternatives to nova-enum-field?
If you only need display and edit, a stock Nova Select field with an options map may cover it without an extra dependency. Otherwise, a custom Nova field is roughly equivalent in size, since a field is just a PHP class plus a Vue component. The package becomes worthwhile mainly when you want enum-aware filters and configurable badges out of the box.
How should I roll out nova-enum-field safely?
Start with a single-resource pilot, since the field swap is reversible and rollback is quick. Pin your Nova and Laravel versions first, because Nova field and filter APIs have shifted across majors and an unpinned upgrade can silently break rendering or filtering. Note that dropping PHP 8.1 and Laravel 10 in a minor release signals a fast upgrade cadence, so budget for forced upgrades rather than opt-in ones.
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
robertmarney/lara-hierarchial-collections
simonschaufi/rule-doc-generator
emissaoja/emissaoja
blackbricksoftware/gravityforms-civicrm-form-processor
al-rahabi/fancy-crud
jinas/dhivatar-component
mltstephane/laravel-quality
bernskiold/laravel-talentlms
bernskioldmedia/laravel-form-architect
youbar/easy-crud
c-point-labs/laravel-hostyourai
dbravoan/dbcms-admin-theme-dbcms
dbravoan/dbcms-theme-db-cyber
dbravoan/dbcms-blocks-basic
dbravoan/dbcms-module-content-audit
dbravoan/dbcms-module-ai-assistant
paygate-to/paygate-php
padosoft/askmydocs-connector-base
defstudio/supercharged-carbon
bernskioldmedia/laravel-matomo