Open stevetyler opened 8 years ago
Have you found the solution @stevetyler ?
@stevetyler and @mr339 I'm using in combination with ember-router-scroll addon.
I've refactored to use ember-concurrency too, so to get it working I've just set to "remember" my screen location, and then release it.
pageClicked: task(function * (number) {
this.scroll && this.set('scroll.preserveScrollPosition', true);
yield timeout(1000);
this.set('currentPage', number);
this.scroll && this.set('scroll.preserveScrollPosition', false);
}),
But, sometimes it does not work because I don't know when to "release" it, so to get it working i've just set a timeout with 1000ms.
But I've open an issue: https://github.com/mharris717/ember-cli-pagination/issues/273 about how to get right time to release the screen locker.
Similar to Google, I'd like to scroll to top when going to a new page. I could use an observer but would rather the addon did this? Many thanks