Updating to the new 3.0.1 version of Metabox AIO introduces a new version of the builder that includes nifty status toggles for internal metabox post types.
File: wp-content/plugins/meta-box-aio/vendor/meta-box/meta-box-builder/src/ToggleStatusColumn.php
Unfortunately the code hides the draft status for all post-types, not just the ones that are listed. See below:
class ToggleStatusColumn {
private $post_types = [ 'meta-box', 'mb-settings-page', 'mb-relationship', 'mb-post-type', 'mb-taxonomy', 'mb-views'];
public function __construct() {
foreach ( $this->post_types as $post_type ) {
// Priority 20 to ensure the column is added after other columns are added (like in views).
add_filter( 'manage_' . $post_type . '_posts_columns', [ $this, 'add_column' ], 20 );
add_action( 'manage_' . $post_type . '_posts_custom_column', [ $this, 'show_column' ], 10, 2 );
}
add_action( 'admin_print_styles-edit.php', [ $this, 'enqueue_scripts' ] );
add_action( 'wp_ajax_mbb_toggle_status', [ $this, 'handle_toggle_status' ] );
add_filter( 'display_post_states', [ $this, 'remove_draft_state_label' ], 10, 2 ); //<--THIS LINE NEEDED TO BE COMMENTED OUT TO RESOLVE THIS FOR ME
}
Will this be addressed in a future update?
I did discover that you can add your own custom post types to the $post-types array, and it will add that status toggle to the admin list for that post type as well. It would be cool if that was an exposed option in the custom post type settings, since switching posts between published and draft states is a fairly common use case.