bug: DataTable2 is missing min_height

Aperta
#6,499 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
3/5
Tempo stimato
1-2 giorni
Idoneità per principianti
52/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Tranquilla
Stack tecnologico
python
Ambito
frontend

Direzione di ricerca

Inizia individuando l’implementazione di DataTable2 e la relativa documentazione dell’API, quindi riproduci su Windows la tabella con vincoli verticali descritta nell’issue. Traccia come vengono gestiti min_width e visible_vertical_scroll_bar; il lavoro è completo quando viene esposta un’opzione min_height e lo scorrimento verticale funziona quando la tabella è più corta dello spazio disponibile per il suo contenuto.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

bug
Duplicate Check
Describe the bug

We notice with a DataTable2, a min_width attribute.

Per the DataTabe2 documentation:

min_width - Minimum table width before horizontal scrolling kicks in.

We notice when using the min_width, that a horizontal scrollbar appears if both the DataTable2 length size falls below the min_width threshold and the visible_horizontal_scroll_bar attribute is set to true.

Image

We also notice that DataTable2 has a visible_vertical_scroll_bar attribute, which like the visible_horizontal_scroll_bar attribute displays a vertical scrollbar (presumably if the DataTable2 height size falls below some threshold).

We notice in the DataTable2 API documentation:

https://flet-dev.github.io/flet-datatable2/datatable2/#flet_datatable2.datatable2.DataTable2.vertical_lines

...that there's a min_width attribute, but no min_height attribute.

Because of that, when shrinking a table (vertically) we notice no scrollbar:

Image

This is a problem, as without a scrollbar, the only way to view the other rows (that are hidden by the vertical shrinking of the window) in the DataTable2 is to maximize the DataTable2 window (rather than use a scrollbar).

Nelson

Code sample
Code
[Paste your code here]
To reproduce

Please see issue description.

Expected behavior

No response

Screenshots / Videos
Captures

[Upload media here]

Operating System

Windows

Operating system details

Windows 11 Professional

Flet version

0.84.0

Regression

No, it isn't

Suggestions

No response

Logs
Logs
[Paste your logs here]
Additional details

No response

Lingua principale
Python
Stelle
17.5k
Fork
740
Merge medio
1g 15h
PR unite (30g)
73

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di flet-dev/flet

Tutte le issue di flet-dev/flet

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.