Skip to content

[RBB] Ahead/Behind Toggle #3997

Closed
Closed

Description

@nerdneha

This is part of #3956 and shows how your branch has diverged from your target branch (ex: master). This will help you understand what changes can be brought into your branch (behind) and what commits are unique to your branch (ahead).

User Flow to check functionality:

  • go to compare view with no toggle showing
  • click on compare tab, click into the "compare a branch..." input, and click on "master" and see:
    • the toggle appear in the compare view
    • Behind (x) selected by default where x is the # of commits your branch is behind "master" (old view showed commits ahead of master)
    • the commits that are missing from your branch that exist in the target branch
  • click on Ahead (y) in the toggle where y is the # of commits your branch is ahead of "master" and see:
    • the commits that exist only in your branch and not the target branch
  • press "x" in the branch input, select another target branch, and see:
    • the compare view where you can toggle behind/ahead
    • the respective commits listed

Changes:

  • create toggle
  • Behind (x) & Ahead (y) counts
  • Behind (x) is selected by default
  • default view shows the commits that your branch is behind (relative to the target branch)
  • clicking Ahead (y) shows commits
  • clicked Ahead (y) shows the commits that your branch is ahead (relative to the target branch)

Other pieces:

Before (shows "ahead" by default):
screen shot 2018-02-08 at 2 11 27 am

After:
image

Activity

  1. added this to the milestone on Feb 13, 2018
  2. shiftkey commented on Feb 15, 2018

    @shiftkey
    Member

    @donokuda mentioned in chat that he'd like to experiment with this toggle against real repository data, so I'm gonna see if I can get a branch together to mimic this experience while we're wrapping up 1.1, even if we throwaway the resulting code.

  3. self-assigned this
    on Feb 15, 2018
  4. shiftkey commented on Feb 16, 2018

    @shiftkey
    Member

    I've pushed up ahead-behind-toggle-spike which hacks in a rough UX for this: https://github.com/desktop/desktop/compare/ahead-behind-toggle-spike - try it out!

    I cheated and used a tab bar to "emulate" the toggle button, but it should be good enough to get a feel for the feature.

    A couple of quick observations based on the time I spent testing this:

    • I found myself glancing up and to the right a lot to remember what branch I was on while doing this - that bit of information seems important to remember "where I am right now" and felt further away from the compare "area".
    • When I was considering whether to merge a branch into this current branch, the "ahead" details - representing the commits on my branch - didn't really feel as relevant as the "behind" details. That might be down to the workflow.
    • Viewing those "ahead" isolated from the whole history, to identify my work that was distinct from the other branch, still feels very useful.
  5. removed their assignment
    on Feb 16, 2018
  6. j-f1 commented on Feb 16, 2018

    @j-f1
    Contributor

    I found myself glancing up and to the right a lot to remember what branch I was on while doing this - that bit of information seems important to remember "where I am right now" and felt further away from the compare "area".

    How about labeling the dropdown with “bump-to-react-16 → master”?

  7. donokuda commented on Feb 20, 2018

    @donokuda
    Contributor

    😍Thanks @shiftkey for doing this and adding your thoughts!

    I found myself glancing up and to the right a lot to remember what branch I was on while doing this - that bit of information seems important to remember "where I am right now" and felt further away from the compare "area".

    I can see this as a potential issue. @niik and I chatted about this and we decided it makes sense for us to keep moving forward with the current design, but check if the lack of showing your current branch is confusing to users. If it does turn out to be an issue, I think we could figure out a way to incorporate that information into the area. Something like what @j-f1 suggested might work.

    When I was considering whether to merge a branch into this current branch, the "ahead" details - representing the commits on my branch - didn't really feel as relevant as the "behind" details. That might be down to the workflow.

    Just to clarify, this is intended. We'll only surface the merge branch section when you have the "Before" tab selected since it also acts as a list of commits that you're missing from a branch you'll eventually want to merge into.

    Out of curiosity, what would be the next steps after this spike?

  8. nerdneha commented on Feb 21, 2018

    @nerdneha
    ContributorAuthor

    @donokuda, my voluntary 2💰: if there's no changes to designs for now based on findings, i think we can keep this and potentially create a user test script to answer this question better once we get it in a PR

    @shiftkey given that you've spiked this feature, do you think the scripted "user flow" and the listed changes are comprehensive? are we missing anything?

  9. shiftkey commented on Feb 21, 2018

    @shiftkey
    Member

    @donokuda @nerdneha I'm happy to proceed as-is and address the UX feels later - whether it's as part of a PR or end-user testing/feedback

  10. changed the title [-]Ahead/Behind Toggle[/-] [+][RBB] Ahead/Behind Toggle[/+] on Mar 19, 2018
  11. locked as resolved and limited conversation to collaborators on Jul 17, 2018
  12. unlocked this conversation on Sep 27, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions