anchor.diff:          label.pgn-jump.input(for=pgmpid) Jump to:
           .input-append
             input.input-small(id=pgmpid, type='text', size='8', placeholder='Page number')
  -          button.btn.btn-inverse(type='button') Go!
  +            button.btn.btn-inverse(type='button') Go!
   
  -    - if ((max_page - current) >= 1 )
  -      - params.page = current + 1
  -      li
  -        a(href=link_to(route, params)) #{current + 1}
  +    //- right surrounding pages displayed if current page less then one from bottom
  +    - for (var i=1 ; i <= SURROUNDING_NUMBER; i++) {
  +    -   if ((max_page - current) > i )
  +          - params.page = current + i
  +          li
  +            a(href=link_to(route, params)) #{current + i}
  +    - }
   
  -    - if ((max_page - current) >= 2)
  -      - params.page = current + 2
  -      li
  -        a(href=link_to(route, params))  #{current + 2}
  -
  -    - if (max_page - current > 3)
  +    //- right ellipsis displayed, if exists 1+ pages between last page
  +    //- and surrounding pages
  +    - if (max_page - current > SURROUNDING_NUMBER + 1)
         li.dropdown
           - delete(params.page)
           a.more.dropdown-toggle(href=link_to(route, params), data-toggle='dropdown') ...
  
positive.code: //- Create pagination
  //-
  //-   route  (String)  - routing rule. Ex: "forum.thread".
  
negative.code:           .input-append
              input.input-small(id=pgmpid, type='text', size='8', placeholder='Page number')
              button.btn.btn-inverse(type='button') Go!
  
      //- last page displayed always, but current
      - if (max_page - current !== 0)
        - params.page = max_page
        li
          a(href=link_to(route, params)) #{max_page}
  