digital-creative/nova-inline-morph-to

This package is abandoned and no longer maintained. No replacement package was suggested.

A Laravel Nova field for displaying morphTo relationship inline.

Installs: 28 831

Dependents: 2

Suggesters: 0

Security: 0

Stars: 33

Watchers: 3

Forks: 15

Open Issues: 1

Language:Vue

v1.0.0 2024-12-01 02:12 UTC

README

Latest Version on Packagist Total Downloads License

Laravel Nova Inline MorphTo Field in action

Install

composer require digital-creative/nova-inline-morph-to

Usage

The signature is the same as the default MorphTo field that ships with Nova.

use DigitalCreative\InlineMorphTo\InlineMorphTo;

class Article extends Resource
{
    public function fields(Request $request)
    {
        return [
            ...
            InlineMorphTo::make('Template')->types([
                \App\Nova\Video::class,
                \App\Nova\Image::class,
                \App\Nova\Text::class,
                \App\Nova\Gallery::class,
            ]),
            ...
        ];

    }
}

License

The MIT License (MIT). Please see License File for more information.