pico icon indicating copy to clipboard operation
pico copied to clipboard

[Change Request] Remove explicit background-color on tr element

Open myth opened this issue 4 years ago • 2 comments

Hi,

What do you think about removing the explicit background-color: var(--background-color) on the <tr> element?

Right now tables don't play nicely with <article> in dark mode, as the background colors differ, the table sticks out quite abruptly. In light mode, the main section of an <article> is already white, so the white background color doesn't make a difference.

Could a simple solution be to let <tr> be transparent, but keep:

table[role="grid"] tbody tr:nth-child(2n+1) {
  background-color: var(--table-row-stripped-background-color);
}

At first glance it seems to maintain existing behaviour in light mode, and give a similar aesthetic also in dark mode inside an <article>

myth avatar Dec 22 '21 22:12 myth

Hi @myth, I agree. Nice find. I will ship this small change in the next release.

lucaslarroche avatar Dec 31 '21 09:12 lucaslarroche

Great, thanks!

myth avatar Jan 01 '22 02:01 myth