This isn’t possible in one query. You can’t set posts per page for individual taxonomy queries.
You can either query 12 status or aside posts together:
array(
'posts_per_page' => 12,
'tax_query' => array(
array(
'taxonomy' => 'post_format',
'field' => 'slug',
'terms' => array( 'post-format-status', 'post-format-aside' ),
),
),
)
Or perform separate queries with get_posts()
with the desired number for each, merging the results, then sorting the merged results by date:
// Get statuses.
$statuses = get_posts( array(
'numberposts' => 7,
'tax_query' => array(
array(
'taxonomy' => 'post_format',
'field' => 'slug',
'terms' => 'post-format-status',
),
),
) );
// Get asides.
$asides = get_posts( array(
'numberposts' => 5,
'tax_query' => array(
array(
'taxonomy' => 'post_format',
'field' => 'slug',
'terms' => 'post-format-aside',
),
),
) );
// Merge results.
$posts = array_merge( $statuses, $asides );
// Sort results by comparing the dates.
uasort( $posts, function( $a, $b ) {
return strtotime( $b->post_date ) - strtotime( $a->post_date );
} );
global $post;
foreach ( $posts as $post ) : setup_postdata( $post );
endforeach; wp_reset_postdata();