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

Embeddable link pasted inside table disappears #2763

Closed
f1ames opened this issue Oct 3, 2018 · 4 comments · Fixed by ckeditor/ckeditor5-media-embed#56
Closed

Embeddable link pasted inside table disappears #2763

f1ames opened this issue Oct 3, 2018 · 4 comments · Fixed by ckeditor/ckeditor5-media-embed#56
Assignees
Labels
package:media-embed type:bug This issue reports a buggy (incorrect) behavior.
Milestone

Comments

@f1ames
Copy link
Contributor

f1ames commented Oct 3, 2018

Is this a bug report or feature request? (choose one)

🐞 Bug report

💻 Version of CKEditor

11.0.1

📋 Steps to reproduce

  1. Go to any editor instance with Table and Media Embed plugin (you can use nightly docs).
  2. Create table.
  3. Paste embeddable link (e.g. from YouTube) inside table cell.

✅ Expected result

Link is pasted.

❎ Actual result

Link is pasted and then removed.

table me 1

📃 Other details that might be useful

Tested on Firefox and Chrome.

@Reinmar
Copy link
Member

Reinmar commented Oct 3, 2018

👍 good finding

Similarly to autoformat (where we have the same problem), the feature should not work when it's disabled.

@Mgsy
Copy link
Member

Mgsy commented Oct 3, 2018

And it crashes if you'll hold Ctrl + V for some time.

bug_cke5

automediaembed.js:148 Uncaught TypeError: Cannot read property 'root' of null
    at Object.n.model.change.t [as callback] (automediaembed.js:148)
    at zl._runPendingChanges (model.js:496)
    at zl.change (model.js:154)
    at match.i.hasMedia._timeoutId.Qs.window.setTimeout (automediaembed.js:142)

@Reinmar
Copy link
Member

Reinmar commented Oct 3, 2018

@Mgsy, can you move it to a separate ticket? And could you check it doesn't happen outside a table?

@f1ames
Copy link
Contributor Author

f1ames commented Oct 3, 2018

Same happens inside image caption (so probably happens in all block contexts where media embed is disabled).

oleq referenced this issue in ckeditor/ckeditor5-media-embed Oct 29, 2018
Fix: The `AutoMediaEmbed` should not upcast the pasted URL if a media element is disallowed at the current selection. Closes #47.
@mlewand mlewand transferred this issue from ckeditor/ckeditor5-media-embed Oct 9, 2019
@mlewand mlewand added this to the iteration 21 milestone Oct 9, 2019
@mlewand mlewand added status:confirmed type:bug This issue reports a buggy (incorrect) behavior. package:media-embed labels Oct 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
package:media-embed type:bug This issue reports a buggy (incorrect) behavior.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants