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

Offset does not seem to work if offset is bound to a variable #142

Open
oaguy1 opened this issue May 15, 2016 · 1 comment
Open

Offset does not seem to work if offset is bound to a variable #142

oaguy1 opened this issue May 15, 2016 · 1 comment

Comments

@oaguy1
Copy link

oaguy1 commented May 15, 2016

I am running into an issue where the sticky offset for an element is not being set properly if the offset is bound to a variable. In my app, I have an additional header bar that appears for superusers, thus superusers need a different offset value than regular users. I have a function that determines if the current user is a superuser and returns the appropriate offset. Below is how I am using the directive.

<table class="table" sticky sticky-class="stickySticky" offset="{{::getStickyOffset()}}">
...
</table>

When I set the offset to a static number, it works as expected, otherwise, the element's 'top' css attribute is set to 0. I experience this problem with the 1.8.10 and 1.8.7 releases. I have tried simply binding the variable to the offset as well as using the render binding used above (both dynamic and one-time). I am happy to provide additional information as required.

Thank you for your time and for creating such a useful directive!

@aneeshd16
Copy link

I have a similar case, only that my offset depends on a media query. Any info/progress on this?

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