Tailwind class not found in plugin

I have a page on my plugin, and I want to use the rounded-r-lg class. However, its not applied which makes me think that its not found by tailwind. Am I missing somethign? I dont have any css files in my plugin
22 Replies
Matthew
MatthewOP2w ago
I have already done this. I realize now maybe the class just isnt applied. I used this
<x-filament::section class="w-full rounded-r-lg">
<x-filament::section class="w-full rounded-r-lg">
And I cant get it to only round the right side... It remains rounded on all 4 corners
Dennis Koch
Dennis Koch2w ago
Did you check the DevTools? Is the class on the HTML element? Is it overwritten by a different class?
Matthew
MatthewOP2w ago
rounded-r-lg overwrites rounded-xl, right?
Dennis Koch
Dennis Koch2w ago
Default rounded-xl will probably "overwrite" it
Matthew
MatthewOP2w ago
oh
Dennis Koch
Dennis Koch2w ago
Check the CSS definition in your DevTools
Matthew
MatthewOP2w ago
Dennis Koch
Dennis Koch2w ago
One says: "round all" and one says "round-right". So combined they are "round all" 😉
Matthew
MatthewOP2w ago
😭 I hate css So, what can I do now?
Dennis Koch
Dennis Koch2w ago
How about "don't round left side"? If that's what you want?
Matthew
MatthewOP2w ago
yeah, thats what I want But by default, the section has w-full, if I give it w-[17rem], it overwrites it, but why doesnt it work with rounded-xl?
Dennis Koch
Dennis Koch2w ago
Check the CSS. width is one property. border-radius is a shorthand for 4 borders radi I guess the issue is, that you think in Tailwind, not in CSS. What if you want radius in top left and bottom right? If rounded-b-r-xl would overwrite anything else, you couldn't combine them To solve your issue: "don't round left side" translates to rounded-l-none
Matthew
MatthewOP2w ago
Hmm. I see rounded-l-none in my html, but on devtools its not a class.. and I did add this to my tailwind config
'./vendor/thethunderturner/filament-latex/resources/views/**/*.blade.php',
'./vendor/thethunderturner/filament-latex/resources/views/**/*.blade.php',
Dennis Koch
Dennis Koch2w ago
You created a custom theme?
Matthew
MatthewOP2w ago
in my dev app, or my plugin?
Dennis Koch
Dennis Koch2w ago
The dev app
Matthew
MatthewOP2w ago
then yes oh wait,I add this to my tailwind config class of my theme yes now it works I COMPLETELY forgot the theme was there. I thought it was the default config Apologies 😅 And danke for helping :)
Dennis Koch
Dennis Koch2w ago
Biddeschön 😅
Matthew
MatthewOP2w ago
And this also works for php classes as well. Nice How does tailwind know to grab classes in ->extraAttributes([])?
awcodes
awcodes2w ago
it scans what ever files you tell it to scan in the tailwind config's content
toeknee
toeknee2w ago
noting that if you add it in extraAttributes it won't scope the php files there. So any classes not used i would tend to add a dummp classes.blade.php file in the route and add them to a <div class="my_class"></div> you can use tailwind whitelist too but that's temperamental.
Want results from more Discord servers?
Add your server