From 039d89a4a042a8b05ad7190c1310ecd97e2dfb97 Mon Sep 17 00:00:00 2001 From: Sodbileg Gansukh Date: Tue, 4 Oct 2022 17:04:54 +0800 Subject: [PATCH] Added members feature toggle logic --- default.hbs | 49 +++++++++++++++++++++---------------------------- index.hbs | 36 ++++++++++++++++++++---------------- 2 files changed, 41 insertions(+), 44 deletions(-) diff --git a/default.hbs b/default.hbs index 094e27c..32a643a 100644 --- a/default.hbs +++ b/default.hbs @@ -34,46 +34,39 @@
- {{#unless @member}} - - {{> icons/email}} - Subscribe - - {{else}} - Account - {{/unless}} + {{#if @site.members_enabled}} + {{#unless @member}} + + {{> icons/email}} Subscribe + + {{else}} + Account + {{/unless}} + {{/if}}
{{{body}}} - {{^if @member.paid}} + {{#if @site.members_enabled}} + {{#unless @member}}
- {{^if @member}} -

Subscribe to {{@site.title}}

- -
Don’t miss out on the latest issues. Sign up now to get access to the library of members-only issues.
- - -
- {{> icons/email}} - jamie@example.com -
-
Subscribe
-
- {{else}} -

Ready for unlimited access?

- -
Upgrade to a paid account to get full access.
- - Upgrade now - {{/if}} +

Subscribe to {{@site.title}}

+
Don’t miss out on the latest issues. Sign up now to get access to the library of members-only issues.
+ +
+ {{> icons/email}} + jamie@example.com +
+
Subscribe
+
+ {{/unless}} {{/if}}