Twenty Fifteen: adding context to pagination links for screenreaders.
Props afercia, iamtakashi, fixes #30152 Built from https://develop.svn.wordpress.org/trunk@30316 git-svn-id: http://core.svn.wordpress.org/trunk@30315 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
99a35f20e6
commit
40c73b7d0d
|
@ -46,7 +46,9 @@ get_header(); ?>
|
|||
|
||||
<?php
|
||||
the_pagination( array(
|
||||
'before_page_number' => '<span class="meta-nav">' . __( 'Page', 'twentyfifteen' ) . '</span>',
|
||||
'prev_text' => __( 'Previous page', 'twentyfifteen' ),
|
||||
'next_text' => __( 'Next page', 'twentyfifteen' ),
|
||||
'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'twentyfifteen' ) . ' </span>',
|
||||
) );
|
||||
?>
|
||||
|
||||
|
|
|
@ -42,7 +42,9 @@ get_header(); ?>
|
|||
|
||||
<?php
|
||||
the_pagination( array(
|
||||
'before_page_number' => '<span class="meta-nav">' . __( 'Page', 'twentyfifteen' ) . '</span>',
|
||||
'prev_text' => __( 'Previous page', 'twentyfifteen' ),
|
||||
'next_text' => __( 'Next page', 'twentyfifteen' ),
|
||||
'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'twentyfifteen' ) . ' </span>',
|
||||
) );
|
||||
?>
|
||||
|
||||
|
|
|
@ -151,11 +151,6 @@ td {
|
|||
left: auto;
|
||||
}
|
||||
|
||||
.pagination .meta-nav {
|
||||
margin-right: auto;
|
||||
margin-left: 0.3333em;
|
||||
}
|
||||
|
||||
.pagination .prev {
|
||||
right: 0;
|
||||
left: auto;
|
||||
|
|
|
@ -34,7 +34,9 @@ get_header(); ?>
|
|||
|
||||
<?php
|
||||
the_pagination( array(
|
||||
'before_page_number' => '<span class="meta-nav">' . __( 'Page', 'twentyfifteen' ) . '</span>',
|
||||
'prev_text' => __( 'Previous page', 'twentyfifteen' ),
|
||||
'next_text' => __( 'Next page', 'twentyfifteen' ),
|
||||
'before_page_number' => '<span class="meta-nav screen-reader-text">' . __( 'Page', 'twentyfifteen' ) . ' </span>',
|
||||
) );
|
||||
?>
|
||||
|
||||
|
|
|
@ -25,8 +25,8 @@ get_header(); ?>
|
|||
|
||||
<?php
|
||||
the_post_navigation( array(
|
||||
'next_text' => _x( '<span class="meta-nav">Next</span><span class="post-title">%title</span>', 'Next post link', 'twentyfifteen' ),
|
||||
'prev_text' => _x( '<span class="meta-nav">Previous</span><span class="post-title">%title</span>', 'Previous post link', 'twentyfifteen' ),
|
||||
'next_text' => _x( '<span class="meta-nav">Next <span class="screen-reader-text">post:</span></span><span class="post-title">%title</span>', 'Next post link', 'twentyfifteen' ),
|
||||
'prev_text' => _x( '<span class="meta-nav">Previous <span class="screen-reader-text">post:</span></span><span class="post-title">%title</span>', 'Previous post link', 'twentyfifteen' )
|
||||
) );
|
||||
?>
|
||||
|
||||
|
|
|
@ -1025,14 +1025,18 @@ a:focus {
|
|||
text-align: center;
|
||||
}
|
||||
|
||||
.pagination .meta-nav {
|
||||
margin-right: 0.3333em;
|
||||
/* reset screen-reader-text */
|
||||
.pagination .current .screen-reader-text {
|
||||
position: static !important;
|
||||
}
|
||||
|
||||
.pagination .page-numbers {
|
||||
display: none;
|
||||
line-height: 3.2em;
|
||||
padding: 0 0.6667em;
|
||||
}
|
||||
|
||||
.pagination .page-numbers.current {
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
|
@ -2754,12 +2758,13 @@ span > video {
|
|||
padding: 0;
|
||||
}
|
||||
|
||||
.pagination .page-numbers {
|
||||
display: inline-block;
|
||||
/* restore screen-reader-text */
|
||||
.pagination .current .screen-reader-text {
|
||||
position: absolute !important;
|
||||
}
|
||||
|
||||
.pagination .meta-nav {
|
||||
display: none;
|
||||
.pagination .page-numbers {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.image-navigation {
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '4.1-alpha-30315';
|
||||
$wp_version = '4.1-alpha-30316';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue