Page MenuHomePhabricator

Make button placement for Captions consistent with Depicts/statements
Closed, ResolvedPublic


User story: As a Commons editor, I want consistency in button placement, so that I can think about more important things than where each button is located depending on what I'm editing..

We have this:
Currently with Depicts statements on File Page in Edit mode, both the Edit and Publish changes/Cancel buttons are in the top right corner. For Captions, only the Edit button is in the top right corner, and Publish changes/Cancel is in the lower right. Because this pattern works better on mobile (T221658) we want to update it here, too.

We want this:
For Depicts Edit/Publish/Cancel buttons to be consistent with how Captions are -- with the Publish button at the bottom. With testing, we can start with that and see how common it is for people to add enough values where having to scroll back up to save is an annoyance.

Acceptance Criteria:

  • The Depicts Edit/Publish/Cancel buttons are in the lower right corner to match Captions.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptMar 21 2019, 9:09 PM
Ramsey-WMF triaged this task as Low priority.Mar 22 2019, 7:41 PM
Ramsey-WMF moved this task from Untriaged to Next up on the Multimedia board.

In order to make this change, the JS code which controls this UI element in the Captions panel will need to be split up – the "Add a Caption" button and the "Cancel/Publish" button should be separate widgets that are placed in different locations.

Happy to work on this once the patch for CSS refactoring gets merged, since this should directly build on that.

Ha78na added a subscriber: Ha78na.

^ simply blocked till CSS refactor merges

egardner added a comment.EditedApr 23 2019, 11:31 PM

I think that this issue can be addressed as part of T221658 and T221228. The fact that the Captions panel separates the label (top of panel) from the cancel/publish controls (bottom of panel) means the layout functions better on small screens. On the Statement Panel, the panel label and the controls widget both exist in the top region of the panel, and on small screens they collide.

Handling the Statement panel the same as the Captions panel will make it easier to adapt the UI for smaller screen sizes. However, this is the opposite of what was originally suggested here (make both panels more like Statements).

Chiming in to agree with Eric that this will be addressed in T221658 for the reasons stated :)

Hey @PDrouin-WMF, how does this look – it's mostly what we talked about with some small adjustments:

Change 507401 had a related patch set uploaded (by Eric Gardner; owner: Eric Gardner):
[mediawiki/extensions/WikibaseMediaInfo@master] Make Edit/Cancel buttons consistent between panels

egardner claimed this task.Apr 30 2019, 7:51 PM
egardner moved this task from To Do to Code Review on the Structured-Data-Team-Current-Work board.

Button placement looks good, @egardner -- though the Q number being on the left-hand side is throwing me! How'd it get to be like that?

egardner added a comment.EditedApr 30 2019, 9:43 PM

Do you mean the P# for depicts, or the Q# for the individual statements? I moved the depicts number over with its label in attempt to consolidate things and save space. They could also be stacked on top of one another, which I think was what you originally had in your mock-up.

Cparle added a subscriber: Cparle.May 1 2019, 9:53 AM

Acceptance criteria need to be changed for this I think

@PDrouin-WMF ... so, is this ok? If it is can you change the acceptance criteria and I'll merge it

@Cparle thanks for catching this, I updated the acceptance criteria. had to hunt for the other relevant ticket (T221658) that changed this one.

Change 507401 merged by jenkins-bot:
[mediawiki/extensions/WikibaseMediaInfo@master] Make Edit/Cancel buttons consistent between panels

Ramsey-WMF closed this task as Resolved.May 23 2019, 6:46 PM

Placement on prod matches included screenshots (put with the P number in the right spot, right aligned)