Subscribe page integrated 📬
This commit is contained in:
parent
8d1b05ac79
commit
f893505367
File diff suppressed because one or more lines are too long
14
partials/subscribe_form.hbs
Normal file
14
partials/subscribe_form.hbs
Normal file
|
@ -0,0 +1,14 @@
|
||||||
|
<form method="post" action="{{action}}" id="{{form_id}}" class="{{form_class}}">
|
||||||
|
{{hidden}}
|
||||||
|
|
||||||
|
<fieldset>
|
||||||
|
{{input_email id=input_id class=input_class placeholder=placeholder value=email autofocus=autofocus}}
|
||||||
|
</fieldset>
|
||||||
|
<button id="{{button_id}}" class="{{button_class}}" type="submit">Subscribe</button>
|
||||||
|
|
||||||
|
{{script}}
|
||||||
|
|
||||||
|
{{#if error}}
|
||||||
|
<p class="m-small-text in-subscribe-page">Email cannot be blank.</p>
|
||||||
|
{{/if}}
|
||||||
|
</form>
|
40
subscribe.hbs
Normal file
40
subscribe.hbs
Normal file
|
@ -0,0 +1,40 @@
|
||||||
|
{{!< default}}
|
||||||
|
|
||||||
|
<div class="l-wrapper" data-aos="fade-down">
|
||||||
|
<a href="{{@site.url}}" class="m-back">
|
||||||
|
<span class="m-back__icon icon-arrow-left"></span>
|
||||||
|
<span>Back to home</span>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<main class="l-fullscreen">
|
||||||
|
<section class="l-fullscreen__content in-subscribe-page" data-aos="fade-up" data-aos-delay="300">
|
||||||
|
{{^if success}}
|
||||||
|
<div>
|
||||||
|
<header class="m-heading in-subscribe-page">
|
||||||
|
<h1 class="m-heading__title">Subscribe to {{@site.title}}</h1>
|
||||||
|
<p class="m-heading__description in-subscribe-page">
|
||||||
|
Stay up to date! Get all the latest & greatest posts delivered straight to your inbox.
|
||||||
|
</p>
|
||||||
|
</header>
|
||||||
|
{{subscribe_form
|
||||||
|
form_class="m-subscribe-section__form"
|
||||||
|
input_class="m-input in-subscribe-section"
|
||||||
|
button_class="m-button primary block"
|
||||||
|
placeholder="Your email address"
|
||||||
|
autofocus="true"
|
||||||
|
}}
|
||||||
|
</div>
|
||||||
|
{{else}}
|
||||||
|
<div>
|
||||||
|
<header class="m-heading in-subscribe-page">
|
||||||
|
<h1 class="m-heading__title">Subscribed!</h1>
|
||||||
|
<p class="m-heading__description in-subscribe-page">
|
||||||
|
You've successfully subscribed to <strong>{{@site.title}}</strong> with the email address <strong>{{email}}</strong>
|
||||||
|
</p>
|
||||||
|
</header>
|
||||||
|
<a href="{{@site.url}}" class="m-button outlined">Back to home</a>
|
||||||
|
</div>
|
||||||
|
{{/if}}
|
||||||
|
</section>
|
||||||
|
</main>
|
Loading…
Reference in a new issue