iamluc / GloomyPagerBundle

This pager/datagrid/crud has advanced filtering & sorting (Array & Entity/QueryBuilder) in addition of pagination
MIT License
10 stars 4 forks source link

CSS is too generic #5

Open pmithrandir opened 11 years ago

pmithrandir commented 11 years ago

Hello,

In bootsrap.css file, you are using global tagss to define your CSS.

This way, you are affecting the entire website and not only your datagrid part.

It would be less intrusive to define a global div around the datagrid, and to replace the existing CSS tags by :

#datagrid textarea{
...
iamluc commented 11 years ago

Hi,

Unfortunatly, bootstrap.css is not my own CSS, it comes from http://twitter.github.com/bootstrap/ So it cannot be changed easily.

pmithrandir commented 11 years ago

Hi,

I don't really agree with your conclusion. For what I understood from the phylosophy of symfony bundle, you should not impact the others part of the application with your code.

On my side, the impact will require me to overwrite 10 or 20 CSS rules, but for people who use your module in a more important website, it could be too much effort. The effort of overwriting the CSS code would become bigger than the one spared by the module...

Don't you think you could inspire your website from bootstrap, but limit the imapct of it by applying to each rules a class limitator. I think a script would be possible to build for that purpose.

What do you think ? Pierre

iamluc commented 11 years ago

This bundle has a default theme which is bootstrap, but it is not mandatory.

If you don't want bootstrap because it don't fits well in your project, you could :

Or if you can write it, i agree to include an alternative theme which could be choosed in the config (For the moment, the theme is set in Gloomy\PagerBundle\Twig\DataGridExtension::$defaultTheme = 'GloomyPagerBundle:DataGrid:blocks.html.twig')

pmithrandir commented 11 years ago

I'm gonna think about it, as my associate also require a button to validate filter in place of "ENTER" event... he say it's not so intuitive for people not in IT !!

I will check what I can do to prepare a theming as little as possible, or at least, that impact only the datagrid objects.