Page MenuHomePhabricator

Switching between "Upload" and "Search" tabs in the upload dialog clears state of the upload form
Closed, ResolvedPublic1 Story Points

Description

Switching between "Upload" and "Search" tabs in the upload dialog clears state of the upload form. I think this is undesired.

Event Timeline

matmarex created this task.Oct 8 2015, 9:13 PM
matmarex raised the priority of this task from to Needs Triage.
matmarex updated the task description. (Show Details)
matmarex added projects: Multimedia, VisualEditor.
Restricted Application added subscribers: Matanya, Aklapper. · View Herald TranscriptOct 8 2015, 9:13 PM

If one was on the information form they are brought back to the empty upload form after switching to the search tab. I am not sure for how long we should keep the state of the upload form. Till the time this dialog isn't closed once? It might be confusing to see a half filled information form after going through some image searches, especially when there is no thumbnail of the image you uploaded available to see.

(maybe we should add a thumbnail too?)

matmarex triaged this task as High priority.Oct 9 2015, 11:43 AM
matmarex set Security to None.

Switching to the upload tab restarts the upload process by design at the moment. What's the use case for preserving state when changing tabs?

Tabbed dialogs do not clear state of tabs when you switch them. That's just counterintuitive. If you want that behavior, use some different layout.

In general, yes. In this case though the tabs represent processes which are modal to each other so the use cases of switching between the two doesn't really exist. As you touch upon, index layout is probably not the correct thing to use, but is the best option visually at the moment.

If you really want to clear the forms as soon as the user switches away from them, it has to be made more obvious that the action will kill your input. The current tabs look like they could allow multi-tasking (searching for images while a file is being uploaded), but they don't. It's especially annoying because you're losing the uploaded file (which could have taken a while) and potentially the description fields.

If you insist on tabs, then we might just make a warning popup, like the one you get when trying to switch to wikitext. Other ideas:

  • Go back to the original idea of two separate workflows, two tools in the toolbar, and two dialogs – one for uploading, one for searching. The only way to back out of the upload form would be to close the dialog, which is more clearly a "destructive" action than switching tabs.
  • "Upload" as a secondary action in the "Search" dialog, with a "Back" button being the only way to back out – also a more clearly destructive action.

Thoughts?

We have a similar situation with Citoid. What we do there is conceptually have a start page which has the tabs, but as soon as you proceed into any process, the tabs disappear.

Change 244932 had a related patch set uploaded (by Esanders):
Media upload: Only reset upload booklet on dialog setup

https://gerrit.wikimedia.org/r/244932

Jdforrester-WMF closed this task as Resolved.Oct 11 2015, 12:37 PM
Jdforrester-WMF assigned this task to Esanders.
Jdforrester-WMF edited a custom field.

Change 244932 merged by jenkins-bot:
Media upload: Only reset upload booklet on dialog setup

https://gerrit.wikimedia.org/r/244932