From e711668556ab5230af7af611c941f59014d27a1b Mon Sep 17 00:00:00 2001 From: Brian Hinton Date: Wed, 16 Jun 2021 17:19:23 -0400 Subject: [PATCH] Improvement/accessibility blog example (#475) * improvements: updated heading tag order, removed repeat alt values, added aria-labels * chore: added changeset --- .changeset/odd-pianos-argue.md | 5 +++++ examples/blog/src/components/MainHead.astro | 4 ++-- examples/blog/src/components/Nav.astro | 3 ++- examples/blog/src/components/Pagination.astro | 4 ++-- examples/blog/src/components/PostPreview.astro | 6 +++--- examples/blog/src/layouts/post.astro | 6 +++--- examples/blog/src/pages/$author.astro | 6 +++--- examples/blog/src/pages/$posts.astro | 2 +- examples/blog/src/pages/about.astro | 6 ++++-- 9 files changed, 25 insertions(+), 17 deletions(-) create mode 100644 .changeset/odd-pianos-argue.md diff --git a/.changeset/odd-pianos-argue.md b/.changeset/odd-pianos-argue.md new file mode 100644 index 000000000..c359ae911 --- /dev/null +++ b/.changeset/odd-pianos-argue.md @@ -0,0 +1,5 @@ +--- +'@astrojs/example-blog': patch +--- + +Improved accessibility of the example blog diff --git a/examples/blog/src/components/MainHead.astro b/examples/blog/src/components/MainHead.astro index 86f750ddc..dfc47fc01 100644 --- a/examples/blog/src/components/MainHead.astro +++ b/examples/blog/src/components/MainHead.astro @@ -23,8 +23,8 @@ export let canonicalURL: string | undefined; -{next && } -{prev && } +{next && } +{prev && } diff --git a/examples/blog/src/components/Nav.astro b/examples/blog/src/components/Nav.astro index 5949adb0d..5c435b737 100644 --- a/examples/blog/src/components/Nav.astro +++ b/examples/blog/src/components/Nav.astro @@ -51,9 +51,10 @@ a { + \ No newline at end of file diff --git a/examples/blog/src/components/Pagination.astro b/examples/blog/src/components/Pagination.astro index 7b01e59b5..0294e1707 100644 --- a/examples/blog/src/components/Pagination.astro +++ b/examples/blog/src/components/Pagination.astro @@ -34,7 +34,7 @@ export let nextUrl: string;
diff --git a/examples/blog/src/components/PostPreview.astro b/examples/blog/src/components/PostPreview.astro index 59c54e8fa..d02a23fe6 100644 --- a/examples/blog/src/components/PostPreview.astro +++ b/examples/blog/src/components/PostPreview.astro @@ -33,7 +33,7 @@ function formatDate(date) { margin-left: 1em; } -h1 { +h2 { font-weight: 700; font-size: 2.75em; line-height: 1; @@ -52,12 +52,12 @@ time {
-

{post.title}

+

{post.title}

{author.name}

{post.description} - Read + Read

diff --git a/examples/blog/src/layouts/post.astro b/examples/blog/src/layouts/post.astro index 5149528a0..3379bd2dc 100644 --- a/examples/blog/src/layouts/post.astro +++ b/examples/blog/src/layouts/post.astro @@ -62,9 +62,9 @@ import authorData from '../data/authors.json';