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

19655 adds reusable snackbar component to all project view tables #1521

Merged
merged 63 commits into from
Jan 30, 2025

Conversation

tillyw
Copy link
Contributor

@tillyw tillyw commented Jan 9, 2025

Associated issues

fixes cityofaustin/atd-data-tech#19655

Testing

URL to test:

https://deploy-preview-1521--atd-moped-main.netlify.app/ or local

Steps to test:

this pr adds snackbar error and success messages to all of the mutations in the project view. i tried to keep all the error messages and functionality as consistent as possible.

  • start with the summary page of any given project. throttle your network to 'offline' status
  • try adding, updating, deleting (where applicable) the following fields or tables (or modals in some cases) and note the error messages that appear on the top right of the project page. if the update involves a modal, try turning off throttling, opening the modal, turning on throttling and making a change. if there is a template, try loading a template while offline. try your best to break things, you should get error snackbars in most cases and error logging in the console, and no wsods.
    • name
    • follow/unfollow
    • description
    • status update
    • lead
    • sponsor
    • partners
    • project type
    • public process
    • website
    • interim id
    • ecapris id
    • tags
    • subprojects
  • repeat the above with throttling off and note the success messages
  • repeat the steps above for the following pages and tables
    • timeline
      • phases
      • milestones
    • team
    • funding
      • sources
      • work activities
    • notes
    • files

please let me know if i have missed anything!


Ship list

  • Code reviewed
  • Product manager approved
  • Product manager checked DB view dependencies
  • Product manager added to QA test script if applicable
    • Will find a place to add when testing today

@tillyw tillyw added the WIP Work in progress label Jan 10, 2025
Copy link
Collaborator

@mddilley mddilley left a comment

Choose a reason for hiding this comment

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

Thanks for seeing this opportunity to clean up our feedback messages while working on the table feedback. I know that we haven't been the best about keeping this consistent as we added features over the years, and I think these updates will change that for the better in this main view.

I requested some small changes in here, and I think it is 🚢 from there. I was able to see the feedback in all places noted in the test steps. 💯

While testing, I noticed an old bug that isn't introduced in this PR with how we are closing the snackbar with setTimeout. I'll write up a separate issue.

Copy link
Member

@chiaberry chiaberry left a comment

Choose a reason for hiding this comment

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

I have tested this and tried to break it, and I cant! I will look again after the requested changes are addressed and approve then. its a lot of work and you were very thorough

@tillyw
Copy link
Contributor Author

tillyw commented Jan 28, 2025

Thanks for seeing this opportunity to clean up our feedback messages while working on the table feedback. I know that we haven't been the best about keeping this consistent as we added features over the years, and I think these updates will change that for the better in this main view.

I requested some small changes in here, and I think it is 🚢 from there. I was able to see the feedback in all places noted in the test steps. 💯

While testing, I noticed an old bug that isn't introduced in this PR with how we are closing the snackbar with setTimeout. I'll write up a separate issue.

thanks @mddilley !! i agree with all of your edits and i'll get those incorporated shortly. snackbarHandle was driving me crazy >.< i should've just renamed it at the start but it will be pretty painless to find and replace

@tillyw
Copy link
Contributor Author

tillyw commented Jan 28, 2025

Thanks for seeing this opportunity to clean up our feedback messages while working on the table feedback. I know that we haven't been the best about keeping this consistent as we added features over the years, and I think these updates will change that for the better in this main view.

I requested some small changes in here, and I think it is 🚢 from there. I was able to see the feedback in all places noted in the test steps. 💯

While testing, I noticed an old bug that isn't introduced in this PR with how we are closing the snackbar with setTimeout. I'll write up a separate issue.

i noticed this bug as well! once we have the snackbar defined in a single component it should make this an easier fix and hopefully prevent it from reappearing in the future

@tillyw
Copy link
Contributor Author

tillyw commented Jan 28, 2025

I have tested this and tried to break it, and I cant! I will look again after the requested changes are addressed and approve then. its a lot of work and you were very thorough

yay, thank you!! i'm glad it stood up to the test :)

@mddilley mddilley self-requested a review January 30, 2025 15:43
@mddilley mddilley removed the WIP Work in progress label Jan 30, 2025
@mddilley mddilley requested a review from chiaberry January 30, 2025 15:44
@mddilley
Copy link
Collaborator

i chatted with Tilly and moved a couple changes from this PR into cityofaustin/atd-data-tech#20772 so we can review and release this one today. I'll start reviewing shortly. 👀

snackbarState,
snackbarHandle,
handleSnackbar,
Copy link
Member

Choose a reason for hiding this comment

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

much better name! thank you

Copy link
Member

@chiaberry chiaberry left a comment

Choose a reason for hiding this comment

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

I ran through the test steps again and i like the updated messages to refresh the page. this is a slick upgrade imo!

Copy link
Collaborator

@mddilley mddilley left a comment

Choose a reason for hiding this comment

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

Looks great! I reviewed the latest commits, and I verified the feedback is working in the project summary and tables. Thanks for updating! 🙌 🚀 🙌

@roseeichelmann
Copy link
Contributor

I found one tiny itsy bitsy thing, when you delete a file while offline it will actually disappear and look like it was deleted despite giving the error. If you go back online and refresh the page it will be there though

Copy link
Contributor

@roseeichelmann roseeichelmann left a comment

Choose a reason for hiding this comment

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

this looks and works so well, it was such a huge undertaking and improvement! awesome to have these consistent feedback snackbars throughout the app. i found one weird behavior with the file deleting but other than that this is good to go!!

@mddilley
Copy link
Collaborator

@tillyw @chiaberry Heads up that I resolved a small conflict with main in here since y'all both made updates in ProjectTeamTable. it was a small change but wanted to let y'all know.

@roseeichelmann Thanks for finding that bug! Maybe there is a state update that happens before the mutation fails. I'll write up an issue! 📝 🙏

@mddilley mddilley merged commit b6e15a7 into main Jan 30, 2025
5 checks passed
@mddilley mddilley deleted the 19655_add_error_snackbar_to_datagrid_tables branch January 30, 2025 18:26
@tillyw
Copy link
Contributor Author

tillyw commented Jan 30, 2025

@tillyw @chiaberry Heads up that I resolved a small conflict with main in here since y'all both made updates in ProjectTeamTable. it was a small change but wanted to let y'all know.

@roseeichelmann Thanks for finding that bug! Maybe there is a state update that happens before the mutation fails. I'll write up an issue! 📝 🙏

thanks @mddilley for resolving that conflict! @roseeichelmann thanks for catching that! i noticed that behavior as well, and i think it would be worth addressing in a follow-up issue. thanks mike for making an issue for that as well!

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.

Add error snackbar to all DataGridPro tables
4 participants