diff default/input/field.html @ 86:92ca411ee635

chat: new chat_select page to select a jid to talk to + improved button style
author Goffi <goffi@goffi.org>
date Fri, 05 Jan 2018 13:14:22 +0100
parents f76ec90e0e1e
children da8f1ba9034d
line wrap: on
line diff
--- a/default/input/field.html	Wed Jan 03 01:12:16 2018 +0100
+++ b/default/input/field.html	Fri Jan 05 13:14:22 2018 +0100
@@ -8,7 +8,7 @@
 
 {% macro int(name, label="", init=0) %}
     <span class="form_input">
-        <label id="{{name|next_gidx}}">{{label}}</label><input id="{{name|cur_gidx}}" type="number" name="{{name}}" value="{{init}}" step="1" min="0">
+        <label for="{{name|next_gidx}}">{{label}}</label><input id="{{name|cur_gidx}}" type="number" name="{{name}}" value="{{init}}" step="1" min="0">
     </span>
 {% endmacro %}
 
@@ -16,7 +16,7 @@
     {# single line text field
        additional kwargs will be passed as attributes #}
     <span class="form_input">
-        <label id="{{name|next_gidx}}">{{label}}</label><input id="{{name|cur_gidx}}" type="text" name="{{name}}" placeholder="{{placeholder}}" {{"required" if required}} {{kwargs|xmlattr}}>
+        <label for="{{name|next_gidx}}">{{label}}</label><input id="{{name|cur_gidx}}" type="text" name="{{name}}" placeholder="{{placeholder}}" {{"required" if required}} {{kwargs|xmlattr}}>
     </span>
 {% endmacro %}
 
@@ -24,7 +24,7 @@
     {# password field
        additional kwargs will be passed as attributes #}
     <span class="form_input">
-        <label id="{{name|next_gidx}}">{{label}}</label><input id="{{name|cur_gidx}}" type="password" name="{{name}}" {{"required" if required}} {{kwargs|xmlattr}}>
+        <label for="{{name|next_gidx}}">{{label}}</label><input id="{{name|cur_gidx}}" type="password" name="{{name}}" {{"required" if required}} {{kwargs|xmlattr}}>
     </span>
 {% endmacro %}
 
@@ -32,7 +32,7 @@
     {# email field
        additional kwargs will be passed as attributes #}
     <span class="form_input">
-        <label id="{{name|next_gidx}}">{{label}}</label><input id="{{name|cur_gidx}}" type="email" name="{{name}}" {{"required" if required}} {{kwargs|xmlattr}}>
+        <label for="{{name|next_gidx}}">{{label}}</label><input id="{{name|cur_gidx}}" type="email" name="{{name}}" {{"required" if required}} {{kwargs|xmlattr}}>
     </span>
 {% endmacro %}