design virtual pages
This commit is contained in:
parent
8e65a1cc64
commit
c70b4890f8
12 changed files with 131 additions and 84 deletions
|
|
@ -4,16 +4,32 @@
|
|||
<article>
|
||||
<?php snippet('cover', slots: true) ?>
|
||||
<?php slot('title') ?>
|
||||
<h1 class="main-title <?= setTitleFontSizeClass($page->title()) ?>"><?= $page->title() ?></h1>
|
||||
<h2 class="main-title <?= setTitleFontSizeClass($page->title()) ?>"><?= $page->title() ?></h2>
|
||||
<?php endslot() ?>
|
||||
<?php slot('tabs') ?>
|
||||
<?php snippet('tabs', [
|
||||
'left' => [
|
||||
'label' => 'Présentation',
|
||||
'content' => $page->presentation()
|
||||
],
|
||||
'authorFilter' => $page->author()
|
||||
]) ?>
|
||||
<?php slot('text') ?>
|
||||
<?= $page->presentation() ?>
|
||||
<p class="h3">textes :</p>
|
||||
<ul class="texts">
|
||||
<?php foreach($site->index()->filterBy('template', 'in', array('linear', 'grid')) as $article): ?>
|
||||
<?php if ($article->author()->isNotEmpty() && $article->author()->toUser()->name() == $page->title()->value()): ?>
|
||||
<li
|
||||
class="text"
|
||||
>
|
||||
<a href="<?= $article->url() ?>" class="text__title no-line">
|
||||
<h4><?= $article->title() ?></h4>
|
||||
</a>
|
||||
<div class="text__infos">
|
||||
<p>
|
||||
<span class="light">par</span>
|
||||
<a class="author" href="/auteurs/<?= Str::slug($article->author()->toUser()->name()) ?>"><?= $article->author()->toUser()->name() ?></a><br>
|
||||
<span class="light">publié le </span><?= $article->published()->toDate('d/m/Y') ?><br>
|
||||
<span class="light">dans</span> <a href="<?= $article->parent()->url() ?>"><?= $article->parent()->title() ?></a> / <a href="/categories/<?= $article->category() ?>"><?= $article->category() ?></a>
|
||||
</p>
|
||||
</div>
|
||||
</li>
|
||||
<?php endif ?>
|
||||
</ul>
|
||||
<?php endforeach ?>
|
||||
<?php endslot() ?>
|
||||
<?php endsnippet() ?>
|
||||
</article>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue