Last modified: 2011-08-01 00:09:29 UTC
Will be great to have ability to preview file description typed in "Summary"
field of "Upload file" page. Just to verify license tags, links and so on.
Preview should be displayed in pop-up window.
How does this request relate to bug 2258 and bug 73 ?
Pinging for thoughts on this prior to possible implementation.
*** Bug 5473 has been marked as a duplicate of this bug. ***
Ponging... There could be a [Preview] button next to the [Submit] button, much
alike the normal editing form. When the preview shows, the image path, name and
license should stay intact (of course). There is one thing that's bothering me:
where to actually put the preview? The troublemaker is the
[[MediaWiki:uploadtext]]. The question is: in which order should the contents be
1) Uploadtext, preview then form?
2) Preview, uploadtext and form?
3) Preview and form, no uploadtext
While 1) seems like a good compromise, I'd prefer 3) because uploadtext isn't
really needed after the first load of the upload page.
Just spilling some ideas
It's not possible to actually do that. Either we upload the file
with the preview form submission, or you have to select it again
on the preview display.
The idea I had was that uploads would still be associated with summaries, but
that during the first upload of an image, the user would also see a medium-sized
text box (with edit toolbar?) allowing them to enter initial additional content
for the description page.
If this was submitted blank, then the contents of the summary field, if any,
would be used as before. The description page could be previewed prior to
submission in some manner. As Brion states, however, there's a problem when we
consider that the file is attached to that form, and is going to be submitted
along with the rest of it if the user hits Upload, Preview, etc.
Or... the preview can be AJAX. ;)
My first thought was to have an Preview button do exactly what Upload does,
except saving the description, but instead opening the edit page of the
description with the prefilled text.
However, if the user doesn't save the page, the image would be without
description page, which is bad.
So, why not
* Perform a complete upload on preview, also saving the description
* Immediately open the edit page of the description, with preview
This ensures an initial description is saved, and the user can "fine-tune" the
description using preview. The only drawback here is generating two versions of
the description per preview-upload. But then, we do cope with old versions
rather well ;-)
My point was to reduce number of revisions for image descriptions. To check
links/categories for existence before uploading image.
Anyway, users are used to the right to preview anything before committing.
Whereupon they encounter this upload form with a missing preview button.
Test in lynx, etc.
Why only the summary? A single operation should preview the summary and the uploaded media in one go. This is especially important for checking that SVGs are within MediaWiki's rendering capability.
hmm... this should actually not be too hard to do now that we normal uploads on Secial:Upload being submited to the api see recent versions of the special upload page with js2enabled. We are doing an api upload request to an iframe.
I think we could reclassify this bug as adding a "preview" option to the upload api. The "preview" option would take the upload put it in a "stash" then return a rendered thumbnail transform. (and wiki-text parse the comment field along with other warning checks).
The idea behind the implementation will be the same, a button "upload and preview comment", which will upload the image to stash and show a preview of the comment with an option to save or cancel.