drime

French rhyme dictionary with web and CLI interface
git clone https://a3nm.net/git/drime/
Log | Files | Refs | README

page.html (3312B)


      1 <!DOCTYPE html>
      2 <html dir="ltr" lang="en-US">
      3   <head>
      4     <title>{{ title }}</title>
      5     <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
      6     <meta name="viewport" content="width=device-width, initial-scale=1" />
      7 {% if lang == 'fr' %}
      8     <meta name="description" content="dictionnaire de rimes drime" />
      9 {% else %}
     10     <meta name="description" content="drime rhyme dictionary" />
     11 {% endif %}
     12     <link rel="stylesheet" href="static/main.css" type="text/css" media="screen" />
     13     <link rel="stylesheet" href="static/style.css" type="text/css" media="screen" />
     14     <link rel="stylesheet" media="(max-width: 800px)" href="static/mobile.css" />
     15     <script type="text/javascript" src="static/jquery.js"></script>
     16     <script type="text/javascript" src="static/jquery.tablesorter.js"></script>
     17     <script type="text/javascript" id="js">$(document).ready(function() {
     18         $("#results").tablesorter({
     19                 sortList: [[2,1],[3,1],[4,1],[0,0]],
     20                 widgets: ['zebra']
     21         });
     22 }); </script>
     23   </head>
     24   <body>
     25     <header>
     26     <h1><a href="/">drime</a></h1>
     27     <sup><a id="about" href="/about">
     28         {% if lang == 'fr' %}
     29         aide
     30         {% else %}
     31         help
     32         {% endif %}
     33     </a></sup>
     34     {% if not noform %}
     35     <form method="GET" action="query">
     36       <input id="query" name="query"
     37   {% if lang == 'fr' %}
     38       placeholder="mot"
     39   {% else %}
     40       placeholder="word"
     41   {% endif %}
     42         value="{{ q }}"/>
     43       <input id="nsyl" name="nsyl"
     44   {% if lang == 'fr' %}
     45       placeholder="n_syllabes"
     46   {% else %}
     47       placeholder="n_syllables"
     48   {% endif %}
     49         value="{{ nsyl }}"/>
     50         <label id="gender_label">
     51       <input type="checkbox" id="gender" name="gender"
     52         {% if (mode != 'query') or gender == 'on' %}
     53         checked="{{ gender }}"
     54         {% endif %}
     55         />
     56   {% if lang == 'fr' %}
     57       genre&nbsp;?
     58   {% else %}
     59       gender?
     60   {% endif %}
     61       </label>
     62         <label id="classical_label">
     63       <input type="checkbox" id="classical" name="classical"
     64         {% if (mode != 'query') or classical == 'on' %}
     65         checked="{{ classical }}"
     66         {% endif %}
     67         />
     68   {% if lang == 'fr' %}
     69       classique&nbsp;?
     70   {% else %}
     71       classical?
     72   {% endif %}
     73       </label>
     74       <input type="submit"
     75   {% if lang == 'fr' %}
     76     value="Chercher"
     77   {% else %}
     78     value="Search"
     79   {% endif %}
     80       />
     81     </form>
     82     {% endif %}
     83 
     84     {% if result %}
     85 <p id="result_header">
     86 {% if lang == 'fr' %}
     87 Voici
     88 {% else %}
     89 Here are
     90 {% endif %}
     91 {{ displayed }}
     92 {% if lang == 'fr' %}
     93 résultat{% if displayed > 1 %}s{% endif %}
     94 {% else %}
     95 result{% if displayed != 1 %}s{% endif %}
     96 {% endif %}
     97 {# results
     98 {{ page * pagesize + 1 }} to {{ (page+1) * pagesize }} #}
     99 {% if displayed < count %}
    100 {% if lang == 'fr' %}
    101 sur 
    102 {% else %}
    103 out of 
    104 {% endif %}
    105 ≈{{ count }}
    106 {% endif %}
    107 {% if lang == 'fr' %}
    108 pour&nbsp;:
    109 {% else %}
    110 for:
    111 {% endif %}
    112 <strong>{{ keys[0][-1] }}</strong>
    113 {% if not sure %}
    114 <sup class="warning">
    115 {% if lang == 'fr' %}
    116 <a href="/about#badpron" class="darklink">incorrect&nbsp;?</a>
    117 {% else %}
    118 <a href="/about#badpron" class="darklink">incorrect?</a>
    119 {% endif %}
    120 </sup>
    121 {% endif %}
    122 </p>
    123 {%endif%}
    124 
    125     </header>
    126     <div id="body">
    127     {% block body %}
    128     {% endblock %}
    129     </div>
    130   </body>
    131 </html>