Opened 8 years ago

Closed 8 years ago

#16705 closed Bug (fixed)

Unable to paste base64 images using Firefox 50.0

Reported by: Irina Owned by: kkrzton
Priority: Nice to have (we want to work on it) Milestone: CKEditor 4.6.2
Component: General Version: 4.5.0
Keywords: Firefox IBM Cc: Satya Minnekanti

Description

Steps to reproduce

  1. Open nightly sample (http://nightly.ckeditor.com/16-11-30-07-06/standard/samples/)
  2. Use Printsceen or Paint to paste image (Ctrl + V) into the editor

Expected result

base64 image pastes into the editor

Actual result

Other details (browser, OS, CKEditor version, installed plugins)

Firefox 50.0.x only

Change History (7)

comment:1 Changed 8 years ago by Jakub Ś

Keywords: Firefox added
Status: newconfirmed
Version: 4.6.1 (GitHub - master)4.5.0

I have checked CKEditor 4.6 and FF 50.0.2 in deed it doesn't work but it seems that it is still possible to paste base64 images in CKEditor 4.4.8- and this feature got broken in CKEditor 4.5.0.

NOTE: IE11 seems to be working fine in all versions.

comment:2 Changed 8 years ago by Marek Lewandowski

Just a suggestion: couldn't we simply get blob of the image and convert it to base64 with enhanced clipboard that was added in 4.5.0?

comment:3 Changed 8 years ago by kkrzton

As m.lewandowski suggested it can be done by getting Blob of the image and then transforming it to base64. The pasted image is available in dataTransfer object (in files array) as an File (inheriting after Blob). To convert it to base64 one may use FileReader and its readAsDataUrl method.

Since we switched to custom clipboard handling in 4.5.0, it seems that case is not handled properly. The content of clipboard is not properly recognized by recogniseContentType method. Also it seems we are missing the proper flow for this particular case.

comment:4 Changed 8 years ago by Marek Lewandowski

Milestone: CKEditor 4.6.2
Priority: NormalNice to have (we want to work on it)

comment:5 Changed 8 years ago by kkrzton

Owner: set to kkrzton
Status: confirmedassigned

comment:6 Changed 8 years ago by kkrzton

Status: assignedreview

Pushed changes to /16705.

comment:7 Changed 8 years ago by Tomasz Jakut

Resolution: fixed
Status: reviewclosed

LGTM. Fixed with git:b941fec.

Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy