Bug fixes and buttons for previous and next page

* Use buttons for next and previous page in search results
* Add custom routine for stringifying and parsing the selector to JSON
so RegExp objects are preserved
This commit is contained in:
John R. Supplee 2021-01-27 16:15:54 +02:00
parent 4e8fc46475
commit 78a1d08a17
6 changed files with 74 additions and 15 deletions

View file

@ -37,12 +37,16 @@ template(name="globalSearch")
a.fa.fa-link(title="{{_ 'link-to-search' }}" href="{{ getSearchHref }}")
each card in results.get
+resultCard(card)
if hasPreviousPage.get
button.js-previous-page
| {{_ 'previous-page' }}
if hasNextPage.get
button.js-next-page
| {{_ 'next-page' }}
table.global-search-footer
tr
td.global-search-previous-page
if hasPreviousPage.get
button.js-previous-page
| {{_ 'previous-page' }}
td.global-search-next-page(align="right")
if hasNextPage.get
button.js-next-page
| {{_ 'next-page' }}
else
.global-search-instructions
h2 {{_ 'boards' }}