Custom breakpoints with $columnSpan property
Does anyone know if it's possible to use custom defined Tailwind breakpoints within the $columnSpan property for Filament dashboard widgets? For example, I have an '3xl' (2000px) custom breakpoint in Tailwind. When I use it in the $columnSpan property, nothing changes in the front-end when I change my screen to 2001px. Thanks in advance π
9 Replies
Thanks, I will look into it when I get home π
Hi, no luck so far with this issue. I added a breakpoint in Tailwind like this:
The problem is that nothing changes when I use this breakpoint '3xl' like this:
Also, when I change for example the 'xl' breakpoint to '2000px' and I use it like in the example above, it works. Does Filament take into account newly added breakpoints that don't come with the standard Tailwind screens-configuration?
instead of passing an array, pass a string of tailwind classes for all breakpoints at once
That solved my problem, thank you! π
Hi Richard, how did you manage to solve this?
I currently have this. but that doesn't seem to work
Hi, i remember doing exactly that. I don't have my computer close at the moment. In your tailwind config in the content array, do you include the paths to these Filament classes to enable Tailwind to scan the files for CSS-classes? I don't know if Filament has this already configured but i remember i once had problems because of that.
Hi Richard, thanks for your reply.
I currently have this in my table widget:
With 2xl it seems to work, but when using 3xl it's not.
My Tailwind config looks like this:
Hi, i assume your widget lives under the app/Filament/App namespace? I cant think of any other issue causing the problem. I hope someone else can help maybe π¬