Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Table v2 uses invalid row index to style cell #459

Open
wI2L opened this issue Jan 9, 2025 · 1 comment
Open

Table v2 uses invalid row index to style cell #459

wI2L opened this issue Jan 9, 2025 · 1 comment
Assignees

Comments

@wI2L
Copy link

wI2L commented Jan 9, 2025

Hello,

Per my understanding, the v2 package of Lipgloss table package has introduced the HeaderRow constant to denote the row header.

However, I noticed that in one situation, it still uses the btoi(hasHeaders) function to compute the row index:

renderedCell := t.style(r+btoi(hasHeaders), c).Render(t.data.At(r, c))

Since I cannot find any other usage of this regarding rows, I think this is a regression in v2 introduced with the refactor and introduction of the new constant.

@bashbunni I think you worked on this, so maybe you could correct me if I'm wrong.

Thanks

@bashbunni bashbunni self-assigned this Jan 13, 2025
@bashbunni
Copy link
Member

Thanks so much for this - I'm looking into it. One of those funny moments of "it works, but why? 🤔" Will post updates here

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants