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

6272 move status change to footer #6276

Open
wants to merge 6 commits into
base: develop
Choose a base branch
from

Conversation

lache-melvin
Copy link
Contributor

Fixes #6272

👩🏻‍💻 What does this PR do?

Make status change/delete workflows of encounters match those of other features.

Removes status change and delete from toolbar.

Adds delete button to side panel, and status change to footer:
Screenshot 2025-01-24 at 3 28 40 PM

Pre-requisite to hooking into status change logic within vax card.

💌 Any notes for the reviewer?

🧪 Testing

  • Create an encounter
  • On detail view - there is no status dropdown or delete button in the toolbar
  • Footer has new split button, says Mark as Visited by default
  • Clicking the button changes the status
    • Status breadcrumb updates to show visited
    • You get the green success toast that it saved successfully
    • Status button for visited is now disabled
    • You can still change the button, to mark as Pending or Cancelled
  • Click More to open side panel
  • There is now a delete button
  • Clicking delete opens a confirmation modal - confirming deletes the encounter and redirects you to the list view

📃 Documentation

  • Part of an epic: documentation will be completed for the feature as a whole
  • No documentation required: no user facing changes or a bug fix which isn't a change in behaviour
  • These areas should be updated or checked:
    1.
    2.

@github-actions github-actions bot added this to the v2.6.0 milestone Jan 24, 2025
Copy link

Bundle size difference

Comparing this PR to main

Old size New size Diff
5.21 MB 5.21 MB 548 B (0.01%)

@@ -46,7 +46,7 @@ export const SplitButton = <T,>({
<ButtonGroup color={color} variant="outlined" aria-label={ariaLabel}>
<ButtonWithIcon
color={color}
disabled={isDisabled}
disabled={isDisabled || selectedOption.isDisabled}
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hopefully we are okay with the change?

@@ -81,11 +81,15 @@ const useSaveWithStatus = (
};
};

const useSaveWithStatusChangeModal = (
const useSaveWithStatusChange = (
Copy link
Contributor Author

Choose a reason for hiding this comment

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

just renaming as I'm now using both in and outside of the modal

@@ -133,7 +142,7 @@ export const Footer: FC<FooterProps> = ({
gap={2}
>
<Typography sx={{ fontSize: 18, fontWeight: 700 }}>
Document Edit History
{t('label.document-edit-history')}
Copy link
Contributor Author

Choose a reason for hiding this comment

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

side quest - missed translation from ages ago!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Move encounter status from toolbar to footer
1 participant