Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make link text for components and patterns consistent #4278

Merged
merged 1 commit into from
Nov 8, 2024

Conversation

owenatgov
Copy link
Contributor

@owenatgov owenatgov commented Nov 5, 2024

What

Update the text of internal links to components and patterns with the following criteria:

  • Sentence case
  • Includes the word 'component' or 'pattern' in the link (see notes for details on where I haven't done this for every instance of pattern)

Why

This follows #4267 where we've been auditing our link text so that it can be clearly understood out of context by screen reader users who are navigating by links. From the audit, these links have the most clearly defined criteria to update so we're updating these now.

Notes

Component links are a lot easier to adjust compared to pattern links. Components and the way we refer to components are quite specific in that they're an individual 'classes' so it's quite easy to change eg: 'the footer' to 'the Footer component'. Patterns are more nebulous. Sometimes they're specific things eg: the Validation pattern but they're also 'pages', things to ask for, techniques or tasks.

That means the way we link to patterns are harder to update if we're trying to be strict about criteria for internal links. Eg: it's difficult to update link text like 'ask for national insurance numbers' in the context 'read more about how to ask for national insurance numbers'. Following discussions with @calvin-lau-sig7 and the website accessibility squad, we've establshed some slightly looser criteria for patterns. Notably:

  • The technique on it's own is usually fine eg: 'asking users for addresses'
  • The suffix 'page' or 'pages' is normally fine, depending on the page being linked to
  • When the above exampels aren't clear or could be misconstrude, creative use of reference to the thing being part of a user's service should be deployed eg: 'Cookie page' becomes 'your Cookie page' or 'Cookie page in your service'

Copy link

netlify bot commented Nov 5, 2024

You can preview this change here:

Name Link
🔨 Latest commit 590b1ab
🔍 Latest deploy log https://app.netlify.com/sites/govuk-design-system-preview/deploys/672e40b2f5a99800081bec2f
😎 Deploy Preview https://deploy-preview-4278--govuk-design-system-preview.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@owenatgov owenatgov force-pushed the component-and-pattern-link-text branch 4 times, most recently from c0d6c36 to 0066be7 Compare November 5, 2024 15:07
@owenatgov owenatgov force-pushed the component-and-pattern-link-text branch from 0066be7 to c563888 Compare November 5, 2024 16:44
@owenatgov owenatgov force-pushed the component-and-pattern-link-text branch 2 times, most recently from 2787d6a to 48fdc59 Compare November 8, 2024 09:55
Copy link
Contributor

@calvin-lau-sig7 calvin-lau-sig7 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay, all through it, it's looking good!

I had a look at a few pages in preview, and the appearance of these as links seems to make up for some of the inconsistencies we're introducing between link text and body text. (Like the capitalisations [which we'll fix eventually] and extra words).

@owenatgov owenatgov merged commit 9b26345 into main Nov 8, 2024
15 checks passed
@owenatgov owenatgov deleted the component-and-pattern-link-text branch November 8, 2024 16:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants