Table to dark mode
Hello there,
I'm aware that, panel builder has dark mode.
but i'm using table outside of panel builder. just on livewire page. i would like to display table in dark mode.
how do i do that?
thank you
Solution:Jump to solution
You should do the table builder setup if you are using tables outside panel builder
13 Replies
Did you do this setup?
https://filamentphp.com/docs/3.x/tables/installation#installing-tailwind-css
you can use the
dark
class to apply ityes
and where do i apply dark class?
i applied like this in livewire blade page
didn't work
<div class="dark mt-6">
{{ $this->table }}
</div>
Did you add this in the tailwind config?
it has
darkMode: 'class'
Or you can just use dark prefix as well for the background color
what does it mean?
Just the “dark:bg-gray-*”? The prefix
I think this should work
Yeah it can, I was just giving another option for him
If it didn’t work
do i need to do this if i also have panel builder installed?
panel builder has dark mode
You said but i'm using table outside of panel builder
i have installed panel builder for admin panel
i'm using table outside of panel builder
but when i follow table installation instructions. all those instructions are already there like app.css contents e.t.c are already there due to previous panel builder installation.
Solution
You should do the table builder setup if you are using tables outside panel builder
wow it worked
thank you 🙂