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

Incorrect result when image is quoted #3316

Closed
Reinmar opened this issue May 4, 2017 · 2 comments · Fixed by ckeditor/ckeditor5-block-quote#11
Closed

Incorrect result when image is quoted #3316

Reinmar opened this issue May 4, 2017 · 2 comments · Fixed by ckeditor/ckeditor5-block-quote#11
Assignees
Labels
package:block-quote type:bug This issue reports a buggy (incorrect) behavior.
Milestone

Comments

@Reinmar
Copy link
Member

Reinmar commented May 4, 2017

The image should not be quotable now due to https://github.com/ckeditor/ckeditor5-image/issues/54. And after iteration 9 it wasn't – it was always skipped by the quote command. Right now, on current master branches I get this:
may-04-2017 15-06-35

@Reinmar
Copy link
Member Author

Reinmar commented May 4, 2017

Bad commit according to bisect:

(detached:bisect/bad~1 cb2feef ?1) p@m /workspace/ckeditor5> git bisect good
ab5b5494e5eba7beb4a3bac4ea9c5e6d59a610f5 is the first bad commit
commit ab5b5494e5eba7beb4a3bac4ea9c5e6d59a610f5
Author: Travis CI User <[email protected]>
Date:   Tue Apr 11 16:45:47 2017 +0000

    Revision: https://github.com/ckeditor/ckeditor5-image/commit/02869eb4478a2f538006c128b30b9727617af665

:100644 100644 611526d5c4beae7046b0a08ec36843cbbe642175 35acdd8ba971d8127dd462a9c8c1162a54f00d58 M	mgit.json

So, it's this ticket: https://github.com/ckeditor/ckeditor5-image/issues/94.

@Reinmar
Copy link
Member Author

Reinmar commented May 4, 2017

As I explained in https://github.com/ckeditor/ckeditor5-engine/issues/532#issuecomment-299204504 this is a result of Schema's poor behaviour. The schema for image and caption is now totally incorrect, so, as a result, caption is a block element and blocks are allowed in blockQuote...

Fortunately, blockQuote is not yet allowed in image (and won't be, even after https://github.com/ckeditor/ckeditor5-image/issues/54) and apparently we miss a check whether blockQuote can be applied at that level.

OTOH... AFAIR the entire implementation of the block quote command bases on the assumption that blocks returned by Selection#getSelectedBlocks() are children of the same element ;| Which would be true for now if not this case. It may, therefore, require more thinking.

@Reinmar Reinmar self-assigned this May 4, 2017
scofalik referenced this issue in ckeditor/ckeditor5-block-quote May 5, 2017
Fix: Block quote should not be applied to image's caption. Closes: #10.
@mlewand mlewand transferred this issue from ckeditor/ckeditor5-block-quote Oct 9, 2019
@mlewand mlewand added this to the iteration 10 milestone Oct 9, 2019
@mlewand mlewand added status:confirmed type:bug This issue reports a buggy (incorrect) behavior. package:block-quote labels Oct 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
package:block-quote type:bug This issue reports a buggy (incorrect) behavior.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants