Skip to content
This repository was archived by the owner on Sep 8, 2020. It is now read-only.

Conversation

@phurytw
Copy link
Contributor

@phurytw phurytw commented Nov 9, 2015

The scrollpoint can be set using the directive scope option.
This allows to change the scrollpoint using a variable.

Sample

You can change the value in the input and the scrollpoint will be updated if the entered value is valid.

This is done with a $watch() listener. I also changed the block that sets shift, absolute and fixLimit to accept "absolute" values after render and the whole thing is wrapped into a function that is called whenever the $watch() event is fired.

@PowerKiKi
Copy link
Contributor

I'd expect that the class would be toggled accordingly when the scrollpoint value changes. Right now you have to change the value and then scroll to have any effect on the class.

Also please add demo and tests. And do not include a release in a PR.

@phurytw
Copy link
Contributor Author

phurytw commented Nov 10, 2015

Fixed 👌

I also added a demo and a test.

@PowerKiKi
Copy link
Contributor

Great, could you please squash commits into only one and force push ? Then i'll merge.

@phurytw
Copy link
Contributor Author

phurytw commented Nov 10, 2015

Done !

PowerKiKi added a commit that referenced this pull request Nov 11, 2015
Using scrollpoints with variables
@PowerKiKi PowerKiKi merged commit 38915c9 into angular-ui:master Nov 11, 2015
@PowerKiKi
Copy link
Contributor

Released as 1.2.0

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants