Quick/Bulk Edit: Position action buttons in close proximity.

Move the Submit and Cancel buttons in quick edit forms to be next to each other and change the order of the buttons. Improve accessibility for low vision and cognitive impairments for quick editing. 

Props afercia, marybaum.
Fixes #55364.

Built from https://develop.svn.wordpress.org/trunk@53023


git-svn-id: http://core.svn.wordpress.org/trunk@52612 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
joedolson 2022-03-29 19:08:19 +00:00
parent 31c9e9452a
commit 6732d37abf
7 changed files with 41 additions and 12 deletions

View File

@ -915,12 +915,26 @@ tr.inline-edit-row td,
}
.inline-edit-row .submit {
display: flex;
flex-wrap: wrap;
align-items: center;
clear: both;
padding: 0.5em;
margin: 0.5em 0 0;
}
.inline-edit-save.submit .button {
margin-left: 8px;
}
.inline-edit-save .spinner {
float: none;
margin: 0;
}
.inline-edit-row .notice-error {
box-sizing: border-box;
min-width: 100%;
margin-top: 1em;
}

File diff suppressed because one or more lines are too long

View File

@ -914,12 +914,26 @@ tr.inline-edit-row td,
}
.inline-edit-row .submit {
display: flex;
flex-wrap: wrap;
align-items: center;
clear: both;
padding: 0.5em;
margin: 0.5em 0 0;
}
.inline-edit-save.submit .button {
margin-right: 8px;
}
.inline-edit-save .spinner {
float: none;
margin: 0;
}
.inline-edit-row .notice-error {
box-sizing: border-box;
min-width: 100%;
margin-top: 1em;
}

File diff suppressed because one or more lines are too long

View File

@ -2007,14 +2007,17 @@ class WP_Posts_List_Table extends WP_List_Table {
?>
<div class="submit inline-edit-save">
<button type="button" class="button cancel alignleft"><?php _e( 'Cancel' ); ?></button>
<?php if ( ! $bulk ) : ?>
<?php wp_nonce_field( 'inlineeditnonce', '_inline_edit', false ); ?>
<button type="button" class="button button-primary save alignright"><?php _e( 'Update' ); ?></button>
<span class="spinner"></span>
<button type="button" class="button button-primary save"><?php _e( 'Update' ); ?></button>
<?php else : ?>
<?php submit_button( __( 'Update' ), 'primary alignright', 'bulk_edit', false ); ?>
<?php submit_button( __( 'Update' ), 'primary', 'bulk_edit', false ); ?>
<?php endif; ?>
<button type="button" class="button cancel"><?php _e( 'Cancel' ); ?></button>
<?php if ( ! $bulk ) : ?>
<span class="spinner"></span>
<?php endif; ?>
<input type="hidden" name="post_view" value="<?php echo esc_attr( $m ); ?>" />
@ -2022,7 +2025,6 @@ class WP_Posts_List_Table extends WP_List_Table {
<?php if ( ! $bulk && ! post_type_supports( $screen->post_type, 'author' ) ) : ?>
<input type="hidden" name="post_author" value="<?php echo esc_attr( $post->post_author ); ?>" />
<?php endif; ?>
<br class="clear" />
<div class="notice notice-error notice-alt inline hidden">
<p class="error"></p>

View File

@ -696,14 +696,13 @@ class WP_Terms_List_Table extends WP_List_Table {
?>
<div class="inline-edit-save submit">
<button type="button" class="cancel button alignleft"><?php _e( 'Cancel' ); ?></button>
<button type="button" class="save button button-primary alignright"><?php echo $tax->labels->update_item; ?></button>
<button type="button" class="save button button-primary"><?php echo $tax->labels->update_item; ?></button>
<button type="button" class="cancel button"><?php _e( 'Cancel' ); ?></button>
<span class="spinner"></span>
<?php wp_nonce_field( 'taxinlineeditnonce', '_inline_edit', false ); ?>
<input type="hidden" name="taxonomy" value="<?php echo esc_attr( $this->screen->taxonomy ); ?>" />
<input type="hidden" name="post_type" value="<?php echo esc_attr( $this->screen->post_type ); ?>" />
<br class="clear" />
<div class="notice notice-error notice-alt inline hidden">
<p class="error"></p>

View File

@ -16,7 +16,7 @@
*
* @global string $wp_version
*/
$wp_version = '6.0-alpha-53020';
$wp_version = '6.0-alpha-53023';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.