|
|
|
@ -70,19 +70,55 @@ |
|
|
|
|
<tr class="bg-white border-t hover:bg-gray-50"> |
|
|
|
|
<td class="py-4 pl-5 pr-5 bold">Old Password</td> |
|
|
|
|
<td td class="py-4 pr-5 w-2/3"> |
|
|
|
|
<input class="w-full aappearance-none bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg outline-none focus:ring-blue-500 focus:border-blue-500 w-full block p-2.5" type="text" name="oldpassword"> |
|
|
|
|
<div class="relative w-full"> |
|
|
|
|
<div class="absolute inset-y-0 right-0 flex items-center px-2"> |
|
|
|
|
<input class="hidden js-password-toggle" id="toggle-old" type="checkbox" /> |
|
|
|
|
<label class="px-2 py-1 text-sm text-gray-600 font-mono cursor-pointer js-password-label" for="toggle-old" id="input-old-label"> |
|
|
|
|
<svg xmlns="http://www.w3.org/2000/svg" height="20" width="20" viewBox="0 0 24 24"> |
|
|
|
|
<g fill="#8896ab"> |
|
|
|
|
<path d="M23.444,10.239C21.905,8.062,17.708,3,12,3S2.1,8.062.555,10.24a3.058,3.058,0,0,0,0,3.52h0C2.1,15.938,6.292,21,12,21s9.905-5.062,11.445-7.24A3.058,3.058,0,0,0,23.444,10.239ZM12,17a5,5,0,1,1,5-5A5,5,0,0,1,12,17Z" fill="#8896ab"></path> |
|
|
|
|
</g> |
|
|
|
|
</svg> |
|
|
|
|
</label> |
|
|
|
|
</div> |
|
|
|
|
<input class="w-full aappearance-none bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg outline-none focus:ring-blue-500 focus:border-blue-500 w-full block p-2.5" type="password" name="oldpassword" id="input-old"> |
|
|
|
|
</div> |
|
|
|
|
</td> |
|
|
|
|
</tr> |
|
|
|
|
<tr class="bg-white border-t hover:bg-gray-50"> |
|
|
|
|
<td class="py-4 pl-5 pr-5 bold">New Password</td> |
|
|
|
|
<td td class="py-4 pr-5 w-2/3"> |
|
|
|
|
<input class="w-full aappearance-none bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg outline-none focus:ring-blue-500 focus:border-blue-500 w-full block p-2.5" type="text" name="newpassword"> |
|
|
|
|
<div class="relative w-full"> |
|
|
|
|
<div class="absolute inset-y-0 right-0 flex items-center px-2"> |
|
|
|
|
<input class="hidden js-password-toggle" id="toggle-new" type="checkbox" /> |
|
|
|
|
<label class="px-2 py-1 text-sm text-gray-600 font-mono cursor-pointer js-password-label" for="toggle-new" id="input-new-label"> |
|
|
|
|
<svg xmlns="http://www.w3.org/2000/svg" height="20" width="20" viewBox="0 0 24 24"> |
|
|
|
|
<g fill="#8896ab"> |
|
|
|
|
<path d="M23.444,10.239C21.905,8.062,17.708,3,12,3S2.1,8.062.555,10.24a3.058,3.058,0,0,0,0,3.52h0C2.1,15.938,6.292,21,12,21s9.905-5.062,11.445-7.24A3.058,3.058,0,0,0,23.444,10.239ZM12,17a5,5,0,1,1,5-5A5,5,0,0,1,12,17Z" fill="#8896ab"></path> |
|
|
|
|
</g> |
|
|
|
|
</svg> |
|
|
|
|
</label> |
|
|
|
|
</div> |
|
|
|
|
<input class="w-full aappearance-none bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg outline-none focus:ring-blue-500 focus:border-blue-500 w-full block p-2.5" type="password" name="newpassword" id="input-new"> |
|
|
|
|
</div> |
|
|
|
|
</td> |
|
|
|
|
</tr> |
|
|
|
|
<tr class="bg-white border-t hover:bg-gray-50"> |
|
|
|
|
<td class="py-4 pl-5 pr-5 bold">Confirm Password</td> |
|
|
|
|
<td td class="py-4 pr-5 w-2/3"> |
|
|
|
|
<input class="w-full aappearance-none bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg outline-none focus:ring-blue-500 focus:border-blue-500 w-full block p-2.5" type="text" name="confirmpassword"> |
|
|
|
|
<div class="relative w-full"> |
|
|
|
|
<div class="absolute inset-y-0 right-0 flex items-center px-2"> |
|
|
|
|
<input class="hidden js-password-toggle" id="toggle-conf" type="checkbox" /> |
|
|
|
|
<label class="px-2 py-1 text-sm text-gray-600 font-mono cursor-pointer js-password-label" for="toggle-conf" id="input-confirm-label"> |
|
|
|
|
<svg xmlns="http://www.w3.org/2000/svg" height="20" width="20" viewBox="0 0 24 24"> |
|
|
|
|
<g fill="#8896ab"> |
|
|
|
|
<path d="M23.444,10.239C21.905,8.062,17.708,3,12,3S2.1,8.062.555,10.24a3.058,3.058,0,0,0,0,3.52h0C2.1,15.938,6.292,21,12,21s9.905-5.062,11.445-7.24A3.058,3.058,0,0,0,23.444,10.239ZM12,17a5,5,0,1,1,5-5A5,5,0,0,1,12,17Z" fill="#8896ab"></path> |
|
|
|
|
</g> |
|
|
|
|
</svg> |
|
|
|
|
</label> |
|
|
|
|
</div> |
|
|
|
|
<input class="w-full aappearance-none bg-gray-50 border border-gray-300 text-gray-900 text-sm rounded-lg outline-none focus:ring-blue-500 focus:border-blue-500 w-full block p-2.5" type="password" name="confirmpassword" id="input-confirm"> |
|
|
|
|
</div> |
|
|
|
|
</td> |
|
|
|
|
</tr> |
|
|
|
|
</table> |
|
|
|
@ -111,5 +147,32 @@ |
|
|
|
|
</div> |
|
|
|
|
</section> |
|
|
|
|
{% include 'footer.html' %} |
|
|
|
|
<script> |
|
|
|
|
function togglePassword(event) { |
|
|
|
|
let input_name = 'input-new'; |
|
|
|
|
if (event.target.id == 'toggle-old') { |
|
|
|
|
input_name = 'input-old'; |
|
|
|
|
} else |
|
|
|
|
if (event.target.id == 'toggle-conf') { |
|
|
|
|
input_name = 'input-confirm'; |
|
|
|
|
} |
|
|
|
|
const password = document.getElementById(input_name), |
|
|
|
|
passwordLabel = document.getElementById(input_name + '-label'); |
|
|
|
|
if (password.type === 'password') { |
|
|
|
|
password.type = 'text'; |
|
|
|
|
passwordLabel.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" height="20" width="20" viewBox="0 0 24 24"><g fill="#8896ab"><path d="M23.444,10.239a22.936,22.936,0,0,0-2.492-2.948l-4.021,4.021A5.026,5.026,0,0,1,17,12a5,5,0,0,1-5,5,5.026,5.026,0,0,1-.688-.069L8.055,20.188A10.286,10.286,0,0,0,12,21c5.708,0,9.905-5.062,11.445-7.24A3.058,3.058,0,0,0,23.444,10.239Z" fill="#8896ab"></path><path d="M12,3C6.292,3,2.1,8.062.555,10.24a3.058,3.058,0,0,0,0,3.52h0a21.272,21.272,0,0,0,4.784,4.9l3.124-3.124a5,5,0,0,1,7.071-7.072L8.464,15.536l10.2-10.2A11.484,11.484,0,0,0,12,3Z" fill="#8896ab"></path><path data-color="color-2" d="M1,24a1,1,0,0,1-.707-1.707l22-22a1,1,0,0,1,1.414,1.414l-22,22A1,1,0,0,1,1,24Z"></path></g></svg>'; |
|
|
|
|
} else { |
|
|
|
|
password.type = 'password'; |
|
|
|
|
passwordLabel.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" height="20" width="20" viewBox="0 0 24 24"><g fill="#8896ab" ><path d="M23.444,10.239C21.905,8.062,17.708,3,12,3S2.1,8.062.555,10.24a3.058,3.058,0,0,0,0,3.52h0C2.1,15.938,6.292,21,12,21s9.905-5.062,11.445-7.24A3.058,3.058,0,0,0,23.444,10.239ZM12,17a5,5,0,1,1,5-5A5,5,0,0,1,12,17Z" fill="#8896ab"></path></g></svg>'; |
|
|
|
|
} |
|
|
|
|
password.focus(); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
const toggles = ["toggle-old", "toggle-new", "toggle-conf"] |
|
|
|
|
toggles.forEach(function (toggle_id, index) { |
|
|
|
|
document.getElementById(toggle_id).addEventListener('change', togglePassword, false); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
</script> |
|
|
|
|
</body> |
|
|
|
|
</html> |