GloomyPagerBundle icon indicating copy to clipboard operation
GloomyPagerBundle copied to clipboard

CSS is too generic

Open pmithrandir opened this issue 12 years ago • 4 comments

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{
...

pmithrandir avatar Feb 10 '13 15:02 pmithrandir

Hi,

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

iamluc avatar Feb 23 '13 13:02 iamluc

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

pmithrandir avatar Feb 24 '13 11:02 pmithrandir

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 :

  • override the datagrid_stylesheets block
  • use datagrid_javascripts and datagrid_content blocks, then put your own css.

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')

iamluc avatar Feb 25 '13 09:02 iamluc

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.

pmithrandir avatar Feb 25 '13 09:02 pmithrandir