React-bootstrap-table2: Filters in a separate row for better styling

Created on 12 Jul 2019  路  9Comments  路  Source: react-bootstrap-table/react-bootstrap-table2

Hi

I think it would be nice if filters could have their own row, as it would make styling/positioning nicer. This is how it looks in our old version, where we use https://datatables.net/.

image

Notice that the textboxes are in a separate row. This means that, even if the titles wrap over multiple lines, all the textboxes align nicely.

Here is the same section implemented in react-bootstrap table

image

As you can see the textbox for the second column is not aligned with the rest.

The jQuery datatables plugin uses a tfoot section for the filter row.

image

just an idea. Do you think it would require a lot of work?

filter help wanted

Most helpful comment

Tanks a bunch @aliogaili and @AllenFang. Much appreciated!

All 9 comments

did you try header formatter an display flex?

Hi @jendamozna . Do you mean something like this?

image

headerFormatter is a way to custom the header, I think it's not a good solution for @nordicbondpricing 's requirement. So far we don't have this feature and it's minor for me to implement it, so PR is welcome.

Has anyone picked this up? if not, i can give it a go

Hi @ptah23 , that would be awesome! I haven't had the time to look at it unfortunately

@ptah23 PR is welcome

I think this is really good to have, the clutter in the table header when the filters are enabled make the filters not very usable.

Tanks a bunch @aliogaili and @AllenFang. Much appreciated!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

bogannathan picture bogannathan  路  4Comments

rsgoss picture rsgoss  路  4Comments

ethannkschneider picture ethannkschneider  路  3Comments

prajapati-parth picture prajapati-parth  路  4Comments

Randore picture Randore  路  3Comments