<?php
$GLOBALS['TL_CSS'][] = \Contao\Config::get('uploadPath').'/cto_layout/css/news/news_newsteaser.css|static';
$hasText = $this->hasText;
?>
<div class="newsteaser autogrid one_third block <?php echo $this->class; ?>" itemscope itemtype="http://schema.org/Article">
<?php if ($this->addImage): ?>
<div class="image_container<?php echo $this->floatClass; ?>"<?php if ($this->margin || $this->float): ?> style="<?php echo trim($this->margin . $this->float); ?>"<?php endif; ?>>
<?php if ($hasText): ?><a href="<?php echo $this->link; ?>" <?php echo $this->attributes; ?> title="<?php echo $this->alt; ?>" <?php if($this->target && $this->url): ?>target="_blank" <?php endif; ?>><?php endif; ?>
<?php $this->insert('picture_default', $this->picture); ?>
<span class="news-overlay"><i class="fa fa-plus"></i></span>
<?php if ($hasText): ?></a><?php endif; ?>
<?php if ($this->date): ?>
<div class="date" itemprop="datePublished">
<span class="day"><?php echo $this->parseDate("d", $this->timestamp);?></span>
<span class="month"><?php echo $this->parseDate("M", $this->timestamp);?></span>
<span class="year"><?php echo $this->parseDate("Y", $this->timestamp);?></span>
</div>
<?php endif; ?>
<div class="info">
<?php if ($this->author): ?>
<span class="author"><?php echo $this->author; ?></span>
<?php endif; ?>
<?php if ($this->commentCount): ?>
<span class="comments"><?php echo $this->numberOfComments; ?></span>
<?php endif; ?>
</div>
</div>
<?php endif; ?>
<div class="content">
<div class="info-v2"><?php if ($this->date): ?><div class="date-v2"><?php echo $this->date; ?></div><?php endif; ?><?php if ($this->author): ?><div class="author-v2"><?php echo $this->author; ?></div><?php endif; ?><?php if ($this->commentCount): ?><div class="comments-v2"><?php echo $this->commentCount; ?></div><?php endif; ?></div>
<div class="h6"><?php echo $hasText ? $this->linkHeadline : $this->newsHeadline; ?></div>
<div class="teaser" itemprop="description"><?php echo $this->teaser; ?></div>
<div class="info-v3"><?php if ($this->date): ?><div class="date-v3"><?php echo $this->date; ?></div><?php endif; ?><?php if ($this->author): ?><div class="author-v3"><?php echo $this->author; ?></div><?php endif; ?><?php if ($this->commentCount): ?><div class="comments-v3"><?php echo $this->commentCount; ?></div><?php endif; ?></div>
</div>
</div>