How to use Split Component
Tried like this:
return $table
->schema([
Split::make([
ImageColumn::make('avatar'),
TextColumn::make('name'),
TextColumn::make('email'),
])
])...
But got error:
Call to undefined method Filament\Resources\Table::schema()
18 Replies
Where are you using that? In a filament resource?
Table doesn't have schema? this should go into the
columns()
methodYes, using it in filament resource. I also don't think table has schema, but got answer in chat channel that I should use it like that
When using it in columns() it messes up table completely
You can use ->from() to set the tailwind breakpoints. Take a look: https://filamentphp.com/docs/2.x/tables/layout#allowing-columns-to-stack-on-mobile
its probably how youre doing it
Its clear but I asked about right way to do it π
well show us a screenshot of what happened
Need 5 minutes
This is table part of resource:
return $table
->columns([
Tables\Columns\Layout\Split::make([
Tables\Columns\TextColumn::make('department_name'),
Tables\Columns\ToggleColumn::make('published'), ]) ]) ->filters([ // ])...
Tables\Columns\TextColumn::make('department_name'),
Tables\Columns\ToggleColumn::make('published'), ]) ]) ->filters([ // ])...
π€
Please don't tell me that YOU don't know what's wrong! π
Can you show a screenshot without Split?
It works for me
π€
cache clear?
cleared, still the same
Did you publish some Filament view?
What is the filament version?
php artisan filament:upgrade ?
installed everything this morning, didn't touch tailwind, didn't do anything out of standard work. And it's the same in each resource
Thanks to @Leandro Ferreira issue is solved. Problem happens in case of combination when actions are grouped and edit/view pages are set to be modal.