Skip to content

Commit ab8c914

Browse files
Merge pull request #391 from CBID2/adding-new-section
feat: add Touch Target Minimum sections to Links and Button pages
2 parents e764585 + 17ab6fd commit ab8c914

File tree

3 files changed

+18
-0
lines changed

3 files changed

+18
-0
lines changed

components/ContentTemplates/ButtonsTemplate.tsx

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -467,6 +467,13 @@ export const ButtonsTemplate = () => {
467467
</li>
468468
</ul>
469469
</TemplateSection>
470+
<TemplateSection sectionName="touchTargetMinimum" title="Touch Target Minimum">
471+
<p>
472+
When it comes to creating accessible buttons for your websites and applications, it's important that they
473+
are easy to activate. To achieve this goal, WCAG suggests to avoid putting the buttons together. Consider make their size at least 24 by 24 CSS pixels. In doing so, users, especially those who suffer from mobility impairments like hand tremors or are amputees, have an easier time clicking on them.
474+
</p>
475+
476+
</TemplateSection>
470477
<TemplateSection sectionName="otherResources" title="Other Resources">
471478
<ul className="list">
472479
<li>

components/ContentTemplates/LinksTemplate.tsx

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -340,6 +340,15 @@ other places on the web */`}
340340
</li>
341341
</ul>
342342
</TemplateSection>
343+
<TemplateSection
344+
sectionName="touchTargetMinimum"
345+
title="Touch Target Minimum">
346+
<p>
347+
When it comes to creating accessible links, it's important that they
348+
are easy to activate. To do this, WCAG recommends spacing the link's text so that users can understand its context. Doing this would also make it
349+
easier for users who have motor dexterity issues to read them.
350+
</p>
351+
</TemplateSection>
343352
<PageUpdated date="5th January 2024" />
344353
</>
345354
)

data/pageNavigationLists.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ export const buttonPageNavigation: IPageNavigationItem[] = [
3232
{ linkName: "Button States", href: "#buttonStates" },
3333
{ linkName: "Button or Link?", href: "#buttonOrLink" },
3434
{ linkName: "WCAG Criteria", href: "#WCAGCriteria" },
35+
{ linkName: "Touch Target Minimum", href: "#touchTargetMinimum" },}
3536
{ linkName: "Other Resources", href: "#otherResources" },
3637
]
3738

@@ -41,6 +42,7 @@ export const linkPageNavigation: IPageNavigationItem[] = [
4142
{ linkName: "Link State and Style", href: "#linkStates" },
4243
{ linkName: "Image and Icon Links", href: "#linkImage" },
4344
{ linkName: "WCAG Criteria", href: "#WCAGCriteria" },
45+
{ linkName: "Touch Target Minimum", href: "#touchTargetMinimum" },
4446
{ linkName: "Other Resources", href: "#otherResources" },
4547
]
4648

0 commit comments

Comments
 (0)