rastrillo / abono Public

Clone
git clone https://amadan.net/rastrillo/abono

Plain git — no account needed to clone.

Download

Download this file

1{{/* abono/pricing: GET /subscribe, every plan on sale, each a card whose
2 button starts Checkout. When nothing is for sale (Stripe is off, or
3 no plan has a price on sale) it says so instead.
4
5 Data:
6 Title string, the page title's message key
7 Open bool, something is for sale
8 Cards []abonoCard, {Offer, Interval, Action}: one per plan and
9 interval, for the abono-plan-card partial
10 L the request's localizer */}}
11{{define "content"}}{{$L := localizer $}}
12{{if .Open}}
13{{template "page-header" dict "L" $L "Title" (T $L "abono.pages.pricing_title") "Sub" (T $L "abono.pages.pricing_intro")}}
14{{range .Cards}}{{template "abono-plan-card" dict "L" $L "Offer" .Offer "Interval" .Interval "Action" .Action}}
15{{end}}
16{{else}}
17{{template "page-header" dict "L" $L "Title" (T $L "abono.pages.pricing_title")}}
18{{template "empty-state" dict "L" $L "Title" (T $L "abono.pages.closed_title") "Body" (T $L "abono.pages.closed_body")}}
19{{end}}
20{{end}}
21