GIVEN a user wants to change the details of an event
WHEN the user clicks the 'edit' button beside an event
THEN the row of the event should then contain input fields populated with the current event information
AND there should be a button to save the new details
AND there should be a cancel button that turns the row back to normal and does not save any changes that were in the input fields
Development
Create edit button with event listener
Make the text editable using isEditable class or a pre-populated text entry field
Create a save button that runs a function that updates the object in firebase and prints the updated object to the row
Create a cancel button that doesn't save any changes and reverts to the original text of the event
Neither the edit nor the delete button should be shown while the event is in edit mode
User Story
As a user, I should be able to edit an event.
Acceptance Criteria
GIVEN a user wants to change the details of an event WHEN the user clicks the 'edit' button beside an event THEN the row of the event should then contain input fields populated with the current event information AND there should be a button to save the new details AND there should be a cancel button that turns the row back to normal and does not save any changes that were in the input fields
Development