]> git.ipfire.org Git - pbs.git/commitdiff
Refactor search page
authorMichael Tremer <michael.tremer@ipfire.org>
Wed, 1 Jun 2022 17:02:25 +0000 (17:02 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Wed, 1 Jun 2022 17:02:25 +0000 (17:02 +0000)
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/templates/search-form.html

index ae754760b977c4e3a4689dd2b5700907801c4e82..320bbaa1c6dc979488efa155a90e6ff076214eae 100644 (file)
@@ -1,36 +1,34 @@
 {% extends "base.html" %}
 
-{% block title %}{{ _("Advanced search") }}{% end block %}
+{% block title %}{{ _("Search") }}{% end block %}
 
-{% block body %}
-       <nav aria-label="breadcrumb" role="navigation">
-               <ol class="breadcrumb">
-                       <li class="breadcrumb-item"><a href="/">{{ _("Home") }}</a></li>
-                       <li class="breadcrumb-item active">
-                               <a href="/search">{{ _("Search") }}</a>
+{% block container %}
+       <nav aria-label="{{ _("You are here:") }}" role="navigation">
+               <ul class="breadcrumbs">
+                       <li>
+                               <a href="/">{{ _("Home") }}</a>
                        </li>
-               </ol>
+                       <li>
+                               <span class="show-for-sr">{{ _("Current") }}: </span> {{ _("Search") }}
+                       </li>
+               </ul>
        </nav>
 
-       {% if pattern %}
-               <h2 style="word-wrap: break-word;">
-                       {{ _("No results for '%s'.") % pattern }}
-               </h2>
-       {% else %}
-               <h2 style="word-wrap: break-word;">
-                       {{ _("Search") }}
-               </h2>
-
-               <p class="">
-                       {{ _("Type a search pattern into the box below and hit the button.") }}
-               </p>
-       {% end %}
+       <div class="grid-x grid-padding-x">
+               <div class="cell large-6 float-center">
+                       <form method="GET" action="/search">
+                               <div class="input-group">
+                                       <input type="text" class="input-group-field"
+                                               name="q" value="{{ pattern }}"
+                                               placeholder="{{ _("Search") }}">
 
-       <form class="form-inline" method="GET" action="/search">
-               <div class="form-group">
-                       <input type="text" class="form-control mr-2" id="q" name="q" placeholder="{{ _("Search") }}"
-                               value="{{ pattern }}">
+                                       <div class="input-group-button">
+                                               <button type="submit" class="primary button">
+                                                       {{ _("Go!") }}
+                                               </button>
+                                       </div>
+                               </div>
+                       </form>
                </div>
-               <button type="submit" class="btn btn-primary">{{ _("Go!") }}</button>
-       </form>
+       </div>
 {% end block %}