-
Notifications
You must be signed in to change notification settings - Fork 433
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
Add suggestion chips instead of autofilling diagnosis #8369
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
✅ Deploy Preview for care-egov-staging ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
CARE Run #3173
Run Properties:
|
Project |
CARE
|
Branch Review |
suggestion-chips
|
Run status |
Passed #3173
|
Run duration | 03m 01s |
Commit |
61691b3b33: Add suggestion chips instead of autofilling diagnosis
|
Committer | Shivank Kacker |
View all properties for this run ↗︎ |
Test results | |
---|---|
Failures |
0
|
Flaky |
0
|
Pending |
0
|
Skipped |
0
|
Passing |
126
|
View all changes introduced in this branch ↗︎ |
👋 Hi, @shivankacker, This message is automatically generated by prince-chrismc/label-merge-conflicts-action so don't hesitate to report issues/improvements there. |
|
@nihal467 attached screenshots to the PR. It is ready to be tested. |
CC: @gigincg |
✅ Deploy Preview for care-egov-staging ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
@nihal467 updated, the buttons should be clickable and autofill the diagnosis dropdown |
@shivankacker are these expected behaviors? cc: @gigincg |
…suggestion-chips
@nihal467 The bug with chip click has been fixed. I did not hide already entered diagnoses as the Diagnosis dropdown also does not hide it, and it will throw the "Diagnosis already entered error" as well. Anyways I have hid it with the latest commit. But this might be a little confusing for a user who previously marked the diagnosis as entered in error and wishes to add it again. (Just an edge case) |
@shivankacker the edge case seems valid, we shouldn't be hiding already-added badges for now, if user request for the same, we can do that |
@nihal467 understood, reverted the change |
LGTM |
@@ -36,6 +38,10 @@ export default function AddICD11Diagnosis(props: AddICD11DiagnosisProps) { | |||
} | |||
}, [res?.status]); | |||
|
|||
useEffect(() => props.prefill && setSelected(props.prefill), [props.prefill]); | |||
|
|||
useEffect(() => props.setPrefill?.(undefined), [selected]); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@shivankacker can we remove the second use effect and use a util function like handleSelection which updates both selected and prefill state
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Made some changes, is that what you meant?
@shivankacker Your efforts have helped advance digital healthcare and TeleICU systems. 🚀 Thank you for taking the time out to make CARE better. We hope you continue to innovate and contribute; your impact is immense! 🙌 |
Fixes #8342
@coronasafe/care-fe-code-reviewers @coronasafe/code-reviewers
Merge Checklist