I'd like to add a box shadow to the selected row in a grid which also uses the grouping feature. Initially I just applied the box shadow to the table
element of the selected row:
.x-grid-item-selected {
box-shadow: 0 0 6px 2px rgb(119, 119, 119) inset;
}
Unfortunately, the table element of the first row in a group also contains the group header which gave me this result when I selected the first row in a group:
Also I can't apply the box shadow to the tr
element of the grid row (.x-grid-item-selected .x-grid-row
) since chrome doesn't support box shadows on tr
elements (at least not without setting their display property to block which would break the layout completely).
Applying the box shadow to each cell (.x-grid-item-selected .x-grid-cell
) obviously doesn't give me the desired look neither:
Here's how I'd like the selected row to actually look like (just for the sake of completeness):
In ExtJS 4 I was able to accomplish this by using the RowWrap feature which was removed with ExtJS 5.
I'd really appreciate if someone could give me some help with this!
Here's a fiddle to play around with: https://fiddle.sencha.com/#fiddle/jkv
Thanks & best regards
Ps.: I've also asked this question on the Sencha Forums
tr
element didn't work since chrome actually applies those gradients to all cells, but still I was able to find a solution by applying the gradient to every cell and using the:first-child
&:last-child
pseudo selectors. Thanks a lot for the input! – suamikim