Skip to content

polish merge status#5514

Merged
shiftkey merged 32 commits intodisplay-merge-status-in-compare-tabfrom
polish-merge-status
Sep 5, 2018
Merged

polish merge status#5514
shiftkey merged 32 commits intodisplay-merge-status-in-compare-tabfrom
polish-merge-status

Conversation

@donokuda
Copy link
Contributor

(🎯Targets the display-merge-status-in-compare-tab branch.)

This pull request starts some work on polishing the merge status.

I'm running into an issue where the UI is pretty jarring when the status gets updated from "Pending" to the " ✅/ ⚠️" status 😞:

✅:cry: ⚠️:sob:
merge-pending-green merge-pending-x

I tried doing some quick CSS tricks like animating the max-height, but I think a better approach is to prototype out a full transition instead. The transition could include fading in the content as well as doing a transitions with the octicons themselves.

@shiftkey
Copy link
Member

@donokuda I'm looking into some corner cases about the flow itself after testing this more, but I think the "Merge into Current branch" dialog didn't get the same love with the indicator:

@shiftkey shiftkey force-pushed the display-merge-status-in-compare-tab branch from 9f38077 to c3f06c7 Compare August 30, 2018 17:46
@shiftkey
Copy link
Member

@donokuda I'm juggling keeping downstream PRs #5493 and #5495 focused on their specific changes, so don't worry about those conflicts you're seeing - once you're happy with the UX I'll rebase it so that it's easy to review just what's changed here.

@shiftkey
Copy link
Member

@desktop/design I think this is pretty close - I did some tidy up of the Merge dialog and it's now looking like the Compare tab:

screen shot 2018-08-31 at 11 38 48 am

The SCSS can probably be better organized - maybe even unified - but I'll leave that up to y'all to figure out what's important here.

@donokuda
Copy link
Contributor Author

😍There's a few spacing inconsistencies that I can jump in and clean up. Overall, thx @shiftkey!

The SCSS can probably be better organized - maybe even unified - but I'll leave that up to y'all to
figure out what's important here.

👍This makes sense especially if the markup in both places are similar. I'll also take a quick look at that.

@shiftkey shiftkey force-pushed the display-merge-status-in-compare-tab branch from f6b6959 to b1f5f30 Compare September 4, 2018 11:29
@shiftkey shiftkey force-pushed the polish-merge-status branch from 3c4a057 to a417936 Compare September 4, 2018 11:47
@shiftkey shiftkey changed the title [WIP] Polish merge status polish merge status Sep 4, 2018
@shiftkey
Copy link
Member

shiftkey commented Sep 4, 2018

Dropping in some fresh screenshots now that the commits are reorganized:

@desktop/design if you've got a local branch and want to keep working on this you'll need to reset it to the remote:

$ git fetch --all
$ git checkout polish-merge-status
$ git reset origin/polish-merge-status --hard

@donokuda
Copy link
Contributor Author

donokuda commented Sep 4, 2018

I got one more small detail to push, and then I'll comment with some sort of emoji to indicate that my part is also ready to review.

@donokuda
Copy link
Contributor Author

donokuda commented Sep 4, 2018

Was taking a look at this feature in xXdark modeXx and saw that the text treatment between the merge dialog and the compare panel could be more consistent.

Specifically, the emphasized words are white while the rest of the sentence are a little gray so that the more important information stands out.

Before (👀at the panel to the left)
screen shot 2018-09-04 at 8 37 50 am

After
screen shot 2018-09-04 at 8 35 20 am

🥝My part is ready for review now and open to any feedback, especially around CSS stuff like

.merge-status {
background: var(--background-color);
border-width: 0 var(--spacing-half);
border: solid transparent;
box-sizing: content-box;
position: relative;
z-index: 1;
}

Copy link
Contributor

@outofambit outofambit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

css looks good to me, just have a concern about the testing of promiseWithMinimumTimeout

also, want to communicate my excitement about promiseWithMinimumTimeout in general for UI behavior! 👯

@outofambit outofambit dismissed their stale review September 4, 2018 17:46

unblocking merge

@shiftkey
Copy link
Member

shiftkey commented Sep 4, 2018

@donokuda I added the UI work for "unrelated histories" in 264e990 and I had to merge that in here to address a conflict, but I'll leave it up to you whether you want to restyle these or punt to a follow-up PR:

screen shot 2018-09-04 at 2 50 19 pm

screen shot 2018-09-04 at 2 50 14 pm

To test, use a repository that contains a gh-pages branch (like https://github.com/prettier/prettier) and choose that as the branch to merge into your current branch.

@shiftkey
Copy link
Member

shiftkey commented Sep 4, 2018

🍎

@donokuda
Copy link
Contributor Author

donokuda commented Sep 4, 2018

@donokuda I added the UI work for "unrelated histories" in 264e990 and I had to merge that in here to address a conflict, but I'll leave it up to you whether you want to restyle these or punt to a follow-up PR

Famous last words: "This seems simple enough to do."

I'll time box this to lunchtime and respond on whether we should punt for now given that this is more of an edge case.

@shiftkey
Copy link
Member

shiftkey commented Sep 4, 2018

@donokuda thanks for the update. I might even be able to get to it as part of #5495 tomorrow if you don't have a chance today.

This fixes a double nesting / double margin issue
Changing the `<p>` to a `<div>` removes the `margin-top` that gets added. I also updated the classname from `merge-info` to `merge-message` to be more consistent with the rest of the file. I style both class as the same.

We should consider settling on one classname to rule all merge status areas.
@donokuda
Copy link
Contributor Author

donokuda commented Sep 4, 2018

🥗

xXDark ModeXx

Merge dialog Compare tab
screen shot 2018-09-04 at 11 41 51 am screen shot 2018-09-04 at 11 41 43 am

Light mode

Merge dialog Compare tab
screen shot 2018-09-04 at 11 42 08 am screen shot 2018-09-04 at 11 42 02 am

EDIT: /cc @outofambit since you reviewed my codes 🔍 👀

@nerdneha
Copy link
Contributor

nerdneha commented Sep 4, 2018

woo! this is looking great! can we get a gif of the less jarring transition between pending and end result now? :D (will also be helpful for QA and maybe help docs)

@iAmWillShepherd iAmWillShepherd self-assigned this Sep 4, 2018
if (mergeStatus.kind === MergeResultKind.Invalid) {
return (
<p className="merge-info">
<React.Fragment>

This comment was marked as spam.

}

.merge-status-invalid {
color: $red-500;

This comment was marked as spam.

@donokuda
Copy link
Contributor Author

donokuda commented Sep 4, 2018

woo! this is looking great! can we get a gif of the less jarring transition between pending and end result now? :D (will also be helpful for QA and maybe help docs)

@nerdneha Would this work?

@j-f1
Copy link
Contributor

j-f1 commented Sep 5, 2018

Would it be better flipped vertically (i.e. the message, then the icon, then the button? That way, the button’s position wouldn’t change so the user would be able to click it even if the status-getting finishes while they’re hovering.

@shiftkey
Copy link
Member

shiftkey commented Sep 5, 2018

We've got two approvals here and I've got a couple of tasks left in #5495 to tackle, so I'm going to merge this in so I can stop juggling multiple PRs.

@j-f1 I'll let @desktop/design weigh in on that suggestion as this PR is about polishing the current layout - I have no strong feels either way.

@shiftkey shiftkey merged commit 8809069 into display-merge-status-in-compare-tab Sep 5, 2018
@shiftkey shiftkey deleted the polish-merge-status branch September 5, 2018 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready-for-review Pull Requests that are ready to be reviewed by the maintainers

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants