btrask / stronglink

A searchable, syncable, content-addressable notetaking system
Other
1.04k stars 39 forks source link

Blog: hide next/prev page links when nothing more is available #32

Open btrask opened 9 years ago

btrask commented 9 years ago

This is a very minor issue but it's ugly and I bet people will complain about it.

If we have a start URI, we know we should show the button representing the direction we came from. That's because the start URI is never included in the current page.

When fetching results, we should fetch one extra and use that to determine whether there's a subsequent page for the other button.

These links should also be improved by using a real query string formatter.

btrask commented 8 years ago

We don't currently hide individual page buttons, but we started hiding the whole set of them if there can't be any other pages. We also display a "no results found" message if you go past the first or last page, which is what some other blog software does.