[x] I’ve searched for any related issues and avoided creating a duplicate issue.
What happened
The existing guidance for the Back to top (BTT) component says that it should not be used on pages with dynamic content. This excludes quite a few pages (all Drupal pages), even when a BTT component would be helpful on those pages.
We have some examples of BTT being used on pages that have dynamic content:
This code and guidance likely predates most of us. But it's worth noting that our usage of the component is inconsistent, and it doesn't make sense to leave the decision of whether to include BTT to the individual page or the teams. We propose:
The Back to top component should appear dynamically (based on the page height).
If the BTT component can calculate when it should appear based on page height, we can then add the component to basic page templates, and remove the decision-making on when to add it from the teams.
Bug Report
What happened
The existing guidance for the Back to top (BTT) component says that it should not be used on pages with dynamic content. This excludes quite a few pages (all Drupal pages), even when a BTT component would be helpful on those pages.
We have some examples of BTT being used on pages that have dynamic content:
This code and guidance likely predates most of us. But it's worth noting that our usage of the component is inconsistent, and it doesn't make sense to leave the decision of whether to include BTT to the individual page or the teams. We propose:
The Back to top component should appear dynamically (based on the page height).
If the BTT component can calculate when it should appear based on page height, we can then add the component to basic page templates, and remove the decision-making on when to add it from the teams.
Slack thread for context: https://dsva.slack.com/archives/C01DBGX4P45/p1714680374615469
What I expected to happen
I expect the BTT component to appear on every page of VA.gov where scrolling is needed.
Urgency
How urgent is this request? Please select the appropriate option below and/or provide details
Details