Important Notice - Forums is archived

To simplify things and help our users to be more productive, we have archived the current forum and focus our efforts on helping developers on Stack Overflow. You can post new questions on Stack Overflow or join our Discord channel.

Product icon

Vaadin lets you build secure, UX-first PWAs entirely in Java.
Free ebook & tutorial.

Remove stripes from Grid

Peter Hansson
7 years ago Jun 21, 2015 6:56am

How do I remove the alternate row coloring from a Grid ?.  I'm using Valo theme.

This was pretty easy to do with Table: 


but there's no ValoTheme.GRID_NO_STRIPES.
What to do ?

Jens Jansson
7 years ago Jun 22, 2015 7:00am

I'm not sure if Grid has an option to remove the stripes built in, but at least it is easy to add it yourself. If someone knows that there actually is this feature already built-in, then please do share the info.

You can add something like this into your css theme

.no-stripes .v-grid-row-stripe > td {background-color: #FFF;}

and then you can add the style name to the grid:


or if you prefer:


If it doesn't work then check that the css row is more specific than the one in Valo, and add classnames or identifiers to the row to make it more specific.

Jens Jansson
7 years ago Jun 22, 2015 7:09am
Peter Hansson
7 years ago Jun 22, 2015 7:18pm
Thomas Brandstetter
7 years ago Oct 23, 2015 11:20am
Peter Hansson
5 years ago Dec 09, 2017 12:26pm
Peter Hansson
5 years ago Dec 09, 2017 12:44pm
Teerapong Suksuwan
4 years ago Dec 24, 2018 10:03am