How to get rid of clear all in notifications sidebar
how to disable this ? since i dont want my user to accidentally clear all his/her notification on one button
14 Replies
You can override the specific blade file and remove the button/link or comment it etc, just be mindful for future filament releases if any updates done to that blade file it will not auto update and you will have to manually update it, but here is how you do it
so final file should look
Hi, i tried it , it works but need some adjusment for the folder structure
here's mine, need to put inside database folder first, then modal folder
in your
- resources -> views -> vendor -> filament-notifications -> components -> database -> modal -> actions.blade.php
Thank you!
hello do you know which one is this in the original file, im blind at reading code im sorry
Up anyone
just target the CSS?
We don't advise allowing this to grow though and it should be cleaned.
how do i make the notif show specific date time instead of days ago or weeks ago
As it stands, I can't see how you can. You could override the notifications view and format the date. Or submit a PR to add a dateFormat support.
I managed to do it by edit the date format from diffForHumans to this, but is it okay if i edit directly in the vendor folder and not override it?
im new to laravel sorry if my question sound silly
extend the class do not edit directly under vendor
i have tried it but it doesnt work
Absolutely do not edit the vendor.
See here.
https://filamentphp.com/docs/3.x/notifications/customizing-notifications#using-a-custom-notification-object