get_template_partで引数を渡す

<?php
// サムネイル
if (has_post_thumbnail()) {
  $thumbnail_url = get_the_post_thumbnail_url();
} else {
  $thumbnail_url = get_template_directory_uri() . "/assets/images/sample/post_thumbnail.jpg";
}
get_template_part(
  'common/post_content/thummbnail_show',
  null,
  [
    'thumbanail_url' => $thumbnail_url,
    'shape' => 'aspect-ratio-1-1',
  ]
);
?>

<?php echo $args[‘thumbanail_url’] ;?>