youtube filter swallows text that comes after a link, when used together wysiwyghtml5 editor #56

Closed
dgilperez opened this Issue Sep 19, 2012 · 1 comment

Comments

Projects
None yet
2 participants
Contributor

dgilperez commented Sep 19, 2012

In a similar way to #29, I'm seeing a similar behavior when using auto_hml together with https://github.com/xing/wysihtml5. It seams that WYSIWYG editors wrap different lines with <br/> tags, removing white space after the link.

Better explained with an example, this works:

AutoHtml::auto_html("bar http://www.youtube.com/watch?v=hsl3ckR_D7Q <br>foo"){ youtube(:width => 400, :height => 240)}
=> "bar <iframe width=\"400\" height=\"240\" src=\"//www.youtube.com/embed/hsl3ckR_D7Q\" frameborder=\"0\" allowfullscreen></iframe> <br>foo"

But this doesn't:

AutoHtml::auto_html("bar http://www.youtube.com/watch?v=hsl3ckR_D7Q<br>foo"){ youtube(:width => 400, :height => 240)}
=> "bar <iframe width=\"400\" height=\"240\" src=\"//www.youtube.com/embed/hsl3ckR_D7Q\" frameborder=\"0\" allowfullscreen></iframe>"

Ideas?

Owner

dejan commented Jan 3, 2014

This has been fixed by merging #57.

@dejan dejan closed this Jan 3, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment