geminispace.info

gemini search engine
git clone https://git.clttr.info/geminispace.info.git
Log (Feed) | Files | Refs (Tags) | README | LICENSE

commit 3679863e4070931a32c9be7519707f2dbb4c25d5
parent 220709fdd46669fb36fdc321dc82f95205fe0b2d
Author: Natalie Pendragon <natpen@natpen.net>
Date:   Thu, 16 Apr 2020 18:18:25 -0400

[serve] Update formatting

Diffstat:
Mgus/serve.py | 10+++-------
1 file changed, 3 insertions(+), 7 deletions(-)

diff --git a/gus/serve.py b/gus/serve.py @@ -16,9 +16,8 @@ app = jetforce.JetforceApplication() def _render_header(): return [ - "------------GUS------------", - "| Gemini Universal Search |", - "===========================", + "# GUS - Gemini Universal Search", + "", "=> / Home", "=> /search Search GUS" ] @@ -109,7 +108,7 @@ def _render_results(results): def _render_results_header(query, num_results): return [ "", - "> \"{}\" - {} hits".format(query, num_results), + "## \"{}\" - {} hits".format(query, num_results), "" ] @@ -117,15 +116,12 @@ def _render_results_header(query, num_results): def _render_results_footer(num_results): data = [ "", - "===========================", ] num_pages = math.ceil(num_results / 10) current_page = 1 if num_results == 0: current_page = 0 paging_feature_note = "" - if num_pages > 1: - paging_feature_note = " (paging coming soon)" data.append("Page {} of {}{}".format(current_page, num_pages, paging_feature_note)) return data