Add labels

Poeple seem to forget wat those fields are for mid-way through filling
the form. The place holder stuff is not overly obvious apparently.

This makes it consistent with all our other UI nevertheless
This commit is contained in:
Girish Ramakrishnan
2018-06-04 20:08:37 -07:00
parent 7ac99f16cd
commit a76631ee3d
2 changed files with 11 additions and 5 deletions

View File

@@ -62,22 +62,28 @@
<div class="row">
<div class="col-md-12 text-center">
<h1>Welcome to Cloudron</h1>
<h3>Create an Admin Account</h3>
<h3>Setup Admin Account</h3>
</div>
</div>
<br/>
<br/>
<div class="row">
<div class="col-md-8 col-md-offset-2 text-center">
<div class="col-md-6 col-md-offset-3">
<div class="form-group" ng-class="{ 'has-error': setupForm.displayName.$dirty && setupForm.displayName.$invalid }">
<input type="text" class="form-control" ng-model="account.displayName" id="inputDisplayName" name="displayName" placeholder="Display Name" required autocomplete="off" autofocus>
<label class="control-label">Full Name</label>
<input type="text" class="form-control" ng-model="account.displayName" id="inputDisplayName" name="displayName" placeholder="Full Name" required autocomplete="off" autofocus>
</div>
<div ng-show="account.requireEmail" class="form-group" ng-class="{ 'has-error': setupForm.email.$dirty && setupForm.email.$invalid }">
<label class="control-label">Email <sup><a href="https://cloudron.io/documentation/installation/#administrator-setup" class="help" target="_blank"><i class="fa fa-question-circle"></i></a></sup></label>
<input type="email" class="form-control" ng-model="account.email" id="inputEmail" name="email" placeholder="Email" required autocomplete="off" tooltip-trigger="focus" uib-tooltip="This email address is local to your Cloudron and used for notifications and password reset. A valid email is also required for Let's Encrypt certificates.">
</div>
<div class="form-group" ng-class="{ 'has-error': (setupForm.username.$dirty && setupForm.username.$invalid) || (!setupForm.username.$dirty && error.username) }">
<label class="control-label">Username</label>
<p ng-show="!setupForm.username.$dirty && error.username">{{ error.username }}</p>
<input type="text" class="form-control" ng-model="account.username" id="inputUsername" name="username" placeholder="Username" ng-maxlength="512" ng-minlength="3" required autocomplete="off">
</div>
<div class="form-group" ng-class="{ 'has-error': setupForm.password.$dirty && setupForm.password.$invalid }">
<label class="control-label">Password</label>
<input type="password" class="form-control" ng-model="account.password" id="inputPassword" name="password" placeholder="Password" ng-pattern="/^(?=.*\d)(?=.*[a-z])(?=.*[A-Z])(?=.*[^a-zA-Z0-9])(?!.*\s).{8,30}$/" required autocomplete="off">
<div class="control-label" ng-show="setupForm.password.$dirty && setupForm.password.$invalid">
<small ng-show="setupForm.password.$dirty && setupForm.password.$invalid">Password must be 8-30 character with at least one uppercase, one numeric and one special character</small>
@@ -86,9 +92,10 @@
</div>
</div>
<br/>
<br/>
<div class="row">
<div class="col-md-12 text-center">
<input type="submit" class="btn btn-primary" ng-disabled="setupForm.$invalid" value="Done">
<input type="submit" class="btn btn-success" ng-disabled="setupForm.$invalid" value="Done">
</div>
</div>
<br/>