tailwind normal blade views
Hi i have read through some posts here, but just want to ask your opinion
1. When you install laravel it installs Tailwind, so you should be able to use all tailwind classes available in normal blade files that are not connected to Filament (bg colors etc)?
2. If you use a blade view that get's pulled into a filament file can you only use classes that filament uses or you have to make your own theme?
Just a bit confused as I am pulling a blade view into a modal in filament on the front-end and only some classes work.
Thanks
13 Replies
make sure you check this
you need to add the paths of your blade to tailwind
content
https://filamentphp.com/docs/3.x/forms/installation#installing-tailwind-csshi, thanks for the reply, I have this in my default tailwind config
Is this ok? As its not pulling in default tailwind classes, thanks
When you install laravel it installs Tailwind, so you should be able to use all tailwind classes available in normal blade files that are not connected to Filament (bg colors etc)?When you recompile that CSS file it includes any classes that are used in files which are listed in the
content
section of your Tailwind Config.
If you use a blade view that get's pulled into a filament file can you only use classes that filament uses or you have to make your own theme?Are we talking about the Panel? If so: The panel has it's separate precompiled CSS file with all the TW classes we use. If you add new ones you need to register your own CSS file (a theme in our words)
Hi, yep it's not a panel, I set up a theme to use in the panel and it is working well, im talking about using a blade view that gets pulled into a front-facing livewire full page component. Only some classes are working in the blade view, thanks
Then it's usually just an issue with the Tailwind config. Did you follow the install guides for the packages you are using in the frontend?
One thing, if I am using the panel do i need to install:
Thanks
You still need to go through the table installation guide. The panel is separate apart from composer
@Dennis Koch ah ok, a quick suggestion as I have seen this issue with others, can you put on docs "Even if you are using the panel but want to use this feature in frontend please install the packages"
I think that would help a lot.
Can I ask even though i didn't install the packages it still works on the front end? when without the packages it's working fine.
I mean there is a note:
The Table Builder package is pre-installed with the Panel Builder. This guide is for using the Table Builder in a custom TALL Stack applicationBut the docs will be restructured for v4 anyway
@Dennis Koch This is confusing now lol
This is what I have in my project, seems like the packages were installed, but i still have the issue with tailwind classes
Very weird, that the tailwind classes are not working correctly
Can you share what "are not working correctly" means in your case?
Solution
You did recompile your CSS file?
My bad 😦 sorry for wasting your time, you led me in the right direction though, I was using inspect element in chrome to check design and I add some classes there, but they didnt show, but i need to add it to code base first recompile then it shows, thanks