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

feat(SavedTripList): Updated trip card design #1151

Merged
merged 35 commits into from
Apr 24, 2024
Merged

Conversation

amy-corson-ibigroup
Copy link
Contributor

@amy-corson-ibigroup amy-corson-ibigroup commented Feb 22, 2024

Description:

PR Checklist:

  • Does the code follow accessibility standards (WCAG 2.1 AA Compliant)?
  • Are all languages supported (Internationalization/Localization)?
  • Are appropriate Typescript types implemented?
Before After
image image
image image

|

@amy-corson-ibigroup amy-corson-ibigroup added the WIP Work in progress label Feb 22, 2024
Copy link
Collaborator

@binh-dam-ibigroup binh-dam-ibigroup left a comment

Choose a reason for hiding this comment

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

I like the new design! At first read, this needs a11y support and some other tweaks as indicated.

lib/components/mobile/mobile.css Show resolved Hide resolved
lib/components/user/monitored-trip/route-block-wrapper.tsx Outdated Show resolved Hide resolved
lib/components/user/monitored-trip/saved-trip-list.tsx Outdated Show resolved Hide resolved
width: 27px;
height: 27px;
border-radius: 50%;
background-color: ${(props) => (props.monitored ? '#4152a4' : 'transparent')};
Copy link
Collaborator

Choose a reason for hiding this comment

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

This is nice! I think a border of the same color should be shown for all cases, so that the outline of the circle is visible for non-monitored days.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I added the borders (although I went with #333 for the color, to make it clear those days were not monitored). I think I prefer without but I'll leave it up to the 2nd reviewer to break the tie!

Before After
image image

Copy link
Collaborator

Choose a reason for hiding this comment

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

I prefer the "after" version!

Copy link
Collaborator

Choose a reason for hiding this comment

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

Am I missing CSS in the screenshot below?
image

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Rats, I thought beb2dd2 fixed this but I guess not. Is it because I'm calling getBaseColor at the top level instead of inside the MonitoredDays component?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Much better!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@miles-grant-ibigroup @binh-dam-ibigroup removed the border in accordance with our tech call conversation - we can use borders on the buttons inside the form, hopefully to show that those are interactive and these aren't?

Copy link
Collaborator

Choose a reason for hiding this comment

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

@amy-corson-ibigroup Hmm I think each day should still show the circle shape somehow. Maybe in some pale grey? Contrast-wise, it should be ok, as the high-contrast circle denotes a selected day vs. a low-contrast.

lib/components/user/monitored-trip/trip-summary-pane.tsx Outdated Show resolved Hide resolved
lib/components/user/monitored-trip/trip-summary-pane.tsx Outdated Show resolved Hide resolved
lib/components/user/monitored-trip/trip-summary-pane.tsx Outdated Show resolved Hide resolved
lib/components/user/styled.ts Outdated Show resolved Hide resolved
lib/components/user/styled.ts Outdated Show resolved Hide resolved
Copy link
Collaborator

@binh-dam-ibigroup binh-dam-ibigroup left a comment

Choose a reason for hiding this comment

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

Could you tweak imports, types, CSS and some of the visuals and aria-labels as indicated?

lib/components/user/monitored-trip/trip-summary-pane.tsx Outdated Show resolved Hide resolved
lib/components/user/monitored-trip/trip-summary-pane.tsx Outdated Show resolved Hide resolved
lib/components/user/styled.ts Outdated Show resolved Hide resolved
lib/components/user/monitored-trip/trip-summary-pane.tsx Outdated Show resolved Hide resolved
lib/components/user/types.ts Show resolved Hide resolved
lib/components/user/styled.ts Show resolved Hide resolved
const SavedTripBody = styled.div`
display: flex;
justify-content: center;
padding: 0 15px;
Copy link
Collaborator

Choose a reason for hiding this comment

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

Do you have a preference for having the location icons flush or indented with respect to the the trip name heading?

width: 27px;
height: 27px;
border-radius: 50%;
background-color: ${(props) => (props.monitored ? '#4152a4' : 'transparent')};
Copy link
Collaborator

Choose a reason for hiding this comment

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

Much better!

Copy link
Collaborator

@miles-grant-ibigroup miles-grant-ibigroup left a comment

Choose a reason for hiding this comment

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

Getting there! But still a bit more cleanup needed

Copy link
Collaborator

@miles-grant-ibigroup miles-grant-ibigroup left a comment

Choose a reason for hiding this comment

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

It's all nitpicks at this point but I'm being nitpicky since this css is what will define us re-doing the editor UI!

Copy link
Collaborator

@miles-grant-ibigroup miles-grant-ibigroup left a comment

Choose a reason for hiding this comment

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

This was an endless review process but thank you for bearing with it I think we got something wonderful in the end

const TripDetailWithIcon = styled(TextWIcon)`
align-items: center;
gap: 12px;
// TODO: Do this in grid
Copy link
Collaborator

Choose a reason for hiding this comment

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

Is this legal in styled-components? I'm nervous. Shouldn't it be /* comment */

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Styled components supports JS line comments! styled-components/stylelint-processor-styled-components#164

@amy-corson-ibigroup
Copy link
Contributor Author

Thank you so much @binh-dam-ibigroup and @miles-grant-ibigroup!!

@amy-corson-ibigroup amy-corson-ibigroup merged commit 82fb3f1 into dev Apr 24, 2024
9 checks passed
@amy-corson-ibigroup amy-corson-ibigroup deleted the update-trip-card branch April 24, 2024 15:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants