How can I disable the "This page" row on the summarizer?

On BaseWidget I added a summarizer but I want to hide the "This page" section from it. Is this something that can be done? I couldn't find it anywhere in documentation.
No description
Solution:
As long as the table records are a paginator instance and has records that row will show. So your only real solution, without overriding the vendor views which isn’t recommended, would be with a custom theme to hide the row via css.
Jump to solution
11 Replies
DJ SneezyCheese
DJ SneezyCheeseOP3mo ago
Bump, for great justice
LeandroFerreira
LeandroFerreira3mo ago
php artisan vendor:publish --tag=filament-tables-translations
'page' => 'This page',
'page' => 'This page',
DJ SneezyCheese
DJ SneezyCheeseOP3mo ago
I apologize - I'm not understanding the implementation suggested here. To be clear I am trying to hide "This page" row and related summaries from the summarizer.
Solution
awcodes
awcodes3mo ago
As long as the table records are a paginator instance and has records that row will show. So your only real solution, without overriding the vendor views which isn’t recommended, would be with a custom theme to hide the row via css.
LeandroFerreira
LeandroFerreira3mo ago
Ahh, sorry
DJ SneezyCheese
DJ SneezyCheeseOP3mo ago
Thank you - I will pitch this idea to my leadership. A workaround is better than no solution. 🔥 You rule.
DJ SneezyCheese
DJ SneezyCheeseOP3mo ago
All good - thanks either way! Out of curiosity - I am failing to accomplish this CSS edit - what am I not understanding? :facepalm: sorry!
awcodes
awcodes3mo ago
What have you tried?
DJ SneezyCheese
DJ SneezyCheeseOP3mo ago
sorry for the delayed reply - I've tried these approaches:
/* Hide "This page" row in table summaries */
- tr.fi-ta-summary-row:has(span.fi-ta-summary-row-heading:contains("This page")) {
- display: none;
- }
-
- /* Hide "This page" row in table summaries */
- .fi-ta-row.fi-ta-summary-row:has(
- > td > span.fi-ta-summary-row-heading:contains("This page")
- ) {
+ /* Hide "This page" row while keeping "All carriers" row */
+ .fi-ta-summary-row td span.fi-ta-summary-row-heading:not(:contains("All carriers")) {
display: none;
}
/* Hide "This page" row in table summaries */
- tr.fi-ta-summary-row:has(span.fi-ta-summary-row-heading:contains("This page")) {
- display: none;
- }
-
- /* Hide "This page" row in table summaries */
- .fi-ta-row.fi-ta-summary-row:has(
- > td > span.fi-ta-summary-row-heading:contains("This page")
- ) {
+ /* Hide "This page" row while keeping "All carriers" row */
+ .fi-ta-summary-row td span.fi-ta-summary-row-heading:not(:contains("All carriers")) {
display: none;
}
/* Hide "This page" row in table summaries */
+ .fi-ta-summary-row:first-of-type {
display: none;
}
/* Hide "This page" row in table summaries */
+ .fi-ta-summary-row:first-of-type {
display: none;
}
/* Hide "This page" row in table summaries */
+ .fi-ta-summary-row:has(.fi-ta-summary-row-heading) td:first-child:not(:has(.fi-ta-summary-row-heading:contains("All carriers"))) {
display: none;
}
/* Hide "This page" row in table summaries */
+ .fi-ta-summary-row:has(.fi-ta-summary-row-heading) td:first-child:not(:has(.fi-ta-summary-row-heading:contains("All carriers"))) {
display: none;
}
(in app.css)
awcodes
awcodes3mo ago
in css, :contains doesn't work with text of the element. if there's no class, id or attribute specific to it then you'll have to target in another way, probably with a :nth() selector.
DJ SneezyCheese
DJ SneezyCheeseOP3mo ago
I can try that - thanks 💯

Did you find this page helpful?