Skip to content
This repository has been archived by the owner on Apr 6, 2023. It is now read-only.

Commit

Permalink
fix: modify styles, logos, validations styles and add eye to show pas…
Browse files Browse the repository at this point in the history
…sword
  • Loading branch information
ignaciorodrigues1 committed Mar 25, 2019
1 parent 696ed8c commit 1eb8c36
Show file tree
Hide file tree
Showing 10 changed files with 108 additions and 20 deletions.
13 changes: 13 additions & 0 deletions assets/icons/hide.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
20 changes: 11 additions & 9 deletions assets/icons/view.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
File renamed without changes
17 changes: 17 additions & 0 deletions assets/js/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,3 +52,20 @@ $("#btn-modal-small").click(function() {
$(".modal .close").click(function() {
$(".modal").fadeOut();
});


// script to show and hide password
$(".show-hide").click(function() {
$(this).toggleClass("ms-icon icon-hide");
var input = $($(this).attr("toggle"));

if (input.attr("type") == "password") {
input.attr("type", "text");
$('span.content-eye').text('Ocultar');
$(this).removeClass("ms-icon icon-view").addClass("ms-icon icon-hide");
} else {
input.attr("type", "password");
$('span.content-eye').text('Mostrar');
$(this).removeClass("ms-icon icon-hide").addClass("ms-icon icon-view");
}
});
40 changes: 39 additions & 1 deletion assets/scss/core/_base.scss
Original file line number Diff line number Diff line change
Expand Up @@ -112,12 +112,17 @@ textarea {

&__checkbox {
cursor: pointer;
margin-bottom: $dp-spaces--lv3;

label {
font-weight: normal;
vertical-align: middle;
margin-left: $dp-spaces--lv4;
}

&:nth-last-child(1) {
margin-bottom: $dp-spaces--lv4;
}
}/* Field checkbox */

&--50 {
Expand All @@ -127,6 +132,26 @@ textarea {
padding-right: $dp-spaces--lv3;
}
}/* Field to 50% percent */


.show-hide {
float: right;
font-size: $dp-font-size-small;
font-weight: normal;
font-style: italic;
color: $dp-color-grey;
line-height: $dp-font-small-lineheight;
vertical-align: bottom;

&:hover {
opacity: 0.7;
}
}

.content-eye {
font-family: $dp-font-family-proximanova;
font-size: $dp-font-size-small;
}
}
}

Expand All @@ -147,12 +172,24 @@ input[type='checkbox'] {
}
}
}

&:focus {
& ~ .checkmark {
color: $dp-color-default;
border: 1px solid $dp-color-yellow;
border-radius: $dp-border-radius;
-webkit-box-shadow: 0 0 0 2px $dp-color-brown-brightness;
box-shadow: 0 0 0 2px $dp-color-brown-brightness;
outline: none;
}
}
}

input:not([type='checkbox']) {
padding: 10px 12px;
height: 40px;
width: 100%;
color: $dp-color-grey;
border: 1px solid $dp-color-lightgrey;
border-radius: $dp-border-radius;
background-color: $dp-color-white;
Expand Down Expand Up @@ -200,7 +237,8 @@ input[type="tel"] {
.error {
input,
select,
textarea {
textarea,
.checkmark {
border: 1px solid $dp-color-red;
}

Expand Down
18 changes: 18 additions & 0 deletions assets/scss/modules/_atomic-class.scss
Original file line number Diff line number Diff line change
Expand Up @@ -42,3 +42,21 @@
.m-bottom--lv8 {
margin-bottom: $dp-spaces--lv8;
}

.logo-doppler-new {
display: inline-block;
background-image: url('../img/doppler-logo-new.svg');
background-repeat: no-repeat;
height: 40px;
width: 145px;
text-indent: -99em;
}

.logo-doppler-old {
display: inline-block;
background-image: url('../img/doppler-logo-old.svg');
background-repeat: no-repeat;
height: 30px;
width: 85px;
text-indent: -99em;
}
2 changes: 1 addition & 1 deletion assets/scss/modules/_forms.scss
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
content: '';
position: absolute;
left: 4px;
bottom: 9px;
bottom: 10px;
width: 4px;
height: 7px;
border: solid $check-color;
Expand Down
4 changes: 2 additions & 2 deletions assets/scss/templates/_signup.scss
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
.content-signin {
float: right;
display: inline-block;
margin-top: $dp-spaces--lv1;
margin-top: $dp-spaces--lv3;
font-family: $dp-font-family-proximanova;
font-style: italic;

Expand Down Expand Up @@ -54,7 +54,7 @@
}

.content-legal {
margin-top: $dp-spaces--lv5;
margin-top: $dp-spaces--lv4;

p {
font-size: $dp-font-size-rpgd;
Expand Down
14 changes: 7 additions & 7 deletions assets/templates/signup.html
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
<main class="panel-wrapper">
<article class="main-panel">
<header>
<img src="img/doppler-logo.svg" class="logo-doppler" alt="Doppler">
<h1 class="logo-doppler-new">Doppler</h1>
<small class="content-signin">¿Ya tienes una cuenta? <a href="#" class="link-green" target="_blank">INGRESA</a></small>
</header><!-- header -->
<h5>Regístrate</h5>
Expand All @@ -46,14 +46,14 @@ <h5>Regístrate</h5>
<ul class="field-group">
<li class="field-item field-item--50 error">
<label for="name">Nombre:</label>
<input type="name" name="name" id="name" placeholder="Nombre">
<input type="text" name="name" id="name" placeholder="Nombre">
<div class="wrapper-errors bounceIn">
<p class="error-message">¡Ouch! Este campo está vacío</p>
</div>
</li>
<li class="field-item field-item--50 error">
<label for="lastname">Apellido:</label>
<input type="lastname" name="name" id="lastname" placeholder="Apellido">
<input type="text" name="lastname" id="lastname" placeholder="Apellido">
<div class="wrapper-errors bounceIn">
<p class="error-message">¡Ouch! Este campo está vacío</p>
</div>
Expand All @@ -80,12 +80,12 @@ <h5>Regístrate</h5>
</div>
</li>
<li class="field-item">
<label for="password">Contraseña:</label>
<input type="password" name="password" id="password" placeholder="Escribe tu clave secreta">
<label for="password">Contraseña: <a toggle="#password-field" class="ms-icon icon-view show-hide"> <span class="content-eye">Mostrar</a></label>
<input type="password" name="password" id="password-field" placeholder="Escribe tu clave secreta">
<div class="wrapper-password">
<p class="password-message"><span class="waiting-message">8 caracteres como mínimo</span><span class="waiting-message">Un dígito</span></p>
<p class="password-message"><span class="lack-message">8 caracteres como mínimo</span><span class="waiting-message">Un dígito</span></p>
<p class="password-message"><span class="complete-message">8 caracteres como mínimo</span><span class="lack-message">Un dígito</span></p>
<p class="password-message"><span class="lack-message">8 caracteres como mínimo</span><span class="lack-message">Un dígito</span></p>
<p class="password-message"><span class="complete-message">8 caracteres como mínimo</span><span class="complete-message">Un dígito</span></p>
<p class="password-message"><span class="secure-message">¡Tu contraseña es segura!</span></p>
</div><!-- the final container of message validations -->
</li>
Expand Down

0 comments on commit 1eb8c36

Please sign in to comment.