Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
breakoutModewide
languagehtml
<div class='"pagination'">
    {{#if summary}}
        <div class='"pagination__summary'">{{summary}}</div>
    {{/if}}
    <div class='"pagination__pages'">
        {{#if displayFirstLink}}
            <a hawksearch-page='"1'" class='"pagination__page pagination__page--first'" title='"First'">
                <hawksearch-icon name='"chevron-back'" size='"1.2em'"></hawksearch-icon>
            </a>
        {{/if}}
        {{#if displayPreviousLink}}
            <a hawksearch-page='"{{subtract page 1}}'" class='"pagination__page pagination__page--previous'" title='"Previous'">
                <hawksearch-icon name='"chevron-left'" size='"1.2em'"></hawksearch-icon>
            </a>
        {{/if}}
        {{#each pages}}
            {{#if (eq this @root.page)}}
                <span class='"pagination__page pagination__page--selected'">{{this}}</span>
            {{else}}
                <a hawksearch-page='"{{this}}'" class='"pagination__page'">{{this}}</a>
            {{/if}}
        {{/each}}
        {{#if displayNextLink}}
            <a hawksearch-page='"{{add page 1}}'" class='"pagination__page pagination__page--next'" title='"Next'">
                <hawksearch-icon name='"chevron-right'" size='"1.2em'"></hawksearch-icon>
            </a>
        {{/if}}
        {{#if displayLastLink}}
            <a hawksearch-page='"{{totalPages}}'" class='"pagination__page pagination__page--last'" title='"Last'">
                <hawksearch-icon name='"chevron-forward'" size='"1.2em'"></hawksearch-icon>
            </a>
        {{/if}}
    </div>
</div>