django-imagefield
django-imagefield copied to clipboard
Request: preview selected file.
Thanks for this nice module. It could be awesome if the selected file is previewed after selection and before save.
This is an excellent idea!
- The implementation would probably belong into the
PPOIAndPreviewMixinand inppoi.js, even when not using the PPOI widget. (We could also rename the JS file.) - This
returnshould be removed, we need.imagefieldelements added below https://github.com/matthiask/django-imagefield/blob/8f537dd6059a9ad6cebf23de63c8a1c32e9491a3/imagefield/widgets.py#L39-L40 - A good way to add an empty image element seems to be
src="data:,according to https://stackoverflow.com/questions/5775469/whats-the-valid-way-to-include-an-image-with-no-src