mirror of
https://github.com/YunoHost/yunohost-admin.git
synced 2024-09-03 20:06:15 +02:00
Merge pull request #212 from YunoHost/good_practices_about_passwords
Add comments about good practices for choosing passwords
This commit is contained in:
commit
61d516be83
7 changed files with 14 additions and 2 deletions
|
@ -340,6 +340,7 @@
|
|||
// Default values
|
||||
args[k].type = (typeof v.type !== 'undefined') ? v.type : 'string';
|
||||
args[k].inputType = 'text';
|
||||
args[k].isPassword = false;
|
||||
args[k].required = (typeof v.optional !== 'undefined' && v.optional == "true") ? '' : 'required';
|
||||
args[k].attributes = "";
|
||||
args[k].helpText = "";
|
||||
|
@ -458,6 +459,7 @@
|
|||
if (v.name == 'password' || args[k].type == 'password') {
|
||||
// Change html input type
|
||||
args[k].inputType = 'password';
|
||||
args[k].isPassword = true;
|
||||
}
|
||||
|
||||
});
|
||||
|
|
|
@ -149,6 +149,8 @@
|
|||
"free": "Free",
|
||||
"fs_type": "FS Type",
|
||||
"gateway": "Gateway: ",
|
||||
"good_practices_about_admin_password": "You are now about to define a new admin password. The password should be at least 8 characters - though it is good practice to use longer password (i.e. a passphrase) and/or to use various kind of characters (uppercase, lowercase, digits and special characters).",
|
||||
"good_practices_about_user_password": "You are now about to define a new user password. The password should be at least 8 characters - though it is good practice to use longer password (i.e. a passphrase) and/or to use various kind of characters (uppercase, lowercase, digits and special characters).",
|
||||
"home": "Home",
|
||||
"hook_adminjs_group_configuration": "Configuration",
|
||||
"hook_conf_cron": "Regular tasks",
|
||||
|
|
|
@ -41,11 +41,15 @@
|
|||
<div class="form-group">
|
||||
<label for="{{name}}" class="col-sm-12">{{label}}</label>
|
||||
|
||||
|
||||
{{#if helpText}}
|
||||
<span class="help-block help-block--help col-sm-12">{{{helpText}}}</span>
|
||||
{{/if}}
|
||||
|
||||
<div class="col-sm-12">
|
||||
{{#if isPassword}}
|
||||
<p class="text-warning">{{t 'good_practices_about_admin_password'}}</p>
|
||||
{{/if}}
|
||||
|
||||
{{#if choices}}
|
||||
<select id="{{name}}" name="{{name}}" required class="form-control" {{{attributes}}}>
|
||||
|
|
|
@ -7,6 +7,8 @@
|
|||
<div class="panel panel-default">
|
||||
<div class="panel-body">
|
||||
|
||||
<div class="alert alert-warning">{{t 'good_practices_about_admin_password'}}</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="password" class="col-sm-4 control-label">{{t 'administration_password'}}</label>
|
||||
<div class="col-sm-8">
|
||||
|
|
|
@ -6,6 +6,8 @@
|
|||
|
||||
<div class="separator"></div>
|
||||
|
||||
<div class="alert alert-warning">{{t 'good_practices_about_admin_password'}}</div>
|
||||
|
||||
<form action="#/tools/adminpw" method="PUT" class="form-horizontal">
|
||||
|
||||
<div class="panel panel-default">
|
||||
|
|
|
@ -65,7 +65,7 @@
|
|||
<label for="confirmation" class="col-sm-3 control-label">{{t 'password_confirmation'}}</label>
|
||||
<div class="col-sm-9">
|
||||
<input type="password" id="confirmation" name="confirmation" class="form-control" placeholder="•••••" required>
|
||||
<div class="help-block">{{t 'password_description' password_min_length}}</div>
|
||||
<div class="help-block">{{t 'good_practices_about_user_password'}}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
@ -89,7 +89,7 @@
|
|||
<label for="confirmation" class="col-sm-3 control-label">{{t 'password_confirmation'}}</label>
|
||||
<div class="col-sm-9">
|
||||
<input type="password" id="confirmation" name="confirmation" class="form-control" placeholder="•••••">
|
||||
<div class="help-block">{{t 'password_description' password_min_length}}</div>
|
||||
<div class="help-block">{{t 'good_practices_about_user_password'}}</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
|
Loading…
Reference in a new issue