Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Align publish button #19175

Closed
karmatosed opened this issue Dec 16, 2019 · 23 comments
Closed

Align publish button #19175

karmatosed opened this issue Dec 16, 2019 · 23 comments
Labels
Needs Dev Ready for, and needs developer efforts [Status] In Progress Tracking issues with work in progress

Comments

@karmatosed
Copy link
Member

karmatosed commented Dec 16, 2019

Currently, the publish button floats in the middle of the screen :

image

@karmatosed karmatosed added the Needs Design Feedback Needs general design feedback. label Dec 16, 2019
@karmatosed karmatosed changed the title Align publish button on mobile web Align publish button Dec 16, 2019
@karmatosed
Copy link
Member Author

If we aligned left it would be placed here:

image

@MichaelArestad
Copy link
Contributor

MichaelArestad commented Dec 16, 2019

What is the reason for the center alignment? Feels like a one-off? It probably should be aligned left.

Edit: The only reason I can think of is that when it is center aligned, it is similar in position to the original publish button so you don't have to move the cursor or your finger much.

@shaunandrews
Copy link
Contributor

I think it looks centered right now because its aligned with the position of the Publish button in the normal Top Bar of Gutenberg. Making it wider could help it keep the appearance of that alignment, but also fill the space a little more and be easier to tap:

image

@shaunandrews
Copy link
Contributor

If we wanna get fancy with it, we could add a transition to the button so it appears to grow in size when the publish sidebar appears.

@karmatosed
Copy link
Member Author

karmatosed commented Dec 16, 2019

I actually prefer it aligned left as stops us having the close and publish right next to each other. Beside each other, they feel like a trap we are laying down. We might be able to do something by swapping the preview and publish.

@karmatosed
Copy link
Member Author

An interesting point the button changes anyway:

Frame 18

@MichaelArestad
Copy link
Contributor

An interesting point the button changes anyway:

Yeah. That's what I saw. Worth testing as a PR.

@karmatosed karmatosed added Needs Dev Ready for, and needs developer efforts and removed Needs Design Feedback Needs general design feedback. labels Dec 18, 2019
@shaunandrews
Copy link
Contributor

having the close and publish right next to each other.

On mobile, it seems to be more logical for the next action (publish) to be on the right. The cancel (or maybe it should be a back arrow?) would logically be on the left. (This would be reversed with rtl languages.)

@MichaelArestad
Copy link
Contributor

On mobile, it seems to be more logical for the next action (publish) to be on the right. The cancel (or maybe it should be a back arrow?) would logically be on the left. (This would be reversed with rtl languages.)

That thought crossed my mind as well. A media query to change the close button position and button position on mobile could work. The downside is the close button would be in a different spot just for this part of the flow.

I wonder if the button should be here:

image

Just some things to consider.

@mapk
Copy link
Contributor

mapk commented Dec 18, 2019

In the vein of @shaunandrews' comment, here's an idea of how that might look.

publish

@karmatosed
Copy link
Member Author

karmatosed commented Dec 19, 2019

@mapk that mock covers the close though, I don't think < works as the action here. I actually don't think changing close to be < just in this case works as it's a pattern we use throughout so far. If we change it in other places it could change here of course.

@mapk
Copy link
Contributor

mapk commented Dec 23, 2019

@karmatosed yea, it doesn't "cover" the close X icon, just replaces it with the < icon. We do use this pattern elsewhere when shifting back to another view. For example in the editor Top Toolbar.

Screen Shot 2019-12-23 at 3 51 31 PM

However, I'm completely open to other ideas and was just sharing some visuals. Because I agree that having the "Publish" button right next to the X feels like an accident waiting to happen, I'd be more in favor Michael's solution because it moves the "Publish" button away from the X.

@karmatosed karmatosed added Needs Design Feedback Needs general design feedback. and removed Needs Dev Ready for, and needs developer efforts labels Jan 7, 2020
@karmatosed
Copy link
Member Author

Moving back to design feedback as not sure we have a clear way here yet (we are close though).

@enriquesanchez
Copy link
Contributor

just FYI, the publish button was recently updated to be center aligned in #17726

@folletto
Copy link
Contributor

Taking Shaun's idea one step beyond — and noting that this means updating all the panels (pre, post) as it changes the ×, what if we make the top part with only buttons, and in a flexbox that extends always the full width?

stretchbuttons

stretchbuttons-one

This would have an extra benefit to make the top area work from zero to three buttons, and have also an explicit label for close. It would also mark the panel as clearly distinct from the other kind of panel (which uses the ×), supporting the perceptual difference between the two.

@paaljoachim
Copy link
Contributor

Having a Publish and Cancel button would make it a lot cleaner, visually better and create better clarity then what exists today.

@enriquesanchez
Copy link
Contributor

I think @folletto's exploration is much clearer to what we have now. We should definitively try this.

@karmatosed
Copy link
Member Author

It looks like we have a decision on the way forward, so let's wrap up this feedback round and get a needs-dev label on this. Thanks everyone.

@karmatosed karmatosed added Needs Dev Ready for, and needs developer efforts and removed Needs Design Feedback Needs general design feedback. labels May 13, 2020
@juanfra
Copy link
Member

juanfra commented May 14, 2020

I'd love to help on this one.

I started to make some tests and the only thing I found (If I understood correctly the way it should be implemented) is that once we have the two buttons one beside the other:

  • When "Publish" is clicked, the "Cancel" button is just beside, but clicking that button won't cancel the publishing, and it'll close the panel instead.

I found this to be the only thing that could be misleading.

@paaljoachim
Copy link
Contributor

paaljoachim commented May 14, 2020

Hey @juanfra

Thanks for getting involved!

Going through the existing process:

  1. Default

Screen Shot 2020-05-14 at 23 44 32

Clicking Publish brings user to step 2.

--

  1. Screen.

Screen Shot 2020-05-14 at 23 45 14

Clicking the X = Brings user back to default 1.
Clicking the Publish button. (Are you ready to publish?) brings user to step 3.

--

  1. Published.

Screen Shot 2020-05-14 at 23 47 00

Clicking the X = Brings user to the next screen.

  1. The published post/page.

Screen Shot 2020-05-15 at 00 21 37


The new process:

  1. Default

Screen Shot 2020-05-14 at 23 44 32

Clicking Publish brings user to step 2.

--

  1. Screen.
    Publish-step-2

Clicking the Cancel button = Brings user back to default 1.
Clicking the Publish button. (Are you ready to publish?) brings user to step 3.

--

  1. Published.
    Publish-Close

Clicking the Close buttons = Brings user to the next screen.

--

  1. The published post/page.

Screen Shot 2020-05-15 at 00 21 37

juanfra added a commit to juanfra/gutenberg that referenced this issue May 15, 2020
Updating the post publish panel buttons to match the designs proposed on WordPress#19175
@juanfra
Copy link
Member

juanfra commented May 15, 2020

Thanks so much for the clarification, @paaljoachim! :)

I just submitted a PR with the proposed changes.

@paaljoachim
Copy link
Contributor

I added an animated gif of what the new Publish button flow looks like.
#22390 (comment)

@noisysocks noisysocks added the [Status] In Progress Tracking issues with work in progress label Jun 22, 2020
kirilzh pushed a commit that referenced this issue Jun 25, 2020
* Update post publish panel block

Updating the post publish panel buttons to match the designs proposed on #19175
@skorasaurus
Copy link
Member

#22390 has been merged; closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs Dev Ready for, and needs developer efforts [Status] In Progress Tracking issues with work in progress
Projects
None yet
Development

No branches or pull requests

10 participants