bug(cdkDrag): Items in DropLIst Jump Down When Using DragBoundary or ConstrainPosition with Custom Preview
- Vorherrschende Sprache
- TypeScript
- Sterne
- 25k
- Forks
- 6.8k
- Ø Merge
- 1 T. 8 Std.
- Gemergte PRs (30 T.)
- 91
Beschreibung
### Is this a regression?
- [ ] Yes, this behavior used to work in the previous version
### The previous version in which this bug was not present was
_No response_
### Description
Items with a custom preview inside of a drop list that should be constrained either by constrainPosition or a dragBoundary appear to jump down for one frame when being dragged before constraint is applied.
### Reproduction
StackBlitz link: https://stackblitz.com/edit/stackblitz-starters-eyxb1gn5?file=src%2Fmain.ts
### Expected Behavior
Constraints are applied to drag preview on starting frame of drag.
### Actual Behavior
Constraints are not applied to drag preview until the second frame of the dragging.
### Environment
- Angular: 19.0.6
- CDK/Material: 19.1.2
- Browser(s): Chrome/Firefox
- Operating System (e.g. Windows, macOS, Ubuntu): Windows
Beitragsleitfaden
Rechercherichtung
Beginne mit der verknüpften StackBlitz-Reproduktion und ihrem Einstiegspunkt src/main.ts. Reproduziere dann das Drag-Verhalten mit einer benutzerdefinierten Vorschau und entweder dragBoundary oder constrainPosition in Chrome oder Firefox. Erledigt ist die Aufgabe, wenn die Einschränkung der Drag-Vorschau bereits im Start-Frame angewendet wird, ohne einen Abwärtssprung um einen Frame.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- angular, typescript
- Bereich
- frontend
- Issue-Typ
- Bug
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Größtenteils klar
- Anfängerfreundlichkeit
- 45/100