stephenbez/tilava-table — pull request #3 by jaycfields (2012-05-04 18:46:27+00:00)
Title: more scrollbar issues

So, I spent the better part of a morning tweaking a few things and found two issues:

- if you don't set the parent of the tilava table to position absolute, things can go very wrong
- since the 'newWidth' can shrink & grow dynamically, the margin for the parent needs to shrink & grow dynamically as well. Since $table.parent().parent() is a container not created or controlled by tilava, it seems like it might make sense to double wrap (so you control the container) or look at another solution.

If you don't do both of those things, the scroll bar can be cut off on the left, can show up way too far to the left (if the table is wide enough that it causes h-scrolling, or can be a bit too far to the right.

To reproduce, you can go to http://stephenbez.github.com/tilava-table/example.html and ctrl+mouse wheel. (for the cut off and slightly too right versions. I can send over the way too far left also, if you want)