Open mrworthington opened 1 month ago
Thanks, I can repro. We're not doing anything special with scrolling afaict, so I'm not sure what accounts for the difference.
I’ve looked at the CSS and I’m not sure what it is either. 🤔
UPDATE: I have since realized that the problem was the default rows setting in Inputs.table. With this change, scrolling works:
Inputs.table(all_ojs, { rows: 1000 })
I was having the same problem with lack of scrolling. I tried removing the row height, and still couldn't get it to scroll. I've now stripped things down to a very simple example with generic data and I still don't get a scrollable table. I'm not sure if this helps diagnose the problem at all. I'm using Quarto version 1.4.539 and my dashboard example is here: https://github.com/eamcvey/quarto-ojs-scroll-troubleshooting
I discovered that you can play around with the quarto dashboard yaml options to get scrolling to work
add these parameters to @mrworthington index_2.qmd
dashboard:
scrolling: false
orientation: columns
see this PR (it's the same file but with mentioned changes)
and see that the input.table now is scrollable
https://github.com/user-attachments/assets/7d7623ce-0d50-4927-ad68-574f7dbc62e2
@wvictor14: Appreciate the PR and can definitely use that for now. I think my general issue is that the default behavior of scrolling changes based off of setting row height, which I would guess is not the expected or intended behavior for the Quarto team. I could be wrong though.
Bug description
Whenever row height is explicitly set in a quarto dashboard using Observable's
Inputs.table()
, it prevents scrolling through the entire contents of a table rendered throughInputs.table()
. If row height is not explicitly set, scrolling occurs as expected.Steps to reproduce
I've put a repo together showing the differences, which lives here: https://github.com/mrworthington/duckdb-in-ojs
Expected behavior
When you render a table with
Inputs.table()
, it should scroll as contents are called upon. Via the Observable docs:When row height isn't set in a quarto dashboard, it behaves as expected (albeit with a weird cutoff that occurs if the table's expanded).
https://github.com/user-attachments/assets/50f86995-fdb4-4509-8327-0b3560c09e37
Actual behavior
However, when row height is explicitly set in the quarto dashboard, the scrolling is prohibited:
https://github.com/user-attachments/assets/3dcf9b5d-afdd-425d-924d-4aeb6e16a733
Your environment
Quarto check output