Problem
When submitting especially long testimonies, users can run into errors when trying to use the mailto link to send the legislator email with their mail client. Different mail clients have different rules around how long the body of a mailto link can be. Trying to send an email for a very long testimony can result in a 400 HTTP error once they've left MAPLE if they surpass this limit, which is an annoying user experience.
e.g. The limit is ~4,096 characters for Gmail - this count includes the subject, recipients, and body of the intended email (after URI encoding). We first ran into this bug when a user attempted to send an ~8,000 character email. For reference, the MAPLE testimony length limit is ~10,000 characters (body only, before URI encoding).
We don't want to modify the MAPLE testimony length limit (because that would limit the expressiveness of the testimony on the MAPLE site itself), and we intentionally are not sending these emails ourselves on our users' behalfs.
To remedy this problem, we should add an alternate user experience for users when publishing testimony that we believe may go over the size limit for mail clients. We should warn users that the mailto link may not work and let them know that they may have to copy/paste manually into their email client.
Success Criteria
Additional Links
- Design: ???
- It may be worth thinking on the design here - even if only to get a rough idea of the error states. (e.g. do we want to disable the "Send Email" button? When it's clicked, should we instead open a modal with instructions to copy/paste into your email client? Can we populate some of the data if we take that approach (e.g. maybe just subject/recipients and make users copy/paste the body?)?
Problem
When submitting especially long testimonies, users can run into errors when trying to use the
mailtolink to send the legislator email with their mail client. Different mail clients have different rules around how long the body of amailtolink can be. Trying to send an email for a very long testimony can result in a 400 HTTP error once they've left MAPLE if they surpass this limit, which is an annoying user experience.e.g. The limit is ~4,096 characters for Gmail - this count includes the subject, recipients, and body of the intended email (after URI encoding). We first ran into this bug when a user attempted to send an ~8,000 character email. For reference, the MAPLE testimony length limit is ~10,000 characters (body only, before URI encoding).
We don't want to modify the MAPLE testimony length limit (because that would limit the expressiveness of the testimony on the MAPLE site itself), and we intentionally are not sending these emails ourselves on our users' behalfs.
To remedy this problem, we should add an alternate user experience for users when publishing testimony that we believe may go over the size limit for mail clients. We should warn users that the
mailtolink may not work and let them know that they may have to copy/paste manually into their email client.Success Criteria
Additional Links