-
Notifications
You must be signed in to change notification settings - Fork 5k
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
Sort contacts alphabetically #11982
Sort contacts alphabetically #11982
Conversation
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tried writing an E2E test for this, but for some reason the app was misbehaving when the add contact form was opened, filled in, and then saved (the new contact was not appearing). If we feel like this is something we want to continue on to ensure proper test coverage, I may need to grab someone to help me with this.
return [ | ||
letter, | ||
sortBy(unsortedContactsByLetter[letter], (contact) => { | ||
return contact.name.toLowerCase(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note that each contact is sorted case-insensitively. I thought this might provide a better experience — when I look through a list that I know is sorted, I don't tend to think about case. I'm happy to change this if we think otherwise, though.
22ebab1
to
5d6713f
Compare
Contacts are grouped together by letter, and the groups are listed alphabetically, but the contacts in each group are not sorted alphabetically themselves. Fixes #10318.
5d6713f
to
f9fe3b9
Compare
Builds ready [f9fe3b9]
Page Load Metrics (541 ± 45 ms)
|
@@ -1,5 +1,6 @@ | |||
import React, { PureComponent } from 'react'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Builds ready [48967e4]
Page Load Metrics (478 ± 46 ms)
|
Builds ready [5e93374]
Page Load Metrics (493 ± 35 ms)
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks great! thanks for the followup changes
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome work! Thanks @mcmire
Contacts are grouped together by letter, and the groups are listed
alphabetically, but the contacts in each group are not sorted
alphabetically themselves.
Fixes #10318.
Before
After