Skip to content

Commit

Permalink
Improve success message in new newsletter form
Browse files Browse the repository at this point in the history
  • Loading branch information
eddiesigner committed Mar 15, 2020
1 parent ef9e841 commit e8deeb1
Show file tree
Hide file tree
Showing 7 changed files with 59 additions and 16 deletions.
Binary file added assets/images/success.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"with the email address": "with the email address",
"Now check your inbox and click the link to confirm your subscription.": "Now check your inbox and click the link to confirm your subscription.",
"Please enter a valid email address": "Please enter a valid email address",
"Oops! There was an error sending the email, please try later": "Oops! There was an error sending the email, please try later",
"Oops! There was an error sending the email, please try later.": "Oops! There was an error sending the email, please try later.",
"Email cannot be blank.": "Email cannot be blank.",
"Get the latest posts delivered right to your inbox.": "Get the latest posts delivered right to your inbox.",
"Stay up to date! Get all the latest & greatest posts delivered straight to your inbox.": "Stay up to date! Get all the latest & greatest posts delivered straight to your inbox.",
Expand Down
2 changes: 1 addition & 1 deletion locales/es.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"with the email address": "con la dirección de correo electrónico",
"Now check your inbox and click the link to confirm your subscription.": "Ahora revisa tu bandeja de entrada y haz click en el enlace para confirmar tu suscripción.",
"Please enter a valid email address": "Por favor introduce una dirección de correo electrónico válida",
"Oops! There was an error sending the email, please try later": "Oops! Ha ocurrido un error, por favor inténtalo más tarde",
"Oops! There was an error sending the email, please try later.": "Oops! Ha ocurrido un error, por favor inténtalo más tarde.",
"Email cannot be blank.": "El correo electrónico no puede estar vacío.",
"Get the latest posts delivered right to your inbox.": "Recibe los últimos artículos directamente en tu bandeja de entrada.",
"Stay up to date! Get all the latest & greatest posts delivered straight to your inbox.": "Mantente al día! Recibe todos los mejores y más recientes artículos directamente en tu bandeja de entrada.",
Expand Down
6 changes: 3 additions & 3 deletions partials/newsletter-form.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ You need to enable the members feature first.
</div>
<div class="m-subscribe__success">
<header class="m-heading no-margin">
<h1 class="m-heading__title">{{t "Subscribed!"}}</h1>
<p class="m-heading__description in-subscribe-page">
<img src="{{asset "images/success.png"}}" alt="Success!" class="m-subscribe__success_icon">
<p class="m-heading__description in-newsletter-form">
{{t "Now check your inbox and click the link to confirm your subscription."}}
</p>
</header>
Expand All @@ -25,7 +25,7 @@ You need to enable the members feature first.
{{t "Please enter a valid email address"}}
</p>
<p class="m-subscribe__error m-small-text">
{{t "Oops! There was an error sending the email, please try later"}}
{{t "Oops! There was an error sending the email, please try later."}}
</p>
</form>
</div>
41 changes: 30 additions & 11 deletions src/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 9 additions & 0 deletions src/sass/components/heading/_description.scss
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,13 @@
font-size: 1rem;
}
}

&.in-newsletter-form {
font-size: 0.875rem;
max-width: 80%;

@include respond-to('medium') {
max-width: 420px;
}
}
}
15 changes: 15 additions & 0 deletions src/sass/components/subscribe/_subscribe-section.scss
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,10 @@
.m-subscribe__error {
display: block;
}

.m-subscribe__form {
margin-bottom: 20px;
}
}

.m-subscribe__success,
Expand All @@ -106,3 +110,14 @@
display: none;
}
}

.m-subscribe__success_icon {
display: block;
width: 64px;
height: 64px;
margin: 0 auto 25px;
}

.m-subscribe__error {
text-align: center;
}

0 comments on commit e8deeb1

Please sign in to comment.