Skip to content
This repository has been archived by the owner on Oct 8, 2021. It is now read-only.

Add attribute: data-direction="forward" #3077

Closed
clarkni5 opened this issue Nov 16, 2011 · 8 comments
Closed

Add attribute: data-direction="forward" #3077

clarkni5 opened this issue Nov 16, 2011 · 8 comments

Comments

@clarkni5
Copy link

I have run into a situation where it would be nice (and would make sense to the user) to override the default transition direction to go forward. For example, using data-rel="back", I would like to specify data-direction="forward"

<a href="spoon" data-rel="back" data-direction="forward">Cancel</a>
@MauriceG
Copy link
Contributor

Hi!
Forward is the opposite of reverse. So if you omit reverse, it is foward. Isn't it?
Without the data-direction set to reverse, the transition goes forward. But may I got you wrong.

@clarkni5
Copy link
Author

Except when using data-rel="back". This sets the direction to reverse and cannot be overridden using the data-direction attribute.

@clarkni5
Copy link
Author

By the way, this is not super important to me, so I won't be hurt if it gets a low priority or is otherwise closed. It just seemed like something that would make the API more complete. If you can set the direction to reverse, you should also be able to set it forward.

@MauriceG
Copy link
Contributor

In your example code you set the target-page, so you can omit the data-rel attribute and set the transition you like.

@clarkni5
Copy link
Author

Yes, but I want it to go backwards in the history, not forwards, which would add to the history stack.

@toddparker
Copy link
Contributor

Would you mind adding this to the feature request wiki page?

@ilmam
Copy link

ilmam commented Sep 30, 2014

Can't believe how this request is old but not addressed yet. Any heads up whether it's going to be implemented at all?

@elliscopef
Copy link

when you want to slide back, add attribute data-rel = "back" with
$("#pag"+currentPage).attr("data-rel","back");

If you want to do forward. Just remove the attribute

$("#pag"+currentPage).removeAttr("data-rel");

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

No branches or pull requests

5 participants