meghdadfadaee/nova-form-card

Submit-capable Laravel Nova 5 cards built with standard Nova fields.

Maintainers

Package info

github.com/MeghdadFadaee/nova-form-card

pkg:composer/meghdadfadaee/nova-form-card

Transparency log

Statistics

Installs: 2

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 0

1.0.0 2026-07-10 00:50 UTC

This package is auto-updated.

Last update: 2026-07-10 23:15:33 UTC


README

Submit-capable Laravel Nova 5 cards powered by standard Nova fields.

nova-form-card gives Nova cards an Action-like flow: define fields, validate input, submit to a card endpoint, run handle(), and return a structured response.

Nova Form Card demo

Why

Nova cards are great for dashboards, but they are usually display-only. This package lets you build reusable form cards without creating a Nova resource page or a custom tool.

Features

  • Use native Nova fields inside a card
  • Submit data to a package route
  • Validate with Nova field rules() / creationRules()
  • Receive values through FormFields
  • Show validation errors beside fields
  • Support dependsOn(), uploads, loading state, custom submit text, and authorization
  • Return success, error, redirect, or refresh responses
  • Render display-only Nova fields such as Badge, Heading, Stack, Status, and Sparkline

Requirements

  • PHP ^8.2
  • Laravel ^11|^12|^13
  • Laravel Nova ^5

Installation

composer require meghdadfadaee/nova-form-card

Laravel auto-discovers the service provider.

Optional publishes:

php artisan vendor:publish --tag=nova-form-card-config
php artisan vendor:publish --tag=nova-form-card-translations

Quick Look

class InviteUserCard extends FormCard
{
    public function fields(NovaRequest $request): array
    {
        return [
            Text::make(__('Email'))->rules('required', 'email'),
        ];
    }

    public function handle(FormFields $fields, NovaRequest $request): mixed
    {
        return static::message(__('Invitation sent.'));
    }
}

Register it anywhere Nova accepts cards.

public function cards(NovaRequest $request): array
{
    return [
        new InviteUserCard(),
    ];
}

Documentation

Read the full documentation in docs/documentation.md.

Useful files:

Testing

composer install
vendor/bin/pest

License

Nova Form Card is open-sourced software licensed under the MIT license.