<?php 
$ep = GOV_anime::get_latest_chapters(get_the_ID(), TRUE);
$latest = $ep['chapter'];
$latestvol = isset($ep['volume']) ? $ep['volume'] : '';
$status = get_post_meta(get_the_ID(),'ero_status',true);
$score = get_post_meta(get_the_ID(),'ero_score',true);
?>
<article class="bs" itemscope="itemscope" itemtype="http://schema.org/CreativeWork">
	<div class="bsx">
		<a href="<?php echo get_permalink(FALSE); ?>" itemprop="url" title="<?php echo get_the_title(FALSE); ?>" class="tip" rel="<?php the_ID(); ?>">
		<div class="limit">
			<div class="ply"><i class="fas fa-book-open" aria-hidden="true"></i></div>
			<?php echo Lightnovel::get_post_thumbnail(get_the_ID(), 'full', 215, 151, array('itemprop'=>'image','title'=>get_the_title(FALSE),'alt'=>get_the_title(FALSE))); ?>
		</div>
			<div class="tt">
				<span class="ntitle"><?php the_title(FALSE); ?></span>
				<?php if($latest){ ?>
				<span class="nchapter"><?php if($latestvol){ echo GOV_lang::get('thumbnail_volume_min_label')." ".$latestvol." "; } ?><?php echo GOV_lang::get('thumbnail_chapter_min_label');?> <?php echo $latest; ?></span>
				<?php } ?>
				<?php if($score){ ?>
				<div class="rt">
						<div class="rating">
							<?php
							if(!$score || ! is_numeric($score)){ $score = '0.0';}
							$scorepros = $score * 10;
							if($score){ ?>
							<div class="rating-prc">
								<div class="rtp">
									<div class="rtb"><span style="width:<?php echo $scorepros; ?>%"></span></div>
								</div>
							</div>
							<div class="numscore"><?php echo $score; ?></div>
							<?php } ?>
						</div>
				</div>
				<?php } ?>
				<h2 itemprop="headline"><?php the_title(); ?></h2>
			</div>
		</a>
	</div>
</article>