-
-
Notifications
You must be signed in to change notification settings - Fork 177
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
Add modal fade option #287
Conversation
You want to add true/false to the class? |
I wanted to add the ability to remove the "fade" class on the |
@schorke I think an "auto" mode would suffice much better. Think about this: if (hasClass(modal,'fade')) // also add fade class to the backdrop We don't change the original plugin options while adding a simple fail safe mechanism, all without developer having to remember "one more thing". What do you think? |
I don't understand the "auto mode". How / where do you set or remove the fade ? |
Basically we change this this[animation] = options[animation] === false || modal[getAttribute](animation) === 'false' ? false : true; to this this[animation] = hasClass(modal,'fade') ? true : false; @schorke what do you think? |
Ok, now I understand ! Yeah, I think your solution is better : keeping it out of options and managed by class ! I'll update my PR. 👍 |
This will require additional tinkering for the case when opening another modal from a currently opened modal. The first example of our demo shows that the |
Done. Please download latest master and give it a try, I'm interested in the modal original events and opening modal from another modal. |
Added the fade option in modal, default is set to true to not break the current behaviour.