bug(table): Table with sticky header 'jumping'
- Vorherrschende Sprache
- TypeScript
- Sterne
- 25k
- Forks
- 6.8k
- Ø Merge
- 1 T. 8 Std.
- Gemergte PRs (30 T.)
- 91
Beschreibung
### Is this a regression?
- [X] Yes, this behavior used to work in the previous version
### The previous version in which this bug was not present was
_No response_
### Description
When scrolling, a table with a sticky header "jumps" if you add an element that has a absolute position. For example, if you display the tooltip and scroll, then the sticky header will change position for a short time.
This is also true with the mat-progress-bar element.
### Reproduction
StackBlitz link:
Steps to reproduce:
1. Open [link](https://stackblitz.com/edit/gatzhq-oe6hfq?file=src%2Fexample%2Ftable-sticky-header-example.ts)
2. The sticky header changes the position on scroll when there is another element on the page with absolute position
https://github.com/angular/components/assets/16895663/bf5172c5-8cba-4a0b-b5da-89afab55d7ee
### Expected Behavior
The sticky header should not change position on scroll when there is another element on the page with an absolute position
### Actual Behavior
The sticky header changes the position on scroll when there is another element on the page with absolute position
### Environment
- Angular: v12, v15, v16
- CDK/Material: v12, v15, v16
- Browser(s): **Chrome Version 114.0.5735.110 (Official Build) (64-bit)**
- Operating System (e.g. Windows, macOS, Ubuntu): **Windows**
Beitragsleitfaden
Rechercherichtung
Beginne mit der verlinkten StackBlitz-Reproduktion und bestätige den Sprung des sticky-header beim Scrollen, wenn der tooltip oder die mat-progress-bar vorhanden ist. Verfolge anschließend die Implementierung des sticky-header der Tabelle und die zugehörigen Tests im Angular components repository. Erledigt ist die Aufgabe, wenn der Header beim Scrollen stabil bleibt, während ein anderes absolut positioniertes Element vorhanden ist.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- angular, typescript
- Bereich
- frontend
- Issue-Typ
- Bug
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Größtenteils klar
- Anfängerfreundlichkeit
- 35/100