filament-tinyeditor icon indicating copy to clipboard operation
filament-tinyeditor copied to clipboard

[Feature] [or Question] Adding custom CSS classes

Open Schrolli91 opened this issue 5 months ago • 1 comments

Is there any possibility to add custom css classes to the formatting of the editor?

In my case it's Tailwind. Is it possible, to inject the Tailwind classes on-the-fly to style the content correctly?

Best regards.

Schrolli91 avatar Jul 30 '25 19:07 Schrolli91

Hi @Schrolli91 ! I have tried a lot of times and this is the best way to add styles using tailwind and Vite. Add this to your AppServiceProvider.

use Illuminate\Support\Facades\Vite;

config([
    'filament-tinyeditor.profiles.default.custom_configs.content_css' => [
        'default', // profile name
        Vite::asset('resources/css/tinyeditor-styles.css'),
    ],
]);

whoisnegrello avatar Sep 23 '25 22:09 whoisnegrello