-
Notifications
You must be signed in to change notification settings - Fork 1
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
MPDX-8217 change the contact and task row links into actual links. #1090
Conversation
Bundle sizes [mpdx-react]Compared against 0b3c384 No significant changes found |
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 like that you moved some of the logic into a custom hook 🔥
src/components/Contacts/ContactFlow/ContactFlowRow/ContactFlowRow.test.tsx
Outdated
Show resolved
Hide resolved
src/components/Reports/FourteenMonthReports/Layout/Table/Table.test.tsx
Outdated
Show resolved
Hide resolved
src/components/Reports/FourteenMonthReports/Layout/Table/Table.tsx
Outdated
Show resolved
Hide resolved
@@ -42,7 +42,7 @@ export const FourteenMonthReport: React.FC<Props> = ({ | |||
currencyType, | |||
isNavListOpen, | |||
title, | |||
onSelectContact, | |||
getContactUrl, |
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.
Instead of prop-drilling getContactUrl
down from the parent, what do you think about using the useGetContactUrls
hook in this component and passing in the path based on the currency type? I can see a case for leaving it as-is, so let me know what you think.
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 would prefer to keep the controls in one place and since it's only going down 1 component, I think we are okay
Functionality looks really good too! One thing I noticed is that in task rows, the contact's name is always underlined now instead of just being underlined on hover. Also, command+clicking contacts and tasks to open them in a new tab opens the contact or task in the tab I was in and opens them in a new tab. Normally command+click doesn't change the current URL. |
Even more conflicts 😭 |
…y: 'standby',` was causing issues on local
…chPolicy: 'standby',` was causing issues on local
Preview branch generated at https://MPDX-8217.d3dytjb8adxkk5.amplifyapp.com |
…chPolicy: 'standby',` was causing issues on local
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.
The only issue I'm seeing is links always being underlined instead of only being underlined on hover, so I'm going to approve.
We might want to add defaultProps: { underline: 'hover' }
to MuiLink
in the theme to ensure consistency in all links across the application. That could also be done later.
Description
In this PR, I converted the contact and task JS click functions into actual links that can be opened in a new tab. This helps with UX
Contact pages
List view: the contacts on the list view are now links
Flows view: The contacts on the flows view are now links.
Map view: the contacts are not links.
Contact details: The links to other contacts on a contact detail page are now links
Task Page
List view: the contacts on the list view are now links.
Reports
All the report pages that feature contacts names are now links.
Coaches
There is no need to edit anything here.
Tools
Appeals: I have made the appeal contacts names into links on both list and flows view
Checklist: