Open Keshav-0907 opened 4 months ago
We already have support for auto saving drafts for our <Form component, I think converting this basic html form to our higher order <Form component should resolve this issue alongside.
cc: @rithviknishad
@Ashesh3 I think @Keshav-0907 meant more like a "Confirm Navigate Away" popup to prevent accidental navigations. Yes, we can always enable form restorations too on top of this.
@Ashesh3 I think @Keshav-0907 meant more like a "Confirm Navigate Away" popup to prevent accidental navigations. Yes, we can always enable form restorations too on top of this.
![]()
Yep, I got that, but since we don't have it anywhere else, even for the more imp and longer forms like consultation, patient etc. Instead of adding this popup for all existing long forms, I feel we should just upgrade this form to support drafts, that serves the same purpose to get users back their data in case they navigate away unintentionally. Just my thoughts, open to discussions!
This drafts solution also aligns with the required solution mentioned in the issue:
all updated data is lost. .... To mitigate the risk of unintentional data loss, ....
I agree with @Ashesh3
@nihal467 / @gigincg / @aparnacoronasafe
@Ashesh3 I think @Keshav-0907 meant more like a "Confirm Navigate Away" popup to prevent accidental navigations. Yes, we can always enable form restorations too on top of this.
![]()
@rithviknishad Sir, I actually meant to address the unintentional data loss concern by adding a 'Discard Changes' confirmation modal. However, following @Ashesh3's suggestion, I think upgrading the form for draft support can be a better approach.
I want to work on this issue. Can you please assign this to me?
@Ashesh3 I think @Keshav-0907 meant more like a "Confirm Navigate Away" popup to prevent accidental navigations. Yes, we can always enable form restorations too on top of this.
![]()
@rithviknishad Sir, I actually meant to address the unintentional data loss concern by adding a 'Discard Changes' confirmation modal. However, following @Ashesh3's suggestion, I think upgrading the form for draft support can be a better approach.
I want to work on this issue. Can you please assign this to me?
Hey, remember that our higher order <Form component already has drafts support, you just need to convert the shifting form to use that higher order <Form component. basically to convert basic html
Hi, @gigincg, @nihal467, @khavinshankar, @mathew-alex, @aparnacoronasafe, This issue has been automatically marked as stale because it has not had any recent activity.
@Keshav-0907 are you still working on this issue? If not I would like to work on this
@rithviknishad it seems like @Keshav-0907 is inactive can you assign me this issue
Hi, @gigincg, @nihal467, @khavinshankar, @mathew-alex, @aparnacoronasafe, This issue has been automatically marked as stale because it has not had any recent activity.
I am actually slightly busy in doing other issues [p2] so as of now I will unassign myself
Is your feature request related to a problem? Please describe. Currently, when a user is updating a form with different fields and accidentally navigates away without saving, all updated data is lost.
Describe the solution you'd like To mitigate the risk of unintentional data loss, we can implement a 'Discard Changes' modal that would serve as a confirmation step before discarding any modifications.
Additional context ( Video : No confirmation model when form is updated and user navigates away )
https://github.com/coronasafe/care_fe/assets/91189139/17b71990-37f1-444c-9f06-05c488d3c235