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

Error from eg.Flicking.moveTo() if the "adaptiveHeight" option is true #436

Closed
getElementsByName opened this issue Jan 2, 2017 · 4 comments
Assignees
Milestone

Comments

@getElementsByName
Copy link

The error line is "$first = $panel.find(":first");" in _setAdaptiveHeight

  1. Set a flicking instance with a adaptiveHeight: true option (defaultIndex is 0)
  2. eg.Flicking.moveTo(1) (except 0 index)
this._flicking = new eg.Flicking(flickingRootElement, {
  adaptiveHeight: true
});

this._flicking.moveTo(1, 0);  //ERROR
@netil netil self-assigned this Jan 3, 2017
@netil
Copy link
Member

netil commented Jan 3, 2017

@getElementByName, could you put your HTML structure for that case?

@getElementsByName
Copy link
Author

@netil
Here is example demo for this bug.
http://codepen.io/getElementByName/pen/VPwaYZ?editors=1111

@netil
Copy link
Member

netil commented Jan 3, 2017

Confirmed.
The exact condition for that error happens when circular options is false.

When panel moves to prev/next direction it try gets prev/next panel element reference according the direction, but in case of non-circular flicking there are condition which prev/next elements are empty.

Try to fix that ASAP.
@getElementByName thanks for the report.

netil added a commit to netil/egjs that referenced this issue Jan 4, 2017
 Fixed param value on evaluating direction

 Ref naver#436
@netil netil closed this as completed in 6c4f961 Jan 5, 2017
@netil
Copy link
Member

netil commented Jan 5, 2017

@getElementByName the fix update was merged to master.

The change will be released according on next release schedule, meanwhile you can apply the changes on your code directly or just checkout the latest from the master branch.

@netil netil modified the milestone: 1.5.0 Jan 10, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants