Skip to content

PHPJunior/nova-quick-view

Folders and files

NameName
Last commit message
Last commit date

Latest commit

c31acfd · Aug 23, 2022

History

5 Commits
Aug 23, 2022
Dec 9, 2020
Dec 9, 2020
Dec 9, 2020
Dec 9, 2020
Dec 9, 2020
Dec 8, 2020
Dec 9, 2020
Dec 9, 2020
Dec 9, 2020
Dec 9, 2020

Repository files navigation

Nova Quick View

Latest Stable Version Total Downloads

screenshot 1 screenshot 2 screenshot 3

Installation

You can install the package in to a Laravel app that uses Nova via composer:

composer require php-junior/nova-quick-view

Usage

Add the following code :

public function fields(Request $request)
{
    return [
        ...
        NovaQuickView::make('Hello', function () {
            return '<p>Hi, there!</p>';
        })
        ->icon('el-icon-search')
        ->title('I am the title')
        ->direction('rtl') rtl / ltr / ttb / btt
        ...
    ];
}

If you need to render HTML content :

public function fields(Request $request)
{
    return [
        ...
        NovaQuickView::make('Hello', function () {
            return view('partials.hello', [
                'text' => 'Hi, there!'
            ])->render();
        })
        ->icon('el-icon-search')
        ->title('I am the title')
        ->direction('rtl') // rtl / ltr / ttb / btt
        ...
    ];
}

Please check icon list from element. If you want to use fontawesome or others, import CSS file in layout.blade.php

Credits

  • All Contributors

License

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