Piero Sgarbi reacted to
batarjal in Patreon Integration
January 18, 2019
Currently only one active goal will be shown. I'll add a setting to pick the goal for each widget in a future version.
Sorry, about the template. Just paste this one into the goal-template, this should work:
{{if $showWidgetTitle}}<h3 class="ipsWidget_title ipsType_reset">{lang="patreon_current_goal"}</h3>{{endif}}
<div class="patreonGoal">
{{if isset($goal['title']) != '' && $goal['title'] != ''}}
<span class="ipsType_large">{lang="patreon_goal_title" sprintf="$goal['title']"}</span><br>
{{endif}}
<div>
<strong class="ipsType_large">{$goal['completed_percentage']}% complete</strong>
</div>
<div class="ipsProgressBar ipsProgressBar_animated">
<div class='ipsProgressBar_progress' style="width: {$goal['completed_percentage']}%"></div>
</div>
{$goal['description']|raw}
{{if $campaign->getMember('title') == null && $showPledgeButton}}
<div class="ipsType_reset ipsType_center"><a class="ipsButton ipsButton_small ipsButton_important" href="{$campaign->joinUrl()}">{lang="patreon_join"}</a></div>
{{endif}}
</div>