Skip to content

Commit b38cc78

Browse files
authored
Fix ARIA label for the logo pointing to the pub landing page. (#8482)
1 parent 1e65b38 commit b38cc78

File tree

80 files changed

+86
-80
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

80 files changed

+86
-80
lines changed

app/lib/dartdoc/dartdoc_page.dart

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -153,8 +153,11 @@ extension DartDocPageRender on DartDocPage {
153153
href: '/',
154154
classes: ['hidden-xs'],
155155
child: d.img(
156-
// TODO: Move this into a class
157-
attributes: {'style': 'height: 30px; margin-right: 1em;'},
156+
attributes: {
157+
'aria-label': 'Go to the landing page of pub.dev',
158+
// TODO: Move this into a class
159+
'style': 'height: 30px; margin-right: 1em;',
160+
},
158161
image: d.Image.decorative(
159162
src: staticUrls.dartLogoSvg,
160163
height: 30,

app/lib/frontend/templates/views/shared/site_header.dart

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,9 @@ d.Node siteHeaderNode({
2424
d.a(
2525
classes: ['logo'],
2626
href: '/',
27+
attributes: {
28+
'aria-label': 'Go to the landing page of pub.dev',
29+
},
2730
child: d.img(
2831
classes: ['site-logo'],
2932
image: d.Image.decorative(

app/test/frontend/golden/authorized_page.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
<noscript>&lt;iframe src="https://www.googletagmanager.com/ns.html?id=GTM-MX6DBN9" height="0" width="0" style="display:none;visibility:hidden">&lt;/iframe></noscript>
3636
<div class="site-header">
3737
<button class="hamburger" aria-label="menu toggle"></button>
38-
<a class="logo" href="/">
38+
<a class="logo" href="/" aria-label="Go to the landing page of pub.dev">
3939
<img class="site-logo" src="/static/hash-%%etag%%/img/pub-dev-logo.svg" alt="" width="140" height="30" role="presentation"/>
4040
</a>
4141
<div class="site-header-space"></div>

app/test/frontend/golden/consent_page.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
<noscript>&lt;iframe src="https://www.googletagmanager.com/ns.html?id=GTM-MX6DBN9" height="0" width="0" style="display:none;visibility:hidden">&lt;/iframe></noscript>
3636
<div class="site-header">
3737
<button class="hamburger" aria-label="menu toggle"></button>
38-
<a class="logo" href="/">
38+
<a class="logo" href="/" aria-label="Go to the landing page of pub.dev">
3939
<img class="site-logo" src="/static/hash-%%etag%%/img/pub-dev-logo.svg" alt="" width="140" height="30" role="presentation"/>
4040
</a>
4141
<div class="site-header-space"></div>

app/test/frontend/golden/create_publisher_page.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
<noscript>&lt;iframe src="https://www.googletagmanager.com/ns.html?id=GTM-MX6DBN9" height="0" width="0" style="display:none;visibility:hidden">&lt;/iframe></noscript>
3535
<div class="site-header">
3636
<button class="hamburger" aria-label="menu toggle"></button>
37-
<a class="logo" href="/">
37+
<a class="logo" href="/" aria-label="Go to the landing page of pub.dev">
3838
<img class="site-logo" src="/static/hash-%%etag%%/img/pub-dev-logo.svg" alt="" width="140" height="30" role="presentation"/>
3939
</a>
4040
<div class="site-header-space"></div>

app/test/frontend/golden/error_page.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
<noscript>&lt;iframe src="https://www.googletagmanager.com/ns.html?id=GTM-MX6DBN9" height="0" width="0" style="display:none;visibility:hidden">&lt;/iframe></noscript>
3535
<div class="site-header">
3636
<button class="hamburger" aria-label="menu toggle"></button>
37-
<a class="logo" href="/">
37+
<a class="logo" href="/" aria-label="Go to the landing page of pub.dev">
3838
<img class="site-logo" src="/static/hash-%%etag%%/img/pub-dev-logo.svg" alt="" width="140" height="30" role="presentation"/>
3939
</a>
4040
<div class="site-header-space"></div>

app/test/frontend/golden/help_page.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
<noscript>&lt;iframe src="https://www.googletagmanager.com/ns.html?id=GTM-MX6DBN9" height="0" width="0" style="display:none;visibility:hidden">&lt;/iframe></noscript>
3636
<div class="site-header">
3737
<button class="hamburger" aria-label="menu toggle"></button>
38-
<a class="logo" href="/">
38+
<a class="logo" href="/" aria-label="Go to the landing page of pub.dev">
3939
<img class="site-logo" src="/static/hash-%%etag%%/img/pub-dev-logo.svg" alt="" width="140" height="30" role="presentation"/>
4040
</a>
4141
<div class="site-header-space"></div>

app/test/frontend/golden/my_activity_log_page.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
<noscript>&lt;iframe src="https://www.googletagmanager.com/ns.html?id=GTM-MX6DBN9" height="0" width="0" style="display:none;visibility:hidden">&lt;/iframe></noscript>
3636
<div class="site-header">
3737
<button class="hamburger" aria-label="menu toggle"></button>
38-
<a class="logo" href="/">
38+
<a class="logo" href="/" aria-label="Go to the landing page of pub.dev">
3939
<img class="site-logo" src="/static/hash-%%etag%%/img/pub-dev-logo.svg" alt="" width="140" height="30" role="presentation"/>
4040
</a>
4141
<div class="site-header-space"></div>

app/test/frontend/golden/my_liked_packages.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636
<noscript>&lt;iframe src="https://www.googletagmanager.com/ns.html?id=GTM-MX6DBN9" height="0" width="0" style="display:none;visibility:hidden">&lt;/iframe></noscript>
3737
<div class="site-header">
3838
<button class="hamburger" aria-label="menu toggle"></button>
39-
<a class="logo" href="/">
39+
<a class="logo" href="/" aria-label="Go to the landing page of pub.dev">
4040
<img class="site-logo" src="/static/hash-%%etag%%/img/pub-dev-logo.svg" alt="" width="140" height="30" role="presentation"/>
4141
</a>
4242
<div class="site-header-space"></div>

app/test/frontend/golden/my_packages.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
<noscript>&lt;iframe src="https://www.googletagmanager.com/ns.html?id=GTM-MX6DBN9" height="0" width="0" style="display:none;visibility:hidden">&lt;/iframe></noscript>
3636
<div class="site-header">
3737
<button class="hamburger" aria-label="menu toggle"></button>
38-
<a class="logo" href="/">
38+
<a class="logo" href="/" aria-label="Go to the landing page of pub.dev">
3939
<img class="site-logo" src="/static/hash-%%etag%%/img/pub-dev-logo.svg" alt="" width="140" height="30" role="presentation"/>
4040
</a>
4141
<div class="site-header-space"></div>

0 commit comments

Comments
 (0)