-
Notifications
You must be signed in to change notification settings - Fork 1
/
clarity-pagination.html
26 lines (24 loc) · 1.94 KB
/
clarity-pagination.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<?php list($name, $pages) = $this->yellow->getLayoutArguments() ?>
<?php if ($pages->isPagination()): ?>
<ul class="pagination pagination-default">
<li class="page-item<?php if (!$pages->getPaginationPrevious()) echo " disabled" ?>" <?php if (!$pages->getPaginationPrevious()) echo " style=\"pointer-events: none\"" ?>>
<a class="page-link" href="<?php echo $pages->getPaginationPrevious() ?>"><svg class="icon rotate-270"><use xlink:href="#arrow"></use></svg></a>
</li>
<li class="page-item<?php if (!$pages->getPaginationPrevious()) echo " disabled" ?>" <?php if (!$pages->getPaginationPrevious()) echo " style=\"pointer-events: none\"" ?>>
<a class="page-link" href="<?php echo $pages->getPaginationPrevious() ?>"><svg class="icon rotate-270"><use xlink:href="#arrow"></use></svg></a>
</li>
<?php if($pages->getPaginationCount() > 1): ?>
<?php for($i = 1; $i <= $pages->getPaginationCount(); ++$i): ?>
<li class="page-item<?php if ($i == $pages->getPaginationNumber()) echo " active" ?>">
<a class="page-link" href="<?php echo $pages->getPaginationLocation(true, $i) ?>"><?php echo $i ?></a>
</li>
<?php endfor ?>
<?php endif ?>
<li class="page-item<?php if (!$pages->getPaginationNext()) echo " disabled" ?>" <?php if (!$pages->getPaginationNext()) echo " style=\"pointer-events: none\"" ?>>
<a class="page-link" href="<?php echo $pages->getPaginationNext() ?>" role="button"><svg class="icon rotate-90"><use xlink:href="#arrow"></use></svg></a>
</li>
<li class="page-item<?php if (!$pages->getPaginationNext()) echo " disabled" ?>" <?php if (!$pages->getPaginationNext()) echo " style=\"pointer-events: none\"" ?>>
<a class="page-link" href="<?php echo $pages->getPaginationNext() ?>" role="button"><svg class="icon rotate-90"><use xlink:href="#arrow"></use></svg></a>
</li>
</ul>
<?php endif ?>