Skip to content

Commit

Permalink
fix(material/chips): chip label appearing above sticky columns (#26794)
Browse files Browse the repository at this point in the history
Fixes that the `z-index`, which is set on the chip labels, appears on top of sticky columns inside a table.

Fixes #26793.
  • Loading branch information
crisbeto authored Mar 15, 2023
1 parent 946cc67 commit e3917ea
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/material/chips/chip.scss
Original file line number Diff line number Diff line change
Expand Up @@ -226,6 +226,11 @@
// Required for the strong focus indicator to fill the chip.
.mat-mdc-chip {
position: relative;

// `.mat-mdc-chip-action-label` below sets a `z-index: 1` to put the label above the focus
// overlay, but that can also cause it to appear above other elements like sticky columns
// (see #26793). Set an explicit `z-index` to prevent the label from leaking out.
z-index: 0;
}

.mat-mdc-chip-action-label {
Expand Down

0 comments on commit e3917ea

Please sign in to comment.