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

Moving over link opens modal #104

Open
Waxolunist opened this issue Oct 2, 2014 · 15 comments
Open

Moving over link opens modal #104

Waxolunist opened this issue Oct 2, 2014 · 15 comments

Comments

@Waxolunist
Copy link
Contributor

When moving with the keys over a popup, the createLink Modal is opened. This is a disturbing behaviour.

@mkoryak
Copy link

mkoryak commented Oct 22, 2014

I agree, this is almost a deal breaker for us.
I also found another bug that is mildly related to this:
If i clicked on a previously created link, it would open the popup. At this point if I clicked save or cancel, the focus would return back to the editor and the modal would open. Because of the trickery done with CLASS_NAME_OPENED and timeouts, what would happen is the modal would close and open itself until some other javascript error in the editor happened.

For now the workaround for me is to override the wysihtml5.views.Composer.prototype.observe in its entirety where the only difference in my impl and yours is this line:

interactionEvents = ["drop", "paste", "mouseup"];

keyup and focus are removed.

@mkoryak
Copy link

mkoryak commented Oct 22, 2014

That being said, it would be great if there was a way to configure which interaction events are bound.

@zires
Copy link

zires commented Nov 3, 2014

👍

@elcoocool
Copy link

Having the same exact issue as mkoryak and not having any luck overriding the interaction events, though.

@mkoryak
Copy link

mkoryak commented Dec 8, 2014

here you go:
https://gist.github.com/mkoryak/3141524127cedb63e167

its a terrible way to fix a bug, but there it is.

@elcoocool
Copy link

Thanks, I'll give it a whirl!

@ryan2johnson9
Copy link

works for me thanks! - is there a pull request for this - will it be included in the next release?

@mkoryak
Copy link

mkoryak commented Feb 2, 2015

that fix is a hack, it will never be released.

@UnconventionalMindset
Copy link

Hi, this problem is happening also to me.
Steps to reproduce:
1. Click on a link.
2. Click confirm/cancel.
Notes:
- The problem doesn't show up if you press the X on the popup.
- The black background is not removed if confirmed/Canceled.
- The popup shows up more times even if it's pressed confirm/cancel.
Nobody fixed it yet?

@mkoryak
Copy link

mkoryak commented Jul 16, 2015

its been fixed, and its called using a different editor :P

@ruudboon
Copy link

Blocking me also. Any updates on the 0.3.4 release?

@anvarazizov
Copy link

big thanks, it works! 👍

@ilunie
Copy link

ilunie commented Nov 25, 2015

It works. however i had have some error in inserting images through modal boxes.
Does anyone know whats going on? Hitting "Insert" button, do nothing.

@ryan2johnson9
Copy link

@ilunie try this to fix your image issue:

I have altered the minified javascript code at

........./gems/bootstrap-wysihtml5-rails-0.3.3.2/vendor/assets/javascripts/bootstrap-wysihtml5/bootstrap3-wysihtml5.js

change

<input value="http://" class="bootstrap-wysihtml5-insert-image-url form-control">

to

<input value="http://" class="bootstrap-wysihtml5-insert-image-url form-control" data-wysihtml5-dialog-field="src">

Hope it helps

@ilunie
Copy link

ilunie commented Nov 26, 2015

@ryan2johnson9. Thanks bro .. 👍

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

9 participants