Skip to content

Commit

Permalink
Improvements based on accessibility feedback (#20)
Browse files Browse the repository at this point in the history
  • Loading branch information
richtabor authored Nov 22, 2024
1 parent 7750880 commit c0bddd8
Show file tree
Hide file tree
Showing 7 changed files with 59 additions and 20 deletions.
2 changes: 1 addition & 1 deletion parts/header.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<!-- wp:group {"metadata":{"name":"Left"},"style":{"spacing":{"blockGap":"var:preset|spacing|20"}},"layout":{"type":"flex","flexWrap":"nowrap"}} -->
<div class="wp-block-group">
<!-- wp:site-logo {"width":60,"shouldSyncIcon":false,"className":"is-style-rounded"} /-->
<!-- wp:site-title /-->
<!-- wp:site-title {"level":0,"className":"is-style-text-title"} /-->
</div>
<!-- /wp:group -->
<!-- wp:group {"metadata":{"name":"Right"},"style":{"spacing":{"blockGap":"var:preset|spacing|20"}},"layout":{"type":"flex","flexWrap":"nowrap"}} -->
Expand Down
10 changes: 5 additions & 5 deletions patterns/posts-list.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,15 @@
<div style="height:var(--wp--preset--spacing--30)" aria-hidden="true" class="wp-block-spacer"></div>
<!-- /wp:spacer -->

<!-- wp:paragraph {"className":"is-style-text-subtitle"} -->
<p class="is-style-text-subtitle"><?php echo esc_html__( 'You may also enjoy…', 'kanso' ); ?></p>
<!-- /wp:paragraph -->
<!-- wp:heading {"className":"is-style-text-subtitle"} -->
<h2 class="wp-block-heading is-style-text-subtitle"><?php echo esc_html__( 'You may also enjoy…', 'kanso' ); ?></h2>
<!-- /wp:heading -->

<!-- wp:query {"queryId":0,"query":{"perPage":"20","pages":0,"offset":0,"postType":"post","order":"desc","orderBy":"date","author":"","search":"","exclude":[],"sticky":"","inherit":true}} -->
<div class="wp-block-query"><!-- wp:post-template {"style":{"spacing":{"blockGap":"var:preset|spacing|10"}}} -->
<!-- wp:group {"style":{"spacing":{"padding":{"top":"2px","bottom":"2px","left":"0px","right":"0px"}}},"layout":{"type":"flex","flexWrap":"nowrap","justifyContent":"space-between"}} -->
<div class="wp-block-group" style="padding-top:2px;padding-right:0px;padding-bottom:2px;padding-left:0px"><!-- wp:post-title {"isLink":true,"style":{"spacing":{"padding":{"top":"0px","bottom":"0px"}},"typography":{"lineHeight":"1.2"}},"className":"no-underline truncate","fontSize":"large"} /-->

<div class="wp-block-group" style="padding-top:2px;padding-right:0px;padding-bottom:2px;padding-left:0px">
<!-- wp:post-title {"level":3,"isLink":true,"className":"no-underline truncate","style":{"spacing":{"padding":{"top":"0px","bottom":"0px"}},"typography":{"lineHeight":"1.2"}},"fontSize":"large"} /-->
<!-- wp:post-date {"textAlign":"right","format":"M Y","style":{"typography":{"lineHeight":"1.2"}}} /--></div>
<!-- /wp:group -->
<!-- /wp:post-template --></div>
Expand Down
6 changes: 3 additions & 3 deletions style.css
Original file line number Diff line number Diff line change
Expand Up @@ -262,8 +262,8 @@ input:not([type=submit]):focus-visible {

/* Navigation block */
.wp-block-navigation .wp-block-navigation__submenu-container {
border-radius: var(--wp--preset--spacing--10);
padding: 12px 8px;
border-radius: var(--wp--preset--spacing--10);
padding: 12px 8px;
}

/* Dark mode toggle block */
Expand All @@ -273,7 +273,7 @@ input:not([type=submit]):focus-visible {
}

.wp-block-tabor-dark-mode-toggle__track:not(.has-background):hover {
background-color: var(--wp--preset--color--theme-4);
background-color: var(--wp--preset--color--theme-4);
color: var(--wp--preset--color--theme-6);
}

Expand Down
35 changes: 35 additions & 0 deletions templates/home.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
<!-- wp:template-part {"slug":"header"} /-->

<!-- wp:group {"tagName":"main","metadata":{"name":"Main"},"style":{"spacing":{"margin":{"top":"0","bottom":"0"},"padding":{"top":"var:preset|spacing|20","bottom":"var:preset|spacing|20"}}},"layout":{"type":"constrained","justifyContent":"center"}} -->
<main class="wp-block-group" style="margin-top:0;margin-bottom:0;padding-top:var(--wp--preset--spacing--20);padding-bottom:var(--wp--preset--spacing--20)"><!-- wp:group {"metadata":{"name":"Title"},"layout":{"type":"constrained"}} -->
<div class="wp-block-group"><!-- wp:heading {"level":1,"className":"is-style-text-title"} -->
<h1 class="wp-block-heading is-style-text-title">Hi, I'm Rich Tabor</h1>
<!-- /wp:heading -->

<!-- wp:site-tagline /--></div>
<!-- /wp:group -->

<!-- wp:group {"metadata":{"name":"Topics"},"layout":{"type":"default"}} -->
<div class="wp-block-group"><!-- wp:tag-cloud {"smallestFontSize":"12px","largestFontSize":"12px"} /--></div>
<!-- /wp:group -->

<!-- wp:spacer {"height":"var:preset|spacing|50"} -->
<div style="height:var(--wp--preset--spacing--50)" aria-hidden="true" class="wp-block-spacer"></div>
<!-- /wp:spacer -->

<!-- wp:query {"queryId":0,"query":{"perPage":1,"pages":0,"offset":0,"postType":"post","order":"desc","orderBy":"date","author":"","search":"","exclude":[],"sticky":"","inherit":true},"metadata":{"categories":["blog"]}} -->
<div class="wp-block-query"><!-- wp:post-template {"layout":{"type":"default","columnCount":1}} -->
<!-- wp:template-part {"slug":"post"} /-->
<!-- /wp:post-template -->

<!-- wp:query-pagination {"paginationArrow":"arrow","showLabel":false,"layout":{"type":"flex","flexWrap":"nowrap","orientation":"horizontal","justifyContent":"space-between"}} -->
<!-- wp:query-pagination-previous {"label":"Prev","fontSize":"x-large"} /-->

<!-- wp:query-pagination-numbers /-->

<!-- wp:query-pagination-next {"label":"Next","fontSize":"x-large"} /-->
<!-- /wp:query-pagination --></div>
<!-- /wp:query --></main>
<!-- /wp:group -->

<!-- wp:template-part {"slug":"footer","area":"footer"} /-->
9 changes: 4 additions & 5 deletions templates/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,10 @@

<!-- wp:group {"tagName":"main","metadata":{"name":"Main"},"style":{"spacing":{"margin":{"top":"0","bottom":"0"},"padding":{"top":"var:preset|spacing|20","bottom":"var:preset|spacing|20"}}},"layout":{"type":"constrained","justifyContent":"center"}} -->
<main class="wp-block-group" style="margin-top:0;margin-bottom:0;padding-top:var(--wp--preset--spacing--20);padding-bottom:var(--wp--preset--spacing--20)"><!-- wp:group {"metadata":{"name":"Title"},"layout":{"type":"constrained"}} -->
<div class="wp-block-group"><!-- wp:heading {"level":1,"className":"is-style-text-title"} -->
<h1 class="wp-block-heading is-style-text-title">Hi, I'm Rich Tabor</h1>
<!-- /wp:heading -->

<!-- wp:site-tagline /--></div>
<div class="wp-block-group">
<!-- wp:query-title {"type":"archive","showPrefix":false} /-->
<!-- wp:term-description /-->
</div>
<!-- /wp:group -->

<!-- wp:group {"metadata":{"name":"Topics"},"layout":{"type":"default"}} -->
Expand Down
10 changes: 6 additions & 4 deletions templates/single.html
Original file line number Diff line number Diff line change
Expand Up @@ -58,14 +58,16 @@
<div style="height:var(--wp--preset--spacing--30)" aria-hidden="true" class="wp-block-spacer"></div>
<!-- /wp:spacer -->

<!-- wp:paragraph {"className":"is-style-text-subtitle"} -->
<p class="is-style-text-subtitle">You may also enjoy…</p>
<!-- /wp:paragraph -->
<!-- wp:heading {"className":"is-style-text-subtitle"} -->
<h2 class="wp-block-heading is-style-text-subtitle">You may also enjoy…</h2>
<!-- /wp:heading -->

<!-- wp:query {"queryId":0,"query":{"perPage":"60","pages":0,"offset":0,"postType":"post","order":"desc","orderBy":"date","author":"","search":"","exclude":[],"sticky":"","inherit":false}} -->
<div class="wp-block-query"><!-- wp:post-template {"style":{"spacing":{"blockGap":"var:preset|spacing|10"}}} -->
<!-- wp:group {"style":{"spacing":{"padding":{"top":"2px","bottom":"2px","left":"0px","right":"0px"}}},"layout":{"type":"flex","flexWrap":"nowrap","justifyContent":"space-between"}} -->
<div class="wp-block-group" style="padding-top:2px;padding-right:0px;padding-bottom:2px;padding-left:0px"><!-- wp:post-title {"isLink":true,"style":{"spacing":{"padding":{"top":"0px","bottom":"0px"}},"typography":{"lineHeight":"1.2"}},"className":"no-underline truncate","fontSize":"large"} /-->
<div class="wp-block-group" style="padding-top:2px;padding-right:0px;padding-bottom:2px;padding-left:0px">

<!-- wp:post-title {"level":3,"isLink":true,"className":"no-underline truncate","style":{"spacing":{"padding":{"top":"0px","bottom":"0px"}},"typography":{"lineHeight":"1.2"}},"fontSize":"large"} /-->

<!-- wp:post-date {"textAlign":"right","format":"M Y"} /--></div>
<!-- /wp:group -->
Expand Down
7 changes: 5 additions & 2 deletions theme.json
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@
"slug": "theme-4"
},
{
"color": "color-mix(in srgb, var(--wp--preset--color--theme-1) 45%, var(--wp--preset--color--theme-6) 55%)",
"color": "color-mix(in srgb, var(--wp--preset--color--theme-1) 32%, var(--wp--preset--color--theme-6) 68%)",
"name": "Theme 5",
"slug": "theme-5"
},
Expand All @@ -94,7 +94,7 @@
"theme-2-dark": "color-mix(in srgb, var(--wp--preset--color--theme-1) 4%, var(--wp--preset--color--theme-6) 96%)",
"theme-3-dark": "color-mix(in srgb, var(--wp--preset--color--theme-1) 12%, var(--wp--preset--color--theme-6) 88%)",
"theme-4-dark": "color-mix(in srgb, var(--wp--preset--color--theme-1) 25%, var(--wp--preset--color--theme-6) 75%)",
"theme-5-dark": "color-mix(in srgb, var(--wp--preset--color--theme-1) 45%, var(--wp--preset--color--theme-6) 55%)",
"theme-5-dark": "color-mix(in srgb, var(--wp--preset--color--theme-1) 50%, var(--wp--preset--color--theme-6) 50%)",
"theme-6-dark": "hsl(0 0% 100% / 85%)"
},
"transition": {
Expand Down Expand Up @@ -851,6 +851,9 @@
":hover": {
"color": {
"text": "var(--wp--preset--color--theme-6)"
},
"typography": {
"textDecoration": "none"
}
},
"color": {
Expand Down

0 comments on commit c0bddd8

Please sign in to comment.