awcodes / filament-table-repeater

A modified version of the Filament Forms Repeater to display it as a table.
MIT License
194 stars 43 forks source link

Can hide the table header #16

Closed margarizaldi closed 1 year ago

margarizaldi commented 1 year ago

My situation requires me to have even more compact repeater, which might be needed by others too.

awcodes commented 1 year ago

I don't think removing the header completely is the right way to go, it creates a11y issues.

Can you try it with just a class of sr-only for the thead?

margarizaldi commented 1 year ago

Let me know your review

awcodes commented 1 year ago

Thanks. I had to fix the columns widths for when the header was hidden, but works well.

margarizaldi commented 1 year ago

Awesome... I have a new idea while you fixing that, but not sure you agree or not...

What if when the item number is 0, the whole table must not exist at all? so we won't have bodyless table there... I think that will have no problem with accessibility issue since there's nothing literally...

awcodes commented 1 year ago

I think the table headers are good for context, but let me think about it a little.

margarizaldi commented 1 year ago

I think the table headers are good for context, but let me think about it a little.

Maybe add another tbody for empty state... Have a great weekend!

awcodes commented 1 year ago

I think this would be good to do similar to Filament tables where, there's a single row in the existing body that spans the column count plus the actions column (if they exist) that says something like 'No items' or something like that.

I just don't like the button being there by itself, centered with nothing but a field label all the way over to the left or right. Just my personal opinion though.

What do you think? Is that something you want to work on?

I'm happy to do it myself. :)

Good idea.

margarizaldi commented 1 year ago

I'll try. Thank you.