PHP code example of crusherrl / nova-info-card

1. Go to this page and download the library: Download crusherrl/nova-info-card library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

crusherrl / nova-info-card example snippets


use CrusherRL\NovaCards\Info;

//...

public function cards()
{
    return [
        (new Info())
            ->info('Some info message')
    ];
}

->info($message)
->success($message)
->warning($message)
->danger($message)
->message($message, $level) // accepted values for $level: 'info', 'success' , 'warning', 'danger'

(new Info())
    ->heading('Info heading')
    ->info('Some info message')

(new Info())
    ->info('Be sure to checkout the original Project 
    <a href="https://github.com/pdmfc/nova-info-card/" class="underline font-bold text-blue-800">pdmfc/nova-info-card</a>!')
    ->asHtml(),

(new Info())
    ->info('Be sure to checkout the original Project <a href="https://github.com/pdmfc/nova-info-card/" class="underline font-bold text-blue-800">pdmfc/nova-info-card</a>!')
    ->setColors([
        'border' => 'rgb(48 107 203)',
        'background' => 'hsl(217.09deg 88.71% 75.69%)',
        'text' => '#4f4f4f',
        'icon' => 'black'
    ])
    ->asHtml(),

(new Info())
    ->info('Be sure to checkout the original Project<a href="https://github.com/pdmfc/nova-info-card/" class="underline font-bold text-blue-800">pdmfc/nova-info-card</a>!')
    ->setBorderColor('rgb(48 107 203)')
    ->setBackgroundColor('blue-200')
    ->setTextColor('#4f4f4f')
    ->setIconColor('black')
    ->asHtml(),