Initial commit
This commit is contained in:
commit
65e0da7e11
1397 changed files with 596542 additions and 0 deletions
34
site/templates/news.php
Normal file
34
site/templates/news.php
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
<?php snippet('header') ?>
|
||||
|
||||
<?php
|
||||
// $size = [' xs', ' lg'];
|
||||
// $position = [' top', ' bottom'];
|
||||
?>
|
||||
|
||||
<!-- UPDATE - data-grid should be $gridLayoutVariable -->
|
||||
<div id="news">
|
||||
<?php foreach ($page->medias()->toFiles() as $image): ?>
|
||||
<?php if ($image): ?>
|
||||
<?php
|
||||
$displayWidth = $image->displayWidth()->isNotEmpty() ? $image->displayWidth() : 50;
|
||||
?>
|
||||
<div class="item" style="width: <?= $displayWidth ?>vw">
|
||||
<?php if ($image->pageLink()->isNotEmpty() && $pageLink = page($image->pageLink()->value())): ?>
|
||||
<a href="<?= $pageLink->url() ?>" class="link-overlay" style="width: <?= $displayWidth ?>vw"></a>
|
||||
<?php elseif ($image->stream()->isNotEmpty()): ?>
|
||||
<a href="<?= $image->stream() ?>" class="link-overlay" style="width: <?= $displayWidth ?>vw"></a>
|
||||
<?php endif ?>
|
||||
<?php snippet('responsive-image', ['image' => $image]) ?>
|
||||
<div class="caption" style="width: <?= $displayWidth ?>vw"><!----><?php if ($image->subtitle()->isNotEmpty()): ?>
|
||||
<div class="subtitle uppercase"><?= $image->subtitle()->html() ?></div>
|
||||
<?php endif ?><!----><?php if ($image->date()): ?>
|
||||
<div class="date uppercase"><?= $image->date('d.m.Y') ?></div>
|
||||
<?php endif ?><!----><?php if ($image->caption()->isNotEmpty()): ?>
|
||||
<div class="text"><?= $image->caption()->kt() ?></div>
|
||||
<?php endif ?><!----></div>
|
||||
</div>
|
||||
<?php endif ?>
|
||||
<?php endforeach ?>
|
||||
</div>
|
||||
|
||||
<?php snippet('footer') ?>
|
||||
Loading…
Add table
Add a link
Reference in a new issue