diff options
author | Danny Milosavljevic <dannym@scratchpost.org> | 2019-06-19 17:39:29 +0200 |
---|---|---|
committer | Danny Milosavljevic <dannym@scratchpost.org> | 2019-06-19 17:47:13 +0200 |
commit | d5b827097b456100039370003899ec7ad04ac934 (patch) | |
tree | dd70034376592c898ecd84230528699bbf8dae19 /src | |
parent | 8c91c82e3529a4a479864655a2ac76a90e7f12ad (diff) | |
download | cuirass-d5b827097b456100039370003899ec7ad04ac934.tar cuirass-d5b827097b456100039370003899ec7ad04ac934.tar.gz |
templates: If applicable, disable "Last" and "First" pagination links.
* src/cuirass/templates.scm (pagination): Disable "Last" and "First"
if applicable.
Diffstat (limited to 'src')
-rw-r--r-- | src/cuirass/templates.scm | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/cuirass/templates.scm b/src/cuirass/templates.scm index 342fd13..ab1b85c 100644 --- a/src/cuirass/templates.scm +++ b/src/cuirass/templates.scm @@ -210,7 +210,8 @@ (nav (@ (class "mx-auto") (aria-label "Page navigation")) (ul (@ (class "pagination")) - (li (@ (class "page-item")) + (li (@ (class "page-item" + ,(if (string-null? prev-link) " disabled"))) (a (@ (class "page-link") (href ,first-link)) "<< First")) @@ -224,7 +225,8 @@ (a (@ (class "page-link") (href ,next-link)) "Next >")) - (li (@ (class "page-item")) + (li (@ (class "page-item" + ,(if (string-null? next-link) " disabled"))) (a (@ (class "page-link") (href ,last-link)) "Last >>")))))) |