Scrolling for treetable needs position clamping to prevent overshooting
- Lingua principale
- Dart
- Stelle
- 1.7k
- Fork
- 404
- Merge medio
- 6g 17h
- PR unite (30g)
- 18
Descrizione
https://github.com/flutter/devtools/pull/4226/files#diff-7f63e0b64be4d80b632e5eefe1cac93308dff718f53fc1fe6e1db774ffd4e7a9R198
Current Problem: When autoscrolling for the treetable, if the index is near the maxScrollingExtent, it will overshoot and therefore create a bouncing animation.
Solution: By clamping the position to be between 0.0 - maxScrollExtent, this will make sure the scroll will stay in the appropriate range. However, maxScrollExtent is not updating after parents are expanded and before scrolling happens. Therefore, if an index is greater than the previous maxScrollExtent even if it is in range after parents are expanded, it still believes that the index is not in range and therefore not scroll to the correct position.
Guida per i contributori
Apri la guida per i contributori
Direzione di ricerca
Inizia dal diff della pull request collegata, soprattutto intorno alla riga 198, e segui la logica di autoscrolling di treetable e la gestione della sua estensione massima dello scorrimento. Riproduci il caso di scorrimento vicino alla fine e verifica che lo scorrimento rimanga nell’intervallo valido dopo l’espansione dei parent, usando qualsiasi test nelle vicinanze o punto di ingresso dei test di treetable esistente che trovi.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- dart
- Ambito
- frontend
- Tipo di issue
- Bug
- Difficoltà
- 3/5
- Tempo stimato
- 1-2 giorni
- Stato di attività
- Ferma
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 42/100