shibomb/filament-multi-components-column

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

A Simple Mutli Components Column for Filament Table

v1.0.0 2023-02-07 02:58 UTC

This package is auto-updated.

Last update: 2023-11-04 14:05:36 UTC


README

You can use Filament Tables Stack.

Filament MultiComponents Column

Latest Version on Packagist GitHub Code Style Action Status Total Downloads

A Simple Mutli Components Column for Filament Table.

Filament Admin Panel

This package is tailored for Filament Admin Panel.

Make sure you have installed the admin panel before you continue with the installation. You can check the documentation here

Supported Versions

PHP: 8.0

Laravel: 8 & 9

Installation

You can install the package via composer:

composer require shibomb/filament-multi-components-column
php artisan filament-multi-components-column:install

Placing components horizontally in a single column

use Shibomb\FilamentMultiComponentColumn\Components\MultiComponentsColumn;

class FooBarResource extends Resource
{
    :
    public static function table(Table $table): Table
    {
        :
        return $table
            ->columns([
                MultiComponentsColumn::make('foo')
                    ->components([
                        Tables\Columns\TextColumn::make('foo'),
                        Tables\Columns\TextColumn::make('bar')
                    ]),
        :

Placing components verticaly in a single column

                MultiComponentsColumn::make('foo')
                    ->components([
                        Tables\Columns\TextColumn::make('foo'),
                        Tables\Columns\TextColumn::make('bar')
                    ])
                    ->verticaly(),

Override ClassNames

                MultiComponentsColumn::make('foo')
                    ->components([
                        Tables\Columns\TextColumn::make('foo'),
                        Tables\Columns\TextColumn::make('bar')
                    ])
                    ->classNames('your-original-class'),

Append ClassNames

                MultiComponentsColumn::make('foo')
                    ->components([
                        Tables\Columns\TextColumn::make('foo'),
                        Tables\Columns\TextColumn::make('bar')
                    ])
                    ->appendClassNames('rounded-lg bg-primary-500'),

Note: If calling verticaly(), appendClassNames() must be called after verticaly().

Testing

composer test

Changelog

Please see CHANGELOG for more information on what has changed recently.

Contributing

Please see CONTRIBUTING for details.

Security Vulnerabilities

Please review our security policy on how to report security vulnerabilities.

Credits

License

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