-
-
Notifications
You must be signed in to change notification settings - Fork 41
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
Cell height is off by as much as 30+x #200
Comments
Thx for your deep analysis. Is this something we can help in this repo, or a bug to be fixed in the upstream jupyterlab code base? |
That's Jupyerlab code, maintained by Jupyter, but the bug doesn't exist in jupyterlab itself. There must be some way that the value is either being misused, manipulated, or it's not being called at the proper time and it isn't capable of grabbing the data it needs to calculate the proper value. I ended up writing some css that sets the output cells to be closed, and then a sort of hack-y function that sets it to be open after calculating the height, but it's by no means ideal. |
Hey @igloo1505 thanks for reaching out. Did you turn on notebook windowing by choice? I would advice turning it off (what should be the case by default) to avoid entering the complexity of DOM measuring especially when dealing with an heavily customized application. |
Description
When rendering markdown, some (most... maybe all to some extent) cells calculate their height to be significantly larger than what's expected. The values are coming from a hook that runs on scroll as well as after the initial render at line 866 in
@jupyterlab/ui-components/lib/components/windowedlist.js
whereconst estimatedTotalHeight = this.viewModel.getEstimatedTotalSize();
returns a value that makes zero sense.Expected behavior
Display output in a cell that more or less fits the content of that cell.
Context
I'm using this in a fairly complicated application with lots of other css potentially effecting things, but as this is a value that is directly calculated in javascript and appended to the element instead of a css value the only way I can think of for that to effect things is if some css value is causing some weird measurement within that
getEstimatedTotalSize
function.The text was updated successfully, but these errors were encountered: