From dff2b416feb5a6514c984d0e3aea82d63e4257b9 Mon Sep 17 00:00:00 2001
From: Stefano Alberto Russo <stefano.russo@gmail.com>
Date: Fri, 5 Nov 2021 02:55:07 +0100
Subject: [PATCH] UI imporvements in password fields.

---
 .../code/rosetta/core_app/templates/create_task.html |  2 +-
 .../rosetta/core_app/templates/task_connect.html     | 12 ++++++------
 2 files changed, 7 insertions(+), 7 deletions(-)

diff --git a/services/webapp/code/rosetta/core_app/templates/create_task.html b/services/webapp/code/rosetta/core_app/templates/create_task.html
index b05291f..b2912bc 100644
--- a/services/webapp/code/rosetta/core_app/templates/create_task.html
+++ b/services/webapp/code/rosetta/core_app/templates/create_task.html
@@ -93,7 +93,7 @@
             <td valign="top"><b>Task&nbsp;password</b></td>
             <td>
             
-             <input type="password" name="task_auth_password" placeholder="{{data.task_auth_token}}" size="37" /><br>
+             <input type="text" name="task_auth_password" placeholder="{{data.task_auth_token}}" size="37" style="-webkit-text-security: disc;" /><br>
              <input type="hidden" name="task_auth_token" value="{{data.task_auth_token}}">
 
              <!-- <font size=-1>A one-time task password. By default set to a randomly generated token, and automatically handled by Rosetta. Can be also set to a custom one, which in this case will be required to be entered manually when connecting to the task (as it will not be stored by Rosetta). Six characters minimum.</font> -->
diff --git a/services/webapp/code/rosetta/core_app/templates/task_connect.html b/services/webapp/code/rosetta/core_app/templates/task_connect.html
index 6d96124..b4cbda0 100644
--- a/services/webapp/code/rosetta/core_app/templates/task_connect.html
+++ b/services/webapp/code/rosetta/core_app/templates/task_connect.html
@@ -3,7 +3,7 @@
 {% include "navigation.html"%}
 <!-- with body_args="style='background: #202020'" -->
     <center>
-    <div style="width:300px;">
+    <div style="width:370px;">
       <form class="form-signin" role="form" action='/direct_connect/{{data.task.uuid}}/' method='POST'>
         {% csrf_token %}
         <br />
@@ -13,15 +13,15 @@
         <h2> Connecting to task <b>{{ data.task.name }}</b></h2>
         <p style="font-size: 16px;">
         <br />
-        User: <input style="margin-bottom:5px;" type="username" class="form-control" value="{{ request.user.email }}"name='username' disabled >
+        User: <input style="margin-bottom:15px;" type="username" class="form-control" value="{{ request.user.email }}"name='username' readonly >
         
         
         {% if data.task.requires_proxy_auth %}
         
           {% if data.task.auth_token %}
-          Password: <input type="text" class="form-control" placeholder="" value="{{data.task.auth_token}}" name='password' disabled>
+          Password: <input type="text" size=37 class="form-control" placeholder="" value="{{data.task.auth_token}}" name='password' readonly>
           {% else %}
-          Password: <input type="password" class="form-control" placeholder="" value="placeholder" name='password' disabled>
+          Password: <input type="password" class="form-control" placeholder="" value="placeholder" name='password' readonly>
           <p style="margin-left:10px; font-size:0.9em; color:#484848">
           <i class="fa fa-info-circle" style="color:#337ab7"></i>
           This task will require to manually enter the password set up when creating the task
@@ -31,13 +31,13 @@
         {% else %}
         
           {% if data.task.auth_token %}
-          Password: <input type="text" class="form-control" placeholder="" value="{{data.task.auth_token}}" name='password' disabled>
+          Password: <input type="text" class="form-control" placeholder="" value="{{data.task.auth_token}}" name='password' readonly>
           <p style="margin-left:10px; font-size:0.9em; color:#484848">
           <i class="fa fa-info-circle" style="color:#337ab7"></i>
           This task will require to manually enter the above user and password token
           </p> 
           {% else %}
-          Password: <input type="password" class="form-control" placeholder="" value="placeholder" name='password' disabled>
+          Password: <input type="password" class="form-control" placeholder="" value="placeholder" name='password' readonly>
           <p style="margin-left:10px; font-size:0.9em; color:#484848">
           <i class="fa fa-info-circle" style="color:#337ab7"></i>
           This task will require to manually enter the above user and the password set up when creating the task
-- 
GitLab