cody icon indicating copy to clipboard operation
cody copied to clipboard

Edit: Persist a users prompt until submitted or deleted

Open umpox opened this issue 1 year ago • 0 comments

What:

  • The Edit input can be hidden quite easily, this means a user could possibly lose their prompt that they have been writing.

How:

  • Once the input is dirty, save the prompt to local storage until it is either: removed from the input, or submitted.
  • This way, users are still able to access a partially written prompt even if they close the Edit input.
  • We should ensure that we properly save the prompt, including any contextItems in local storage. We can enrich the Edit input with these values using the initialValues object.

umpox avatar Mar 22 '24 15:03 umpox