Skip to content

[MPDX-8566] Preference goal warnings #1284

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

Merged
merged 11 commits into from
Apr 15, 2025
Merged

Conversation

canac
Copy link
Contributor

@canac canac commented Mar 24, 2025

Description

  • Warn if the preferences goal is below the machine-calculated goal
  • Warn if the preferences goal has not been updated in the last year
  • Extract HI logic into a reusable module

The goal is to implement a UI similar to this mock-up from stakeholders. Note that we are considering language change to something like "system-generated support goal" but that is still being discussed.

image

MPDX-8566

Testing

  • On Pedro's account list
    • Change the monthly goal in preferences to less than $6,000/month
    • Verify that you see a warning above the input while typing and in the accordion header after saving
    • Verify that you see a warning on the My Accounts grid, on the dashboard, and on the MPD Health report
  • On Pedro's account list
    • Change the monthly goal to >$6,000/month
    • In src/lib/healthIndicator.ts change DateTime.now().minus({ year: 1 }) to DateTime.now()
    • Verify that the "Updated at" label is red on the My Accounts grid, on the dashboard, and on the MPD Health report

Checklist:

  • I have given my PR a title with the format "MPDX-(JIRA#) (summary sentence max 80 chars)"
  • I have applied the appropriate labels. (Add the label "On Staging" to get the branch automatically merged into staging.)
  • I have requested a review from another person on the project

@canac canac added the Preview Environment Add this label to create an Amplify Preview label Mar 24, 2025
@canac canac requested a review from dr-bizz March 24, 2025 18:53
@canac canac self-assigned this Mar 24, 2025
Copy link
Contributor

Preview branch generated at https://8566-goal-warning.d3dytjb8adxkk5.amplifyapp.com

Copy link
Contributor

github-actions bot commented Mar 24, 2025

Bundle sizes [mpdx-react]

Compared against 1d1fd1a

Route Size (gzipped) Diff
/accountLists 124.35 KB +4.19 KB
/accountLists/[accountListId] 276.39 KB +11.4 KB
/accountLists/[accountListId]/coaching/[coachingId] 254.02 KB +8.74 KB
/accountLists/[accountListId]/reports/coaching 253.98 KB +8.73 KB
/accountLists/[accountListId]/reports/donations/[[...contactId]] 347.24 KB +8.58 KB
/accountLists/[accountListId]/reports/healthIndicator 253.53 KB added

Copy link
Contributor

@dr-bizz dr-bizz left a comment

Choose a reason for hiding this comment

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

Great work on this! I left a few comments but it's looking awesome

Copy link
Contributor

@dr-bizz dr-bizz 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 looking great! I've left a few comments, but I think it's looking good. I'll approve to unblock you

@canac canac force-pushed the 8566-goal-warning branch from adadb8b to 2b30e9b Compare April 15, 2025 15:06
@canac canac merged commit 7aff140 into 8565-preference-goal-date Apr 15, 2025
18 of 19 checks passed
@canac canac deleted the 8566-goal-warning branch April 15, 2025 15:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Preview Environment Add this label to create an Amplify Preview
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants