backoffice: add class to have alternate backgrounds in fields blocks (#45369)

This commit is contained in:
Frédéric Péters 2021-02-16 12:53:53 +01:00
parent f59b73c7c6
commit b7141845d1
1 changed files with 11 additions and 1 deletions

View File

@ -2118,7 +2118,7 @@ div.timetable-widget {
}
.remove-button {
position: absolute;
right: 0;
right: 3px;
top: 0.5em;
margin-right: 0;
span {
@ -2130,3 +2130,13 @@ div.timetable-widget {
}
}
}
.pk-blocks-zebra {
// add a gray background for even numbered blocks, but that means odd
// childs when the first child is an error.
.error ~ .BlockSubWidget:nth-child(odd),
.BlockSubWidget:first-child ~ .BlockSubWidget:nth-child(even) {
background: hsla(0, 0%, 0%, 0.05);
box-shadow: -0.5em -0.5em 0 .5em hsla(0, 0%, 0%, 0.05);
}
}