cds-snc / platform-forms-client

NextJS application that serves the public-facing website for Forms
https://forms-staging.cdssandbox.xyz/
MIT License
34 stars 13 forks source link

A form is closed with information on what an end-user should do next. #686

Closed srtalbot closed 1 month ago

srtalbot commented 2 years ago

User story: As a program administrator I need to let people know that a form is no longer active with error messaging So that when they navigate to the form they have the context they need to know it is closed

Story context Example of the issue experienced by the Red Pine team, who were using forms to screen research participants.

Finding from testing of the response UI

This need mainly affects forms where the entry path (that is, how people find the form) is an email or basically isn't a link to the form that we can take down.

Even in the case when an external page links to the form and we can remove it, it may be the case that an end-user has saved the form URL and will return to the form to complete it. The likelihood of this scenario increases as we start to allow saving form data (a known feature that we'll get to at some point)

The error message needs some form-specific content on it

Acceptance criteria

srtalbot commented 2 years ago

Could take about a week and a half to complete the card.

craigzour commented 2 years ago

Do we think we will need such feature (marking a form as closed) in the future? Thinking this would probably be the best approach if we want to do something clean. If not then we can think of a different solution but it will probably end up being a "hacky" one. Something like adding a property to the JSON template to explicitly say that this form is not available.

jeberhardt commented 2 years ago

This could be handled in a similar way that the "endPage" content is handled. If the content is there, then the form is closed, and that content could be displayed.

samsadasivan commented 1 year ago

Form is closed

This is the page that will be displayed when a user deletes a form. This page would appear when someone archives or "unpublishes" their form in the future.

This screen exits under the "Delete a published form" flow ![image.png]image.png(https://images.zenhubusercontent.com/611408c194b5030c28d18261/5ac22278-145c-4998-89df-404c664f21d9)

patheard commented 2 months ago

a related incident to this: https://docs.google.com/document/d/1YKOaiCrfbVefCPzcZ1uR6e2eeQGothgufl-fUoT8Idg

One of the action items that could fit in is around how we could notify a user that the form they currently have loaded in their browser can no longer be submitted:

Display “Closed form” message when a lookup for a form ID is retrieved and the form is marked for deletion.

This could also be a scheduled check that occurs when a form is loaded in a browser to alert the user sooner. Use Google Analytics to determine the length of time people will sit on a form.

We will need research to determine messaging to the user (perhaps falls into the form owner’s responsibility bucket and the custom Close Form message should be used).

connorscarolyns commented 1 month ago

Designs exist for this, they should be reviewed against the new context: https://www.figma.com/design/SBkP2G0bV4jwoghIvlZ1zg/v2.-Download-and-confirm-responses?node-id=3131-70222&t=ON16jdF7baAhwQfE-4

srtalbot commented 1 month ago

Feedback from a client:

"I think it would be really helpful if a notification was sent when a form is closed – this would help avoid accidental closure."

timarney commented 1 month ago

@samsadasivan is the figma above the one to use for this?

timarney commented 1 month ago

@thiessenp-cds

Please break out a todo list on the dev side i.e.

This will make it easier to discuss progress in stand-up but give us a better sense of how long the feature will take.

samsadasivan commented 1 month ago

PROPOSAL: Very similar to the designs @connorscarolyns already proposed. I added some pieces for the extra scenarios considered around notifications and banners.

Notes:

image.png
samsadasivan commented 1 month ago
image.png
samsadasivan commented 1 month ago

TRANSLATION VIEW

samsadasivan commented 1 month ago

Form closed automatically via set date > user re-opens via toggle

image.png
samsadasivan commented 1 month ago

Content design, cc: @anikbrazeau

image.png
timarney commented 1 month ago

Going to propose we tackle this in a few iterations:

Update 1 - Adding the custom description message (using existing toggle) -> ship

Update 2 - Add email functionality to notify form owners a form has been closed (using existing toggle) -> ship

Update 3 - Custom closing date + the rest of the functionality -> ship


cc: @Abi-Nada @srtalbot @samsadasivan @thiessenp-cds thoughts?

samsadasivan commented 1 month ago

Love it - thank you @timarney !

samsadasivan commented 1 month ago

One outlier - I am going to look into this morning: Banner for the form output that a form will be closing. Just checking with DS

anikbrazeau commented 1 month ago

Some content considerations

cc: @samsadasivan

samsadasivan commented 1 month ago

For output: We will use GCDS "Notice" Information component image.png

timarney commented 1 month ago

@thiessenp-cds

I built out a POC for update 1 https://github.com/cds-snc/platform-forms-client/pull/4389 as that's the most straight forward one.

anikbrazeau commented 1 month ago

Figma link: https://www.figma.com/design/0mKC8oMGAtAkzgMsfrpobH/Closing-a-form?node-id=6218-2241&node-type=canvas&t=VNcJxMrjnj8gINNV-0

timarney commented 1 month ago

Update 1 - Adding the custom description message (using existing toggle) -> ship

https://github.com/cds-snc/platform-forms-client/pull/4389

Preview link

https://xbtvlc4cs27e4zxs6dflkpgwru0hdkpk.lambda-url.ca-central-1.on.aws

thiessenp-cds commented 1 month ago

update 2 - Add email functionality to notify form owners a form has been closed (using existing toggle)

thiessenp-cds commented 1 month ago

update 3 - form open/closed dates and times

thiessenp-cds commented 1 month ago

update 4 - form open/closed Notice

thiessenp-cds commented 1 month ago

After a quick meeting sync, we prioritized the order to: 3, 4, 2 (where 3 and 4 would ship together)