Skip to content

Commit e4170bf

Browse files
authored
fix: grid pro highlight read-only cells variant (#10581)
1 parent 4313b33 commit e4170bf

File tree

3 files changed

+14
-14
lines changed

3 files changed

+14
-14
lines changed

packages/grid-pro/src/styles/vaadin-grid-pro-base-styles.js

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -36,19 +36,18 @@ const gridPro = css`
3636
/* On macOS the editable-cell part is a button inside the body cell. On other platforms the body cell is the editable-cell part. */
3737
3838
@media (any-hover: hover) {
39-
[part~='body-cell']:is([part~='editable-cell'], :has([part~='editable-cell'])):hover {
39+
.body-cell:is([part~='editable-cell'], :has([part~='editable-cell'])):hover {
4040
--vaadin-grid-cell-background-color: var(--_highlight-color);
4141
}
4242
}
4343
44-
:host([navigating]) [part~='body-cell']:is([part~='editable-cell']:focus, :has([part~='editable-cell']:focus)) {
44+
:host([navigating]) .body-cell:is([part~='editable-cell']:focus, :has([part~='editable-cell']:focus)) {
4545
--vaadin-grid-cell-background-color: var(--_highlight-color);
4646
}
4747
4848
/* Indicate editable cells */
4949
50-
:host([theme~='highlight-editable-cells'])
51-
[part~='body-cell']:is([part~='editable-cell'], :has([part~='editable-cell'])) {
50+
:host([theme~='highlight-editable-cells']) .body-cell:is([part~='editable-cell'], :has([part~='editable-cell'])) {
5251
--vaadin-grid-row-highlight-background-color: var(
5352
--vaadin-grid-pro-editable-cell-background-color,
5453
var(--_highlight-color)
@@ -57,16 +56,17 @@ const gridPro = css`
5756
5857
/* Indicate read-only cells */
5958
60-
:host([theme~='highlight-read-only-cells'])
61-
[part~='body-cell']:not([part~='editable-cell'], :has([part~='editable-cell'])) {
62-
--_highlight-background-image: repeating-linear-gradient(
63-
-45deg,
64-
transparent,
65-
transparent 30%,
66-
var(--_highlight-color2) 30%,
67-
var(--_highlight-color2) 50%
68-
)
69-
padding-box 0 0 / 6px 6px;
59+
:host([theme~='highlight-read-only-cells']) .body-cell:not([part~='editable-cell'], :has([part~='editable-cell'])) {
60+
--_cell-highlight-background-image: repeating-linear-gradient(
61+
-45deg,
62+
transparent,
63+
transparent 30%,
64+
var(--_highlight-color2) 30%,
65+
var(--_highlight-color2) 50%
66+
);
67+
background-repeat: repeat;
68+
background-size: 6px 6px;
69+
background-clip: padding-box;
7070
}
7171
7272
/* Loading editor cell styles are used by Flow GridPro */
854 Bytes
Loading
905 Bytes
Loading

0 commit comments

Comments
 (0)