Accessibility: bump headings one level up on the Appearance > Widgets screen for a better headings hierarchy.

Props mrahmadawais, afercia.
Fixes #33659.
Built from https://develop.svn.wordpress.org/trunk@35015


git-svn-id: http://core.svn.wordpress.org/trunk@34980 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Andrea Fercia 2015-10-10 16:34:25 +00:00
parent 5fdf928bcf
commit 6b449abadc
13 changed files with 34 additions and 16 deletions

View File

@ -419,7 +419,11 @@ body.adding-widget .add-new-widget:before {
box-shadow: none;
}
#available-widgets .widget-title h4 {
#customize-controls .widget-title h3 {
font-size: 1em;
}
#available-widgets .widget-title h3 {
padding: 0 0 5px;
font-size: 14px;
}
@ -621,7 +625,7 @@ body.adding-widget #customize-preview {
.last-widget {
margin-bottom: 15px;
}
.widget-title h4 {
.widget-title h3 {
padding: 13px 15px;
}
.widget-top a.widget-action:after {

File diff suppressed because one or more lines are too long

View File

@ -419,7 +419,11 @@ body.adding-widget .add-new-widget:before {
box-shadow: none;
}
#available-widgets .widget-title h4 {
#customize-controls .widget-title h3 {
font-size: 1em;
}
#available-widgets .widget-title h3 {
padding: 0 0 5px;
font-size: 14px;
}
@ -621,7 +625,7 @@ body.adding-widget #customize-preview {
.last-widget {
margin-bottom: 15px;
}
.widget-title h4 {
.widget-title h3 {
padding: 13px 15px;
}
.widget-top a.widget-action:after {

File diff suppressed because one or more lines are too long

View File

@ -22,9 +22,11 @@
text-decoration: none;
}
.widget-title h3,
.widget-title h4 {
margin: 0;
padding: 15px;
font-size: 1em;
line-height: 1;
overflow: hidden;
white-space: nowrap;
@ -100,6 +102,7 @@
cursor: pointer;
}
.sidebar-name h2,
.sidebar-name h3 {
margin: 0;
padding: 8px 10px;
@ -142,6 +145,7 @@ div#widgets-left .inactive-sidebar.closed .sidebar-name {
margin-bottom: 10px;
}
div#widgets-left .sidebar-name h2,
div#widgets-left .sidebar-name h3 {
padding: 10px 0;
margin: 0 0 0 10px;
@ -243,6 +247,7 @@ div#widgets-right .sidebar-description {
margin-top: -5px;
}
div#widgets-right .sidebar-name h2,
div#widgets-right .sidebar-name h3 {
padding: 15px 7px;
}

View File

@ -22,9 +22,11 @@
text-decoration: none;
}
.widget-title h3,
.widget-title h4 {
margin: 0;
padding: 15px;
font-size: 1em;
line-height: 1;
overflow: hidden;
white-space: nowrap;
@ -100,6 +102,7 @@
cursor: pointer;
}
.sidebar-name h2,
.sidebar-name h3 {
margin: 0;
padding: 8px 10px;
@ -142,6 +145,7 @@ div#widgets-left .inactive-sidebar.closed .sidebar-name {
margin-bottom: 10px;
}
div#widgets-left .sidebar-name h2,
div#widgets-left .sidebar-name h3 {
padding: 10px 0;
margin: 0 10px 0 0;
@ -243,6 +247,7 @@ div#widgets-right .sidebar-description {
margin-top: -5px;
}
div#widgets-right .sidebar-name h2,
div#widgets-right .sidebar-name h3 {
padding: 15px 7px;
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -81,7 +81,7 @@ function wp_list_widget_controls( $sidebar, $sidebar_name = '' ) {
?>
<div class="sidebar-name">
<div class="sidebar-name-arrow"><br /></div>
<h3><?php echo esc_html( $sidebar_name ); ?> <span class="spinner"></span></h3>
<h2><?php echo esc_html( $sidebar_name ); ?> <span class="spinner"></span></h2>
</div>
<?php
}
@ -226,7 +226,7 @@ function wp_widget_control( $sidebar_args ) {
<span class="screen-reader-text"><?php echo $widget_title; ?></span>
</a>
</div>
<div class="widget-title"><h4><?php echo $widget_title ?><span class="in-widget-title"></span></h4></div>
<div class="widget-title"><h3><?php echo $widget_title; ?><span class="in-widget-title"></span></h3></div>
</div>
<div class="widget-inside">

View File

@ -297,7 +297,7 @@ wpWidgets = {
if ( ui.draggable.hasClass('ui-sortable-helper') ) {
$('#removing-widget').show().children('span')
.html( ui.draggable.find('div.widget-title').children('h4').html() );
.html( ui.draggable.find( 'div.widget-title' ).children( 'h3' ).html() );
}
},
out: function(e,ui) {
@ -310,7 +310,7 @@ wpWidgets = {
// Area Chooser
$( '#widgets-right .widgets-holder-wrap' ).each( function( index, element ) {
var $element = $( element ),
name = $element.find( '.sidebar-name h3' ).text(),
name = $element.find( '.sidebar-name h2' ).text(),
id = $element.find( '.widgets-sortables' ).attr( 'id' ),
li = $('<li tabindex="0">').text( $.trim( name ) );

File diff suppressed because one or more lines are too long

View File

@ -244,7 +244,7 @@ if ( isset($_GET['editwidget']) && $_GET['editwidget'] ) {
<div class="wrap">
<h1><?php echo esc_html( $title ); ?></h1>
<div class="editwidget"<?php echo $width; ?>>
<h3><?php printf( __( 'Widget %s' ), $name ); ?></h3>
<h2><?php printf( __( 'Widget %s' ), $name ); ?></h2>
<form action="widgets.php" method="post">
<div class="widget-inside">
@ -361,7 +361,7 @@ do_action( 'widgets_admin_page' ); ?>
<div id="available-widgets" class="widgets-holder-wrap">
<div class="sidebar-name">
<div class="sidebar-name-arrow"><br /></div>
<h3><?php _e('Available Widgets'); ?> <span id="removing-widget"><?php _ex('Deactivate', 'removing-widget'); ?> <span></span></span></h3>
<h2><?php _e( 'Available Widgets' ); ?> <span id="removing-widget"><?php _ex( 'Deactivate', 'removing-widget' ); ?> <span></span></span></h2>
</div>
<div class="widget-holder">
<div class="sidebar-description">

View File

@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.4-alpha-35014';
$wp_version = '4.4-alpha-35015';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.