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: badge in progress content component #5618

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

christian14b
Copy link
Collaborator

Screenshot 2024-10-25 at 3 02 44 PM Screenshot 2024-10-25 at 3 02 54 PM

@@ -30,6 +30,12 @@ export const ID_US_ECONOMIC_EQUALITY = 'us-economic-equality';
export const ID_CLIMATE_ACTION = 'climate-action';
export const ID_REFUGEE_EQUALITY = 'refugee-equality';
export const ID_BASIC_NEEDS = 'basic-needs';
// TODO: Use the LoanChannelQueryMap to get the correct filters
Copy link
Collaborator

Choose a reason for hiding this comment

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

Is a ticket logged for this?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Added this as a note because I wasn't sure if we have already handled this (the query params needed to redirect users to lend/filter), but I'll create a follow-up ticket if it's not

Copy link
Collaborator

Choose a reason for hiding this comment

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

The query map will work if our achievements directly match existing channels in that map file. Do our achievements as defined match existing channels?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Most of them, the problem is the OR conditions in the Badge breakdowns spreadsheet I think... Seems like only Climate actions and Basic needs will need to be handled differently

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Well, I don't think we will need the query map to replace this, we need specifics query params for Climate actions and Basic needs

class="tw-pt-1 tw-pb-1.5 tw-flex tw-flex-col md:tw-flex-row tw-items-center tw-justify-left tw-gap-3"
>
<BadgeContainer :status="BADGE_IN_PROGRESS" :shape="getBadgeShape()" class="tw-z-1">
<img
Copy link
Collaborator

Choose a reason for hiding this comment

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

The dashed border is showing up inside the badge icon. It should show around the outside. Is this because of the maxheight override? Also, it would be helpful to add BadgeModal stories to cover the 5 different badge use cases, to ensure the badge icon looks correctly for each.

Related, this version of the BadgeModal requires there to be modal content to be complete compared to the mocks (modal without title, back button, etc.). Is that something you see as a follow-up ticket?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

My bad, badge image is old, new one looks good
image

And yeah, I think the other elements should be handled while integrating this in BadgeModal, I'll create a separate ticket to integrate them

Copy link
Collaborator

Choose a reason for hiding this comment

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

Sounds good regarding the follow-up ticket. Please include a link to the mocks and bullets for the specific requirements in the mocks that are still needed.

};

const badgeName = computed(() => props.badge?.fields?.challengeName ?? '');
const badgeImage = computed(() => props.badge?.fields?.badgeImage?.fields?.file?.url ?? '');
Copy link
Collaborator

Choose a reason for hiding this comment

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

This will need to change once we update to use all badge icons, this needs to be the badge of the current level. I'm creating utils to get the correct tier. Please add a TODO here to use the icon of the correct in-progress badge level.

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.

2 participants