Publier Globinours 1.0.0-rc.3
This commit is contained in:
parent
ea8c24d622
commit
9a2b4068da
325 changed files with 38230 additions and 20 deletions
14
app/Views/_public_animal_cards.php
Normal file
14
app/Views/_public_animal_cards.php
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
<?php if (!$animals): ?><div class="empty"><?= h(t('public_site.no_animals')) ?></div><?php else: ?><div class="grid">
|
||||
<?php foreach ($animals as $a): ?><a class="animal-card"
|
||||
href="<?= h($siteUrl('animal', ['id' => (int)$a['id']])) ?>"><?php if ($a['primary_photo']): ?><img
|
||||
loading="lazy" src="/media/animals/<?= (int)$a['id'] ?>/<?= h(rawurlencode($a['primary_photo'])) ?>"
|
||||
alt="<?= h($a['name']) ?>"><?php else: ?><div class="photo-placeholder"><?= h($a['species_icon'] ?: '🐾') ?>
|
||||
</div><?php endif; ?><div class="animal-card-body">
|
||||
<h3><?= h($a['name']) ?></h3>
|
||||
<div class="meta">
|
||||
<?= h(($a['species_name'] ?: SpeciesService::label($a['species'])) . ' · ' . public_age($a)) ?></div>
|
||||
<div class="chips"><?php if ($a['sex'] === 'F'): ?><span class="chip">♀
|
||||
<?= h(t('sex.female')) ?></span><?php elseif ($a['sex'] === 'M'): ?><span class="chip">♂
|
||||
<?= h(t('sex.male')) ?></span><?php endif; ?><?php if ($a['sterilization_status'] === 'yes'): ?><span
|
||||
class="chip">✓ <?= h(t('public_site.sterilized')) ?></span><?php endif; ?></div>
|
||||
</div></a><?php endforeach; ?></div><?php endif; ?>
|
||||
Loading…
Add table
Add a link
Reference in a new issue