Leaf rows are not calculated correctly
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Aptitud para principiantes
- 55/100
- Tipo de issue
- Error
- Claridad
- Bastante claro
- Estado de actividad
- Activo
- Stack tecnológico
- typescript
- Área
- frontend
Línea de trabajo
Comienza con el CodeSandbox enlazado y reproduce el caso de encabezados anidados; después, sigue cómo se calculan los encabezados hoja en el código de la tabla. Confirma si los encabezados con subencabezados se incluyen intencionadamente; el trabajo estará terminado cuando se corrija el cálculo y se cubra el comportamiento con una prueba de regresión, o cuando se documente la definición prevista de un encabezado hoja.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
TanStack Table version
v8.19.3
Framework/Library version
v.18.0.4
Describe the bug and the steps to reproduce it
Bug exists also in the newest version.
Leaf headers include headers which contain subheaders - it seems inconsistent with a definition of a leaf node.
Quoting https://en.wikipedia.org/wiki/Tree_(graph_theory):
[...] an external vertex (or outer vertex, terminal vertex or leaf) is a vertex of degree 1.
Which means one edge connected. With that logic, only headers with no subheaders should be treated as leaf headers - the only exception is the root header with one subheader.
If this is a design choice, not a feature, I think an understanding of a leaf should be included in the docs, as it is at least confusing.
I'm not opening a PR because I'm not sure if I'm not missing something, but if it turns out to be an issue I'm happy to fix it.
Your Minimal, Reproducible Example - (Sandbox Highly Recommended)
https://codesandbox.io/p/sandbox/h684m4
Screenshots or Videos (Optional)
No response
Do you intend to try to help solve this bug with your own PR?
Yes, I think I know how to fix it and will discuss it in the comments of this issue
Terms & Code of Conduct
- I agree to follow this project's Code of Conduct
- I understand that if my bug cannot be reliable reproduced in a debuggable environment, it will probably not be fixed and this issue may even be closed.
- Lenguaje dominante
- TypeScript
- Estrellas
- 28.4k
- Forks
- 3.6k
- Merge medio
- 1 d 1 h
- PR fusionados (30 d)
- 7
Guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de TanStack/table
-
Dificultad 1/5 Menos de una hora Aptitud para principiantes 78/100
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 35/100
-
Dificultad 3/5 1-2 días Aptitud para principiantes 78/100
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 35/100
-
Dificultad 3/5 1-2 días Aptitud para principiantes 48/100
Todos los issues de TanStack/table
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
bcgov/bc-wallet-mobile#4761 · 1 comentario ·
-
external-issue to-triage
Dificultad 2/5 1-3 horas Aptitud para principiantes 88/100
-
area-deployment area-integrations triage:bot-seen
Dificultad 2/5 Medio día Aptitud para principiantes 86/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
-
refactor
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100