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

Modal: Add prototype method for exceptions to enforceFocus #8537

Closed
JamesMGreene opened this issue Jul 20, 2013 · 4 comments
Closed

Modal: Add prototype method for exceptions to enforceFocus #8537

JamesMGreene opened this issue Jul 20, 2013 · 4 comments

Comments

@JamesMGreene
Copy link

It seems that adding a new prototype method to Modal to deal with special exceptions for enforceFocus would be handy in avoiding situations like zeroclipboard/zeroclipboard#159.

jQuery UI has a similar extension point for their modal dialog, called _allowInteraction; see zeroclipboard/zeroclipboard#179.

@fat
Copy link
Member

fat commented Jul 26, 2013

i dont really understand what you want? seems like your proposed fix is legit? just override enforceFocus?

@JamesMGreene
Copy link
Author

It's a legit fix, yeah. My concern is that fully overriding the method might lead to unexpected issues when a consumer upgrades their Bootstrap version, i.e. if that method changes in later versions to fix a bug or something. Obviously the consumer can just update their prototype override but that wouldn't even be necessary if there was a more granular extension point specifically just for allowing interaction exceptions.

If you think it's too much of an edge case, that's cool. However, the existence of that same extension point in jQuery UI makes me suspect it's come up more than a few times before.

@fat
Copy link
Member

fat commented Jul 27, 2013

hm… i think for now that your solution as is makes the most sense. It's not so much that it's a rare edge case, as that's how i really want people to be extending the plugins.

cheers

@fat fat closed this as completed Jul 27, 2013
@JamesMGreene
Copy link
Author

kthx

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

2 participants