Skip to content

Commit

Permalink
hide newsletter sign-up form
Browse files Browse the repository at this point in the history
  • Loading branch information
tsubik committed Aug 22, 2024
1 parent 90675d6 commit 0fa461f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
8 changes: 4 additions & 4 deletions pages/newsletter.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,11 +38,11 @@ const Newsletter = ({ url, newsletters, language }) => {
{intl.formatMessage({ id: 'newsletter.showing_results', defaultMessage: 'Showing {count} previous newsletters' }, { count: newsletters.length })}
</h2>

<Link href="/newsletter/sign-up">
{/* <Link href="/newsletter/sign-up">
<a className="card-link c-button -secondary">
{intl.formatMessage({ id: 'newsletter.subscribe_to', defaultMessage: 'Subscribe to our newsletter' })}
</a>
</Link>
</Link> */}
</div>

<div className="newsletter-grid">
Expand All @@ -67,10 +67,10 @@ const Newsletter = ({ url, newsletters, language }) => {
))}
</div>

<div className="newsletter-cta">
{/* <div className="newsletter-cta">
{intl.formatMessage({ id: 'newsletter.want_to_receive', defaultMessage: 'Want to receive the latest updates from the Open Timber Portal?' })}
&nbsp;<Link href="/newsletter/sign-up"><a>{intl.formatMessage({ id: 'newsletter.subscribe_to', defaultMessage: 'Subscribe to our newsletter' })}</a></Link>.
</div>
</div> */}
</div>
</div>
</Layout>
Expand Down
5 changes: 4 additions & 1 deletion pages/newsletter/sign-up.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ const NewsletterSignUp = ({ url }) => {
NewsletterSignUp.propTypes = {
url: PropTypes.shape({}).isRequired,
};
NewsletterSignUp.getInitialProps = ({ url }) => ({ url });
NewsletterSignUp.getInitialProps = ({ url }) => {
return { redirectTo: '/newsletter', redirectPermanent: false };
// return { url };
};

export default NewsletterSignUp;

0 comments on commit 0fa461f

Please sign in to comment.