Show date as block and inline depeding on the screen size

This commit is contained in:
Diego Najar 2021-10-13 21:41:49 +02:00
parent 1f6dd0b6e7
commit 72d89576f1

View file

@ -68,15 +68,29 @@
<!-- End Page title --> <!-- End Page title -->
<!-- Page date --> <!-- Page date -->
<!-- This block is not visible on small devices -->
<div class="d-none d-sm-block">
<?php if ($theme->dateFormat()=='relative'): ?> <?php if ($theme->dateFormat()=='relative'): ?>
<small class="color-blue"><?php echo $pageTmp->relativeTime() ?></small> <small class="color-blue"><?php echo $pageTmp->relativeTime() ?></small>
<?php else: ?> <?php else: ?>
<small class="color-blue"><?php echo $pageTmp->date() ?></small> <small class="color-blue"><?php echo $pageTmp->date() ?></small>
<?php endif ?> <?php endif ?>
</div>
<!-- End Page date --> <!-- End Page date -->
</div> </div>
<!-- Page date -->
<!-- This block is only visible on small devices -->
<div class="d-block d-sm-none">
<?php if ($theme->dateFormat()=='relative'): ?>
<small class="color-blue"><?php echo $pageTmp->relativeTime() ?></small>
<?php else: ?>
<small class="color-blue"><?php echo $pageTmp->date() ?></small>
<?php endif ?>
</div>
<!-- End Page date -->
<!-- Page description --> <!-- Page description -->
<?php if ($pageTmp->description()): ?> <?php if ($pageTmp->description()): ?>
<p class="mb-1 form-text"><?php echo $pageTmp->description(); ?></p> <p class="mb-1 form-text"><?php echo $pageTmp->description(); ?></p>