pages-core icon indicating copy to clipboard operation
pages-core copied to clipboard

Create a reusable API response structure for the UI to manage alerts

Open apburnes opened this issue 9 months ago • 0 comments

To standardize messages from the API to the UI, we need a reusable API response structure the UI can consume to show alert modals, toasts, etc when UI components are interacting with the UI

Notes

  • This could be used to warn users of a destructive action or possible conflicts in the database.

Acceptance Criteria

  • [ ] Define a structure for alerts to be consumed
  • [ ] Create a UI hook and component that can open and show the alert to the users
  • [ ] Place the alert component in the root of the app structure or layout so it is consistent and predictable across all pages
  • [ ] Add alert hook to async api calls to intercept any responses that fit the alert structure to open the alert component

apburnes avatar Feb 20 '25 22:02 apburnes