Skip to content

Fix: accessible title in cloud snippet search results#343

Merged
sheabunge merged 2 commits intocore-betafrom
a11y-cloud-snippet-title
Apr 15, 2026
Merged

Fix: accessible title in cloud snippet search results#343
sheabunge merged 2 commits intocore-betafrom
a11y-cloud-snippet-title

Conversation

@rami-elementor
Copy link
Copy Markdown
Contributor

Replace <a href="#"> with <button> to improve semantics. Links are used only for linking to other pages. In this case, clicking the title open a modal. So, it's not a link.

The change also makes keyboard navigation more intuitive. Before you could open only with ENTER, after the change you can use either ENTER or SPACE.

Before:

before

After:

after

color: #2271b1;
cursor: pointer;
text-align: start;
text-decoration: underline;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

what do you say about, no underline by default, but only when hover or focus?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Underlining links is a primary accessibility best practice because it ensures that color is not the only way to identify interactive text.

While the Web Content Accessibility Guidelines (WCAG) do not strictly mandate underlines, they do require that links be visually distinguishable from surrounding text.

I prefer to keep the underline on the link.

@sheabunge sheabunge merged commit b4b892f into core-beta Apr 15, 2026
8 checks passed
@sheabunge sheabunge deleted the a11y-cloud-snippet-title branch April 15, 2026 06:21
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.

4 participants