discourse-subscriptions/assets/javascripts/discourse/templates/s/show.hbs

51 lines
1.1 KiB
Handlebars

<div class="discourse-subscriptions-section-columns">
<div class="section-column discourse-subscriptions-confirmation-billing">
<h2>
{{model.product.name}}
</h2>
<hr>
<p>
{{html-safe model.product.description}}
</p>
</div>
<div class="section-column">
{{#unless model.product.subscribed}}
<h2>
{{i18n 'discourse_subscriptions.subscribe.card.title'}}
</h2>
<hr>
{{payment-options
plans=model.plans
selectedPlan=selectedPlan
}}
<hr>
{{subscribe-card cardElement=cardElement}}
{{#if loading}}
{{loading-spinner}}
{{else if isAnonymous}}
{{login-required}}
{{else}}
<div class='promo-code'>
{{input type="text" name="promo_code" placeholderKey="discourse_subscriptions.subscribe.promo_code" value=promoCode}}
</div>
{{d-button
disabled=loading
action="stripePaymentHandler"
class="btn btn-primary btn-payment"
label="discourse_subscriptions.plans.payment_button"
}}
{{/if}}
{{/unless}}
</div>
</div>