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

Additional entry point for review comments #2084

Merged
merged 32 commits into from Apr 29, 2019

Conversation

Projects
5 participants
@kuychaco
Copy link
Member

commented Apr 18, 2019

Please be sure to read the contributor's guide to the GitHub package before submitting any pull requests.

Requirements

  • Filling out the template is required. Any pull request that does not include enough information to be reviewed in a timely manner may be closed at the maintainers' discretion.
  • Suggestion: You can use checklists to keep track of progress for the sections on metrics, tests, documentation, and user research.

Description of the Change

We received feedback asking to save users clicks when looking at reviews for non-checked out branches. See #2077.

This PR enables users to access reviews for any PR listed in the GitHub tab (not just the checked out PR) via a "See reviews" context menu item.

I also took this opportunity to add a quick way to view the PR on dotcom via a "View on GitHub" context menu item.

Screenshot/Gif

open-reviews

Fullscreen_4_18_19__2_14_PM

Alternate Designs

Initially considered hiding the option behind a right-click context menu, but figured adding a kebab icon would make this more discoverable. The drawback is that the icon takes up some UI real-estate, but in my opinion it's small and discreet enough that it's fine. Open to feedback and other suggestions.

Benefits

Currently, it is only possible to view review comments for the checked out PR from the PR list.

In order to view review comments for a PR that is not checked out the user has to click the desired PR in the PR list to open the PR detail pane item, open the "Files" tab, and click the "See reviews" button in the footer of the tab.

With this change, we increase consistency by allowing the user to open reviews for any PR directly from the PR list. Previously this was only possible for the checked out PR.

Possible Drawbacks

None really... the only mild concern is that the additional icon might increase visual noise.

Applicable Issues

Fixes #2077

Metrics

Adding an event for 'open-reviews-tab'.
Adding an event for 'open-issueish-in-browser' to collect information about the users leaving the editor for the browser.

Tests

Tested openOnGitHub method along with open-issueish-in-browser event firing
Tested that showActionsMenu handler is called when the menu icon is clicked
Currently there is no good way to test Electron Menus.

Documentation

N/A

Release Notes

Access review comments for any PR listed in the GitHub panel via an "ellipses" icon

User Experience Research (Optional)

N/A

@kuychaco kuychaco self-assigned this Apr 18, 2019

@kuychaco kuychaco added this to In progress in Sprint : 4 April 2019 - 8 May 2019 : v0.29.0 via automation Apr 18, 2019

@codecov

This comment has been minimized.

Copy link

commented Apr 18, 2019

Codecov Report

Merging #2084 into master will increase coverage by <.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2084      +/-   ##
==========================================
+ Coverage   92.55%   92.55%   +<.01%     
==========================================
  Files         207      207              
  Lines       12016    12025       +9     
  Branches     1745     1747       +2     
==========================================
+ Hits        11121    11130       +9     
  Misses        895      895
Impacted Files Coverage Δ
lib/containers/current-pull-request-container.js 100% <ø> (ø) ⬆️
lib/containers/issueish-search-container.js 95.83% <ø> (ø) ⬆️
lib/controllers/issueish-searches-controller.js 73.68% <100%> (+7.01%) ⬆️
lib/views/issueish-list-view.js 97.5% <100%> (+0.35%) ⬆️
lib/controllers/issueish-list-controller.js 100% <100%> (ø) ⬆️
lib/views/reviews-view.js 82.5% <0%> (-0.22%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f98abf3...cff5a35. Read the comment docs.

@aviflax

This comment has been minimized.

Copy link

commented Apr 18, 2019

👋 I’m the user who shared the feedback in #2077. @annthurium pointed me to this PR and I think the change looks great!!!

@@ -63,6 +63,11 @@
text-align: center;
}

&--menu {
color: @text-color-subtle;
transform: rotate(90deg);

This comment has been minimized.

Copy link
@annthurium

annthurium Apr 19, 2019

Contributor

@kuychaco : what's the rationale for rotating the icon?

I'm not a fan for a couple of reasons:

  1. it's inconsistent with other kebab menus in the package such as undo discard which keep the icon in its original orientation.

  2. right now the icon is not vertically centered. It's a lot more annoying to fix when the icon is rotated. If we remove the rotation we can just add a line-height of 1.

Screen Shot 2019-04-19 at 7 48 23 AM

This comment has been minimized.

Copy link
@kuychaco

kuychaco Apr 23, 2019

Author Member

Sounds good! Thanks for making the change!

Show resolved Hide resolved lib/controllers/issueish-list-controller.js Outdated

annthurium and others added some commits Apr 19, 2019

annthurium
fix icon vertical centering
also remove rotation to be consistent with other kebab menus in the package
annthurium
actually fix the icon
I staged the wrong file because I wasn't paying attention -- see previous commit.
Istanbul ignore electron menu logic
Seems like there's no good way to test Electron menus. Not even supported in spectron -- electron/spectron#21
Move `showActionsMenu` to IssueishListController
Keep view simple and free of unnecessary logic

@kuychaco kuychaco marked this pull request as ready for review Apr 24, 2019

@kuychaco kuychaco requested a review from vanessayuenn Apr 24, 2019

@vanessayuenn
Copy link
Contributor

left a comment

I have some small nits with some of the tests, but otherwise this LGTM!

Show resolved Hide resolved test/controllers/issueish-list-controller.test.js Outdated
Show resolved Hide resolved test/controllers/issueish-list-controller.test.js Outdated
Show resolved Hide resolved test/controllers/issueish-list-controller.test.js Outdated
Show resolved Hide resolved test/controllers/issueish-list-controller.test.js Outdated

vanessayuenn and others added some commits Apr 25, 2019

Update test/controllers/issueish-list-controller.test.js
Co-Authored-By: kuychaco <kuychaco@github.com>
Use strictEqual instead of equal
Co-Authored-By: Vanessa Yuen <vanessayuenn@users.noreply.github.com>

@kuychaco kuychaco requested a review from vanessayuenn Apr 25, 2019

@kuychaco

This comment has been minimized.

Copy link
Member Author

commented Apr 29, 2019

That pending atom.github [old] check is irrelevant... it's an orphan left over from creating a new Azure pipeline to fix our Azure install. Gonna go ahead and merge this because we have all the green checks we need

@kuychaco kuychaco merged commit c28b7ef into master Apr 29, 2019

14 of 15 checks passed

atom.github [old]
Details
atom.github Build #20190429.14 succeeded
Details
atom.github (Lint) Lint succeeded
Details
atom.github (Linux beta) Linux beta succeeded
Details
atom.github (Linux dev) Linux dev succeeded
Details
atom.github (Linux stable) Linux stable succeeded
Details
atom.github (MacOS beta) MacOS beta succeeded
Details
atom.github (MacOS dev) MacOS dev succeeded
Details
atom.github (MacOS stable) MacOS stable succeeded
Details
atom.github (Snapshot) Snapshot succeeded
Details
atom.github (Windows beta) Windows beta succeeded
Details
atom.github (Windows dev) Windows dev succeeded
Details
atom.github (Windows stable) Windows stable succeeded
Details
codecov/patch 100% of diff hit (target 92.55%)
Details
codecov/project 92.55% (+<.01%) compared to f98abf3
Details

Sprint : 4 April 2019 - 8 May 2019 : v0.29.0 automation moved this from In progress to Merged Apr 29, 2019

@kuychaco kuychaco deleted the ku-open-reviews-from-pr-list branch Apr 29, 2019

@smashwilson smashwilson referenced this pull request May 8, 2019

Closed

v0.29.0-0 QA Review #2129

11 of 11 tasks complete
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.