Sfoglia il codice sorgente

Set `autofocus` on inputs

JC Brand 7 anni fa
parent
commit
2203e9505a
2 ha cambiato i file con 2 aggiunte e 2 eliminazioni
  1. 1 1
      src/templates/login_panel.html
  2. 1 1
      src/templates/register_panel.html

+ 1 - 1
src/templates/login_panel.html

@@ -8,7 +8,7 @@
         {[ if (authentication == LOGIN || authentication == EXTERNAL) { ]}
             <label>{{{__("Jabber ID:")}}}</label>
             <p class="form-help fade-in invalid-jid-msg error hidden">{{{_('Please enter a valid XMPP address')}}}</p>
-            <input type="text" name="jid" placeholder="{{{placeholder_username}}}">
+            <input autofocus type="text" name="jid" placeholder="{{{placeholder_username}}}">
             {[ if (authentication !== EXTERNAL) { ]}
                 <label>{{{__("Password:")}}}</label>
                 <input type="password" name="password" placeholder="{{{__('password')}}}">

+ 1 - 1
src/templates/register_panel.html

@@ -9,7 +9,7 @@
     	{{{default_domain}}}
     {[ } ]}
     {[ if (!default_domain) { ]}
-    	<input type="text" name="domain" placeholder="{{{domain_placeholder}}}">
+    	<input autofocus type="text" name="domain" placeholder="{{{domain_placeholder}}}">
         <input class="pure-button button-primary" type="submit" value="{{{label_register}}}">
     {[ } ]}
 </form>