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

Editing external image via CKBox editing changes current image and reinserts it at the same time #17056

Closed
f1ames opened this issue Sep 6, 2024 · 1 comment · Fixed by #17101
Assignees
Labels
package:ckbox type:bug This issue reports a buggy (incorrect) behavior.

Comments

@f1ames
Copy link
Contributor

f1ames commented Sep 6, 2024

📝 Provide detailed reproduction steps (if any)

  1. Go to full featured demo https://ckeditor.com/docs/ckeditor5/latest/examples/builds-custom/full-featured-editor.html.
  2. Set editor HTML to (via e.g. source mode):
<h2 class="document-title" id="ec24b0e365a7ffc9b5918f9f23af2fc87">
    Handheld emperor
</h2>
<p>
    Nintendo, a Japanese electronics company, started as a <a href="https://en.wikipedia.org/wiki/Hanafuda"><i>hanafuda</i> cards</a> manufacturer in 1889. In the mid-1970s, they entered the early video games market and became famous for their home video and handheld game consoles. Nintendo introduced consoles like the <strong>NES</strong>, <strong>SNES</strong>, and <strong>Wii</strong>. But the most revolutionary was for sure the <strong>Game Boy</strong>.
</p>
<h3 class="document-subtitle" id="eb498c56ecda85e445e86add04718a7e2">
    A countdown of Nintendo handhelds
</h3>
<p>
<img src="https://ckeditor.com/docs/ckeditor5/latest/assets/img/features-collaboration.png">
</p>
  1. Focus image and press edit button in its' toolbar.
  2. Do some editing and "Apply".

✔️ Expected result

I would expect to have one image with my edits applied.

❌ Actual result

I end up with 2 images in the editor:

  • Initial one, which is resized (according to edited sizes).
  • Other one, which looks like a proper editing result.
Screen.Recording.2024-09-06.at.14.16.42.mov

❓ Possible solution

...

📃 Other details

  • Browser: Chrome
  • OS: macOS
  • First affected CKEditor version: Not sure
  • Installed CKEditor plugins: See linked demo config

If you'd like to see this fixed sooner, add a 👍 reaction to this post.

@Mati365
Copy link
Member

Mati365 commented Sep 16, 2024

@f1ames I checked this issue and ckbox used insertImage command that tried to insert block image in place of inline image. After adjusting ckbox command options to smarter deduce if user selected inline image and it looks like it works.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
package:ckbox type:bug This issue reports a buggy (incorrect) behavior.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants