Opened 9 years ago
Last modified 9 years ago
#13825 confirmed New Feature
Large files should not be previewed during upload.
Reported by: | Jakub Ś | Owned by: | |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | General | Version: | 4.5.0 |
Keywords: | Cc: |
Description (last modified by )
Add-on to #13824
- Drop large file into editor e.g. 30MB image
- Try clicking in to editor
Result: Eeditor doesn't respond because it processes base64 string to display image in editor. Also the very important thing to notice is that upload of such file with preview feature used takes much much longer.
We should introduce configuration variable for maximum file size for which preview should be displayed. Any file above that size will be uploaded without the preview. Image will be displayed only after the file is fully uploaded to the server.
Change History (11)
comment:1 Changed 9 years ago by
Description: | modified (diff) |
---|
comment:2 Changed 9 years ago by
Status: | new → confirmed |
---|
comment:3 Changed 9 years ago by
comment:4 Changed 9 years ago by
Milestone: | → CKEditor 4.5.5 |
---|
comment:5 Changed 9 years ago by
Milestone: | CKEditor 4.5.5 → CKEditor 4.5.6 |
---|
comment:6 Changed 9 years ago by
Owner: | set to kkrzton |
---|---|
Status: | confirmed → assigned |
comment:7 Changed 9 years ago by
As I note here: http://dev.ckeditor.com/ticket/14230: The idea of the uploadImage
was to make it super simple so one can replace it with different upload widget if one want to have a different behavior.
So, in fact, I do not like this ticket. In my opinion uploadImage
should stay simple, we could have a tutorial how to handle big files or a separate plugin for it. If we will start to adding more and more config options to uploadImage
users will not be ably anymore to take it, copy and change.
comment:8 Changed 9 years ago by
And I am not sure if simple "not showing preview" is enough. To make big images work fine there should be a server side code which will resize them. Otherwise it does not make sense. And the uploadImage does not handle resized images yet.
comment:9 Changed 9 years ago by
As we talked, resizing and not crashing are two different problems. But:
- I do not think this should be a config option. It should be a fixed value, user should not check what size it good to prevent browser crashing.
- Even if it will be one plugin we could consider two
uploadWidget
s to prevent having to many ifs in that code.
comment:10 Changed 9 years ago by
Owner: | kkrzton deleted |
---|---|
Status: | assigned → confirmed |
After some discussion about possible and simplest solution:
- Preview image is not shown for images large than X MB (the size should be determined after some testing in major browsers). For those images sample preview image is shown inside the placeholder.
- After image is successfully uploaded to the server, the placeholder is resized with the real image width/height.
- The resize operation (mentioned in 2.) should not be an undo step. Therefore using undo (e.g. Ctrl+Z) should not affect the size of an image.
comment:12 Changed 9 years ago by
Milestone: | CKEditor 4.5.6 |
---|
This request needs further discussion, we'll get back to it later.
This is because
uploadimage
plugin useloadAndUpload
option: http://docs.ckeditor.com/#!/api/CKEDITOR.fileTools.uploadWidgetDefinition-property-loadMethodWe could consider using
upload
for large file, so not showing the file preview. This could be done as an extension of this or as a separate plugin.This ticket needs a investigation how large files upload works in browsers.